modelFrequencyCalc

Frequency deviation calculation from a rotating phasor

Information

This block uses the real and imaginary components of a Cartesian representation of a voltage phasor to estimate the electrical frequency deviation from nominal value present at the node.

    Vr*der(Vi) - Vi*der(Vr)
f = -----------------------
          Vr^2 + Vi^2

The calculations are done using the filtered derivative of the real and imaginary parts of the phasor representation. The user is required to set proper values for initialization of the calculations, together with a smoothing filter time constant, used to filter the derivative components.

Note

The calculated frequency is just an estimate and can deviate by a certain margin of error.

Parameters

TypeNameDefaultDescription
Booleanstart_guessfalse
Realreal_start1Phasor initial real part
Realimag_start0Phasor initial imaginary part
Types.TimeTs0.01Smoothing filter time constant

Connectors

TypeNameDefaultDescription
Modelica.Blocks.Interfaces.RealInputreal_part
Modelica.Blocks.Interfaces.RealOutputyO/P is in rad/sec
Modelica.Blocks.Interfaces.RealInputimag_part

Components

TypeNameDefaultDescription
Modelica.Blocks.Continuous.DerderOfReal
Modelica.Blocks.Math.ProductImagXderReal
Modelica.Blocks.Math.Adddiff
Modelica.Blocks.Math.Divisiondivision
Modelica.Blocks.Math.ProductRealXderImag
Modelica.Blocks.Math.Productimag2
Modelica.Blocks.Math.Productreal2
Modelica.Blocks.Math.Addsum
Modelica.Blocks.Continuous.DerderOfImag