Buildings.Electrical.DC.Sources

Package with models for DC sources

Information

This package contains models that represent different types of DC sources.

Extends from Modelica.Icons.SourcesPackage (Icon for packages containing sources).

Package Content

Name Description
Buildings.Electrical.DC.Sources.ConstantVoltage ConstantVoltage Model of a constant DC voltage source
Buildings.Electrical.DC.Sources.PVSimple PVSimple Simple PV model
Buildings.Electrical.DC.Sources.PVSimpleOriented PVSimpleOriented Simple PV model with orientation
Buildings.Electrical.DC.Sources.VoltageSource VoltageSource Model of a generoic DC voltage source
Buildings.Electrical.DC.Sources.WindTurbine WindTurbine Wind turbine with power output based on table as a function of wind speed
Buildings.Electrical.DC.Sources.Examples Examples Package with example models
Buildings.Electrical.DC.Sources.BaseClasses BaseClasses Package with base classes for DC sources

Buildings.Electrical.DC.Sources.ConstantVoltage Buildings.Electrical.DC.Sources.ConstantVoltage

Model of a constant DC voltage source

Buildings.Electrical.DC.Sources.ConstantVoltage

Information

This model represents a simple DC voltage source with constant voltage.

Extends from Buildings.Electrical.Interfaces.Source (Partial model of a generic source.).

Parameters

TypeNameDefaultDescription
replaceable package PhaseSystemOnePhasePhase system
VoltageV Value of constant voltage [V]
Reference Parameters
BooleanpotentialReferencetrueServe as potential root for the reference angle theta
BooleandefiniteReferencefalseServe as definite root for the reference angle theta

Connectors

TypeNameDescription
replaceable package PhaseSystemPhase system
NegativePinnNegative pin

Modelica definition

model ConstantVoltage "Model of a constant DC voltage source" extends Buildings.Electrical.Interfaces.Source( redeclare package PhaseSystem = PhaseSystems.TwoConductor, redeclare Interfaces.Terminal_p terminal, final potentialReference=true, final definiteReference=false); parameter Modelica.SIunits.Voltage V(start=1) "Value of constant voltage"; Modelica.Electrical.Analog.Interfaces.NegativePin n "Negative pin"; equation terminal.v[1] = V; terminal.v[2] = n.v; sum(terminal.i) + n.i = 0; end ConstantVoltage;

Buildings.Electrical.DC.Sources.PVSimple Buildings.Electrical.DC.Sources.PVSimple

Simple PV model

Buildings.Electrical.DC.Sources.PVSimple

Information

Model of a simple photovoltaic array.

This model computes the power as

P=A   fact   η   G

where A is the panel area, fact is the fraction of the aperture area, η is the panel efficiency and G is the total solar irradiation. This power is equal to P = v   i, where v is the voltage across the panel and i is the current that flows through the panel.

To avoid a large voltage drop the panel electric connector, it is recommended to use this model together with a model that prescribes the voltage. See Buildings.Electrical.DC.Sources.Examples.PVSimple.

Note: This model takes as input the total solar irradiation on the panel. This has to be computed converting the incoming radiation to take tilt and azimuth into account.

Extends from Buildings.Electrical.Interfaces.PartialPV (Base model for a PV system).

Parameters

TypeNameDefaultDescription
AreaA Net surface area [m2]
RealfAct0.9Fraction of surface area with active solar cells [1]
Realeta0.12Module conversion efficiency [1]
replaceable package PhaseSystemPartialPhaseSystemPhase system
Nominal conditions
VoltageV_nominal Nominal voltage (V_nominal >= 0) [V]

Connectors

TypeNameDescription
output RealOutputPGenerated power [W]
replaceable package PhaseSystemPhase system
input RealInputGTotal solar irradiation per unit area [W/m2]

Modelica definition

model PVSimple "Simple PV model" extends Buildings.Electrical.Interfaces.PartialPV( redeclare package PhaseSystem = PhaseSystems.TwoConductor, redeclare Interfaces.Terminal_p terminal); protected Loads.Conductor con( mode=Types.Load.VariableZ_P_input, V_nominal=V_nominal) "Conductor, used to interface power with electrical circuit"; equation connect(con.terminal, terminal); connect(solarPower.y, con.Pow); end PVSimple;

Buildings.Electrical.DC.Sources.PVSimpleOriented Buildings.Electrical.DC.Sources.PVSimpleOriented

Simple PV model with orientation

Buildings.Electrical.DC.Sources.PVSimpleOriented

Information

Model of a simple photovoltaic array.

This model computes the power as

P=A   fact   η   G

where A is the panel area, fact is the fraction of the aperture area, η is the panel efficiency and G is the total solar irradiation, which is the sum of direct and diffuse irradiation. The model takes into account the location and the orientation of the PV panel, specified by the surface tilt, latitude and azimuth.

This power is equal to P = v   i, where v is the voltage across the panel and i is the current that flows through the panel.

To avoid a large voltage drop the panel electric connector, it is recommended to use this model together with a model that prescribes the voltage. See Buildings.Electrical.DC.Sources.Examples.PVSimpleOriented.

This model takes as an input the direct and diffuse solar radiation from the weather data bus.

Extends from Buildings.Electrical.Interfaces.PartialPVOriented (Base model of a PV system with orientation).

Parameters

