650 likes | 827 Views
SYSTEMS Identification. Ali Karimpour Assistant Professor Ferdowsi University of Mashhad. Reference: “System Identification Theory For The User” Lennart Ljung. Lecture 11. Recursive estimation methods. Topics to be covered include : Introduction. The Recursive Least-Squares Algorithm.
E N D
SYSTEMSIdentification Ali Karimpour Assistant Professor Ferdowsi University of Mashhad Reference: “System Identification Theory For The User” Lennart Ljung
Lecture 11 Recursive estimation methods Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
Introduction Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
Adaptive Introduction In many cases it is necessary, or useful, to have a model of the system available on-line. The need for such an on-line model is required in order to: • Which input should be applied at the next sampling instant? • How should the parameters of a matched filter be tuned? • What are the best predictions of the next few output? • Has a failure occurred and, if so, of what type? Adaptive control, adaptive filtering, adaptive signal processing, adaptive prediction.
Introduction The on-line computation of the model must completed during one sampling interval. Identification techniques that comply with this requirement will be called: • Recursive identification methods. • Recursive identification methods. Used in this Reference. • On-line identification. • Real-time identification. • Adaptive parameter estimation. • Sequential parameter estimation.
Minimizing argument of some function or… General identification method: Information state Introduction Algorithm format This form cannot be used in a recursive algorithm, since it cannot be completed in one sampling instant. Instead following recursive algorithm must comply: Since the information in the latest pair of measurement { y(t) , u(t) } normally is small compared to the pervious information so there is a more suitable form Small numbers reflecting the relative information value in the latest measurement.
The Recursive Least-Squares Algorithm Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
The Recursive Least-Squares Algorithm Weighted LS Criterion The estimate for the weighted least squares is: Where
The Recursive Least-Squares Algorithm Recursive algorithm Suppose the weighting sequence has the following property: Now
The Recursive Least-Squares Algorithm Recursive algorithm Suppose the weighting sequence has the following property:
The Recursive Least-Squares Algorithm Recursive algorithm Version with Efficient Matrix Inversion To avoid inverting at each step, let introduce Remember matrix inversion lemma
The Recursive Least-Squares Algorithm Version with Efficient Matrix Inversion Moreover we have We can summarize this version of algorithm as:
The size of the matrix R(t) will depend on the λ(t) The Recursive Least-Squares Algorithm Normalized Gain Version
The Recursive Least-Squares Algorithm Initial Condition A possibility could be to initialize only at a time instant t0 By LS method Clearly if P0is large or t is large, then above estimate is the same as:
The Recursive Least-Squares Algorithm Asymptotic Properties of the Estimate
The Recursive Least-Squares Algorithm Multivariable case Remember SISO Now for MIMO
Kalman Filter The Recursive Least-Squares Algorithm Kalman Filter Interpretation The Kalman Filter for estimating the state of system The linear regression model can be cast to above form as: Now, let Exercise: Derive the Kalman filter for above mention system, and show that it is exactly same as the Recursive Least-Squares Algorithmfor multivariable case.
The Recursive Least-Squares Algorithm Kalman Filter Interpretation Kalman filter interpretation gives important information, as well as some practical hints:
The Recursive Least-Squares Algorithm Coping with Time-varying Systems An important reason for using adaptive methods and recursive identification in practice is: • The properties of the system may be time varying. • We want the identification algorithm to track the variation. This is handled by weighted criterion, by assigning less weight to older measurements
The Recursive Least-Squares Algorithm Coping with Time-varying Systems These choices have the natural effect that in the recursive algorithms the step size will not decrease to zero.
The Recursive Least-Squares Algorithm Coping with Time-varying Systems Another and more formal alternative to deal with time-varying parameters is that the true parameters varies like a random walk so Exercise: Derive the Kalman filter for above mention system, and show that it is exactly same as the Recursive Least-Squares Algorithmfor multivariable case. Note: The additive term R1(t) in P(t) prevents the gain L(t) from tending to zero.
The Recursive IV Method Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
Remember Weighted LS Criterion: Where The Recursive IV Method The IV estimate for instrumental variable method is:
The Recursive IV Method The IV estimate for instrumental variable method is:
Recursive Prediction-Error Methods Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
so we have the gradient with respect to θis Recursive Prediction-Error Methods Analogous to the weighted LS case, let us consider a weighted quadratic prediction-error criterion Where
Recursive Prediction-Error Methods Analogous to the weighted LS case, let us consider a weighted quadratic prediction-error criterion Remember the general search algorithm developed for PEM as: For each iteration i, we collect one more data point, so now define As an approximation let:
Recursive Prediction-Error Methods Analogous to the weighted LS case, let us consider a weighted quadratic prediction-error criterion As an approximation let: With above approximation and taking μ(t)=1, we thus arrive at the algorithm: This terms must be recursive too.
This terms must be recursive too. Recursive Prediction-Error Methods
This terms must be recursive too. Recursive Prediction-Error Methods
This terms must be recursive too. Recursive Prediction-Error Methods
Recursive Prediction-Error Methods Family of recursive prediction error methods • According to the model structure Wide family of methods • According to the choice of R We shall call “RPEM” For example, the linear regression This is recursive least square method If we consider R(t)=I Where the gain could be normalized so This scheme has been widely used, under the name least mean squares (LMS)
By rule 11.41 Recursive Prediction-Error Methods Example 11.1 Recursive Maximum Likelihood Consider ARMAX model where and Remember chapter 10 This scheme is known as recursive maximum likelihood (RML)
The model structure is well defined only for giving stable predictors. Recursive Prediction-Error Methods Projection into DM In off-line minimization this must be kept in mind as a constraint. The same is true for the recursive minimization.
Recursive Prediction-Error Methods Asymptotic Properties The recursive prediction-error method is designed to make updates of θ in a direction that “on the average” is modified negative gradient of i.e.
It can be shown that has an asymptotic normal distribution, which coincides with that of the corresponding off-line estimate. We thus have Recursive Prediction-Error Methods Asymptotic Properties Moreover (see appendix 11a), for Gauss-Newton RPEM, with
Recursive Pseudolinear Regressions Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
Recursive Pseudolinear Regressions Consider the pseudo linear representation of the prediction And recall that this model structure contains, among other models, the general linear SISO model: A bootstrap method for estimating θwas given by (Chapter 10, 10.64) By Newton - Raphson method
Recursive Pseudolinear Regressions By Newton - Raphson method
Recursive Pseudolinear Regressions Family of RPLRs The RPLR scheme represents a family of well-known algorithms when applied to different special cases of The RPLR scheme represents a family of well-known algorithms when applied to different special cases of The ARMAX case is perhaps the best known of this. If we choose This scheme is known as extended least squares (ELS). Other special cases are displayed in following table:
Recursive Pseudolinear Regressions Other special cases are displayed in following table:
The Choice of Updating Step Topics to be covered include: • Introduction. • The Recursive Least-Squares Algorithm. • The Recursive IV Method. • Recursive Prediction-Error Methods. • Recursive Pseudolinear Regressions. • The Choice of Updating Step. • Implementation.
The Choice of Updating Step Recursive Prediction-Error Methods is based prediction error approach: Recursive Pseudolinear Regressions is based on correlation approach:
Now we are going to speak about that modifies the update direction and determines the length of the update step. The Choice of Updating Step Recursive Prediction-Error Methods (RPEM) Recursive Pseudolinear Regressions (RPLR) The difference between prediction error approach and correlation approach is: We just speak about RPEM, RPLR is the same just one must change
The Choice of Updating Step Update direction There are two basic choices of update directions: Better convergence rate Easier computation
The Choice of Updating Step Update Step: Adaptation gain An important aspect of recursive algorithm is, their ability to cope with time varing systems. There are two different ways of achieving this
The Choice of Updating Step Update Step: Adaptation gain In either case, the choice of update step is a trade-off between • Tracking ability • Noise sensitivity A high gain means that the algorithm is alert in tracking parameter changes but at the same time sensitive to disturbance in data.
The Choice of Updating Step Choice of forgetting factor The choice of forgetting profile β(t,k) is conceptually simple. For a system that changes gradually and in a stationary manner the most common choice is: The constantλ is always chosen slightly less than 1 so This means that measurements that are older than T0 samples are included in the criterion with a weight e-1≈0.36% of the most recent measurement. So T0 is the memory time constant. So we could select λsuch that 1/(1-λ) reflects the ratio between the time constant of variations in the dynamics and those of the dynamics itself. Typical choices of λ are in the range between 0.98 and 0.995. For a system that undergoes sudden changes, rather than steady and slow ones, it is suitable to decrease λ(t) to a small value and then increase it to a value close to 1 again.