Main Content

ssest

Estimate state-space model using time-domain or frequency-domain data

Description

Estimate State-Space Model

example

sys= ssest(tt,nx)estimates the continuous-time state-space modelsysof ordernx, using all the input and output signals in the timetablett. You can use this syntax for SISO and MISO systems. The function assumes that the last variable in the timetable is the single output signal.

sysis anidssmodel of the following form:

x ˙ ( t ) = A x ( t ) + B u ( t ) + K e ( t ) y ( t ) = C x ( t ) + D u ( t ) + e ( t )

A,B,C,D, andKare state-space matrices.u(t) is the input,y(t) is the output,e(t) is the disturbance, andx(t) is the vector ofnxstates.

All entries ofA,B,C, andKare free estimable parameters by default.Dis fixed to zero by default, meaning that there is no feedthrough, except for static systems (nx = 0).

To estimate a discrete-time model, set'Ts'to the model sample time using name-value syntax. To estimate MIMO models, use n-v syntax to specify the input and output channels using'InputName'and'OutputName'to the corresponding timetable variable names. You can also use'InputName'and'OutputName'to specify specific channels when you do not want to use all the available channels intt.

sys= ssest(u,y,nx,'Ts',Ts)estimates a discrete-time state-space model using the time-domain input and output signals in the comma-separated matricesu,yand the model sample timeTs. The software assumes that the data sample time isTsseconds. You can use this syntax for SISO, MISO, and MIMO systems.

example

sys= ssest(u,y,nx)estimates a continuous-time state-space model using the signals in the matricesu,y. The software assumes that the data sample time is 1 second. You cannot change this assumed sample time. If you want to estimate a continuous-time model from data with a sample time other than 1 second, you must first convert your matrix data to a timetable oriddataobject. Estimating continuous-time models from matrix-based data is not recommended.

example

sys= ssest(data,nx)estimates a continuous-time state-space model using the time-domain or frequency-domain data in the data objectdata. Use this syntax especially when you want to estimate a state-space model using frequency-domain or frequency-response data, or when you want to take advantage of the additional information, such as intersample behavior, data sample time, or experiment labeling, that data objects provide.

Estimate Time Series State-Space Model

sys= ssest(tt,nx)estimates the continuous time series modelsysto fit the data in the timetablett.ttmust contain a single numeric variable. The function interprets the timetable variable data as a time series, which has no inputs and a single output.

For a time series model, thesysidssmodel has the following form:

x ˙ ( t ) = A x ( t ) + K e ( t ) y ( t ) = C x ( t ) + e ( t )

sys= ssest(tt,nx,'OutputName',outputVariables,'InputName',[])estimates a multivariate time series model that uses the timetable output signals that have the variable names specified inoutputVariables. The function interprets the specified variables as a multivariate time series. If you specify all the variables inttin'OutputName', you can omit the specification of'InputName'.

sys= ssest([],y,nx,'Ts',Ts)estimates a discrete time series model with the sample timeTsfrom the output data matrixy.syshas as many outputs as there are columns in y.

sys= ssest(data,nx)estimates a time series model that uses the data in theiddatapropertydata.OutputData. The propertydata.InputDatamust be empty.

Specify Additional Model Options

example

sys= ssest(___,Name,Value)incorporates additional options specified by one or more name-value pair arguments. For example, specify a discrete-time system from matrix data that has a sample time of 0.1 usingsys = ssest(um,ym,np,'Ts',0.1). Specify input and output signal variable names that correspond with the variables to use for MIMO timetable data usingsys = ssest(data,nx,'InputName',["u1","u2"],'OutputName',["y1","y3"]). Use the'Form','Feedthrough', and'DisturbanceModel'name-value arguments to modify the default behavior of theA,B,C,D, andKmatrices.

You can use this syntax with any of the previous input-argument combinations.

Configure Initial Parameters

example

sys= ssest(tt,init_sys)uses the linear systeminit_systo configure the initial parameterization ofsysfor estimation using the timetablett.

example

sys= ssest(u,y,init_sys)uses the matrix datau,yfor estimation. Ifinit_sysis a continuous-time model, using a timetable instead of matrices is recommended.

example

sys= ssest(data,init_sys)uses the data objectdatafor estimation.

