Products & Services Solutions Academia Support User Community Company

Learn more about System Identification Toolbox   

step - Plot step response with confidence interval

Syntax

step(m)
step(data)
step(m,'sd',sd,Time)
step(data,'sd',sd,'PW',na,Time)
step(m1,m2,...,dat1, ...,mN,Time,'sd',sd)
step(m1,'PlotStyle1',m2,'PlotStyle2',...,dat1,'PlotStylek',...,mN,
'PlotStyleN',Time,'sd',sd)
[y,t,ysd] = step(m)
mod = step(data)

Description

step can be applied both to any idmodel or idnlmodel object and to iddata sets.

For a discrete-time idmodel m, the step response y and, when required, its estimated standard deviation ysd, are computed using sim. When called with output arguments, y, ysd, and the time vector t are returned. When step is called without output arguments, a plot of the step response is shown. If sd is given a value larger than zero, a confidence region around the response is drawn. It corresponds to the confidence of sd standard deviations. If the input argument list contains 'fill', this region is plotted as a filled area.

Setting the Time Interval

The start time T1 and the end time T2 can be specified by Time = [T1 T2]. If T1 is not given, it is set to -T2/4. The negative time lags (the step is always assumed to occur at time 0) show possible feedback effects in the data when the step is estimated directly from data. If Time is not specified, a default value is used.

Estimating the Step Response from the Data

For an iddata set data, step(data) estimates a high-order, noncausal FIR model after first having prefiltered the data so that the input is "as white as possible." The step response of this FIR model and, when asked for, its confidence region, are then plotted. Note that it might not be possible always to deliver the demanded time interval in this case, because of lack of excitation in the data. A warning is then issued. When called with an output argument, step, in the iddata case, returns this FIR model, stored as an idarx model. The order of the prewhitening filter can be specified as na. The default value is na = 10.

Several Models/Data Sets

Any number and any mixture of models and data sets can be used as input arguments. The responses are plotted with each input/output channel (as defined by the models and data sets InputName and OutputName) as a separate plot. Colors, line styles, and marks can be defined by PlotStyle values, as in

step(m1,'b-*',m2,'y--',m3,'g')

Noise Channels

The noise input channels in m are treated as follows: Consider a model m with both measured input channels u (nu channels) and noise channels e (ny channels) with covariance matrix

where L is a lower triangular matrix. Note that m.NoiseVariance = . The model can also be described with a unit variance, using a normalized noise source v:

Arguments

If step is called with a single idmodel m, the output argument y is a 3-D array of dimension Nt-by-ny-by-nu. Here Nt is the length of the time vector t, ny is the number of output channels, and nu is the number of input channels. Thus y(:,ky,ku) is the response in the kyth output channel to a step in the kuth input channel. No plot is produced when output arguments are used.

ysd has the same dimensions as y and contains the standard deviations of y. This is normally computed using sim. However, when the model m contains an estimated delay (dead time) as in certain process models, the standard deviation is estimated with Monte Carlo techniques, using simsd.

If step is called with an output argument and a single data set in the input arguments, the output is returned as an idarx model mod containing the high-order FIR model, and its uncertainty. By calling step with mod, the responses can be displayed and returned without your having to redo the estimation.

Examples

% Estimate and plot the step response
step(data,'sd',3)
mod = step(data)
step(mod,'sd',3)

See Also

cra 
impulse 

  


Recommended Products

Includes the most popular MATLAB recorded presentations with Q&A sessions led by MATLAB experts.

 © 1984-2009- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS