11 #include <dpsim-models/Base/Base_Ph3_PiLine.h>
12 #include <dpsim-models/MNASimPowerComp.h>
13 #include <dpsim-models/SP/SP_Ph3_Inductor.h>
14 #include <dpsim-models/SP/SP_Ph3_Resistor.h>
15 #include <dpsim-models/Solver/MNAInterface.h>
38 RxLine(String
uid, String name, Logger::Level logLevel = Logger::Level::off);
40 RxLine(String name, Logger::Level logLevel = Logger::Level::off)
41 :
RxLine(name, name, logLevel) {}
59 void mnaCompUpdateVoltage(
const Matrix &leftVector);
60 void mnaCompUpdateCurrent(
const Matrix &leftVector);
64 AttributeBase::List &prevStepDependencies,
65 AttributeBase::List &attributeDependencies,
66 AttributeBase::List &modifiedAttributes)
override;
68 AttributeBase::List &attributeDependencies,
69 AttributeBase::List &modifiedAttributes) {
70 mAttributeDependencies.push_back(
71 line.mSubResistor->attribute(
"right_vector"));
72 mAttributeDependencies.push_back(
73 line.mSubInductor->attribute(
"right_vector"));
74 mModifiedAttributes.push_back(line.attribute(
"right_vector"));
80 AttributeBase::List &attributeDependencies,
81 AttributeBase::List &modifiedAttributes,
85 AttributeBase::List &attributeDependencies,
86 AttributeBase::List &modifiedAttributes,
88 mAttributeDependencies.push_back(leftVector);
89 mAttributeDependencies.push_back(line.mSubInductor->attribute(
"i_intf"));
90 mModifiedAttributes.push_back(line.attribute(
"i_intf"));
91 mModifiedAttributes.push_back(line.attribute(
"v_intf"));
String uid()
Returns unique id.
Base class for all MNA components that are transmitting power.
void mnaCompAddPostStepDependencies(AttributeBase::List &prevStepDependencies, AttributeBase::List &attributeDependencies, AttributeBase::List &modifiedAttributes, Attribute< Matrix >::Ptr &leftVector) override
Add MNA post step dependencies.
void initializeFromNodesAndTerminals(Real frequency)
Initializes component from power flow data.
void mnaCompAddPreStepDependencies(AttributeBase::List &prevStepDependencies, AttributeBase::List &attributeDependencies, AttributeBase::List &modifiedAttributes) override
Add MNA pre step dependencies.
void mnaCompApplyRightSideVectorStamp(Matrix &rightVector)
Stamps right side (source) vector.
void mnaApplyInitialSystemMatrixStamp(SparseMatrixRow &systemMatrix)
Stamps system matrix.
RxLine(String name, Logger::Level logLevel=Logger::Level::off)
Defines name, component parameters and logging level.
void mnaCompInitialize(Real omega, Real timeStep, Attribute< Matrix >::Ptr leftVector)
Initializes internal variables of the component.
std::shared_ptr< Resistor > mInitialResistor
Inductor end to ground resistor to facilitate initialization.
RxLine(String uid, String name, Logger::Level logLevel=Logger::Level::off)
Defines UID, name, logging level.
Matrix mVoltage
Voltage across the component [V].
std::shared_ptr< Inductor > mSubInductor
Inductance submodel.
Matrix mCurrent
Current through the component [A].
void mnaCompApplySystemMatrixStamp(SparseMatrixRow &systemMatrix)
Stamps system matrix.
SimPowerComp< Real >::Ptr clone(String name)
Returns a modified copy of the component with the given suffix added to the name and without.
std::shared_ptr< Resistor > mSubResistor
Resistor submodel.
Base class for all components that are transmitting power.