DPsim
Classes | Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Protected Attributes | List of all members
CPS::SimNode< VarType > Class Template Reference
Inheritance diagram for CPS::SimNode< VarType >:
[legend]
Collaboration diagram for CPS::SimNode< VarType >:
[legend]

Classes

class  MnaPostStepHarm
 

Public Types

typedef VarType Type
 
typedef std::shared_ptr< SimNode< VarType > > Ptr
 
typedef std::vector< Ptr > List
 
- Public Types inherited from CPS::TopologicalNode
typedef std::shared_ptr< TopologicalNodePtr
 
typedef std::vector< Ptr > List
 
- Public Types inherited from CPS::IdentifiedObject
typedef std::shared_ptr< IdentifiedObjectPtr
 
typedef std::vector< Ptr > List
 

Public Member Functions

 SimNode (String uid, String name, std::vector< UInt > matrixNodeIndex, PhaseType phaseType, const std::vector< Complex > &initialVoltage)
 This very general constructor is used by other constructors.
 
 SimNode (PhaseType phaseType=PhaseType::Single)
 Create ground node if no parameters are given.
 
 SimNode (String name, PhaseType phaseType=PhaseType::Single, const std::vector< Complex > &initialVoltage={0, 0, 0})
 
 SimNode (String uid, String name, UInt matrixNodeIndex, PhaseType phaseType=PhaseType::Single, const std::vector< Complex > &initialVoltage={0, 0, 0})
 
 SimNode (UInt matrixNodeIndex, PhaseType phaseType=PhaseType::Single)
 
void initialize ()
 Initialize mVoltage according to mInitialVoltage.
 
void initialize (Matrix frequencies)
 Initialize state matrices with size according to phase type and frequency number.
 
UInt matrixNodeIndex (PhaseType phaseType=PhaseType::Single) override
 Returns matrix index for specified phase.
 
std::vector< UInt > matrixNodeIndices () override
 Returns all matrix indices.
 
VarType singleVoltage (PhaseType phaseType=PhaseType::Single)
 
MatrixVar< VarType > voltage ()
 
void setMatrixNodeIndex (UInt phase, UInt matrixNodeIndex) override
 
void setVoltage (VarType newVoltage)
 
void setPower (VarType newPower)
 
void mnaUpdateVoltage (const Matrix &leftVector)
 
void mnaInitializeHarm (std::vector< Attribute< Matrix >::Ptr > leftVector)
 
void mnaUpdateVoltageHarm (const Matrix &leftVector, Int freqIdx)
 
const Task::List & mnaTasks ()
 Return list of MNA tasks.
 
void mnaUpdateVoltage (const Matrix &leftVector)
 
void mnaUpdateVoltage (const Matrix &leftVector)
 
void mnaInitializeHarm (std::vector< Attribute< Matrix >::Ptr > leftVector)
 
void setVoltage (Complex newVoltage)
 
void setPower (Complex newPower)
 
- Public Member Functions inherited from CPS::TopologicalNode
 TopologicalNode (String uid, String name, PhaseType phaseType, const std::vector< Complex > &initialVoltage)
 This very general constructor is used by other constructors.
 
Bool isGround () const
 
MatrixComp initialVoltage () const
 
void setInitialVoltage (MatrixComp voltage) const
 
void setInitialVoltage (Complex voltage) const
 
void setInitialVoltage (Complex voltage, Int phaseIndex) const
 
Complex initialSingleVoltage (PhaseType phaseType=PhaseType::Single)
 
PhaseType phaseType () const
 
- Public Member Functions inherited from CPS::IdentifiedObject
 IdentifiedObject (const String &uid, const String &name)
 
 IdentifiedObject (const String &name)
 
AttributeBase::Ptr attribute (const String &name) const
 Return pointer to an attribute.
 
template<typename T >
Attribute< T >::Ptr attributeTyped (const String &name) const
 Return pointer to an attribute.
 
const AttributeBase::Map & attributes () const
 
String name ()
 
String uid ()
 Returns unique id.
 
String type ()
 Get component type (cross-platform)
 

Public Attributes

const Attribute< MatrixVar< VarType > >::Ptr mVoltage
 
const Attribute< MatrixVar< VarType > >::Ptr mApparentPower
 Power injected at node.
 
- Public Attributes inherited from CPS::TopologicalNode
const Attribute< MatrixComp >::Ptr mInitialVoltage
 
- Public Attributes inherited from CPS::IdentifiedObject
const Attribute< String >::Ptr mName
 Human readable name.
 
const Attribute< String >::Ptr mUID
 Unique identifier.
 

Static Public Attributes

static Ptr GND = SimNode<VarType>::make()
 

Protected Attributes

std::vector< UInt > mMatrixNodeIndex = {0}
 
Matrix mFrequencies
 List of considered network harmonics.
 
UInt mNumFreqs = 0
 Number of harmonics.
 
Task::List mMnaTasks
 
- Protected Attributes inherited from CPS::TopologicalNode
PhaseType mPhaseType = PhaseType::Single
 
Bool mIsGround = false
 
- Protected Attributes inherited from CPS::IdentifiedObject
AttributeList::Ptr mAttributes = AttributeList::make()
 Attribute List.
 

Additional Inherited Members

- Static Public Member Functions inherited from SharedFactory< SimNode< VarType > >
static std::shared_ptr< SimNode< VarType > > make (Args &&...args)
 

Detailed Description

template<typename VarType>
class CPS::SimNode< VarType >

Definition at line 17 of file SimNode.h.

Constructor & Destructor Documentation

◆ SimNode() [1/3]

template<typename VarType >
CPS::SimNode< VarType >::SimNode ( String  name,
PhaseType  phaseType = PhaseType::Single,
const std::vector< Complex > &  initialVoltage = {0, 0, 0} 
)
inline

Create named node and optionally assigns an initial voltage. This should be the constructor called by users in examples.

Definition at line 49 of file SimNode.h.

◆ SimNode() [2/3]

template<typename VarType >
CPS::SimNode< VarType >::SimNode ( String  uid,
String  name,
UInt  matrixNodeIndex,
PhaseType  phaseType = PhaseType::Single,
const std::vector< Complex > &  initialVoltage = {0, 0, 0} 
)
inline

Create node with name and node number. This is mostly used by functions.

Definition at line 54 of file SimNode.h.

◆ SimNode() [3/3]

template<typename VarType >
CPS::SimNode< VarType >::SimNode ( UInt  matrixNodeIndex,
PhaseType  phaseType = PhaseType::Single 
)
inline

Create node with default name and node number. This is mostly used by functions.

Definition at line 62 of file SimNode.h.


The documentation for this class was generated from the following files: