Salta al contenuto
Note per Studenti System Identification - Estimation Problem and Parametric Model Classes Report

System Identification - Estimation Problem and Parametric Model Classes

In questa pagina 3

The estimation problem

Idea. We want to reconstruct a function g:X→Y=Rpg:X\to Y=\mathbb R^p from a collection of samples (s,y)∈X×Y(s,y)\in X\times Y, assuming that y=g(s)+e,y=g(s)+e, where ee is a disturbance (noise). The reconstruction g^\hat g should ideally be "similar" to gg.

Example. g:R→Rg:\mathbb R\to\mathbb R with the two samples (0,0)(0,0) and (1,1)(1,1). One may choose g^(s)={0s=01s=1∗s≠0, s≠1\hat g(s)=\begin{cases}0&s=0\\1&s=1\\ *&s\ne0,\ s\ne1\end{cases} where ∗* is arbitrary.

Problem. The reconstruction of gg (g^\hat g) is an ill-posed problem: there are "too many" choices for g^\hat g.

Making the problem well posed. We choose a parametric class M(θ)\mathcal M(\theta) with θ∈Θ⊆Rn\theta\in\Theta\subseteq\mathbb R^n and require g^∈M(θ)\hat g\in\mathcal M(\theta). For g:R→Rg:\mathbb R\to\mathbb R: M1(θ): g^(s;θ)=θ1+θ2s,M2(θ): g^(s;θ)=θ1+θ2s+θ3s2.\mathcal M_1(\theta):\ \hat g(s;\theta)=\theta_1+\theta_2s,\qquad\mathcal M_2(\theta):\ \hat g(s;\theta)=\theta_1+\theta_2s+\theta_3s^2.

Goal of estimation. Find g^∈M(θ)\hat g\in\mathcal M(\theta) such that it generalises to points which are not in the dataset, i.e. g^(s)≈g(s)\hat g(s)\approx g(s) for points (s,g(s))(s,g(s)) which are not among the samples.

In the "real world" formulation (same assumption y=g(x)+ey=g(x)+e): we observe (x,y)(x,y); g^≈g\hat g\approx g means that g^\hat g maps the samples in XX to g(x)g(x) (up to an approximation error) and that it generalises, i.e. g^(x)≈g(x)\hat g(x)\approx g(x) even for points x∈Xx\in X which we do not observe. To make the problem tractable we choose a model class M(θ)\mathcal M(\theta) and then select θ∈Rm\theta\in\mathbb R^m such that g^(x;θ)≈g(x)\hat g(x;\theta)\approx g(x).

Dynamical systems: gray box and black box

For a dynamical system x˙(t)=f(x(t),u(t)),y(t)=h(x(t),u(t)),\dot x(t)=f\big(x(t),u(t)\big),\qquad y(t)=h\big(x(t),u(t)\big), the functions ff and hh are unknown (either gray box or black box). The data are S=(x(0),u,ti)S=\big(x(0),u,t_i\big) and the measured y(ti)y(t_i) (physical measurements).

  • Gray box: estimate the unknown or uncertain (physical) parameters of a model whose structure is known.
  • Black box: choose a model class M(θ)\mathcal M(\theta) and estimate θ\theta. Examples: M1(θ): {x˙(t)=θ1x(t)+θ2u(t)y(t)=θ3x(t)+θ4u(t) θ∈R4,M2(θ): {x˙(t)=θ1x(t)+θ2cos⁡(x(t))+θ3u(t)y(t)=θ4x(t)+θ5u(t) θ∈R5.\mathcal M_1(\theta):\ \begin{cases}\dot x(t)=\theta_1x(t)+\theta_2u(t)\\y(t)=\theta_3x(t)+\theta_4u(t)\end{cases}\ \theta\in\mathbb R^4,\qquad\mathcal M_2(\theta):\ \begin{cases}\dot x(t)=\theta_1x(t)+\theta_2\cos\big(x(t)\big)+\theta_3u(t)\\y(t)=\theta_4x(t)+\theta_5u(t)\end{cases}\ \theta\in\mathbb R^5.

System identification means: choose M(θ)\mathcal M(\theta) and optimise θ\theta. The goal is to predict the future outputs y(t)y(t).

Before estimating one asks whether θ\theta can be recovered at all: see A Priori Identifiability of Parametric ModelsA parametric model is identifiable a priori if its parameters can be recovered from observational parameters computed from the noise-free continuous output to an impulse input; for linear time-invariant SISO systems these are the transfer function coefficients, shown on a two-state example.A Priori Identifiability of Parametric Models →.

Statistics, estimators, estimates

Definition (statistic). A statistic is a measurable function of yy that does not depend on θ\theta, such that it maps Y→Rm⊇ΘY\to\mathbb R^m\supseteq\Theta.

Examples. For a sample {yi}i=1n\{y_i\}_{i=1}^n with y∼(μ,σ2)y\sim(\mu,\sigma^2): yˉn=1n∑i=1nyi  (sample mean),Sn2=1n∑i=1n(yi−μ)2,Tn2=1n∑i=1n(yi−yˉ)2.\bar y_n=\frac1n\sum_{i=1}^ny_i\ \ (\text{sample mean}),\qquad S_n^2=\frac1n\sum_{i=1}^n(y_i-\mu)^2,\qquad T_n^2=\frac1n\sum_{i=1}^n(y_i-\bar y)^2. (Only yˉn\bar y_n and Tn2T_n^2 are computed from the data alone; Sn2S_n^2 contains the unknown mean μ\mu.)

Definition (estimator). An estimator is a statistic of yy with values in Θ\Theta, denoted θ^(y)\hat\theta(y) or θ^\hat\theta. For instance the sample mean yˉ\bar y is an estimator of the mean μ\mu; we use an estimator to estimate a "good" value of θ\theta.

Definition (estimate). An estimate is the value assumed by an estimator for some observations of yy.

The estimators studied next: Least Squares Estimation - Linear and Weighted Least SquaresThe least squares estimator minimises the sum of squared deviations between observed and predicted outputs; for models linear in the parameters it has a closed form given by the normal equation, extended to weighted least squares and illustrated on a straight-line fit and on a DC motor.Least Squares Estimation - Linear and Weighted Least Squares → and Maximum Likelihood Estimation - OverviewMaximum likelihood estimation starts from a probability model of the noise, turns it into the likelihood of the parameters given the data, and chooses the parameters that maximise it, instead of only minimising a weighted squared error.Maximum Likelihood Estimation - Overview →.

Versione ripasso

  • Goal: reconstruct g:X→Rpg:X\to\mathbb R^p from samples y=g(s)+ey=g(s)+e. Ill posed (too many choices), so pick a parametric class M(θ)\mathcal M(\theta), θ∈Θ⊆Rn\theta\in\Theta\subseteq\mathbb R^n (e.g. θ1+θ2s\theta_1+\theta_2s or θ1+θ2s+θ3s2\theta_1+\theta_2s+\theta_3s^2) and require g^∈M(θ)\hat g\in\mathcal M(\theta).
  • Aim: generalise, g^(s)≈g(s)\hat g(s)\approx g(s) also at points not in the dataset.
  • Dynamical systems x˙=f(x,u)\dot x=f(x,u), y=h(x,u)y=h(x,u) with unknown f,hf,h: gray box = estimate unknown physical parameters; black box = choose M(θ)\mathcal M(\theta) and estimate θ\theta. Goal of system identification: predict future outputs y(t)y(t).
  • Statistic: measurable function of yy not depending on θ\theta (sample mean yˉn\bar y_n; Tn2T_n^2 with yˉ\bar y). Estimator θ^(y)\hat\theta(y): statistic with values in Θ\Theta. Estimate: value of the estimator for given observations.

Teoria collegata