Lecture Notes - MIT - System Identification
Lecture Notes - MIT - System Identification
6.435
SET 12
Identification in Practice Error Filtering Order Estimation Model Structure Validation Examples
Munther A. Dahleh
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 1
Practical Identification
Given: Want 1) 2) 3) a model for the plant a model for the noise an estimate of the accuracy
flexibility
parsimony
Lecture 12
What do we know? We know methods for identifying models inside a priori given model structures. How can we use this knowledge to provide a model for the plant, the process noise, with reasonable accuracy.
Lecture 12
Considerations
Pre-treatment of data Remove the biase (may not be due to inputs) Filter the high frequency noise Outliers Introduce filtered errors. Emphasize certain frequency range. (The filter depends on the criterion).
Lecture 12
Pick a model structure (or model structures) Which one is better? How can you decide which one reflects the real system? Is there any advantage from picking a model with a large number of parameters, if the input is exciting only a smaller number of frequency points? What are the important quantities that can be computed directly from the data (inputs & outputs), that are important to identification?
Lecture 12
Pre-treatment of Data
Removing the biase
If input
Lecture 12
New Data:
Method II: Model the offset by an unknown constant and estimate it.
Lecture 12
High Frequency disturbances in the data record. High means above the frequency of interest. Related to the choice of the sampling period.
sampler
Lecture 12
Wanti-alias
Sample
high frequency noise depends on: a) high frequency noise due to b) aliasing. Problem occurs at both the inputs and outputs.
L LTI LP filter.
equivalently i.e. multiply the noise filter by Outliers, Bursts Either erroneous or high-disturbed data point. Could have a very bad effect on the estimate. Solution: a) Good choice of a criterion (Robust to changes) b) Observe the residual spectrum. Sometimes it is possible to determine bad data. c) Remove by hand!!! Messing up with real data. d) Failure-detection using hypothesis testing or statistical methods. (Need to define a threshold).
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 10
Lecture 12
11
If
Lecture 12
12
Heuristically, is chosen as a compromise between minimizing the integral of and matching the error spectrum Input spectrum Noise spectrum With a pre-filter: Can view the pre-filters as weighting functions to emphasize certain frequency ranges. This interpretation may not coincide with getting rid of high frequency components of the data. Depending on the criterion, the choice of L can be different.
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 13
weighting function
OE Model Structures
If
much better at
low-frequency.
Lecture 12
14
Example (book)
No noise. PSRB
OE:
Lecture 12
15
Good match at low frequency. Not as good at high frequency. Introduce a high-pass filter (5th order Butterworth filter, cut-off freq = 0.5 rad/sec.
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 16
Lecture 12
17
Lecture 12
18
If rolls off, and is large at high frequency. If looks like , then it will emphasize the high frequency part of the criterion. Conclusions are not as transparent in the noisy case. However, it is in general true for large (SNR). Same example and the frequency response of
Lecture 12
is:
19
Not a very good match at low frequency. Better than OE at high frequency. Can change this through a pre-filter. (5th order Butterworth, lowpass with cut-off frequency = 0.5)
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 20
Lecture 12
21
Lecture 12
22
Conclusions
Pre filters can be viewed as design parameters as well as the standard interpretation for noise reduction. Pre-treatment of the data is quite valuable, however should be done with care. Sampling can be quite tricky. Need to estimate the bandwidth of the system.
Lecture 12
23
Theme: Fit the data with the least complex model structure. Avoid over-fitting which amounts to fitting noise. Better to compare similar model structures, although it is necessary to compare different structures at the end.
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 24
Available data dictates the possible model structures and their dimensions. Can noise help identify the parameters? How bad is the effect of noise? Consistency in general is guaranteed for any SNR. What does that mean? Is there a rigorous way of comparing different model structures?
min prediction
model structure
Akaikes Information Theoretic Criterion (AIC). Akaikes final prediction error critierion (FPE).
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 25
Order Estimation
Qualitative Spectral estimate Step response if available. Otherwise, step response of spectral estimate. Quantitative Covariance matrices Information matrix Residual-input correlation Residual whiteness All methods are limited by the input used.
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 26
Covariance Matrix
Lecture 12
27
Case 1: u is
WN, v is WN
is singular.
Increase s until
Use SVD, robust rank tests. , observe a sudden drop in the rank. Case 2: u is p.e of order If , Noise is white. is singular.
you really cannot estimate the order of the system if it is larger than .
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 28
. Of course N is fixed
Lecture 12
29
test:
rank
non singular
Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 30
Examples
unknown. Study possible conclusions for different experiments and different SNR. Model structure
Inputs
WN
Can determine from the spectrum or u (or simply FFT).
Lecture 12
31
SNR:
All examples, you can access both the inputs and outputs.
Lecture 12
32
First Experiment
From data
Lecture 12
33
Estimated system
small
(ARX)
Comment: If m is the correct structure estimates of the parameters. Plot shows different SNR.
Lecture 12
34
Second Experiment
u is p.e of order 2.
1 0.1 0.01
Lecture 12
37
regardless of the estimates were quite bad for comparison to WN inputs. Even though noise helps in obtaining asymptotic convergence (through providing excitation), it is not helpful for finite-data records, since its effect cannot be averaged. Accuracy depends on in
Lecture 12
38
Lecture 12
39
=1 =1 =0 =0
Lecture 12
40
Third Experiment
u is p.e of order 4.
1 0.1 0.01
Lecture 12
41
Theoretical Analysis:
Data is informative w. r. to
Results for
Lecture 12
42
Lecture 12
43
ARX (of an ARX plant) Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 44
SNR = 1
ARX (of an ARX plant) Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 45
SNR = 0.01
ARX (of an ARX plant) Lecture 12 6.435, System Identification Prof. Munther A. Dahleh 46
Conclusions
Accuracy of estimates depend on If ARX, Estimate of accuracy Large is large. is singular. is large.
u is not rich
is large.
47
Lecture 12
48
by a small
Lecture 12
49
Lecture 12
50
Lecture 12
51
is by
Lecture 12
52
Proof: expand
around
also
Notice:
Lecture 12
53
and
Lecture 12
54
Lecture 12
55
Lecture 12
56
Example
Assume that the innovations unknown variance. are Gaussian with
Lecture 12
57
Approximately minimize
Lecture 12
58
Lecture 12
59
estimate of
(FPE)
Lecture 12
60
Example 2
is unknown. 3 experiments
Lecture 12
61
Experiment 1
u = rand sequence
Lecture 12
62
Estimated parameters
ARX OE
-1.4 -1.4
0.49 0.49
1 1
0.5 0.5
0 0
AIC or FPE
Lecture 12
Experiment 2
u is p.e of order 2
ARX: OE:
Lecture 12
64
Structure
(1, 1, 1) (2, 2, 1) (3, 3, 1)
ARX Parameters
(-0.8627, 2.3182) (-1.4, 0.49, 1, 0.5) (- * * * * ) ( 0.034) 0 170
OE Parameters
(-0.85, 2.51) (-1.4, 0.49, 1, 0.5) ( * * * * ) 0.214 0 0.3317
Loss of identifiability.
Clearly
Lecture 12
65
Experiment 3
Structure
(2 2 1) (3 3 1)
ARX Parameters
(-1.4004, 0.4903, 0.98, 0.51) singular 3.4x10-5
OE Parameters
(-1.40, 0.49, 0.95, 0.54) singular 9.2x10-6
OE model is preferred.
Lecture 12
66
Structure
(2 2 1) (3 3 1)
ARX Parameters
(-1.4, 0.49, 1.0031, 0.4944) ( * * * ) 1.6x10-5 1.3x10-5
OE Parameters
(1.399, 0.489, 0.99, 0.50) ( * * * ) 1.3x10-5 4.2x10-5 Num. errors
{In fact
Lecture 12
67
Validation
Use different sets of data to validate the model structure and the estimated model. You can obtain different estimates using the data and then average them. OR you can construct new input-output pairs and re-estimate.
Lecture 12
68
Conclusions
Criterion contains a penalty function for the dimension of the system. AIC is one way of doing that. (FPE) is an estimate of the AIC with a quadratic objective. AIC has connections with information theory observation assumed PDF true Entropy of PDF
w. r. to
Lecture 12
69