## Buildings.Electrical.PhaseSystems.OnePhase

Single phase two connectors AC system

### Information

This package declares the functions that are used to implement the AC single phase models.

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

### Package Content

Name Description
j Return vector rotated by 90 degrees
rotate Rotate a vector of an angle Theta (anti-counterclock)
product Multiply two complex numbers represented by vectors x[2] and y[2]
divide Divide two complex numbers represented by vectors x[2] and y[2]
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
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

## Buildings.Electrical.PhaseSystems.OnePhase.j

Return vector rotated by 90 degrees

### Information

Extends from (Return vector rotated by 90 degrees).

### Inputs

TypeNameDefaultDescription
Realx[n]

### Outputs

TypeNameDescription
Realy[n]

### Modelica definition

redeclare function extends j "Return vector rotated by 90 degrees" algorithm y := {-x[2], x[1]}; end j;

## Buildings.Electrical.PhaseSystems.OnePhase.rotate

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

### Information

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

### Inputs

TypeNameDefaultDescription
Realx[n]

### Outputs

TypeNameDescription
Realy[n]

### Modelica definition

redeclare function extends rotate "Rotate a vector of an angle Theta (anti-counterclock)" algorithm y[1] := cos(theta)*x[1] - sin(theta)*x[2]; y[2] := sin(theta)*x[1] + cos(theta)*x[2]; end rotate;

## Buildings.Electrical.PhaseSystems.OnePhase.product

Multiply two complex numbers represented by vectors x[2] and y[2]

### Information

Extends from (Multiply two vectors).

### Inputs

TypeNameDefaultDescription
Realx[n]
Realy[n]

### Outputs

TypeNameDescription
Realz[n]

### Modelica definition

redeclare function extends product "Multiply two complex numbers represented by vectors x[2] and y[2]" algorithm z := {x[1]*y[1] - x[2]*y[2], x[1]*y[2] + x[2]*y[1]}; end product;

## Buildings.Electrical.PhaseSystems.OnePhase.divide

Divide two complex numbers represented by vectors x[2] and y[2]

### Information

Extends from (Divide two vectors).

### Inputs

TypeNameDefaultDescription
Realx[n]
Realy[n]

### Outputs

TypeNameDescription
Realz[n]

### Modelica definition

redeclare function extends divide "Divide two complex numbers represented by vectors x[2] and y[2]" algorithm z := {x[1]*y[1] + x[2]*y[2], x[2]*y[1] - x[1]*y[2]}/(y[1]^2 + y[2]^2); end divide;

## Buildings.Electrical.PhaseSystems.OnePhase.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

TypeNameDefaultDescription

### Outputs

TypeNameDescription

### Modelica definition

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

## Buildings.Electrical.PhaseSystems.OnePhase.thetaRef

Return absolute angle of rotating reference system

### Information

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

### Inputs

TypeNameDefaultDescription

### Outputs

TypeNameDescription

### Modelica definition

redeclare function extends thetaRef "Return absolute angle of rotating reference system" algorithm thetaRef := theta[1]; end thetaRef;

## Buildings.Electrical.PhaseSystems.OnePhase.phase

Return phase

### Information

Extends from (Return phase).

### Inputs

TypeNameDefaultDescription
Realx[n]

### Outputs

TypeNameDescription

### Modelica definition

redeclare function extends phase "Return phase" algorithm phase := atan2(x[2], x[1]); end phase;

## Buildings.Electrical.PhaseSystems.OnePhase.phaseVoltages

Return phase to neutral voltages

### Information

Extends from (Return phase to neutral voltages).

### Inputs

TypeNameDefaultDescription
VoltageV system voltage [V]

### Outputs

TypeNameDescription
Voltagev[n]phase to neutral voltages [V]

### Modelica definition

redeclare function extends phaseVoltages "Return phase to neutral voltages" algorithm v := {V*cos(phi), V*sin(phi)}; end phaseVoltages;

## Buildings.Electrical.PhaseSystems.OnePhase.phaseCurrents

Return phase currents

### Information

Extends from (Return phase currents).

### Inputs

TypeNameDefaultDescription
CurrentI system current [A]

### Outputs

TypeNameDescription
Currenti[n]phase currents [A]

### Modelica definition

redeclare function extends phaseCurrents "Return phase currents" algorithm i := {I*cos(phi), I*sin(phi)}; end phaseCurrents;

## Buildings.Electrical.PhaseSystems.OnePhase.phasePowers

Return phase powers

### Information

Extends from (Return phase powers).

### Inputs

TypeNameDefaultDescription
ActivePowerP active system power [W]

### Outputs

TypeNameDescription
Powerp[n]phase powers [W]

### Modelica definition

redeclare function extends phasePowers "Return phase powers" algorithm p := {P, P*tan(phi)}; end phasePowers;

## Buildings.Electrical.PhaseSystems.OnePhase.phasePowers_vi

Return phase powers

### Information

Extends from (Return phase powers).

### Inputs

TypeNameDefaultDescription
Voltagev[n] phase voltages [V]
Currenti[n] phase currents [A]

### Outputs

TypeNameDescription
Powerp[n]phase powers [W]

### Modelica definition

redeclare function extends phasePowers_vi "Return phase powers" algorithm p := {v[1]*i[1] + v[2]*i[2], v[2]*i[1] - v[1]*i[2]}; end phasePowers_vi;

## Buildings.Electrical.PhaseSystems.OnePhase.systemVoltage

Return system voltage as function of phase voltages

### Information

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

### Inputs

TypeNameDefaultDescription
Voltagev[n] [V]

### Outputs

TypeNameDescription
VoltageV[V]

### Modelica definition

redeclare function extends systemVoltage "Return system voltage as function of phase voltages" algorithm V := Modelica.Fluid.Utilities.regRoot(v*v, delta= 1e-5); end systemVoltage;

## Buildings.Electrical.PhaseSystems.OnePhase.systemCurrent

Return system current as function of phase currents

### Information

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

### Inputs

TypeNameDefaultDescription
Currenti[n] [A]

### Outputs

TypeNameDescription
CurrentI[A]

### Modelica definition

redeclare function extends systemCurrent "Return system current as function of phase currents" algorithm I := Modelica.Fluid.Utilities.regRoot(i*i, delta= 1e-5); end systemCurrent;

## Buildings.Electrical.PhaseSystems.OnePhase.activePower

### Inputs

TypeNameDefaultDescription
Voltagev[n] phase voltages [V]
Currenti[n] phase currents [A]

### Outputs

TypeNameDescription
ActivePowerPactive system power [W]

### Modelica definition

redeclare function extends activePower "Return total power as function of phase powers" algorithm // P = v[1]*i[1] + v[2]*i[2] P := v*i; end activePower;

Automatically generated Mon May 4 10:19:58 2015.