TypeNameDefaultDescription
AreaA Net surface area [m2]
RealfAct0.9Fraction of surface area with active solar cells [1]
Realeta0.12Module conversion efficiency [1]
replaceable package PhaseSystemPartialPhaseSystemPhase system
Orientation
Angletil Surface tilt [rad]
Anglelat Latitude [rad]
Angleazi Surface azimuth [rad]
Nominal conditions
VoltageV_nominal Nominal voltage (V_nominal >= 0) [V]

Connectors

TypeNameDescription
output RealOutputPGenerated power [W]
replaceable package PhaseSystemPhase system
BusweaBusWeather data

Modelica definition

model PVSimpleOriented "Simple PV model with orientation" extends Buildings.Electrical.Interfaces.PartialPVOriented( redeclare package PhaseSystem = PhaseSystems.TwoConductor, redeclare Interfaces.Terminal_p terminal, redeclare Buildings.Electrical.DC.Sources.PVSimple panel(V_nominal=V_nominal)); end PVSimpleOriented;

Buildings.Electrical.DC.Sources.VoltageSource Buildings.Electrical.DC.Sources.VoltageSource

Model of a generoic DC voltage source

Buildings.Electrical.DC.Sources.VoltageSource

Information

This model represents a simple DC voltage source with variable voltage.

Extends from Buildings.Electrical.Interfaces.VariableVoltageSource (Partial model of a generic variable voltage source.).

Parameters

TypeNameDefaultDescription
replaceable package PhaseSystemOnePhasePhase system
Booleanuse_V_intrueIf true, the voltage is an input
Reference Parameters
BooleanpotentialReferencetrueServe as potential root for the reference angle theta
BooleandefiniteReferencefalseServe as definite root for the reference angle theta
Initialization
VoltageV.start1Value of constant voltage [V]
RealInputV_in.start1Input voltage [V]

Connectors

TypeNameDescription
replaceable package PhaseSystemPhase system
NegativePinnNegative pin
Initialization
input RealInputV_inInput voltage [V]

Modelica definition

model VoltageSource "Model of a generoic DC voltage source" extends Buildings.Electrical.Interfaces.VariableVoltageSource( V(start = 1), redeclare package PhaseSystem = PhaseSystems.TwoConductor, redeclare Interfaces.Terminal_p terminal, final potentialReference=true, final definiteReference=false); Modelica.Electrical.Analog.Interfaces.NegativePin n "Negative pin"; equation terminal.v[1] = V_in_internal; terminal.v[2] = n.v; sum(terminal.i) + n.i = 0; end VoltageSource;

Buildings.Electrical.DC.Sources.WindTurbine Buildings.Electrical.DC.Sources.WindTurbine

Wind turbine with power output based on table as a function of wind speed

Buildings.Electrical.DC.Sources.WindTurbine

Information

Model of a wind turbine whose power is computed as a function of wind-speed as defined in a table.

Input to the model is the local wind speed. The model requires the specification of a table that maps wind speed in meters per second to generated power Pt in Watts. The model has a parameter called scale with a default value of one that can be used to scale the power generated by the wind turbine. The generated DC electrical power is

P = Pt scale = v i,

where v is the voltage and i is the current. For example, the following specification (with default scale=1) of a wind turbine

  WindTurbine_Table tur(
    table=[3.5, 0;
           5.5,   100;
           12, 900;
           14, 1000;
           25, 1000]) "Wind turbine";

yields the performance shown below. In this example, the cut-in wind speed is 3.5 meters per second, and the cut-out wind speed is 25 meters per second, as entered by the first and last entry of the wind speed column. Below and above these wind speeds, the generated power is zero.

alt-image

Extends from Buildings.Electrical.Interfaces.PartialWindTurbine (Partial model of a wind turbine with power output based on table as a function of wind speed).

Parameters

TypeNameDefaultDescription
Realscale1Scaling factor, used to allow adjusting the power output without changing the table
BooleantableOnFilefalsetrue, if table is defined on file or in function usertab
Realtable[:, 2][3.5, 0; 5.5, 0.1; 12, 0.9; ...Table of generated power (first column is wind speed, second column is power)
StringtableName"NoName"Table name on file or in function usertab (see documentation)
StringfileName"NoName"File where matrix is stored
replaceable package PhaseSystemPartialPhaseSystemPhase system
Wind correction
Realh Height over ground
HeighthRef10Reference height for wind measurement [m]
RealnWin0.4Height exponent for wind profile calculation
Nominal conditions
VoltageV_nominal Nominal voltage (V_nominal >= 0) [V]

Connectors

TypeNameDescription
input RealInputvWinSteady wind speed [m/s]
output RealOutputPGenerated power [W]
replaceable package PhaseSystemPhase system

Modelica definition

model WindTurbine "Wind turbine with power output based on table as a function of wind speed" extends Buildings.Electrical.Interfaces.PartialWindTurbine( redeclare package PhaseSystem = Buildings.Electrical.PhaseSystems.TwoConductor, redeclare Buildings.Electrical.DC.Interfaces.Terminal_p terminal); protected Loads.Conductor con( mode=Buildings.Electrical.Types.Load.VariableZ_P_input, V_nominal=V_nominal) "Conductor, used to interface the power with the electrical circuit"; equation connect(con.terminal, terminal); connect(gain.y, con.Pow); end WindTurbine;