WOLFRAM SYSTEM MODELER

# StateSpace

Discrete State Space block # Wolfram Language

In:= `SystemModel["Modelica.Blocks.Discrete.StateSpace"]`
Out:= # Information

This information is part of the Modelica Standard Library maintained by the Modelica Association.

The discrete state space block defines the relation between the input u and the output y in state space form:

```    x = A * pre(x) + B * u
y = C * pre(x) + D * u
```

where pre(x) is the value of the discrete state x at the previous sample time instant. The input is a vector of length nu, the output is a vector of length ny and nx is the number of states. Accordingly

```        A has the dimension: A(nx,nx),
B has the dimension: B(nx,nu),
C has the dimension: C(ny,nx),
D has the dimension: D(ny,nu)
```

Example:

```     parameter: A = [0.12, 2;3, 1.5]
parameter: B = [2, 7;3, 1]
parameter: C = [0.1, 2]
parameter: D = zeros(ny,nu)

results in the following equations:
[x]   [0.12  2.00] [pre(x)]   [2.0  7.0] [u]
[    ] = [          ]*[         ] + [        ]*[    ]
[x]   [3.00  1.50] [pre(x)]   [0.1  2.0] [u]
[pre(x)]            [u]
y   = [0.1  2.0] * [         ] + [0  0] * [    ]
[pre(x)]            [u]
```

# Parameters (8)

samplePeriod Value: Type: Time (s) Description: Sample period of component Value: 0 Type: Time (s) Description: First sample time instant Value: size(B, 2) Type: Integer Description: Number of inputs Value: size(C, 1) Type: Integer Description: Number of outputs Value: [1, 0; 0, 1] Type: Real[:,size(A, 1)] Description: Matrix A of state space model Value: [1; 1] Type: Real[size(A, 1),:] Description: Matrix B of state space model Value: [1, 1] Type: Real[:,size(A, 1)] Description: Matrix C of state space model Value: zeros(size(C, 1), size(B, 2)) Type: Real[size(C, 1),size(B, 2)] Description: Matrix D of state space model

# Outputs (3)

sampleTrigger Type: Boolean Description: True, if sample time instant Type: Boolean Description: Rising edge signals first sample instant Type: Real[size(A, 1)] Description: State vector

# Connectors (2)

u y Type: RealInput[nin] Description: Connector of Real input signals Type: RealOutput[nout] Description: Connector of Real output signals