Modelica.Electrical.QuasiStationary.SinglePhase.Ideal

Ideal components for AC singlephase models

Information


This package hosts ideal models for quasi stationary single phase circuits. Quasi stationary theory for single phase circuits can be found in the references.

See also

MultiPhase.Ideal

Extends from Modelica.Icons.Package (Icon for standard packages).

Package Content

NameDescription
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Idle Idle Idle branch
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Short Short Short cut branch
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealCommutingSwitch IdealCommutingSwitch Ideal commuting switch
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealIntermediateSwitch IdealIntermediateSwitch Ideal intermediate switch
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealOpeningSwitch IdealOpeningSwitch Ideal electrical opener
Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealClosingSwitch IdealClosingSwitch Ideal electrical closer


Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Idle Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Idle

Idle branch

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Idle

Information


This model is a simple idle branch considering the complex current i = 0.

See also

Short

Extends from Interfaces.OnePort (Two pins, current through).

Connectors

TypeNameDescription
PositivePinpin_pPositive pin
NegativePinpin_nNegative pin

Modelica definition

model Idle "Idle branch"
  extends Interfaces.OnePort;
equation 
  i = Complex(0);
end Idle;

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Short Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Short

Short cut branch

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.Short

Information


This model is a simple short cut branch considering the complex voltage v = 0.

See also

Idle

Extends from Interfaces.OnePort (Two pins, current through).

Connectors

TypeNameDescription
PositivePinpin_pPositive pin
NegativePinpin_nNegative pin

Modelica definition

model Short "Short cut branch"
  extends Interfaces.OnePort;
equation 
  v = Complex(0);
end Short;

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealCommutingSwitch Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealCommutingSwitch

Ideal commuting switch

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealCommutingSwitch

Information


The commuting switch has a positive pin p and two negative pins n1 and n2. The switching behaviour is controlled by the inpug signal control. If control is true, the pin p is connected with the negative pin n2. Otherwise, the pin p is connected to the negative pin n1.

In order to prevent singularities during switching, the opened switch has a (very low) conductance Goff and the closed switch has a (very low) resistance Ron. The limiting case is also allowed, i.e., the resistance Ron of the closed switch could be exactly zero and the conductance Goff of the open switch could be also exactly zero. Note, there are circuits, where a description with zero Ron or zero Goff is not possible.

Please note: In case of useHeatPort=true the temperature dependence of the electrical behavior is not modelled. The parameters are not temperature dependent.

Use with care: This switch is only intended to be used for structural changes, not for fast switching sequences, due to the quasistationary formulation.

Extends from Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort (Partial model to include a conditional HeatPort in order to describe the power loss via a thermal network).

Parameters

TypeNameDefaultDescription
ResistanceRon1.E-5Closed switch resistance [Ohm]
ConductanceGoff1.E-5Opened switch conductance [S]
BooleanuseHeatPortfalse=true, if HeatPort is enabled
TemperatureT293.15Fixed device temperature if useHeatPort = false [K]

Connectors

TypeNameDescription
HeatPort_aheatPort 
PositivePinp 
NegativePinn2 
NegativePinn1 
input BooleanInputcontroltrue => p--n2 connected, false => p--n1 connected

Modelica definition

model IdealCommutingSwitch "Ideal commuting switch"
  import Modelica.ComplexMath.real;
  import Modelica.ComplexMath.conj;
  parameter Modelica.SIunits.Resistance Ron(final min=0)=1.E-5 
    "Closed switch resistance";
  parameter Modelica.SIunits.Conductance Goff(final min=0)=1.E-5 
    "Opened switch conductance";
  extends Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort(final T=293.15);
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.PositivePin p;
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.NegativePin n2;
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.NegativePin n1;
  Modelica.Blocks.Interfaces.BooleanInput control 
    "true => p--n2 connected, false => p--n1 connected";
protected 
  Complex s1(re(final unit="1"), im(final unit="1"));
  Complex s2(re(final unit="1"), im(final unit="1")) "Auxiliary variables";
  constant Modelica.SIunits.ComplexVoltage  unitVoltage=
                                                       Complex(1,0);
  constant Modelica.SIunits.ComplexCurrent  unitCurrent=
                                                       Complex(1,0);
equation 
  Connections.branch(p.reference, n1.reference);
  p.reference.gamma = n1.reference.gamma;
  Connections.branch(p.reference, n2.reference);
  p.reference.gamma = n2.reference.gamma;
  p.i + n2.i + n1.i = Complex(0,0);
  p.v - n1.v = (s1*unitCurrent)*(if (control) then 1 else Ron);
  n1.i = -(s1*unitVoltage)*(if (control) then Goff else 1);
  p.v - n2.v = (s2*unitCurrent)*(if (control) then Ron else 1);
  n2.i = -(s2*unitVoltage)*(if (control) then 1 else Goff);
  LossPower = real(p.v*conj(p.i)) + real(n1.v*conj(n1.i)) + real(n2.v*conj(n2.i));
end IdealCommutingSwitch;

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealIntermediateSwitch Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealIntermediateSwitch

Ideal intermediate switch

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealIntermediateSwitch

Information


The intermediate switch has four switching contact pins p1, p2, n1, and n2. The switching behaviour is controlled by the input signal control. If control is true, the pin p1 is connected to pin n2, and the pin p2 is connected to the pin n2. Otherwise, the pin p1 is connected to n1, and p2 is connected to n2.

IdealIntermediateSwitch1

In order to prevent singularities during switching, the opened switch has a (very low) conductance Goff and the closed switch has a (very low) resistance Ron.

IdealIntermediateSwitch2

The limiting case is also allowed, i.e., the resistance Ron of the closed switch could be exactly zero and the conductance Goff of the open switch could be also exactly zero. Note, there are circuits, where a description with zero Ron or zero Goff is not possible.

Please note: In case of useHeatPort=true the temperature dependence of the electrical behavior is not modelled. The parameters are not temperature dependent.

Use with care: This switch is only intended to be used for structural changes, not for fast switching sequences, due to the quasistationary formulation.

Extends from Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort (Partial model to include a conditional HeatPort in order to describe the power loss via a thermal network).

Parameters

TypeNameDefaultDescription
ResistanceRon1.E-5Closed switch resistance [Ohm]
ConductanceGoff1.E-5Opened switch conductance [S]
BooleanuseHeatPortfalse=true, if HeatPort is enabled
TemperatureT293.15Fixed device temperature if useHeatPort = false [K]

Connectors

TypeNameDescription
HeatPort_aheatPort 
PositivePinp1 
PositivePinp2 
NegativePinn1 
NegativePinn2 
input BooleanInputcontroltrue => p1--n2, p2--n1 connected, otherwise p1--n1, p2--n2 connected

Modelica definition

model IdealIntermediateSwitch "Ideal intermediate switch"
  import Modelica.ComplexMath.real;
  import Modelica.ComplexMath.conj;
  parameter Modelica.SIunits.Resistance Ron(final min=0)=1.E-5 
    "Closed switch resistance";
  parameter Modelica.SIunits.Conductance Goff(final min=0)=1.E-5 
    "Opened switch conductance";
  extends Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort(final T=293.15);
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.PositivePin p1;
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.PositivePin p2;
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.NegativePin n1;
  Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.NegativePin n2;
  Modelica.Blocks.Interfaces.BooleanInput control 
    "true => p1--n2, p2--n1 connected, otherwise p1--n1, p2--n2  connected";
protected 
  Complex s1(re(final unit="1"), im(final unit="1"));
  Complex s2(re(final unit="1"), im(final unit="1"));
  Complex s3(re(final unit="1"), im(final unit="1"));
  Complex s4(re(final unit="1"), im(final unit="1")) "Auxiliary variables";
  constant Modelica.SIunits.ComplexVoltage  unitVoltage=
                                                       Complex(1,0);
  constant Modelica.SIunits.ComplexCurrent  unitCurrent=
                                                       Complex(1,0);
equation 
  Connections.branch(p1.reference, n1.reference);
  p1.reference.gamma = n1.reference.gamma;
  Connections.branch(p2.reference, n2.reference);
  p2.reference.gamma = n2.reference.gamma;
  Connections.branch(n1.reference, n2.reference);
  n1.reference.gamma = n2.reference.gamma;

  p1.v - n1.v = (s1*unitCurrent)*(if (control) then 1 else Ron);
  p2.v - n2.v = (s2*unitCurrent)*(if (control) then 1 else Ron);
  p1.v - n2.v = (s3*unitCurrent)*(if (control) then Ron else 1);
  p2.v - n1.v = (s4*unitCurrent)*(if (control) then Ron else 1);

  p1.i = if control then s1*unitVoltage*Goff + s3*unitCurrent else s1*unitCurrent + s3*unitVoltage*Goff;
  p2.i = if control then s2*unitVoltage*Goff + s4*unitCurrent else s2*unitCurrent + s4*unitVoltage*Goff;
  n1.i = if control then -s1*unitVoltage*Goff - s4*unitCurrent else -s1*unitCurrent - s4*unitVoltage*Goff;
  n2.i = if control then -s2*unitVoltage*Goff - s3*unitCurrent else -s2*unitCurrent - s3*unitVoltage*Goff;

  LossPower = real(p1.v*conj(p1.i)) + real(p2.v*conj(p2.i)) + real(n1.v*conj(n1.i)) + real(n2.v*conj(n2.i));
end IdealIntermediateSwitch;

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealOpeningSwitch Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealOpeningSwitch

Ideal electrical opener

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealOpeningSwitch

Information


The ideal opening switch has a positive pin p and a negative pin n. The switching behaviour is controlled by the input signal control. If control is true, pin p is not connected with negative pin n. Otherwise, pin p is connected with negative pin n.

In order to prevent singularities during switching, the opened switch has a (very low) conductance Goff and the closed switch has a (very low) resistance Ron. The limiting case is also allowed, i.e., the resistance Ron of the closed switch could be exactly zero and the conductance Goff of the open switch could be also exactly zero. Note, there are circuits, where a description with zero Ron or zero Goff is not possible.