Specify Additional Estimation Options

example

sys= ssest(___,opt)incorporates an option setoptthat specifies options such as estimation objective, handling of initial conditions, regularization, and numerical search method used for estimation. You can specifyoptafter any of the previous input-argument combinations.

Return Estimated Initial States

example

[sys,x0] = ssest(___)returns the value of initial states computed during estimation.

Examples

collapse all

Estimate a state-space model and compare its response with the measured output.

Load the input/output data, which is stored in a timetable.

loadsdata1tt1

Estimate a fourth-order state-space model.

nx = 4; sys = ssest(tt1,nx);

Compare the simulated model response with the measured output.

compare(tt1,sys)

Figure contains an axes object. The axes object contains 2 objects of type line. These objects represent Validation data (y), sys: 70.78%.

The plot shows that the fit percentage between the simulated model and the estimation data is greater than 70%.

You can view more information about the estimation by exploring theidsspropertysys.Report.

sys.Report
ans = Status: 'Estimated using SSEST with prediction focus' Method: 'SSEST' InitialState: 'zero' N4Weight: 'CVA' N4Horizon: [6 10 10] Fit: [1x1 struct] Parameters: [1x1 struct] OptionsUsed: [1x1 idoptions.ssest] RandState: [] DataUsed: [1x1 struct] Termination: [1x1 struct]

For example, find out more information about the termination conditions.

sys.Report.Termination
ans =struct with fields:WhyStop: 'No improvement along the search direction with line search.' Iterations: 7 FirstOrderOptimality: 85.9759 FcnCount: 123 UpdateNorm: 10.0081 LastImprovement: 0

The report includes information on the number of iterations and the reason the estimation stopped iterating.

Load the data, which consists of the input vectorumat1, the output vectorymat1, and the sample timeTs.

loadsdata1umat1ymat1Ts

Combine the data into the single timetablett. View the first two rows oftt.

tt = timetable(umat1,ymat1,'rowtimes',seconds(Ts*(1:size(umat1,1)))); head(tt,2)
Time umat1 ymat1 _______ _____ ________ 0.1 sec 1 -0.58724 0.2 sec -1 1.1082

Usettto estimate a continuous-time state-space model.

sys = ssest(tt,2);

Compare the model output with the estimation data.

compare(tt,sys)

Figure contains an axes object. The axes object contains 2 objects of type line. These objects represent Validation data (ymat1), sys: 70.63%.

Load the input-output dataz1, which is stored in aniddataobject. This is the same data used to estimate a fourth-order model inState-Space Model.

loadiddata1z1

Determine the optimal model order by specifying argumentnxas a range from1:10.

nx = 1:10; sys = ssest(z1,nx);

An automatically generated plot shows the Hankel singular values for models of the orders specified bynx.

States with relatively small Hankel singular values can be safely discarded. The suggested default order choice is2.

Select the model order in theChosen Orderlist and clickApply.

Load time-domain system response data.

loadiddata7z7;

Identify a fourth-order state-space model of the data. Specify a known delay of2seconds for the first input and0seconds for the second input.

nx = 4; sys = ssest(z7(1:300),nx,'InputDelay',[2;0]);

Estimate a continuous-time model function by first converting matrix data to a timetable.

Load the data, which includes input matrixusteam, output matrixysteam, and sample timeTs.

loadsdatasteam.matusteamysteamTs

Combineusteamandysteaminto the single timetablettsteam. In order to create a variable for each channel, you must specify each matrix column explicitly.

tts = timetable(usteam(:,1),usteam(:,2),ysteam(:,1),ysteam(:,2),...'rowtimes',seconds(Ts*(1:size(usteam,1)))); head(tts,4)
时间Var1 Var2 Var3 Var4  ________ _______ _______________ _________ 0.05 sec -1.5283 2.0584 0.57733 -0.12274 0.1 sec 1.4412 -2.005 0.75804 -0.086114 0.15 sec 1.4314 2.0584 -0.76577 -0.19845 0.2 sec 1.4412 -1.9806 0.47721 -0.20577

Estimate a continuous-time state-space model.

nx = 3; sysc = ssest(tts,nx,'InputName',["Var1""Var2"],'OutputName',["Var3""Var4"]);

Compare the model to the data.

