This example shows how simplify the custom Simscape™ synchronous machine model.
Detailed per-unit stator voltage equations include the effect of rate of change of magnetic flux linkage, and the effect of speed variation:
Large-scale studies are simulations that include more than 10 generators or motors. To reduce computational requirements of large-scale studies, simplifications are necessary. Simplifications for large-scale studies, include neglecting the following:
The transformer voltage terms, and
The effect of speed variations. is set to 1.
These simplifications yield the following per-unit stator voltage equations:
You can use the Comparison Tool to see the differences between the detailed and simplified Simscape components. Type visdiff( 'ThreePhaseExamples.sm', 'ThreePhaseExamples.sm_simplified' ) at the MATLAB® command line to open the Comparison Tool to see the detailed differences on lines 176 and 177 of the files. The detailed Synchronous Machine component is on the left side, and the simplified Synchronous Machine component is on the right side.
Open the model.
open_system( 'ee_custom_sm_simplified' );
Specify values of initial conditions.
pu_psid0 = 0.7850; pu_psiq0 = -0.6216; pu_psifd0 = 0.9553; pu_psi1d0 = 0.8269; pu_psi1q0 = -0.5686; pu_psi2q0 = -0.5686; Efd0 = 1.2803; torque0 = 0.4610;
The example model, ee_custom_sm_simplified, has been configured using Simulink® Variants. To execute the detailed model, set the variable isSimplified to false. To execute the simplified model, set the variable isSimplified to true.
Simulate detailed model.
isSimplified = false; %#ok<NASGU> sim( 'ee_custom_sm_simplified' ); t1 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine.Synchronous_Machine.pu_voltage.series.time; v1 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine.Synchronous_Machine.pu_voltage.series.values; w1 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine.Synchronous_Machine.pu_velocity.series.values;
Simulate simplified model.
isSimplified = true;
sim( 'ee_custom_sm_simplified' );
t2 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine_simplified.Synchronous_Machine_simplified.pu_voltage.series.time;
v2 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine_simplified.Synchronous_Machine_simplified.pu_voltage.series.values;
w2 = simlog_ee_custom_sm_simplified.Synchronous_Machine_Variant.Synchronous_Machine_simplified.Synchronous_Machine_simplified.pu_velocity.series.values;
The voltage and rotor velocity traces can be overlaid to directly compare differences.
figure; subplot(2,1,1); plot( t1, v1, t2, v2 ); ylim( [ 0.95 1.05 ] ); legend( 'Detailed', 'Simplified' ); title( 'Terminal voltage, pu' ); subplot(2,1,2); plot( t1, w1, t2, w2 ); ylim( [ 0.95 1.05 ] ); title( 'Rotor velocity, pu' );
This example shows:
How to simplify the custom synchronous machine model
A comparison of Simscape component source code
A comparison of model simulation outputs