Grammians - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


DynamicSystems

  

Grammians

  

compute the controllability and observability grammians

 

Calling Sequence

Parameters

Options

Description

Examples

Calling Sequence

Grammians( sys, opts )

Parameters

sys

-

System(ss); state-space System object

opts

-

(optional) equation(s) of the form option = value; specify options for the Grammians command

Options

• 

checkstability = truefalse

  

True means check whether the system is stable; if it is not stable, an error occurs. False means skip the check. The default is true.

• 

output = C or O or list of these names

  

Specifies the returned values. If equal to C, then the controllability grammian is returned. If equal to O, then the observability grammian is returned. If a list of these names, then the output is a list/sequence (see returnlist) with each C replaced with the controllability grammian and each O replaced with the observability grammian. The default is [C,O].

• 

returnlist = truefalse

  

True means return a list; false means return an expression sequence. The default is false.

Description

• 

The Grammians command computes the grammians of sys, a state-space system.

• 

Depending on the value of the output option, either the controllability grammian, the observability grammian, or both, is computed.

• 

For a grammian to exist, the system must be stable. For a continuous-time system, all eigenvalues, λ, of A must lie in the open left-half plane: λ<0. For a discrete-time system, all eigenvalues, λ, of A must lie in the open unit-circle: λ<1. If sys is not stable, an error occurs, unless the option checkstability is false.

• 

A grammian is the positive-definite matrix X that solves the appropriate Lyapunov equation (see LyapunovSolve).

Controllability Grammian

• 

For a continuous system, the Lyapunov equation is A·X+X·AT=B·BT.

• 

For a discrete system, the Lyapunov equation is A·X·ATX=B·BT.

Observability Grammian

• 

For a continuous system, the Lyapunov equation is AT·X+X·A=CT·C.

• 

For a discrete system, the Lyapunov equation is AT·X·AX=CT·C.

Examples

withDynamicSystems&colon;

Assign a state-space system.

aSysStateSpace5&comma;3|3&comma;4&comma;2&comma;3&comma;1&comma;0|0&comma;1&comma;0&comma;0&colon;

Compute its controllability grammian.

CgGrammiansaSys&comma;output=C

Cg1.681818181818182.136363636363642.136363636363642.72727272727273

(1)

Verify that Cg meets the Lyapunov equation (b^+ is the transpose of b, see LinearAlgebra[Transpose]).

useaSysin`.`a&comma;Cg&plus;`.`Cg&comma;a&equals;`.`b&comma;b%Tend use

−4.00000000000000−6.00000000000000−6.00000000000000−9.00000000000001=−4−6−6−9

(2)

See Also

DynamicSystems

DynamicSystems[ControllabilityMatrix]

DynamicSystems[ObservabilityMatrix]

DynamicSystems[Observable]

DynamicSystems[SSTransformation]

LinearAlgebra

LinearAlgebra[Eigenvalues]

LinearAlgebra[LyapunovSolve]

LinearAlgebra[Rank]