Harmony
HARMONic stabilitY assessment of PE-penetrated power systems
Loading...
Searching...
No Matches
AC_source.h
Go to the documentation of this file.
1#ifndef AC_SOURCE_H
2#define AC_SOURCE_H
3
9#include "Source_base.h"
10
19class AC_source : public Source_base {
20public:
29 AC_source(const std::string& symbol, const std::string& location, int pins, double V, DenseMatrix Z);
38 AC_source(const std::string& symbol, const std::string& location, int pins, double V, const std::vector<double>& Z);
47 AC_source(const std::string& symbol, const std::string& location, int pins, double V, const double Z);
48
49 // Destructor
50 ~AC_source();
51
52 void writeMNAmatrix(SymEngine::DenseMatrix&, std::unordered_map<Bus*, int>&, int, std::map<Element*, std::vector<RCP<const Basic>>>&) override;
53
54 std::vector<MatrixXcd> simulateInputStep(
55 const std::vector<MatrixXcd>& states, int nKeep) const override;
56
57 // Function to print AC source values
58 void printElementValues() override;
59
60private:
61 // Properties
62
63};
64
65#endif
66
Base class for AC and DC voltage sources and generators.
Ideal AC voltage source with added series impedance.
Definition AC_source.h:19
~AC_source()
Definition AC_source.cpp:96
std::vector< MatrixXcd > simulateInputStep(const std::vector< MatrixXcd > &states, int nKeep) const override
Simulate a step response given input states (override in dynamic elements).
Definition AC_source.cpp:145
void writeMNAmatrix(SymEngine::DenseMatrix &, std::unordered_map< Bus *, int > &, int, std::map< Element *, std::vector< RCP< const Basic > > > &) override
Stamp this element into the symbolic MNA matrix (override in derived classes).
Definition AC_source.cpp:102
void printElementValues() override
Print extended element-specific values (override in derived classes).
Definition AC_source.cpp:140
Base class for multi-phase network elements with Y-parameters and MNA stamping hooks.
Definition Element.h:29
Common properties and power-flow methods for source elements.
Definition Source_base.h:16
vector< double > V
Definition Source_base.h:35