This package contains utility components for testing examples.
Extends from Modelica.Icons.UtilitiesPackage
(Icon for utility packages).
Name | Description |
---|---|
DcBrakeSettings | Setting for DC current braking |
DQCurrentController | Current controller in dq coordinate system |
DQToThreePhase | Transforms dq to three-phase |
FromDQ | Transform rotor fixed space phasor to instantaneous stator quantities |
MultiTerminalBox | Terminal box Y/D-connection |
ParameterRecords … | Parameter records |
RampedRheostat | Rheostat with linearly decreasing resistance |
SinCosEvaluation | Evaluation of the signals of a sin-cos-resolver |
SwitchedRheostat | Rheostat which is shortened after a given time |
SwitchYD | Y-D-switch |
SwitchYDwithArc | Y-D-switch with arc |
SynchronousMachineData | Computes machine parameter from usual datasheet |
TerminalBox | Terminal box Y/D-connection |
ToDQ | Transform instantaneous stator inputs to rotor fixed space phasor |
TransformerData | Calculates Impedances from nominal values |
VfController | Voltage-Frequency-Controller |
Simple Voltage-Frequency-Controller.
Amplitude of voltage is linear dependent (VNominal/fNominal) on frequency (input signal "u"), but limited by VNominal (nominal RMS voltage per phase).
m sine-waves with amplitudes as described above are provided as output signal "y".
By setting parameter EconomyMode=true, Voltage rises quadratically with frequency which means flux,torque and loss reduction for fan and pump drives.
The sine-waves are intended to feed a m-phase SignalVoltage.
Phase shifts between sine-waves may be chosen by the user; default values are (k-1)/m*pi for k in 1:m.
Extends from Modelica.Blocks.Interfaces.SIMO
(Single Input Multiple Output continuous control block).
Type | Name | Default | Description |
---|---|---|---|
final Integer | nout | m | Number of outputs |
Integer | m | 3 | Number of phases |
Angle | orientation[m] | -Modelica.Electrical.Polyphase.Functions.symmetricOrientation(m) | Orientation of phases |
Voltage | VNominal | Nominal RMS voltage per phase | |
Frequency | fNominal | Nominal frequency | |
Angle | BasePhase | 0 | Common phase shift |
Boolean | EconomyMode | false | Economy mode: voltage quadratic dependent on frequency |
Type | Name | Description |
---|---|---|
input RealInput | u | Connector of Real input signal |
output RealOutput | y[nout] | Connector of Real output signals |
The polyphase input values u[m]
are transformed to the corresponding space phasor which is rotated to the rotor fixed reference system,
using the provided mechanical rotor angle phi. The output are the resulting d and q components of the space phasor arranged in one vector y[2]
.
Extends from Modelica.Blocks.Interfaces.MIMO
(Multiple Input Multiple Output continuous control block).
Type | Name | Default | Description |
---|---|---|---|
final Integer | nin | m | Number of inputs |
final Integer | nout | 2 | Number of outputs |
Integer | m | 3 | Number of phases |
Integer | p | Number of pole pairs |
Type | Name | Description |
---|---|---|
input RealInput | u[nin] | Connector of Real input signals |
output RealOutput | y[nout] | Connector of Real output signals |
input RealInput | phi |   |
The d and q components of a space phasor u[2]
are rotated back to the stator fixed reference system,
using the provided mechanical rotor angle phi. The output are the instantaneous polyphase values y[m]
.
Extends from Modelica.Blocks.Interfaces.MIMO
(Multiple Input Multiple Output continuous control block).
Type | Name | Default | Description |
---|---|---|---|
final Integer | nin | 2 | Number of inputs |
final Integer | nout | m | Number of outputs |
Integer | m | 3 | Number of phases |
Integer | p | Number of pole pairs |
Type | Name | Description |
---|---|---|
input RealInput | u[nin] | Connector of Real input signals |
output RealOutput | y[nout] | Connector of Real output signals |
input RealInput | phi |   |
Transforms dq currents or voltages to three-phase currents or voltages.
The desired d- and q-components of the space phasor in rotor fixed coordinate system are given by inputs d
and q
.
Using the given rotor position (input phi
), the correct three-phase values (output y[3]
) are calculated.
They can be used to feed a current source which in turn feeds an induction machine.
Inputs d
and q
can be given either as peak values (useRMS=false
) or as RMS (useRMS=true
).
The correction by factor √2 is done automatically.
Extends from Modelica.Blocks.Interfaces.MO
(Multiple Output continuous control block).
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
Integer | p | Number of pole pairs | |
Boolean | useRMS | true | If true, inputs dq are multiplied by sqrt(2) |
final Integer | nout | m | Number of outputs |
Type | Name | Description |
---|---|---|
output RealOutput | y[nout] | Connector of Real output signals |
input RealInput | d | d-component |
input RealInput | q | q-component |
input RealInput | phi | Rotor angle |
Simple Current controller
The desired d- and q-component of the space phasor current in rotor fixed coordinate system are given by inputs id
and iq
.
Using the given rotor position (input phi
), the actual three-phase currents are measured and transformed to the d-q coordinate system.
Two PI-controllers determine the necessary d- and q- voltages, which are transformed back to three-phase (output y[3]
).
They can be used to feed a voltage source which in turn feeds a permanent magnet synchronous machine.
Inputs d
and q
can be given either as peak values (useRMS=false
) or as RMS (useRMS=true
).
The correction by factor √2 is done automatically.
The measured currents iActual[m]
are assumed to be instantaneous values.
Note: No care is taken for current or voltage limiting, as well as for field weakening.
Extends from Modelica.Blocks.Interfaces.MO
(Multiple Output continuous control block).
Type | Name | Default | Description |
---|---|---|---|
Integer | p | Number of pole pairs | |
Boolean | useRMS | true | If true, inputs dq are multiplied by sqrt(2) |
Frequency | fsNominal | Nominal frequency | |
Voltage | VsOpenCircuit | Open circuit RMS voltage per phase @ fsNominal | |
Resistance | Rs | Stator resistance per phase | |
Inductance | Ld | Inductance in d-axis | |
Inductance | Lq | Inductance in q-axis | |
Boolean | decoupling | false | Use decoupling network |
final MagneticFlux | psiM | sqrt(2) * VsOpenCircuit / (2 * pi * fsNominal) | Approximation of magnetic flux linkage |
final Integer | nout | m | Number of outputs |
Type | Name | Description |
---|---|---|
output RealOutput | y[nout] | Connector of Real output signals |
input RealInput | id | Reference of d-current |
input RealInput | iq | Reference of q-current |
input RealInput | phi | Rotor angle |
input RealInput | iActual[m] | Measured three-phase currents |
The sin-cos-resolver provides four tracks:
All four tracks have the same amplitude and the same offset > amplitude. Offset is used to detect loss of a track. To remove offset, (minus sine) is subtracted from (sine) and (minus cosine) from (cosine), resulting in a cosine and a sine signal with doubled amplitude but without offset.
Interpreting cosine and sine as real and imaginary part of a phasor, one could calculate the angle of the phasor (i.e., transform rectangular coordinates to polar coordinates). This is not very robust if the signals are superimposed with some noise. Therefore the phasor is rotated by an angle that is obtained by a controller. The controller aims at imaginary part equal to zero. The resulting angle is continuous, i.e. differentiating the angle results in 2*π*frequency. If desired, the angle can be wrapped to the interval ]-π, +π].
If the sin-cos-resolver provides one period of the tracks during a rotation of 2π/p, the result is the angle with respect to one pole pair and can be directly used for field oriented control.
Extends from Modelica.Blocks.Icons.Block
(Basic graphical layout of input/output block).
Type | Name | Description |
---|---|---|
input RealInput | u[4] | Signal from sin-cos-resolver |
output RealOutput | phi | Angle |
output RealOutput | w | Angular velocity |
Simple Star-Delta-switch.
If control is false, plug_sp and plug_sn are star connected and plug_sp connected to the supply plug.
If control is true, plug_sp and plug_sn are delta connected and they are connected to the supply plug.
Note there is a delay between opening star connection and closing delta connection, respectively opening delta connection and closing star connection.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
Resistance | Ron | 1e-5 | Closed switch resistance |
Conductance | Goff | 1e-5 | Opened switch conductance |
Time | delayTime | 0 | Time delay |
Type | Name | Description |
---|---|---|
PositivePlug | plugSupply | To grid |
PositivePlug | plug_sp | To positive stator plug |
NegativePlug | plug_sn | To negative stator plug |
input BooleanInput | control[m] |   |
Star-Delta-switch with arc when switch opens.
If control is false, plug_sp and plug_sn are star connected and plug_sp connected to the supply plug.
If control is true, plug_sp and plug_sn are delta connected and they are connected to the supply plug.
Note there is a delay between opening star connection and closing delta connection, respectively opening delta connection and closing star connection.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
Resistance | Ron | 1e-5 | Closed switch resistance |
Conductance | Goff | 1e-5 | Opened switch conductance |
Time | delayTime | 0 | Time delay |
Voltage | V0 | Initial arc voltage | |
VoltageSlope | dVdt | Arc voltage slope | |
Voltage | Vmax | Max. arc voltage |
Type | Name | Description |
---|---|---|
PositivePlug | plugSupply | To grid |
PositivePlug | plug_sp | To positive stator plug |
NegativePlug | plug_sn | To negative stator plug |
input BooleanInput | control[m] |   |
This model represents the internal connections of the terminal box of an electric machine.
The parameter terminalConnection
is used to switch between star
(terminalConnection = "Y"
) and delta (terminalConnection = "D"
) connection.
The (single-phase) connector starPoint
is only available if star connection is selected.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
String | terminalConnection | Choose "Y" for star or "D" for delta connection |
Type | Name | Description |
---|---|---|
PositivePlug | plug_sp | To be connected with positive stator plug |
NegativePlug | plug_sn | To be connected with negative stator plug |
PositivePlug | plugSupply | To be connected with grid |
NegativePin | starpoint | Star point |
This model represents the internal connections of the terminal box of an electric machine.
The parameter terminalConnection
is used to switch between star
(terminalConnection = "Y"
) and delta (terminalConnection = "D"
) connection.
The star point is a plug with
mSystem = Electrical.Polyphase.Functions.numberOfSymmetricBaseSystems(m)
phases,
representing the star points of each base system; see
Modelica.Magnetic.FundamentalWave.UsersGuide.Polyphase.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
final Integer | mSystems | Modelica.Electrical.Polyphase.Functions.numberOfSymmetricBaseSystems(m) | Number of symmetric base systems |
final Integer | mBasic | integer(m / mSystems) | Number of phases of basic system |
String | terminalConnection | Choose "Y" for star or "D" for delta connection |
Type | Name | Description |
---|---|---|
PositivePlug | plug_sp | To be connected with positive stator plug |
NegativePlug | plug_sn | To be connected with negative stator plug |
PositivePlug | plugSupply | To be connected with grid |
NegativePlug | starpoint | Star point |
Switched rheostat, used for starting induction motors with slipring rotor:
The external rotor resistance RStart
is shortened at time tStart
.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
Resistance | RStart | Starting resistance | |
Time | tStart | Duration of switching on the starting resistor |
Type | Name | Description |
---|---|---|
PositivePlug | plug_p | To positive rotor plug |
NegativePlug | plug_n | To negative rotor plug |
Ramped rheostat, used for starting induction motors with slipring rotor:
The external rotor resistance RStart
is reduced to zero,
starting at time tStart
with a linear ramp tRamp
.
Type | Name | Default | Description |
---|---|---|---|
Integer | m | 3 | Number of phases |
Resistance | RStart | Starting resistance | |
Time | tStart | Time instance of reducing the rheostat | |
Time | tRamp | Duration of ramp |
Type | Name | Description |
---|---|---|
PositivePlug | plug_p | To positive rotor plug |
NegativePlug | plug_n | To negative rotor plug |
Lets the user choose the layout, and determines the necessary DC current for DC current braking of an induction machine.
The icon shows the four layout variants. Phases with half the current are depicted with half the line thickness, phases with zero current are depicted with dashed line.
Type | Name | Description |
---|---|---|
parameter Current | INominal | Nominal RMS current per phase |
parameter String | layout | Braking connection layout |
parameter String | terminalConnection | Terminal connection |
parameter Boolean | connect3 | Connect 3rd terminal |
parameter Current | Idc | DC braking current |
parameter Current | is[3] | Phase currents |
The parameters of the synchronous machine model with electrical excitation (and damper) are calculated from parameters normally given in a technical description, according to the standard EN 60034-4:2008 Appendix C.
Extends from Modelica.Icons.Record
(Icon for records).
Type | Name | Description |
---|---|---|
parameter ApparentPower | SNominal | Nominal apparent power |
parameter Voltage | VsNominal | Nominal stator voltage per phase |
parameter Current | IsNominal | Nominal stator current per phase |
parameter Impedance | ZReference | Reference impedance |
parameter Frequency | fsNominal | Nominal stator frequency |
parameter AngularVelocity | omega | Nominal angular frequency |
parameter Current | IeOpenCircuit | Open circuit excitation current @ nominal voltage and frequency |
parameter Real | effectiveStatorTurns | Effective number of stator turns |
parameter Real | turnsRatio | Stator current / excitation current |
parameter Real | x0 | Stator stray inductance per phase (approximately zero impedance) [pu] |
parameter Real | xd | Synchronous reactance per phase, d-axis [pu] |
parameter Real | xq | Synchronous reactance per phase, q-axis [pu] |
parameter Real | xdTransient | Transient reactance per phase, d-axis [pu] |
parameter Real | xdSubtransient | Subtransient reactance per phase, d-axis [pu] |
parameter Real | xqSubtransient | Subtransient reactance per phase, q-axis [pu] |
parameter Time | Ta | Armature time constant |
parameter Time | Td0Transient | Open circuit field time constant Td0' |
parameter Time | Td0Subtransient | Open circuit subtransient time constant Td0'', d-axis |
parameter Time | Tq0Subtransient | Open circuit subtransient time constant Tq0'', q-axis |
parameter Temperature | TsSpecification | Specification temperature of stator resistance |
parameter Temperature | TsRef | Reference temperature of stator resistance |
parameter LinearTemperatureCoefficient20 | alpha20s | Temperature coefficient of stator resistance at 20 degC |
parameter Temperature | TrSpecification | Specification temperature of (optional) damper cage |
parameter Temperature | TrRef | Reference temperature of damper resistances in d- and q-axis |
parameter LinearTemperatureCoefficient20 | alpha20r | Temperature coefficient of damper resistances in d- and q-axis |
parameter Temperature | TeSpecification | Specification excitation temperature |
parameter Temperature | TeRef | Reference temperature of excitation resistance |
parameter LinearTemperatureCoefficient20 | alpha20e | Temperature coefficient of excitation resistance |
parameter Real | xmd | Main field reactance per phase, d-axis [pu] |
parameter Real | xmq | Main field reactance per phase, q-axis [pu] |
parameter Real | xe | Excitation reactance [pu] |
parameter Real | xrd | Damper reactance per phase, d-axis [pu] |
parameter Real | xrq | Damper reactance per phase, d-axis [pu] |
parameter Real | rs | Stator resistance per phase at specification temperature [pu] |
parameter Real | rrd | Damper resistance per phase at specification temperature, d-axis [pu] |
parameter Real | rrq | Damper resistance per phase at specification temperature, q-axis [pu] |
parameter Real | re | Excitation resistance per phase at specification temperature [pu] |
parameter Resistance | Rs | Stator resistance per phase at TRef |
parameter Inductance | Lssigma | Stator stray inductance per phase |
parameter Inductance | Lmd | Main field inductance per phase in d-axis |
parameter Inductance | Lmq | Main field inductance per phase in q-axis |
parameter Inductance | Lrsigmad | Damper stray inductance in d-axis |
parameter Inductance | Lrsigmaq | Damper stray inductance in q-axis |
parameter Resistance | Rrd | Damper resistance in d-axis at TRef |
parameter Resistance | Rrq | Damper resistance in q-axis at TRef |
parameter Resistance | Re | Excitation resistance at TRef |
parameter Real | sigmae | Stray fraction of total excitation inductance |
The parameters of the transformer models are calculated from parameters normally given in a technical description.
Extends from Modelica.Icons.Record
(Icon for records).
Type | Name | Description |
---|---|---|
parameter Frequency | f | Nominal frequency |
parameter Voltage | V1 | Primary nominal line-to-line voltage (RMS) |
parameter String | C1 | Choose primary connection |
parameter Voltage | V2 | Secondary open circuit line-to-line voltage (RMS) @ primary nominal voltage |
parameter String | C2 | Choose secondary connection |
parameter ApparentPower | SNominal | Nominal apparent power |
parameter Real | v_sc | Impedance voltage drop pu |
parameter Power | P_sc | Short-circuit (copper) losses |
parameter Real | n | Ratio primary voltage (line-to-line) / secondary voltage (line-to-line) |
parameter Voltage | V1ph | Primary phase voltage (RMS) |
parameter Current | I1ph | Primary phase current (RMS) |
parameter Voltage | V2ph | Secondary phase voltage (RMS) |
parameter Current | I2ph | Secondary phase current (RMS) |
parameter Impedance | Z1ph | Primary impedance per phase |
parameter Resistance | R1 | Warm primary resistance per phase |
parameter Inductance | L1sigma | Primary stray inductance per phase |
parameter Impedance | Z2ph | Secondary impedance per phase |
parameter Resistance | R2 | Warm secondary resistance per phase |
parameter Inductance | L2sigma | Secondary stray inductance per phase |