compare(tts,sysc)

Figure contains 2 axes objects. Axes object 1 contains 2 objects of type line. These objects represent Validation data (Var3), sysc: 90.8%. Axes object 2 contains 2 objects of type line. These objects represent Validation data (Var4), sysc: 62.29%.

Modify the canonical form of the A, B, and C matrices, include a feedthrough term in the D matrix, and eliminate disturbance-model estimation in the K matrix.

Load input-output data and estimate a fourth-order system using thessestdefault options.

loadiddata1z1sys1 = ssest(z1,4);

Specify the companion form and compare theAmatrix with the defaultAmatrix.

sys2 = ssest(z1,4,'Form','companion'); A1 = sys1.A
A1 =4×4-0.5155 -3.8483 0.6657 -0.2666 5.8665 -2.7285 1.0649 -1.4694 -0.4487 0.9308 -0.6235 18.8148 -0.4192 0.5595 -16.0688 0.5399
A2 = sys2.A
A2 =4×4103× 0 0 0 -7.1122 0.0010 0 0 -0.9547 0 0.0010 0 -0.3263 0 0 0.0010 -0.0033

Include a feedthrough term and compareDmatrices.

sys3 = ssest(z1,4,'Feedthrough',1); D1 = sys1.D
D1 = 0
D3 = sys3.D
D3 = 0.0339

Eliminate disturbance modeling and compareKmatrices.

sys4 = ssest(z1,4,'DisturbanceModel','none'); K1 = sys1.K
K1 =4×10.0520 0.0973 0.0151 0.0270
K4 = sys4.K
K4 =4×10 0 0 0

Specifyssestestimate initial states as independent estimation parameters.

ssestcan handle initial states using one of several methods. By default,ssestchooses the method automatically based on your estimation data. You can choose the method yourself by modifying the option set usingssestOptions.

Load the input-output dataz1and estimate a second-order state-space modelsysusing the default options. Use the syntax that returns initial statesx0.

loadiddata1z1[sys,x0] = ssest(z1,2); x0
x0 =2×10 0

By default, the estimation is performed using the'auto'setting forInitialState. Find out which methodssestapplied by reviewing the value ofInitialStateinsys.Report.

sys.Report.InitialState
ans = 'zero'

The software applied the 'zero'方法,这意味着软件设置初始states to zero instead of estimating them. This selection is consistent with the0values returned forx0.

Specify thatssestestimate the initial states instead as independent parameters using the'estimate'setting. UsessestOptionsto create a modified option set and specify that option set to estimate a new model.

opt = ssestOptions('InitialState','estimate'); [sys1,x0] = ssest(z1,2,opt); x0
x0 =2×10.0068 0.0052

x0now has estimated parameters with nonzero values.

获得一个正规化的基于状态空间模型for a second-order system from a narrow bandwidth signal.

Load estimation data.

loadregularizationExampleDataeData;

Create the transfer function model used for generating the estimation data (true system).

trueSys = idtf([0.02008 0.04017 0.02008],[1 -1.561 0.6414],1);

Estimate an unregularized state-space model.

opt = ssestOptions('SearchMethod','lm'); m = ssest(eData,5,'form','modal','DisturbanceModel','none','Ts',eData.Ts,opt);

Estimate a regularized state-space model.

opt.Regularization.Lambda = 10; mr = ssest(eData,5,'form','modal','DisturbanceModel','none','Ts',eData.Ts,opt);

Compare the model outputs with the estimation data.

compare(eData,m,mr);

Figure contains an axes object. The axes object contains 3 objects of type line. These objects represent Validation data (y1), m: 83.85%, mr: 83.68%.

Compare the model impulse responses.

impulse(trueSys,m,mr,50); legend('trueSys','m','mr');

Figure contains an axes object. The axes object with title From: u1 To: y1 contains 6 objects of type line. These objects represent trueSys, m, mr.

Estimate a state-space model of measured input-output data. Configure the parameter constraints and initial values for estimation using a state-space model.

Create anidssmodel to specify the initial parameterization for estimation.

A = blkdiag([-0.1 0.4; -0.4 -0.1],[-1 5; -5 -1]); B = [1; zeros(3,1)]; C = [1 1 1 1]; D = 0; K = zeros(4,1); x0 = [0.1 0.1 0.1 0.1]; Ts = 0; init_sys = idss(A,B,C,D,K,x0,Ts);

