.Modelica_LinearSystems2.StateSpace.Transformation.toDiagonalForm

Information

Syntax

tss = StateSpace.Transformation.toDiagonalForm(ss)

Description

This function computes the diagonal form of a SISO state space system, i.e.

tss:
der(z) = inv(T)*A*T*z + inv(T)*B*u
     y = C*inv(T)*z + D*u

Matrix T has to be diagonalizable, i.e. the algebraic and geometric multiplicities of an eigenvalue must coincide. The diagonal entries of the new system matrix tss.A are the eigenvalues off the systemmatrix ss.A.

Example

   Modelica_LinearSystems2.StateSpace ss=Modelica_LinearSystems2.StateSpace(
      A=[-1, 1; 0, -2],
      B=[1; 0],
      C=[1, 1],
      D=[2]);

algorithm
  tss:=Modelica_LinearSystems2.StateSpace.Transformation.toDiagonalForm(ss);
//  tss=StateSpace(
      A=[-1, 0; 0, -2],
      B=[1; 0],
      C=[1, 0],
      D=[0])

See also

toSimilarForm

Interface

encapsulated function toDiagonalForm
  import Modelica;
  import Modelica_LinearSystems2;
  import Modelica_LinearSystems2.StateSpace;
  import Modelica_LinearSystems2.Math.Matrices.LAPACK;
  input StateSpace ss "State space system";
  output StateSpace tss(redeclare Real A[size(ss.A, 1), size(ss.A, 2)], redeclare Real B[size(ss.B, 1), size(ss.B, 2)], redeclare Real C[size(ss.C, 1), size(ss.C, 2)], redeclare Real D[size(ss.D, 1), size(ss.D, 2)]);
end toDiagonalForm;

Generated at 2024-04-18T18:15:58Z by OpenModelicaOpenModelica 1.22.3 using GenerateDoc.mos