modelPortAC
AC port computing auxiliary quantities
Information
This model computes quantities associated to an AC port that can be useful or relevant for modelling and monitoring purposes, such as the complex power flow, the absolute value of the phase-to-phase voltage, the angle of the current, or various per-unit quantities. The phase-to-ground voltage and line current phasors must be assigned as inputs.
Per-unit quantities, angles and quantities using the generator convention are defined if the corresponding parameters portVariablesPu, portVariablesAngles, and generatorConvention are set to true, respectively.
Parameters
| Type | Name | Default | Description |
|---|---|---|---|
| Types.Power | SNom | Nominal or rated power | |
| Types.Voltage | UNom | Nominal or rated phase-to-phase voltage | |
| Types.Power | SBase | SNom | Base power |
| Types.Voltage | UBase | UNom | Base phase-to-phase voltage |
| Types.Power | PStart | Start value of active power flowing into port | |
| Types.Power | QStart | Start value of reactive power flowing into port | |
| Types.Voltage | UStart | UNom | Start value of phase-to-phase voltage modulus |
| Types.Angle | UPhaseStart | 0 | Start value of voltage phase |
| Boolean | portVariablesPhases | false | Compute voltage and current phases for monitoring purposes only |
| Boolean | portVariablesPu | true | Add per-unit variables to model |
| Boolean | generatorConvention | false | Add currents with generator convention (i > 0 when exiting the device) to model |
| Types.Voltage | VBase | UBase/sqrt(3) | Base phase-to-ground voltage |
| Types.Current | IBase | SBase/(3*VBase) | Base current |
| Types.Voltage | VStart | UStart/sqrt(3) | Start value of phase-to ground voltage modulus |
| Types.Current | IStart | sqrt(PStart^2 + QStart^2)/(3*VStart) | Start value of current modulus |
| Types.ComplexVoltage | vStart | CM.fromPolar(UStart/sqrt(3), UPhaseStart) | Start value of phase-to-ground voltage phasor |
| Types.ComplexCurrent | iStart | CM.conj(Complex(PStart, QStart)/(Complex(3)*vStart)) | Start value of current phasor flowing into the port |
Components
| Type | Name | Default | Description |
|---|---|---|---|
| InputComplexVoltage | v | Port voltage (line-to-neutral) | |
| InputComplexCurrent | i | Port current | |
| Types.ComplexVoltage | u | sqrt(3)*v | Complex phase-to-phase voltage |
| Types.ComplexPower | S | 3*v*CM.conj(i) | Complex power flowing into the port |
| Types.ActivePower | P | S.re | Active power flowing into the port |
| Types.ReactivePower | Q | S.im | Reactive power flowing into the port |
| Types.Voltage | U | CM.'abs'(u) | Port voltage absolute value (phase-to-phase) |
| Types.Current | I | CM.'abs'(i) | Port current (positive entering) |
| Types.PerUnit | PPu | if portVariablesPu then S.re/SBase else 0 | Active power flowing into the port in p.u. (base SBase) |
| Types.PerUnit | QPu | if portVariablesPu then S.im/SBase else 0 | Reactive power flowing into the port in p.u. (base SBase) |
| Types.ComplexPerUnit | vPu | if portVariablesPu then u*(1/UBase) else Complex(0) | Complex voltage across the port in p.u. (base VBase) |
| SI.PerUnit | VPu | if portVariablesPu then U/UBase else 0 | Absolute value of voltage across the port in p.u. (base VBase) |
| Types.ComplexPerUnit | iPu | if portVariablesPu then i*(1/IBase) else Complex(0) | Complex current flowing into the port in p.u. (base IBase) |
| SI.PerUnit | IPu | if portVariablesPu then I/IBase else 0 | Absolute value of complex current flowing into the port in p.u. (base IBase) |
| Types.Angle | UPhase | if portVariablesPhases then atan2(v.im, v.re) else 0 | Phase of voltage across the port |
| Types.Angle | IPhase | if portVariablesPhases then atan2(i.im, i.re) else 0 | Phase of current into the port |
| Types.ComplexCurrent | iGen | -i | Port current, generator convention |
| Types.ActivePower | PGen | -S.re | Active power flowing out of the port |
| Types.ReactivePower | QGen | -S.im | Reactive power flowing out of the port |
| Types.PerUnit | PGenPu | -PPu | Active power flowing out of the port in p.u. (base SBase) |
| Types.PerUnit | QGenPu | -QPu | Reactive power flowing out of the port in p.u. (base SBase) |
| Types.ComplexPerUnit | iGenPu | -iPu | Complex current flowing out of the port in p.u. (base IBase) |
| SI.PerUnit | IGenPu | if portVariablesPu and generatorConvention then I/IBase else 0 | Absolute value of current flowing out of the port in p.u. (base IBase) |
Contents
| Name | Description |
|---|---|
| InputComplexVoltage | Marks potential input for balancedness check without requiring binding equation |
| InputComplexCurrent | Marks potential input for balancedness check without requiring binding equation |