• No results found

This section will discuss one of the key developments in this research which is a new method of handling bounds and constraints on an SFL system. The main background has already been given on this area in section 2.12.3. It was discussed how Kurtz and Henson (1996, 1998) introduced the methods for constant constraints technique (CCT) and variable constraint technique (VCT) which were later adopted and improved by others. The main drawback which can be explained further now is the uncertainty in the constraints beyond the horizon. The SFL model as shown in Equation 4-48 is again shown here:

𝝃(π‘˜ + 1) = 𝐴𝑑𝝃(π‘˜) + 𝐡𝑑𝒗(π‘˜)

π’š(π‘˜) = 𝐢𝑑𝝃(π‘˜) Equation 4-48

126 𝝃 = [𝑦,𝑑𝑦 𝑑𝑑, 𝑑2𝑦 𝑑𝑑2, … , π‘‘π‘Ÿπ‘¦ π‘‘π‘‘π‘Ÿ] Equation 4-59

The model is formed of SFL tuning parameters and the derivatives of the outputs. Other than the plant output 𝑦, there is no other information from the plant in the SFL model, but there is in the control law (Kravaris and Chung, 1987):

𝑒 =𝑣 βˆ’ βˆ‘ π›½π‘˜πΏπ‘“ π‘˜β„Ž(π‘₯) π‘Ÿ π‘˜=0 π›½π‘ŸπΏπ‘”πΏπ‘“π‘Ÿβˆ’1β„Ž(π‘₯) = 𝑣 βˆ’ 𝛽0β„Ž(π‘₯) βˆ’ 𝛽1πΏπ‘“β„Ž(π‘₯) 𝛽1πΏπ‘”β„Ž(π‘₯) Equation 4-60

Therefore, the main method for constraints handling has leveraged the inverse of the control law to use the plant input and states and determine the inputs on the MPC input 𝑣 through transformation. However, the plant states are measured variables and time-varying, so the Lie derivatives are also time-varying, thus even if the bounds or constraints on 𝑒 are fixed, it does not result in a fixed set of bounds or constraints for 𝑣 (Kurtz and Henson, 1998). In the CCT technique, the strategy is to use the current measured states of the plant and use the control law to transform the constraints on 𝑒 to 𝑣 using the current measurement, and apply it over the whole horizon. This guarantees that the constraints on the first input in the horizon is always valid, because it is obtained using the current plant state, but the future states which are not known will likely be different and therefore the horizon constraints may be unreliable. In contrast, the VCT technique uses an alternative approach where the inputs from the last sampling time are used to calculate the constraints at the current sampling time by propagating the inputs and current measured states through the control law to determine the values of 𝑒, and then performing an optimization to obtain the constraints of 𝑣 using the constraint on 𝑒.

The CCT and VCT techniques both guarantee the first input in the horizon will be feasible, and because that is the only input in an MPC that is implemented, the techniques enable the use of model-based control on a process, even though the constraints applied beyond the first value of the horizon are likely to be unreliable. One important statement from Kurtz and Henson (1997) is that the VCT technique could be achieved through an iterative and nonlinear program, but this approach would not be computationally efficient. However, recent developments show that iterative approaches are now more usable than at the time of the

127

original writing because of the advances in computational efficiency. This has led to the use of artificial neural networks (ANNs) to map nonlinear constraints in single input and multiple- input SFL (Deng et al. 2009), and more recently by Schnelle and Eberhard (2015) the use of iterative techniques to calculate the constraints using state estimators and future state predictions (Chang and Chen, 2014). There is a possibility of using an iterative approach with the SQP algorithm (Boggs and Tolle, 1995), with two important features of the SQP being the ability to apply a nonlinear constraints function which can be supplied with parameters beyond the traditional states and inputs in traditional optimization, but also can be initialised at an infeasible point and can iteratively find a feasible route to an optimal solution. The importance of these is that the SQP algorithm can be supplied with any set of 𝑣 regardless of whether the initial vector is feasible. Moreover, the nonlinear constraints function does not need to be used to constrain 𝑣, but can be supplied with the values of 𝑣 from the optimizer, and have an iterative routine which incorporates the nonlinear plant, current states 𝒙 and MPC inputs 𝒗 to calculate the future plant inputs 𝒖 using the control law, and therefore constrain the plant states and plant inputs directly. The iterative routine is shown in Figure 4- 11 The output of the function is the feasibility of the solution, so the structure for the SFL MPC scheme with SFL-Plant constraints appears as shown in Figure 4-12, and this scheme is structurally similar to that which was provided by Schnelle and Eberhard (2015)

