functionreadMatrixD
Read the feed forward matrix of a state space system
Extends from Internal.partialReadStateSpaceMatrix (Read the ABCD matrix of the state space form of a system from MAT file).
Information
Syntax
D = Streams.readMatrixD(fileName, matrixName);
Description
Opens the given MATLAB MAT file and reads the matrix D of a state space system from this file.
Example
// Generate dslin.mat of the double pendulum example first
Modelica_LinearSystems2.Utilities.Import.linearize(
"Modelica_LinearSystems2.Utilities.Plants.DoublePendulum", 1.0);
// Read D matrix of the linearized system
readMatrixD("dslin.mat", "ABCD")
// =
// [0.0;
// 0.0;
// 0.0;
// 0.0;
// 0.0;
// 0.0;
// 0.0;
// 0.0]
Inputs
| Type | Name | Default | Description |
|---|---|---|---|
| String | fileName (from partialReadStateSpaceMatrix) | "dslin.mat" | File where matrixName data is stored |
| String | matrixName (from partialReadStateSpaceMatrix) | "ABCD" | Name of the generalized state space system matrix on file |
Outputs
| Type | Name | Default | Description |
|---|---|---|---|
| Real[ny,nu] | D | matrixABCD[nx + 1:nx + ny, nx + 1:nx + nu] |