Introducing the Phasor Simulation Method
In this section, you
Apply the phasor simulation method to a simple linear circuit
Learn advantages and limitations of this method
Up to now you have used two methods to simulate electrical circuits:
Simulation with variable time steps using the continuous Simulink® solvers
Simulation with fixed time steps using a discretized system
This section explains how to use a third simulation method, the phasor solution method.
When to Use the Phasor Solution
The phasor solution method is mainly used to study electromechanical oscillations of power systems consisting of large generators and motors. An example of this method is the simulation of a multimachine system in Three-Phase Systems and Machines. However, this technique is not restricted to the study of transient stability of machines. It can be applied to any linear system.
If, in a linear circuit, you are interested only in the changes in magnitude and phase of all voltages and currents when switches are closed or opened, you do not need to solve all differential equations (state-space model) resulting from the interaction of R, L, and C elements. You can instead solve a much simpler set of algebraic equations relating the voltage and current phasors. This is what the phasor solution method does. As its name implies, this method computes voltages and currents as phasors. Phasors are complex numbers representing sinusoidal voltages and currents at a particular frequency. They can be expressed either in Cartesian coordinates (real and imaginary) or in polar coordinates (amplitude and phase). As the electrical states are ignored, the phasor solution method does not require a particular solver to solve the electrical part of your system. The simulation is therefore much faster to execute. Keep in mind, however, that this faster solution technique gives the solution only at one particular frequency.
Continuous and Discrete Phasor Solutions
In the Simulation type parameter of a Powergui block, you can choose one of two simulation methods. Phasor specifies a continuous phasor solution using a Simulink variable-step solver (such as ode23tb). Discrete phasor uses a local solver to discretize and solve the phasor model at a specified sample time. The discrete phasor simulation method allows you to use Simulink Coder™ to generate code and simulate your model in real time.
Contrary to the continuous phasor solver, which uses a full set of machine differential equations for modelling stator and rotor transients, the discrete phasor solver uses simplified three-phase synchronous and asynchronous machine models where differential equations on the stator side are replaced with algebraic equations. These lower-order machine models eliminate two states (the phid and phiq stator fluxes) to produce simulation results similar to commercial stability software.
Because of this simplification, high-frequency variations of electromagnetic torque and speed due to the DC components of transient stator currents are ignored, resulting in cleaner waveforms that are identical to those obtained with stability software. For stability studies of multi-machine systems involving low frequency electromechanical oscillations (typically in the 0.1–2 Hz range), the discrete phasor solver will produce accurate frequency and voltage variations with sample times in the 2–8 ms range, but which may differ slightly from those obtained with the continuous phasor solver. For models containing no machines, the phasor and discrete phasor solvers will produce identical results.
The larger sample times allowed for the discrete phasor solver allows you to
simulate much larger systems than with the discrete solver (when the
Simulation type parameter is set to
Discrete). The discrete phasor solver has also several
It uses a robust solution method that allows it to eliminate machine parasitic loads.
It eliminates voltage glitches that occur with the continuous phasor solver during fault clearing because small time constants are used in machine models to break algebraic loops.
It simulates multi-machine systems faster than the continuous phasor solver.
It allows you to use Simulink Coder to generate code and simulate your model in real time. With the continuous phasor solver, real-time simulation works only if the model contains no machines.
Continuous Phasor Simulation of a Circuit Transient
You now apply the phasor solution method to a simple linear
circuit. Open the example named Transient Analysis of a Linear Circuit
This circuit is a simplified model of a 60 Hz, 230-kV three-phase power system where only one phase is represented. The equivalent source is modeled by a voltage source (230 kV RMS / sqrt(3) or 132.8 kV RMS, 60 Hz) in series with its internal impedance (Rs Ls). The source feeds an RL load through a 150-km transmission line modeled by a single PI section (RL1 branch and two shunt capacitances, C1 and C2). A circuit breaker is used to switch the load (75 MW, 20 Mvar) at the receiving end of the transmission line. Two measurement blocks are used to monitor the load voltage and current.
The Powergui block at the lower-left corner indicates that the model is continuous. Select the I_load and V_line signals. From the Simulation Data Inspector, select Log Selected Signals. Start the simulation and observe transients in voltage and current waveforms when the load is first switched off at t = 0.0333 s (2 cycles) and switched on again at t = 0.1167 s (7 cycles).
Invoking the Phasor Solution in the Powergui Block
You now simulate the same circuit using the phasor simulation method. This
option is accessible through the Powergui block. Open the Powergui block. Set the
Simulation type parameter to
Phasor. Specify the frequency used to solve the
algebraic network equations. A default value of 60 Hz should already be entered
in the Frequency (Hz) field. Close the Powergui and notice
that the words
Phasor 60 Hz now appear on the Powergui icon,
indicating that the Powergui now applies this method to simulate your circuit.
Before restarting the simulation, specify the appropriate format for the two
signals sent to the Scope block.
Selecting Phasor Signal Measurement Formats
If you now double-click the Voltage Measurement block or
the Current Measurement block, you
see that the Output Signal parameter allows you to output
phasor signals in four different formats:
Complex format is
useful when you want to process complex signals. Note that the Scope block does not accept
complex signals. Select
Magnitude format for both the
Line Voltage and the Load Current Measurement
blocks. This allows you to observe the magnitude of the voltage and current
Restart the simulation. Open the Simulation Data Inspector. Waveforms obtained from the continuous simulation and the phasor simulation are superimposed in this plot.
Waveforms Obtained with the Continuous and Phasor Simulation Methods
Note that with continuous simulation, the opening of the circuit breaker occurs at the next zero crossing of current following the opening order; whereas for the phasor simulation, this opening is instantaneous. This is because there is no concept of zero crossing in the phasor simulation.
Processing Voltage and Current Phasors
To use the Discrete phasor solution method, open the powergui block and set
Simulation type to
phasor. Set Sample time (s) to
1e-3 sec. Run the simulation. The voltage and current
magnitude waveforms should compare with the continuous phasor model, except that
the resolution for the breaker switching times is now 1 ms.
Complex format allows the use of complex
operations and processing of phasors without separating real and imaginary
parts. Suppose, for example, that you need to compute the power consumption
of the load (active power
P and reactive
Q). The complex power
obtained from the voltage and current phasors as
I* is the conjugate of the
current phasor. The 1/2 factor is required to convert magnitudes of
voltage and current from peak values to RMS values.
Complex format for both current and voltage and, using blocks
from the Simulink Math library, implement the power measurement as shown.
Power Computation Using Complex Voltage and Current
The Complex to Magnitude-Angle blocks are required to convert complex phasors to magnitudes before sending them to the scope.
Note that the Power (phasor) block available in the Specialized Power Systems > Control & Measurements > Measurements library implements the above complex equation for measuring active power (P) and reactive power (Q). Connect the complex outputs of the voltage and current measurement blocks to the V and I inputs of the Power (phasor) block.