Figure 4-11 – Iterative Routine for Constraints handling using Nonlinear Plant

1. Optimizer creates a set of 𝒗

a. Constraints handling function is supplied with: i. The set 𝒗(π‘˜, π‘˜ + 𝑁𝑐)

ii. 𝒙(π‘˜) from the nonlinear plant

b. Calculates 𝑒(π‘˜) using control law and 𝒗(π‘˜) and 𝒙(π‘˜) c. Uses 𝑒(π‘˜) to calculate 𝒙(π‘˜ + 1) at the next time step

d. Iterates through steps 2 and 3 until 𝑣(π‘˜ + 𝑁𝑐) by which point: i. π‘₯(π‘˜) to π‘₯(π‘˜ + 𝑁𝑐) are calculated

ii. 𝑒(π‘˜) to 𝑒(π‘˜ + 𝑁𝑐) are calculated

e. Checks all 𝒙 and 𝒖 for feasibility against constraints on 𝒙 and 𝒖 respectively and returns feasibility to optimizer

128

Figure 4-12 – SFL-MPC Scheme with SFL-Plant Constraints

This strategy for constraint handling will be referred to as SFL-Plant constraints, so named because the SFL model and the plant model are combined to calculate the plant inputs and states and determine the feasibility of the MPC input over the whole horizon. The optimization cost function will also be modified now to represent the SFL-Plant constraints. Traditional optimisation problems with constraint handling often appear in a form where the inputs and states are subject to the constraints.

max

π‘₯,𝑒 𝑓(π‘₯)

𝑠𝑒𝑏𝑗𝑒𝑐𝑑 π‘‘π‘œ: 𝑔(π‘₯, 𝑒) β‰₯ 0 β„Ž(π‘₯, 𝑒) = 0

Equation 4-61

In the objective function in Equation 4-61 the inequality function 𝑔(π‘₯) and the equality function β„Ž(π‘₯) can either be explicit linear constraints on the values of π‘₯ and 𝑒 or they can be some nonlinear function of π‘₯ and 𝑒. This is the traditional method of constraints handling. Applying this same objective function to the SFL would yield the following:

129 max 𝑣 𝑦 𝑠𝑒𝑏𝑗𝑒𝑐𝑑 π‘‘π‘œ: 𝑔(πœ‰, 𝑣) β‰₯ 0 β„Ž(πœ‰, 𝑣) = 0 Equation 4-62

With the new SFL-Plant constraints, the new optimization function with constraints changes to the following form:

max 𝑣 𝑦 𝑠𝑒𝑏𝑗𝑒𝑐𝑑 π‘‘π‘œ: π‘˜(π‘₯, 𝑒) β‰₯ 0 𝑙(π‘₯, 𝑒) = 0 π‘₯Μ‡ = 𝑓(π‘₯) + 𝑔(π‘₯)𝑒 𝑦 = β„Ž(π‘₯) Equation 4-63

There is a drawback to this method in that each step in the optimization now has an iterative nonlinear programming strategy to calculate the feasibility of the MPC input with plant inputs and constraints, which adds to the computational effort for control. However, for the ability to determine an accurate horizon and apply real constraints to a crystallization control, as intended by MPC, this extra computation is an acceptable trade-off because it makes possible the ability to find feasible control solutions which are paramount to a successful control strategy. Furthermore, the prediction and control horizons which were previously 5 samples have been increased to 10 (10 minutes using a time step of 1 minute) because in preliminary tests at the shorter horizon length a solution was found in a very short time for each instant the MPC was invoked. The increase in horizon length resulted in slightly longer time to converge a solution but not to the detriment of the controller, it could still be applied in real- time, but also it was possible to gain a better trajectory of the prediction horizon in simulation. This constraints method and implementation appears to be unique at time of writing and thus will be assessed to see if it is a reliable method of constraint handling for SFL applications on crystallization.