Setting all entries ofKto0creates anidssmodel with no state disturbance element.

Use theStructureproperty to fix the values of some of the model parameters. Configure the model so thatBandKare fixed, and only the nonzero entries ofAare estimable.

init_sys.Structure.A.Free = (A~=0); init_sys.Structure.B.Free = false; init_sys.Structure.K.Free = false;

The entries ininit_sys.Structure.A.Freedetermine whether the corresponding entries ininit_sys.Aare free (true) or fixed (false).

Load the measured data and estimate a state-space model using the parameter constraints and initial values specified byinit_sys.

loadiddata2z2; sys = ssest(z2,init_sys);

The estimated parameters ofsyssatisfy the constraints specified byinit_sys.

Input Arguments

collapse all

Estimation data, specified as a uniformly sampledtimetablethat contains variables representing input and output channels or, for multiexperiment data, a cell array of timetables.

Use Entire Timetable

If you want to use all the variables inttas input or output channels, and the variables are organized so that the set of input channel variables is followed by the set of output channel variables, then:

  • For SISO systems, specifyttas anNs-by-2 timetable, whereNs是数量of samples and the two timetable variables represent the measured input channel and output channel respectively.

  • For MIMO systems, specifyttas anNs-by-(Nu+Ny) timetable, whereNu是数量of inputs andNy是数量of outputs. The firstNuvariables must contain the input channels and the remainingNyvariables must contain the output channels.

    When you are estimating state space or transfer function models, you must also explicitly specify the input and output channels, as the following section describes.

  • For multiexperiment data, specify data as anNe-by-1 cell array of timetables, whereNe是数量of experiments. The sample times of all the experiments must match.

Use Selected Variables from Timetable

If you want to explicitly identify the input and output channels, such as when you want to use only a subset of the available channels, when the input and output channel variables are intermixed, or when you are estimating a MIMO state-space or transfer function model, use the'InputName'and'OutputName'name-value arguments to specify which variables to use as inputs and outputs.

For example, suppose thatttcontains six channel variables:"u1","u2","u3", and"y1","y2","y3". For estimation, you want to use the variables"u1"and"u2"as the inputs and the variables"y1"and"y3"as the outputs. Use the following command to perform the estimation:

sys = ssest(tt,__,'InputName',["u1" "u2"],'OutputName',["y1" "y3"])

Use Timetable to Estimate Time Series Models

如果你想估计时间序列模型than an input/output model, use only output variables fromtt. You can either specifyttto contain only the output variables that you want, or extract the output variables fromttifttalso contains input variables. The specification approach is similar to that for input/output model estimation.

  • For a single-output system, specifyttas anNs-by-1 timetable.

  • For a multivariate system, specifyttas anNs-by-(Ny) timetable. Even if you plan to use all the variables intt, you must specify all of them using the'OutputName'name-value argument so that the software does not interpret them as input variables.

For a timetablettthat has variables beyond what you want to use, such as input variables or additional output variables, specify both the output variables you want to use and, in'InputName', an empty array.

For example, suppose thatttcontains six variables:"u1","u2","u3", and"y1","y2","y3". For time series estimation, you want to use the output variables"y1"and"y3". Use the following command to perform the estimation:

sys = ssest(tt,__,'OutputName',["y1" "y3"],'InputName',[])

For more information about working with estimation data types, seeData Types in System Identification Toolbox.

Estimation data, specified for SISO systems as a comma-separated pair ofNs-by-1 real-valued matrices that contain uniformly sampled input and output time-domain signal values. Here,Ns是数量of samples.

For MIMO systems, specifyu,yas an input/output matrix pair with the following dimensions:

  • uNs-by-Nu, whereNu是数量of inputs.

  • yNs-by-Ny, whereNy是数量of outputs.

For multiexperiment data, specifyu,yas a pair of 1-by-Necell arrays, whereNe是数量of experiments. The sample times of all the experiments must match.

For time series data, which contains only outputs and no inputs, specifyyonly.

