System Identification Toolbox

Estimation of Hammerstein-Wiener Nonlinear Structures

Here we give a very brief “cheat sheet” type explanation of how you estimate Hammerstein–Wiener block non-linear models of the form

 y_t = Z(z_t) + H(q,theta)e_t, quad z_t = G(q,theta)x_t,quad x_t = X(u_t)

where Z(cdot), X(cdot) are memoryless mappings that are possibly non-linear, and which can be represented diagramatically as:

The linear transfer function component is of the form

 G(q,theta) = q^{-k}frac{B(q,theta)}{A(q,theta)},quad H(q,theta) = frac{C(q,theta)}{D(q,theta)}

with

 A(q,theta) = 1+a_1q^{-1}+a_2q^{-2}+cdots+a_{n_a}q^{-n_a},qquad B(q,theta) = b_0+b_1q^{-1}+b_2q^{-2}+cdots+b_{n_b}q^{-n_b}
 D(q,theta) = 1+d_1q^{-1}+d_2q^{-2}+cdots+d_{n_d}q^{-n_d},qquad C(q,theta) = 1+c_1q^{-1}+c_2q^{-2}+cdots+c_{n_c}q^{-n_c}.

Four classes of memoryless mappings Z(cdot), X(cdot) are supported. If the sub-component of theta containing the description of Xcdot,eta) is labeled eta, then the memory-less functions supported by the toolbox (which are identical to the supported Z(cdot,eta) functions) may be described as follows.

Polynomial

 X(u_t,eta) = eta_1 u_t + eta_2 u_t^2 +cdots+ eta_ell u_t^{ell}

Saturation

 X(u_t,eta) = left{ begin{array}{cl} eta_3 u_t& ; u_t in [eta_1,eta_2]  eta_2eta_3 & ; u_t > eta_2 eta_1eta_3 & ; u_t < eta_1 end{array} right.

Deadzone

 X(u_t,eta) = left{ begin{array}{cl} u_t-eta_2& ; u_t > eta_2  u_t-eta_1 & ; u_t < eta_1 0 & ; u_t in [eta_1,eta_2] end{array} right.

Piecewise Linear (Hinging Hyperplane)

This non-linearity is described by a set of ‘‘hinge’’ functions of the form

 X_k(u_t,eta_k) = left{ begin{array}{cl} eta_{1,k} + eta_{2,k}u_t & ; u_t > -eta_{1,k}/eta_{2,k}  0 &; mbox{Otherwise} end{array} right.

which are zero up to a ‘‘breakpoint’’, and linear thereafter. The overall piecewise linear function is then the superposition of (say tau of) these hinges:

 X(u_t,eta) = eta_0 + eta_1 u_t + sum_{k=1}^tau X_k(u_t,eta_k).

First Fundamentals

Estimation of models via the command line involves executing the command

z = est(z,m,opt);

Here z specifies the data, m specifies the model structure, and opt determines optional aspects of how the estimate g is obtained. Because it is optional, it is not strictly necessary to use it, so g=est(z,m) is perfectly legal.

Example data

In order to try this command out on various transfer function model structures, we suggest you generate some test data. For example

u     = randn(1,1000);                     % Random white noise input
den   = poly([0.9,0.4]);                   % Linear transfer function part
num   = [1,0.7];
X     = dzone(u,-0.2,0.3);                 % Apply deadzone non-linearity to  input
Z     = filter(num,den,X);                 % Simulate the linear part
y     = sat(Z(:),-0.4,0.2,1);              % Apply saturation non-linearity to output
y     = y + 0.01*randn(size(y));           % Add some measurement noise to make it interesting

Specifying the model structure

The linear component is specified as per the case with no non-linearities. That is, it is done is by specifying the model orders. In the toolbox, these correspond to n_a= m.A, n_b= m.B, n_c= m.C, n_d= m.D, k =m.delay. Unspecified orders are replaced with default values.

The non-linear component is determined according to what the stringe m.in.type and m.out.type are set to as follows

Nonlinearity m.in.type
Polynomial m.in.type='poly’
Deadzone m.in.type='deadzone’
Saturation m.in.type='saturation’
Piece-wise linear m.in.type='hinge’

How to estimate various common structure types

Estimate Hammerstein-Wiener Model knowing correct non-linear structures
z.y=y; z.u=u;               % Specify the input-output data
m.A=2;                      % Specify 2nd order output error model for linear component
m.type='oe';
m.in.type   = 'deadzone';   % Specify input non-linearity is deadzone
m.out.type  = 'saturation'; % Specify ouput non-linearity is saturation

g=est(z,m);                 % Do the estimation
details(g);                 % Present the results
Estimate Hammerstein-Wiener Model using piecewise linear representation on outut
z.y=y; z.u=u;               % Specify the input-output data
m.A=2;                      % Specify 2nd order output error model for linear component
m.type='oe';
m.in.type   = 'deadzone';   % Specify input non-linearity is deadzone
m.out.type  = 'hinge';      % Specify ouput non-linearity is saturation

g=est(z,m);                 % Do the estimation
details(g);                 % Present the results
Estimate Hammerstein-Wiener Model using polynomial representation on input
z.y=y; z.u=u;               % Specify the input-output data
m.A=2;                      % Specify 2nd order output error model for linear component
m.type='oe';
m.in.type   = 'poly';       % Specify input non-linearity is deadzone
m.out.type  = 'saturation'; % Specify ouput non-linearity is saturation

g=est(z,m);                 % Do the estimation
details(g);                 % Present the results
Estimate Hammerstein model, and user-initialise parameters of non-linearity
z.y=y; z.u=u;               % Specify the input-output data
m.A=2;                      % Specify 2nd order output error model for linear component
m.type='oe';
m.in.type   = 'poly';       % Specify input non-linearity is deadzone
m.in.eta = [0,1,0,0];       % Initialise poly input as quadratic
m.out.type  = 'linear';     % This is the default is not explicitly stated

g=est(z,m);                 % Do the estimation
details(g);                 % Present the results

Maintained by Prof. Brett Ninness
University of Newcastle
3 Jun 2010, © Copyright