DPsim
Loading...
Searching...
No Matches
Base_Ph1_PiLine.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/AttributeList.h>
12#include <dpsim-models/Definitions.h>
13
14namespace CPS {
15namespace Base {
16namespace Ph1 {
17class PiLine {
18
19public:
21 const Attribute<Real>::Ptr mSeriesRes;
23 const Attribute<Real>::Ptr mSeriesInd;
25 const Attribute<Real>::Ptr mParallelCap;
27 const Attribute<Real>::Ptr mParallelCond;
28
29 explicit PiLine(CPS::AttributeList::Ptr attributeList)
30 : mSeriesRes(attributeList->create<Real>("R_series")),
31 mSeriesInd(attributeList->create<Real>("L_series")),
32 mParallelCap(attributeList->create<Real>("C_parallel")),
33 mParallelCond(attributeList->create<Real>("G_parallel")){};
34
36 void setParameters(Real seriesResistance, Real seriesInductance,
37 Real parallelCapacitance = 0,
38 Real parallelConductance = 0) const {
39 **mSeriesRes = seriesResistance;
40 **mSeriesInd = seriesInductance;
41 **mParallelCond = parallelConductance;
42 **mParallelCap = parallelCapacitance;
43 }
44};
45} // namespace Ph1
46} // namespace Base
47} // namespace CPS
const Attribute< Real >::Ptr mParallelCap
Capacitance in parallel to the line [F].
const Attribute< Real >::Ptr mParallelCond
Conductance in parallel to the line [S].
const Attribute< Real >::Ptr mSeriesInd
Inductance along the line [H].
const Attribute< Real >::Ptr mSeriesRes
Resistance along the line [ohms].