Description: "DC system"

- Home > Modelica

## Buildings.Electrical.PhaseSystems.DirectCurrent

DC system

### Information

This package declares the functions that are used to implement the DC models.

Extends from PartialPhaseSystem (Base package of all phase systems).

### Package Content

Name | Description
--- | ---
j | Direct current has no complex component
rotate | Rotate a vector of an angle Theta (anti-counterclock)
thetaRel | Return absolute angle of rotating system as offset to thetaRef
thetaRef | Return absolute angle of rotating reference system
phase | Return phase
phaseVoltages | Return phase to neutral voltages
phaseCurrents | Return phase currents
phasePowers | Return phase powers
phasePowers_vi | Return phase powers
systemVoltage | Return system voltage as function of phase voltages
systemCurrent | Return system current as function of phase currents
activePower | Return total power as function of phase powers
Inherited
phaseSystemName="UnspecifiedPhaseSystem" | Name of the phase system represented by the package
n | Number of independent voltage and current components
m | Number of reference angles
Current | Current for connector
Voltage | Voltage for connector
ReferenceAngle | Reference angle for connector
jj | Vectorized version of j
product | Multiply two vectors
divide | Divide two vectors

## Buildings.Electrical.PhaseSystems.DirectCurrent.j

Direct current has no complex component

### Information

Extends from (Return vector rotated by 90 degrees).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Real | x[n] |  |

### Outputs

Type | Name | Description
--- | --- | ---
Real | y[n] |

### Modelica definition

redeclare function extends j "Direct current has no complex component" algorithm y := zeros(n); end j;

## Buildings.Electrical.PhaseSystems.DirectCurrent.rotate

Rotate a vector of an angle Theta (anti-counterclock)

### Information

Extends from (Rotate a vector of an angle Theta (anti-counterclock)).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Real | x[n] |  |
Angle | theta |  | [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Real | y[n] |

### Modelica definition

redeclare function extends rotate "Rotate a vector of an angle Theta (anti-counterclock)" algorithm y[n] := x[n]; end rotate;

## Buildings.Electrical.PhaseSystems.DirectCurrent.thetaRel

Return absolute angle of rotating system as offset to thetaRef

### Information

Extends from (Return absolute angle of rotating system as offset to thetaRef).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Angle | theta[m] |  | [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Angle | thetaRel | [rad]

### Modelica definition

redeclare function extends thetaRel "Return absolute angle of rotating system as offset to thetaRef" algorithm thetaRel := 0; end thetaRel;

## Buildings.Electrical.PhaseSystems.DirectCurrent.thetaRef

Return absolute angle of rotating reference system

### Information

Extends from (Return absolute angle of rotating reference system).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Angle | theta[m] |  | [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Angle | thetaRef | [rad]

### Modelica definition

redeclare function extends thetaRef "Return absolute angle of rotating reference system" algorithm thetaRef := 0; end thetaRef;

## Buildings.Electrical.PhaseSystems.DirectCurrent.phase

Return phase

### Information

Extends from (Return phase).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Real | x[n] |  |

### Outputs

Type | Name | Description
--- | --- | ---
Angle | phase | [rad]

### Modelica definition

redeclare function extends phase "Return phase" algorithm phase := 0; end phase;

## Buildings.Electrical.PhaseSystems.DirectCurrent.phaseVoltages

Return phase to neutral voltages

### Information

Extends from (Return phase to neutral voltages).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Voltage | V |  | system voltage [V]
Angle | phi | 0 | phase angle [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Voltage | v[n] | phase to neutral voltages [V]

### Modelica definition

redeclare replaceable function extends phaseVoltages "Return phase to neutral voltages" algorithm v := {V}; end phaseVoltages;

## Buildings.Electrical.PhaseSystems.DirectCurrent.phaseCurrents

Return phase currents

### Information

Extends from (Return phase currents).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Current | I |  | system current [A]
Angle | phi | 0 | phase angle [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Current | i[n] | phase currents [A]

### Modelica definition

redeclare function extends phaseCurrents "Return phase currents" algorithm i := {I}; end phaseCurrents;

## Buildings.Electrical.PhaseSystems.DirectCurrent.phasePowers

Return phase powers

### Information

Extends from (Return phase powers).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
ActivePower | P |  | active system power [W]
Angle | phi | 0 | phase angle [rad]

### Outputs

Type | Name | Description
--- | --- | ---
Power | p[n] | phase powers [W]

### Modelica definition

redeclare function extends phasePowers "Return phase powers" algorithm p := {P}; end phasePowers;

## Buildings.Electrical.PhaseSystems.DirectCurrent.phasePowers_vi

Return phase powers

### Information

Extends from (Return phase powers).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Voltage | v[n] |  | phase voltages [V]
Current | i[n] |  | phase currents [A]

### Outputs

Type | Name | Description
--- | --- | ---
Power | p[n] | phase powers [W]

### Modelica definition

redeclare function extends phasePowers_vi "Return phase powers" algorithm p := {v*i}; end phasePowers_vi;

## Buildings.Electrical.PhaseSystems.DirectCurrent.systemVoltage

Return system voltage as function of phase voltages

### Information

Extends from (Return system voltage as function of phase voltages).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Voltage | v[n] |  | [V]

### Outputs

Type | Name | Description
--- | --- | ---
Voltage | V | [V]

### Modelica definition

redeclare replaceable function extends systemVoltage "Return system voltage as function of phase voltages" algorithm V := v[1]; end systemVoltage;

## Buildings.Electrical.PhaseSystems.DirectCurrent.systemCurrent

Return system current as function of phase currents

### Information

Extends from (Return system current as function of phase currents).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Current | i[n] |  | [A]

### Outputs

Type | Name | Description
--- | --- | ---
Current | I | [A]

### Modelica definition

redeclare function extends systemCurrent "Return system current as function of phase currents" algorithm I := i[1]; end systemCurrent;

## Buildings.Electrical.PhaseSystems.DirectCurrent.activePower

Return total power as function of phase powers

### Information

Extends from (Return total power as function of phase powers).

### Inputs

Type | Name | Default | Description
--- | --- | --- | ---
Voltage | v[n] |  | phase voltages [V]
Current | i[n] |  | phase currents [A]

### Outputs

Type | Name | Description
--- | --- | ---
ActivePower | P | active system power [W]

### Modelica definition

redeclare function extends activePower "Return total power as function of phase powers" algorithm P := v*i; end activePower;