Class representing piecewise-linear nonlinear estimator for Hammerstein-Wiener models




pwlinear is an object that stores the piecewise-linear nonlinear estimator for estimating Hammerstein-Wiener models.

You can use the constructor to create the nonlinearity object, as follows:

t=pwlinear('NumberOfUnits',N) creates a piecewise-linear nonlinearity estimator object with N breakpoints.

t=pwlinear('BreakPoints',BP) creates a piecewise-linear nonlinearity estimator object with breakpoints at values BP.

t=pwlinear(Property1,Value1,...PropertyN,ValueN) creates a piecewise-linear nonlinearity estimator object specified by properties in pwlinear Properties.

Use evaluate(p,x) to compute the value of the function defined by the pwlinear object p at x.

pwlinear Properties

You can include property-value pairs in the constructor to specify the object.

After creating the object, you can use get or dot notation to access the object property values. For example:

% List all property values
% Get value of NumberOfUnits property
Property NameDescription

Integer specifies the number of breakpoints.

For example:


2-by-n matrix containing the breakpoint x and y value, specified using the following format:

[x1,x2, ...., xn;y1, y2, ..., yn].

If set to a 1-by-n vector, the values are interpreted as x-values and the corresponding y-values are set to zero.


Use pwlinear to specify the piecewise nonlinearity estimator in Hammerstein-Wiener models. For example:


The piecewise nonlinearity is initialized at the specified breakpoints. The breakpoint values are adjusted to the estimation data by nlhw.

More About

expand all


Use pwlinear to define a nonlinear function y=F(x), where F is a piecewise-linear (affine) function of x and there are n breakpoints (xk,yk), k = 1,...,n. yk = F(xk). F is linearly interpolated between the breakpoints. y and x are scalars.

F is also linear to the left and right of the extreme breakpoints. The slope of these extension is a function of xi and yi breakpoints. The breakpoints are ordered by ascending x-values, which is important when you set a specific breakpoint to a different value.

There are minor deviations from the breakpoint values you set and the values actually stored in the object because the toolbox represent breakpoints differently internally.

See Also

Introduced in R2007a

Was this topic helpful?