Limitations

  • Matrix-based data does not support estimation from frequency-domain data. You must use a data object such as aniddataobject oridfrdobject (seedata).

  • Using matrices for estimation data is not recommended for continuous-time estimation because the data does not provide the sample time. The software assumes that the data is sampled at 1 Hz. For continuous-time estimation, it is recommended that you convert each matrix to atimetable. For example, to convert the matricesumandymto atimetablettwith a sample time of 0.5 minutes, use the following command.

    tt = timetable(um,ym,'rowtimes',minutes(0.5*(1:size(u,1))))
    For a more detailed example of converting matrix-based SISO data to a timetable, seeConvert SISO Matrix Data to Timetable. For an example of converting a MIMO matrix pair to a timetable, seeConvert MIMO Matrix Data to Timetable for Continuous-Time Model Estimation.

    For more information about working with estimation data types, seeData Types in System Identification Toolbox.

Estimation data object, specified as aniddataobject, anfrdobject, or anidfrdobject that contains uniformly sampled input and output values. By default, the software sets the sample time of the model to the sample time of the estimation data.

For multiexperiment data, the sample times and intersample behavior of all the experiments must match.

For time-domain estimation,datamust be aniddataobject containing the input and output signal values.

For frequency-domain estimation,datacan be one of the following:

  • Recorded frequency response data (frd(Control System Toolbox)oridfrd)

  • iddataobject with properties specified as follows:

    • InputData— Fourier transform of the input signal

    • OutputData— Fourier transform of the output signal

    • Domain'Frequency'

Limitations

You cannot estimate continuous-time models using discrete-time frequency-domain data.

Order of the estimated model, specified as a nonnegative integer or as a vector containing a range of positive integers.

  • If you already know what order you want your estimated model to have, specifynxas a scalar.

  • If you want to compare a range of potential orders to choose the most effective order for your estimated model, specify the range innx.ssestcreates a Hankel singular-value plot that shows the relative energy contributions of each state in the system. States with relatively small Hankel singular values contribute little to the accuracy of the model and can be discarded with little impact. The index of the highest state you retain is the model order. The plot window includes a suggestion for the order to use. You can accept this suggestion or enter a different order. For an example, seeDetermine Optimal Estimated Model Order.

    If you do not specifynx, or if you specifynxasbest, the software automatically choosesnxfrom the range1:10.

  • If you are identifying a static system, setnxto0.

Estimation options, specified as anssestOptionsoption set. Options specified byoptinclude:

  • Estimation objective

  • Handling of initial conditions

  • Regularization

  • Numerical search method used for estimation

  • Intersample behavior

For examples showing how to useopt, seeEstimate Initial States as Independent ParametersandEstimate State-Space Model Using Regularization.

Linear system that configures the initial parameterization ofsys, specified as anidssmodel or as a structure. You obtaininit_sysby either performing an estimation using measured data or by direct construction.

Ifinit_sysis anidssmodel,ssestuses the parameter values ofinit_sys作为初始猜测估计sys. For information on how to specifyidss, seeEstimate State-Space Models with Structured Parameterization.ssesthonors constraints on the parameters ofinit_sys, such as fixed coefficients and minimum/maximum bounds.

Use theStructureproperty ofinit_systo configure initial parameter values and constraints for theA,B,C,D, andKmatrices. For example:

  • To specify an initial guess for theAmatrix ofinit_sys, setinit_sys.Structure.A.Valueas the initial guess.

  • To specify constraints for theBmatrix ofinit_sys:

    • Setinit_sys.Structure.B.Minimumto the minimumBmatrix value

    • Setinit_sys.Structure.B.Maximumto the maximumBmatrix value

    • Setinit_sys.Structure.B.Freeto indicate if entries of theBmatrix are free parameters for estimation

    To set more complex constraints, such as interdependence of coefficients, use grey-box estimation usinggreyestandidgrey.

You must assign finite initial values for all matrix parameters.

Ifinit_sysis not a state-space (idss) model, the software first convertsinit_systo anidssmodel.ssestuses the parameters of the resulting model as the initial guess for estimation.

If you do not specifyoptandinit_syswas obtained by estimation, then the software uses estimation options frominit_sys.Report.OptionsUsed.

For an example, seeEstimate Partially Known State-Space Model Using Structured Estimation.

Name-Value Arguments

