Skip to Main Content Skip to Search
Product Documentation

modred - Model order reduction

Syntax

modred
rsys = modred(sys,elim,'method')

Description

modred reduces the order of a continuous or discrete state-space model sys by eliminating the states found in the vector elim. The full state vector X is partitioned as X = [X1;X2] where X2 is to be discarded, and the reduced state is set to Xr = X1 + T*X2 where T is chosen to enforce matching DC gains (steady-state response) between sys and rsys.

elim can be a vector of indices or a logical vector commensurate with X where true values mark states to be discarded. This function is usually used in conjunction with balreal. Use balreal to first isolate states with negligible contribution to the I/O response. If sys has been balanced with balreal and the vector g of Hankel singular values has M small entries, you can use modred to eliminate the corresponding M states. For example:

[sys,g] = balreal(sys)  % Compute balanced realization
elim = (g<1e-8)         % Small entries of g are negligible states
rsys = modred(sys,elim)
% Remove negligible states

rsys = modred(sys,elim,'method') also specifies the state elimination method. Choices for 'method' include

The 'Truncate' option tends to produces a better approximation in the frequency domain, but the DC gains are not guaranteed to match.

If the state-space model sys has been balanced with balreal and the grammians have m small diagonal entries, you can reduce the model order by eliminating the last m states with modred.

Examples

Consider the continuous fourth-order model

To reduce its order, first compute a balanced state-space realization with balreal by typing

h = tf([1 11 36 26],[1 14.6 74.96 153.7 99.65])
[hb,g] = balreal(h)
g'

These commands produce the following result.

ans =
   1.3938e-01   9.5482e-03   6.2712e-04   7.3245e-06

The last three diagonal entries of the balanced grammians are small, so eliminate the last three states with modred using both matched DC gain and direct deletion methods.

hmdc = modred(hb,2:4,'MatchDC')
hdel = modred(hb,2:4,'Truncate')

Both hmdc and hdel are first-order models. Compare their Bode responses against that of the original model h(s).

bode(h,'-',hmdc,'x',hdel,'*')

The reduced-order model hdel is clearly a better frequency-domain approximation of h(s). Now compare the step responses.

step(h,'-',hmdc,'-.',hdel,'--')

While hdel accurately reflects the transient behavior, only hmdc gives the true steady-state response.

Algorithms

The algorithm for the matched DC gain method is as follows. For continuous-time models

the state vector is partitioned into x1, to be kept, and x2, to be eliminated.

Next, the derivative of x2 is set to zero and the resulting equation is solved for x1. The reduced-order model is given by

The discrete-time case is treated similarly by setting

Limitations

With the matched DC gain method, A22 must be invertible in continuous time, and IA22 must be invertible in discrete time.

See Also

balreal | minreal

  


Free Control Systems Interactive Kit

Learn more about resources for designing, testing, and implementing control systems.

Get free kit

Trials Available

Try the latest control systems products.

Get trial software
 © 1984-2012- The MathWorks, Inc.    -   Site Help   -   Patents   -   Trademarks   -   Privacy Policy   -   Preventing Piracy   -   RSS