11 #include <dpsim-models/Base/Base_Ph1_Switch.h>
12 #include <dpsim-models/MNASimPowerComp.h>
13 #include <dpsim-models/Solver/MNAInterface.h>
14 #include <dpsim-models/Solver/MNASwitchInterface.h>
15 #include <dpsim-models/Solver/MNAVariableCompInterface.h>
34 Bool mPrevState =
false;
35 Real mDeltaResClosed = 0;
36 Real mDeltaResOpen = 1.5;
44 void setInitParameters(Real timestep);
48 Logger::Level logLevel = Logger::Level::off);
50 varResSwitch(String name, Logger::Level logLevel = Logger::Level::off)
85 AttributeBase::List &attributeDependencies,
86 AttributeBase::List &modifiedAttributes,
94 SparseMatrixRow &systemMatrix,
Dynamic Phasor Three-Phase Switch.
String uid()
Returns unique id.
Base class for all MNA components that are transmitting power.
MNA interface to be used by switching devices.
MNA interface to be used by elements that require recomputing of the system matrix.
Switch with variable resistance to avoid numerical oscillations, when an inductive current is suddenl...
void mnaCompApplySystemMatrixStamp(SparseMatrixRow &systemMatrix)
Stamps system matrix.
Bool mnaIsClosed()
Check if switch is closed.
void mnaCompApplySwitchSystemMatrixStamp(Bool closed, SparseMatrixRow &systemMatrix, Int freqIdx)
Stamps system matrix considering the defined switch position.
SimPowerComp< Complex >::Ptr clone(String name)
Returns a modified copy of the component with the given suffix added to the name and without.
Bool hasParameterChanged()
Returns true if one of the element paramters has changed.
void initializeFromNodesAndTerminals(Real frequency)
Initializes states from power flow data.
void mnaCompUpdateCurrent(const Matrix &leftVector)
Update interface current from MNA system results.
varResSwitch(String uid, String name, Logger::Level logLevel=Logger::Level::off)
Defines UID, name and log level.
void mnaCompInitialize(Real omega, Real timeStep, Attribute< Matrix >::Ptr leftVector)
Initializes MNA specific variables.
void mnaCompAddPostStepDependencies(AttributeBase::List &prevStepDependencies, AttributeBase::List &attributeDependencies, AttributeBase::List &modifiedAttributes, Attribute< Matrix >::Ptr &leftVector)
void mnaCompPostStep(Real time, Int timeStepCount, Attribute< Matrix >::Ptr &leftVector)
MNA pre step operations.
void mnaCompUpdateVoltage(const Matrix &leftVector)
Update interface voltage from MNA system results.
varResSwitch(String name, Logger::Level logLevel=Logger::Level::off)
Defines name and log level.
void mnaCompApplyRightSideVectorStamp(Matrix &rightVector)
Stamps right side (source) vector.
Base class for all components that are transmitting power.