Specify optional pairs of arguments asName1=Value1,...,NameN=ValueN, whereNameis the argument name andValueis the corresponding value. Name-value arguments must appear after other arguments, but the order of the pairs does not matter.

Before R2021a, use commas to separate each name and value, and encloseNamein quotes.

Example:sys = ssest(data,nx,'Ts',0.1)

Input channel names for timetable data, specified as a string, a character vector, or an array or cell array of strings or character vectors. By default, the software interprets all but the last variable inttas input channels. When you want to select a subset of the timetable variables as input channels use'InputName'to identify them. For example,sys = ssest(tt,__,'InputName',["u1" "u2"])selects the variablesu1andu2as the input channels for the estimation.

Output channel names for timetable data, specified as a string, a character vector, or an array or cell array of strings or character vectors. By default, the software interprets the last variable inttas the sole output channel. When you want to select a subset of the timetable variables as output channels, use'OutputName'to identify them. For example,sys = ssest(tt,__,'OutputName',["y1" "y3"])selects the variablesy1andy3as the output channels for the estimation.

Sample time of the estimated model, specified as the comma-separated pair consisting of'Ts'and either0or a positive scalar.

  • For continuous-time models, specify'Ts'as0.

  • For discrete-time models, specify'Ts'as the data sample time in units defined by the following:

    • For timetable-based data — The timetableTimecolumn

    • For matrix-based data — Seconds

    • For data objects, such asiddataobjects — Thedata.TimeUnitproperty

To obtain the data sample time for a timetablett, use the timetable propertytt.Properties.Timestep.

Input delay for each input channel, specified as the comma-separated pair consisting of'InputDelay'and a numeric vector.

  • For continuous-time models, specify'InputDelay'in the time units stored in the timetable, the data objectTimeUnitproperty, or, for matrix data, in seconds.

  • For discrete-time models, specify'InputDelay'in integer multiples of the sample timeTs. For example, setting'InputDelay'to3specifies a delay of three sampling periods.

For a system withNuinputs, setInputDelayto anNu-by-1 vector. Each entry of this vector is a numerical value that represents the input delay for the corresponding input channel. For an example, seeIdentify State-Space Model with Input Delay.

To apply the same delay to all channels, specifyInputDelayas a scalar.

Type of canonical form ofsys, specified as the comma-separated pair consisting of'Form'and one of the following values:

  • 'free'— All entries of the matricesA,B,C,D, andKare treated as free.

  • 'modal'— Obtainsysin modal form.

  • 'companion'— Obtainsysin companion form.

  • 'canonical'— Obtainsysin the observability canonical form.

For definitions of the canonical forms, seeState-Space Realizations.

For more information, seeEstimate State-Space Models with Canonical Parameterization. For an example, seeModify Form, Feedthrough, and Disturbance-Model Matrices.

Direct feedthrough from input to output, specified as the comma-separated pair consisting of'Feedthrough'and a logical vector of lengthNu, whereNu是数量of inputs. If you specifyFeedthroughas a logical scalar, that value is applied to all the inputs. For static systems, the software always assumes'Feedthrough'is1.

For an example, seeModify Form, Feedthrough, and Disturbance-Model Matrices.

Option to estimate time-domain noise component parameters in the K matrix, specified as the comma-separated pair consisting of'DisturbanceModel'and one of the following values:

  • 'estimate'— Estimate the noise component. TheKmatrix is treated as a free parameter.

  • 'none'— Do not estimate the noise component. The elements of theKmatrix are fixed at zero.

For frequency-domain data, the software assumes that'DisturbanceModel'is'none'.

For an example, seeModify Form, Feedthrough, and Disturbance-Model Matrices.

Output Arguments

collapse all

Identified state-space model, returned as anidssmodel. This model is created using the specified model orders, delays, and estimation options.

Information about the estimation results and options used is stored in theReportproperty of the model.Reporthas the following fields.

Report Field Description
Status

Summary of the model status, which indicates whether the model was created by construction or obtained by estimation.

Method

Estimation command used.

InitialState

