Function: VRFT1_dy_du


 

C = VRFT1_dy_du(u,y,Md,Mu,B,Wd,Wu,lambda,k,optFilt)


Design a 1 d.o.f. linear controller so as to match the d(t) to y(t) output sensitivity with the model reference Md and the d(t) to u(t) input sensitivity with the model reference Mu (see Figure 1).

Figure 1: 1 degree of freedom control scheme.


Inputs (compulsory)

- u: column vector (Nx1) that contains the INPUT data collected from the plant.

- y: matrix (Nx2) that contain the OUTPUT data collected from the plant: y(:,1) contains the output of the plant when it is fed by u; y(:,2) contains the output of the plant when it is fed by y(:,1). If y is a Nx4 matrix, the columns 1 and 2 contains the OUTPUT data collected in the first experiment and the columns 3 and 4 contains the OUTPUT data collected in the second experiments (the noise realizations in the two experiments must be uncorrelated).

- Md: tf-object that represents the discrete transfer function of the reference model. The reference model Md(z) describes the desired closed loop behaviour from the signal d(t) to the output y(t) (output sensitivity).

- Mu: tf-object that represents the discrete trasfer function Mu(z) that describes the desired dynamical relationship from d(t) to u(t) (input sensitivity).

- B: column vector of tf-objects. The linear controller has the following structure: C(z,θ)= B'*θ, where B is a column vector of transfer functions, and θ is the vector of parameters.


Inputs (optional)

- Wd: tf-object of the weighting function Wd(z). If this parameter is empty [], the function automatically sets Wd(z) = 1.

- Wu: tf-object of the weighting function Wu(z). If this parameter is empty [], the function automatically sets Wu(z) = 1.

- lambda: this parameter is used to balance the emphasis on Mr (lambda close to 0) or on Mu (lambda close to 1). Note that 0<=lambda<=1. If this parameter is empty [], the function automatically sets lambda = 0.5.

- k: this parameter must be used only if the measured output y is noisy, and a single experiment is available; in this case this parameter sets the order of an ARX(k,k) model used to make an approximate model of the plant. Otherwise this parameter must be empty: [].

- optFilt: if this parameter is set to 'n', the optimal filter is disabled, and the filter L(z) is set to 1. If this parameter is empty ([]) the function uses the optimal VRFT filter.


Outputs

- C: tf-object, which represents the transfer function of the designed controller.