Please note: In case of useHeatPort=true the temperature dependence of the electrical behavior is not modelled. The parameters are not temperature dependent.

Use with care: This switch is only intended to be used for structural changes, not for fast switching sequences, due to the quasistationary formulation.

Extends from Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.OnePort (Two pins, current through), Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort (Partial model to include a conditional HeatPort in order to describe the power loss via a thermal network).

Parameters

TypeNameDefaultDescription
ResistanceRon1.E-5Closed switch resistance [Ohm]
ConductanceGoff1.E-5Opened switch conductance [S]
BooleanuseHeatPortfalse=true, if HeatPort is enabled
TemperatureT293.15Fixed device temperature if useHeatPort = false [K]

Connectors

TypeNameDescription
PositivePinpin_pPositive pin
NegativePinpin_nNegative pin
HeatPort_aheatPort 
input BooleanInputcontroltrue => switch open, false => p--n connected

Modelica definition

model IdealOpeningSwitch "Ideal electrical opener"
  import Modelica.ComplexMath.real;
  import Modelica.ComplexMath.conj;
 extends Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.OnePort;
 parameter Modelica.SIunits.Resistance Ron(final min=0)=1.E-5 
    "Closed switch resistance";
 parameter Modelica.SIunits.Conductance Goff(final min=0)=1.E-5 
    "Opened switch conductance";
 extends Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort(final T=293.15);
 Modelica.Blocks.Interfaces.BooleanInput control 
    "true => switch open, false => p--n connected";
protected 
 Complex s(re(final unit="1"), im(final unit="1")) "Auxiliary variable";
 constant Modelica.SIunits.ComplexVoltage  unitVoltage=
                                                      Complex(1,0);
 constant Modelica.SIunits.ComplexCurrent  unitCurrent=
                                                      Complex(1,0);
equation 
 v = (s*unitCurrent)*(if control then 1 else Ron);
 i = (s*unitVoltage)*(if control then Goff else 1);

 LossPower = real(v*conj(i));
end IdealOpeningSwitch;

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealClosingSwitch Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealClosingSwitch

Ideal electrical closer

Modelica.Electrical.QuasiStationary.SinglePhase.Ideal.IdealClosingSwitch

Information


The ideal closing switch has a positive pin p and a negative pin n. The switching behaviour is controlled by input signal control. If control is true, pin p is connected with negative pin n. Otherwise, pin p is not connected with negative pin n.

In order to prevent singularities during switching, the opened switch has a (very low) conductance Goff and the closed switch has a (very low) resistance Ron. The limiting case is also allowed, i.e., the resistance Ron of the closed switch could be exactly zero and the conductance Goff of the open switch could be also exactly zero. Note, there are circuits, where a description with zero Ron or zero Goff is not possible.

Please note: In case of useHeatPort=true the temperature dependence of the electrical behavior is not modelled. The parameters are not temperature dependent.

Use with care: This switch is only intended to be used for structural changes, not for fast switching sequences, due to the quasistationary formulation.

Extends from Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.OnePort (Two pins, current through), Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort (Partial model to include a conditional HeatPort in order to describe the power loss via a thermal network).

Parameters

TypeNameDefaultDescription
ResistanceRon1.E-5Closed switch resistance [Ohm]
ConductanceGoff1.E-5Opened switch conductance [S]
BooleanuseHeatPortfalse=true, if HeatPort is enabled
TemperatureT293.15Fixed device temperature if useHeatPort = false [K]

Connectors

TypeNameDescription
PositivePinpin_pPositive pin
NegativePinpin_nNegative pin
HeatPort_aheatPort 
input BooleanInputcontroltrue => p--n connected, false => switch open

Modelica definition

model IdealClosingSwitch "Ideal electrical closer"
  import Modelica.ComplexMath.real;
  import Modelica.ComplexMath.conj;
  extends Modelica.Electrical.QuasiStationary.SinglePhase.Interfaces.OnePort;
    parameter Modelica.SIunits.Resistance Ron(final min=0)=1.E-5 
    "Closed switch resistance";
    parameter Modelica.SIunits.Conductance Goff(final min=0)=1.E-5 
    "Opened switch conductance";
  extends Modelica.Electrical.Analog.Interfaces.ConditionalHeatPort(final T=293.15);
    Modelica.Blocks.Interfaces.BooleanInput control 
    "true => p--n connected, false => switch open";
protected 
    Complex s(re(final unit="1"), im(final unit="1")) "Auxiliary variable";
    constant Modelica.SIunits.ComplexVoltage  unitVoltage=
                                                         Complex(1,0);
    constant Modelica.SIunits.ComplexCurrent  unitCurrent=
                                                         Complex(1,0);
equation 
    v = (s*unitCurrent)*(if control then Ron else 1);
    i = (s*unitVoltage)*(if control then 1 else Goff);

    LossPower = real(v*conj(i));
end IdealClosingSwitch;

Automatically generated Fri Nov 12 16:29:24 2010.