.Modelica_LinearSystems2.DiscreteZerosAndPoles.'constructor'.fromZerosAndPoles

Information

Syntax

dzp = 'constructor'.fromZerosAndPoles(zp, Ts, method)

Description

Computes a DiscreteZerosAndPoles record

           product(q + n1[i]) * product(q^2 + n2[i,1]*q + n2[i,2])
dzp = k * ---------------------------------------------------------
           product(q + d1[i]) * product(q^2 + d2[i,1]*q + d2[i,2])

from a continuous zeros-and-poles transfer function. The functions applies the discretization methods of DiscreteStateSpace.'constructor'.fromStateSpace, i.e, the continuous zeros-and-poles representation is transformed to continuous state space first and then converted to a discrete state space system. Finally the discrete zeros-and-poles transfer function is derived from DiscreteStateSpace by DiscreteStateSpace.Conversion.toDiscreteZerosAndPoles.

Example

  zp=Modelica_LinearSystems2.ZerosAndPoles(      n1={2},  d1={1},      d2=[1,1]);

  dzp=Modelica_LinearSystems2.DiscreteZerosAndPoles.'constructor'.fromZerosAndPoles(zp,0.1)

  //                          (q - 0.818182)*(q^2 + 2*q + 1)
  // dzp = 0.00248841 * ---------------------------------------------
  //                     (q - 0.904762)*(q^2 - 1.89549*q + 0.904988)

Interface

function fromZerosAndPoles
  import Modelica;
  import Modelica_LinearSystems2;
  import Modelica_LinearSystems2.DiscreteZerosAndPoles;
  import Modelica_LinearSystems2.ZerosAndPoles;
  import Modelica_LinearSystems2.StateSpace;
  import Modelica_LinearSystems2.DiscreteStateSpace;
  input ZerosAndPoles zp "continuous zeros and poles transfer function";
  input Modelica.Units.SI.Time Ts "Sample time" annotation(
    Dialog(group = "Data used to construct discrete from continuous system"));
  input Modelica_LinearSystems2.Utilities.Types.Method method = Modelica_LinearSystems2.Utilities.Types.Method.Trapezoidal "Discretization method" annotation(
    Dialog(group = "Data used to construct discrete from continuous system"));
  output DiscreteZerosAndPoles dzp;
end fromZerosAndPoles;

Generated at 2024-11-21T19:25:40Z by OpenModelicaOpenModelica 1.24.2 using GenerateDoc.mos