diff options
author | Thales1330 <thaleslima.ufu@gmail.com> | 2016-10-17 17:27:49 -0200 |
---|---|---|
committer | Thales1330 <thaleslima.ufu@gmail.com> | 2016-10-17 17:27:49 -0200 |
commit | c4f6b784f575b19506d3207d3f8fbf9496db5b43 (patch) | |
tree | dc50b6b50c81570727ca8810240505630513cf26 /Project/Workspace.cpp | |
parent | d60de5e4c4774c5b840c5cab2cb629a5bbe9df42 (diff) | |
download | PSP.git-c4f6b784f575b19506d3207d3f8fbf9496db5b43.tar.gz PSP.git-c4f6b784f575b19506d3207d3f8fbf9496db5b43.tar.xz PSP.git-c4f6b784f575b19506d3207d3f8fbf9496db5b43.zip |
Transformer form under implementation
Diffstat (limited to 'Project/Workspace.cpp')
-rw-r--r-- | Project/Workspace.cpp | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Project/Workspace.cpp b/Project/Workspace.cpp index bfcfb89..229e39e 100644 --- a/Project/Workspace.cpp +++ b/Project/Workspace.cpp @@ -977,12 +977,16 @@ void Workspace::ValidateElementsVoltages() { for(auto it = m_elementList.begin(); it != m_elementList.end(); it++) { Element* child = *it; + + std::vector<double> nominalVoltage; + std::vector<ElectricalUnit> nominalVoltageUnit; for(int i = 0; i < (int)child->GetParentList().size(); i++) { Bus* parent = (Bus*)child->GetParentList()[i]; if(parent) { - child->SetNominalVoltage(parent->GetEletricalData().nominalVoltage, - parent->GetEletricalData().nominalVoltageUnit); + nominalVoltage.push_back(parent->GetEletricalData().nominalVoltage); + nominalVoltageUnit.push_back(parent->GetEletricalData().nominalVoltageUnit); } } + child->SetNominalVoltage(nominalVoltage, nominalVoltageUnit); } } |