How initial states were handled during estimation, returned as one of the following values:

  • 'zero'— The initial state is set to zero.

  • 'estimate'— The initial state is treated as an independent estimation parameter.

  • 'backcast'— The initial state is estimated using the best least squares fit.

  • Column vector of lengthNx, whereNx是数量of states. For multi-experiment data, a matrix withNecolumns, whereNe是数量of experiments.

  • Parametric initial condition object (x0obj) created usingidpar. Only for discrete-time state-space models.

This field is especially useful when theInitialStateoption in the estimation option set is'auto'.

N4Weight

Weighting scheme used for singular-value decomposition by the N4SID algorithm, returned as one of the following values:

  • 'MOESP'— Uses the MOESP algorithm.

  • 'CVA'— Uses the Canonical Variate Algorithm.

  • 'SSARX'— A subspace identification method that uses an ARX estimation-based algorithm to compute the weighting.

This option is especially useful when theN4Weightoption in the estimation option set is'auto'.

N4Horizon

Forward and backward prediction horizons used by the N4SID algorithm, returned as a row vector with three elements —[r sy su], whereris the maximum forward prediction horizon.sy是数量of past outputs, andsu是数量of past inputs that are used for the predictions.

Fit

Quantitative assessment of the estimation, returned as a structure. SeeLoss Function and Model Quality Metricsfor more information on these quality metrics. The structure has the following fields:

Field Description
FitPercent

Normalized root mean squared error (NRMSE) measure of how well the response of the model fits the estimation data, expressed as the percentagefitpercent= 100(1-NRMSE).

LossFcn

Value of the loss function when the estimation completes.

MSE

Mean squared error (MSE) measure of how well the response of the model fits the estimation data.

FPE

Final prediction error for the model.

AIC

Raw Akaike Information Criteria (AIC) measure of model quality.

AICc

Small-sample-size corrected AIC.

nAIC

Normalized AIC.

BIC

Bayesian Information Criteria (BIC).

Parameters

Estimated values of model parameters.

OptionsUsed

Option set used for estimation. If no custom options were configured, this is a set of default options. SeessestOptionsfor more information.

RandState

State of the random number stream at the start of estimation. Empty,[], if randomization was not used during estimation. For more information, seerng.

DataUsed

Attributes of the data used for estimation. Structure with the following fields:

Field Description
Name

Name of the data set.

Type

Data type.

Length

Number of data samples.

Ts

Sample time. This is equivalent toData.Ts.

InterSample

Input intersample behavior. One of the following values:

  • 'zoh'— Zero-order hold maintains a piecewise-constant input signal between samples.

  • 'foh'— First-order hold maintains a piecewise-linear input signal between samples.

  • 'bl'— Band-limited behavior specifies that the continuous-time input signal has zero power above the Nyquist frequency.

The value ofIntersamplehas no effect on estimation results for discrete-time models.

InputOffset

Offset removed from time-domain input data during estimation.

OutputOffset

Offset removed from time-domain output data during estimation.

Termination

Termination conditions for the iterative search used for prediction error minimization, returned as a structure with the following fields:

Field Description
WhyStop

Reason for terminating the numerical search.

Iterations

Number of search iterations performed by the estimation algorithm.

FirstOrderOptimality

-norm of the gradient search vector when the search algorithm terminates.

FcnCount

Number of times the objective function was called.

UpdateNorm

规范的梯度搜索过去尽管向量ration. Omitted when the search method is'lsqnonlin'or'fmincon'.

LastImprovement

Criterion improvement in the last iteration, expressed as a percentage. Omitted when the search method is'lsqnonlin'or'fmincon'.

Algorithm

Algorithm used by'lsqnonlin'or'fmincon'search method. Omitted when other search methods are used.

不需要数字的评估方法al search optimization, theTerminationfield is omitted.

For more information on usingReport, seeEstimation Report.

Initial states computed during the estimation, returned as an array containing a column vector corresponding to each experiment.

This array is also stored in theParametersfield of the modelReportproperty.

For an example, seeEstimate Initial States as Independent Parameters.

Algorithms

ssestinitializes the parameter estimates using either a noniterative subspace approach or an iterative rational function estimation approach. It then refines the parameter values using the prediction error minimization approach. For more information, seepemandssestOptions.

References

[1] Ljung, L.System Identification: Theory for the User, Second Edition. Upper Saddle River, NJ: Prentice Hall PTR, 1999.

Version History

Introduced in R2012a

expand all