DPsim
Loading...
Searching...
No Matches
DP_Ph1_DPDQInterface.h
1/* Copyright 2017-2021 Institute for Automation of Complex Power Systems,
2 * EONERC, RWTH Aachen University
3 *
4 * This Source Code Form is subject to the terms of the Mozilla Public
5 * License, v. 2.0. If a copy of the MPL was not distributed with this
6 * file, You can obtain one at https://mozilla.org/MPL/2.0/.
7 *********************************************************************************/
8
9#pragma once
10
11#include <dpsim-models/Definitions.h>
12
13namespace CPS {
14namespace DP {
15namespace Ph1 {
18
19protected:
21 MatrixFixedSize<2, 2> mDQToDPTransform;
23 MatrixFixedSize<2, 2> mDPToDQTransform;
24
27
28public:
31
33 void setDPShiftFrequency(const Real &omegaShift);
34
36 MatrixFixedSize<2, 2> DQToDPTransform() { return mDQToDPTransform; };
38 MatrixFixedSize<2, 2> DPToDQTransform() { return mDPToDQTransform; };
39
41 void updateDQToDPTransform(const Real &thetaDQ, const Real &simTime);
43 void updateDPToDQTransform(const Real &thetaDQ, const Real &simTime);
44
46 Complex applyDQToDPTransform(const MatrixFixedSize<2, 1> &dqMatrix);
48 MatrixFixedSize<2, 1> applyDPToDQTransform(const Complex &dpComplex);
49};
50} // namespace Ph1
51} // namespace DP
52} // namespace CPS
MatrixFixedSize< 2, 2 > mDQToDPTransform
Transform from DQ to DP domain.
void updateDQToDPTransform(const Real &thetaDQ, const Real &simTime)
Update transformation matrix from DQ to DP.
void updateDPToDQTransform(const Real &thetaDQ, const Real &simTime)
Update transformation matrix from DP to DQ.
MatrixFixedSize< 2, 2 > DQToDPTransform()
Getter for transform from DQ to DP domain.
Complex applyDQToDPTransform(const MatrixFixedSize< 2, 1 > &dqMatrix)
Apply transform to obtain current complex DP.
MatrixFixedSize< 2, 1 > applyDPToDQTransform(const Complex &dpComplex)
Apply transform to obtain current DQ vector.
MatrixFixedSize< 2, 2 > DPToDQTransform()
Getter for transform from DP to DQ domain.
MatrixFixedSize< 2, 2 > mDPToDQTransform
Transform from DP to DQ domain.
Real mOmegaShift
Shifting frequency of the DP domain (assumed to be constant)
void setDPShiftFrequency(const Real &omegaShift)
Setter for shit frequency.