11 #include <dpsim-models/Base/Base_SynchronGenerator.h>
12 #include <dpsim-models/MNASimPowerComp.h>
13 #include <dpsim-models/Solver/MNAInterface.h>
27 Logger::Level logLevel = Logger::Level::off);
45 void trapezoidalCurrentStates();
54 Real nomPower, Real nomVolt, Real nomFreq, Int poleNumber,
55 Real nomFieldCur, Real Rs, Real Ll, Real Lmd, Real Lmq, Real Rfd,
56 Real Llfd, Real Rkd, Real Llkd, Real Rkq1, Real Llkq1, Real Rkq2,
57 Real Llkq2, Real inertia, Real initActivePower, Real initReactivePower,
58 Real initTerminalVolt, Real initVoltAngle, Real initMechPower);
66 Real electricalTorque()
const;
68 Real rotationalSpeed()
const;
70 Real rotorPosition()
const;
72 void step(MatrixComp &voltage, Real time);
81 void mnaStep(Matrix &systemMatrix, Matrix &rightVector, Matrix &leftVector,
84 void mnaCompApplyRightSideVectorStamp(Matrix &rightVector)
override;
86 void mnaCompApplySystemMatrixStamp(SparseMatrixRow &systemMatrix)
override;
94 AttributeBase::List &attributeDependencies,
95 AttributeBase::List &modifiedAttributes,
97 void mnaCompPostStep(Real time, Int timeStepCount,
Base synchronous generator model.
Synchronous generator model in dq-reference frame.
void step(MatrixComp &voltage, Real time)
Calculates flux and current from the voltage vector.
void initialize(Real omega, Real timeStep)
SynchronGeneratorDQ(String name, String uid, Logger::Level logLevel=Logger::Level::off)
Defines UID, name and logging level.
void trapezoidalFluxStates()
calculate flux states using trapezoidal rule - depcrecated
virtual void mnaCompUpdateVoltage(const Matrix &leftVector) override
Retrieves calculated voltage from simulation for next step.
void mnaCompAddPostStepDependencies(AttributeBase::List &prevStepDependencies, AttributeBase::List &attributeDependencies, AttributeBase::List &modifiedAttributes, Attribute< Matrix >::Ptr &leftVector) override
Add MNA post step dependencies.
Matrix abcToDq0Transform(Real theta, MatrixComp &abc)
Park transform as described in Krause.
virtual void mnaCompInitialize(Real omega, Real timeStep, Attribute< Matrix >::Ptr leftVector) override=0
Initializes variables of component.
void mnaStep(Matrix &systemMatrix, Matrix &rightVector, Matrix &leftVector, Real time)
MatrixComp mCompensationCurrent
Compensation current source set point.
void setParametersFundamentalPerUnit(Real nomPower, Real nomVolt, Real nomFreq, Int poleNumber, Real nomFieldCur, Real Rs, Real Ll, Real Lmd, Real Lmq, Real Rfd, Real Llfd, Real Rkd, Real Llkd, Real Rkq1, Real Llkq1, Real Rkq2, Real Llkq2, Real inertia, Real initActivePower, Real initReactivePower, Real initTerminalVolt, Real initVoltAngle, Real initMechPower)
MatrixComp dq0ToAbcTransform(Real theta, Matrix &dq0)
Inverse Park transform as described in Krause.
String uid()
Returns unique id.
Base class for all MNA components that are transmitting power.