Package with models for DC/DC conversion
Information
This package contains models for DC/DC conversion.
AC/DC converters can be found in the respective AC package.
Extends from Modelica.Icons.Package (Icon for standard packages).
Package Content
DC DC converter
Information
This is a DC/DC converter, based on a power balance between the two DC sides.
The paramater conversionFactor defines the ratio between the two averaged DC voltages.
The loss of the converter is proportional to the power transmitted at the second DC side.
The parameter eta
is the efficiency of the transfer.
The loss is computed as
Ploss = (1-η) PDC,
where PDC is the power transmitted. This model is symmetric and the power
can be transmitted in both directions. The loss is computed depending on the direction
of the power flow.
Extends from Buildings.Electrical.Interfaces.PartialConversion (Model representing a generic two port system for conversion).
Parameters
Type | Name | Default | Description |
replaceable package PhaseSystem_p | PartialPhaseSystem | Phase system of terminal p |
replaceable package PhaseSystem_n | PartialPhaseSystem | Phase system of terminal n |
Voltage | VHigh | | DC voltage on side 1 of the transformer (primary side) [V] |
Voltage | VLow | | DC voltage on side 2 of the transformer (secondary side) [V] |
Real | eta | | Converter efficiency |
Ground |
side 1 |
Boolean | ground_1 | true | Connect side 1 of converter to ground |
side 2 |
Boolean | ground_2 | true | Connect side 2 of converter to ground |
Connectors
Type | Name | Description |
replaceable package PhaseSystem_p | Phase system of terminal p |
replaceable package PhaseSystem_n | Phase system of terminal n |
Modelica definition
model DCDCConverter
"DC DC converter"
extends Buildings.Electrical.Interfaces.PartialConversion(
redeclare package PhaseSystem_p =
PhaseSystems.TwoConductor,
redeclare package PhaseSystem_n =
PhaseSystems.TwoConductor,
redeclare Interfaces.Terminal_n terminal_n,
redeclare Interfaces.Terminal_p terminal_p);
parameter Modelica.SIunits.Voltage VHigh
"DC voltage on side 1 of the transformer (primary side)";
parameter Modelica.SIunits.Voltage VLow
"DC voltage on side 2 of the transformer (secondary side)";
parameter Real eta(min=0, max=1)
"Converter efficiency";
parameter Boolean ground_1 = true
"Connect side 1 of converter to ground";
parameter Boolean ground_2 = true
"Connect side 2 of converter to ground";
Modelica.SIunits.Power LossPower
"Loss power";
protected
parameter Real conversionFactor = VLow/VHigh
"Ratio of high versus low voltage";
Modelica.SIunits.Current i1,i2;
Modelica.SIunits.Voltage v1,v2;
Modelica.SIunits.Power P_p
"Power at terminal p";
Modelica.SIunits.Power P_n
"Power at terminal n";
equation
Connections.potentialRoot(terminal_n.theta);
Connections.potentialRoot(terminal_p.theta);
if not ground_1
then
i1 = 0;
else
v1 = 0;
end if;
if not ground_2
then
i2 = 0;
else
v2 = 0;
end if;
P_p =
PhaseSystem_p.activePower(terminal_p.v, terminal_p.i);
P_n =
PhaseSystem_n.activePower(terminal_n.v, terminal_n.i);
v1 = terminal_n.v[2];
v2 = terminal_p.v[2];
sum(terminal_n.i) + i1 = 0;
sum(terminal_p.i) + i2 = 0;
// Voltage relation
v_p = v_n*conversionFactor;
// OLD equations that take into account the power at the secondary
// power balance
// LossPower = (1-eta) * abs(P_p);
// P_n + P_p - LossPower = 0;
// Symmetric and linear version
LossPower = P_p + P_n;
if i_n >=0
then
i_p = i_n/conversionFactor/(eta - 2);
else
i_n = conversionFactor*i_p/(eta - 2);
end if;
end DCDCConverter;
Automatically generated Mon May 4 10:19:50 2015.