gram (Control Design and Simulation Module, MathScript Function)
Member of the ssanals class.
Syntax
Gr = gram(SysInSS, type)
Description
Calculates the controllability or observability Grammians of a stable linear time-invariant (LTI) system model in state-space form.
Inputs
Name | Description | ||||
SysInSS | Specifies a linear time-invariant (LTI) model in state-space. | ||||
type | Specifies whether this function computes the controllability or observability Grammians of the SysInSS model. type is a string that can take the following values:
|
Outputs
Name | Description |
Gr | Returns the controllability or observability Grammian of the SysInSS model, depending on the value you specify for the type input. Gr is a real matrix. |
Examples
SysIn = ss([-5, 1; -1, -2], [1, 2]', [2, 1], 0)
Gr = gram(SysIn, 'O')