summaryrefslogtreecommitdiffstats
path: root/Project/PropertiesData.h
diff options
context:
space:
mode:
authorThales Lima Oliveira <thaleslima.ufu@gmail.com>2017-09-04 20:05:30 -0300
committerGitHub <noreply@github.com>2017-09-04 20:05:30 -0300
commit926af7f34aaf5aebdbac0cbc550ed75647874258 (patch)
tree4df26f8c631aeeeed6e5c9e8aab87c4c663bd30f /Project/PropertiesData.h
parent17d1dd82ec065eff08546ef1fd2a188ce77471b2 (diff)
parent6f3421c4150e49af026432a2a2be0171d741ad03 (diff)
downloadPSP.git-926af7f34aaf5aebdbac0cbc550ed75647874258.tar.gz
PSP.git-926af7f34aaf5aebdbac0cbc550ed75647874258.tar.xz
PSP.git-926af7f34aaf5aebdbac0cbc550ed75647874258.zip
Merge pull request #33 from Thales1330/wip/electromechanical-calc
Wip electromechanical calc
Diffstat (limited to 'Project/PropertiesData.h')
-rw-r--r--Project/PropertiesData.h55
1 files changed, 55 insertions, 0 deletions
diff --git a/Project/PropertiesData.h b/Project/PropertiesData.h
new file mode 100644
index 0000000..634e60e
--- /dev/null
+++ b/Project/PropertiesData.h
@@ -0,0 +1,55 @@
+#ifndef PROPERTIESDATA_H
+#define PROPERTIESDATA_H
+
+#include "wx/language.h"
+#include "Element.h"
+#include "PowerElement.h"
+
+enum PowerFlowMethod { GAUSS_SEIDEL = 0, NEWTON_RAPHSON };
+enum GUITheme { THEME_LIGHT = 0, THEME_DARK };
+
+struct SimulationData {
+ // General simulation data
+ double basePower = 100.0;
+ ElectricalUnit basePowerUnit = UNIT_MVA;
+ bool faultAfterPowerFlow = true;
+ bool scPowerAfterPowerFlow = true;
+
+ // Power flow
+ PowerFlowMethod powerFlowMethod = GAUSS_SEIDEL;
+ double accFator = 1.0;
+ double powerFlowTolerance = 1e-7;
+ int powerFlowMaxIterations = 5000;
+
+ // Stability
+ double stabilityFrequency = 60.0;
+ double timeStep = 1e-2;
+ double stabilitySimulationTime = 10.0;
+ double stabilityTolerance = 1e-8;
+ int stabilityMaxIterations = 100;
+ int controlTimeStepRatio = 10;
+ double plotTime = 1e-2;
+ bool useCOI = true;
+};
+
+struct GeneralData {
+ wxLanguage language = wxLANGUAGE_ENGLISH;
+ GUITheme theme = THEME_LIGHT;
+};
+
+class PropertiesData
+{
+ public:
+ PropertiesData();
+ ~PropertiesData();
+
+ SimulationData GetSimulationPropertiesData() const { return m_simulData; }
+ void SetSimulationPropertiesData(SimulationData simulationData) { m_simulData = simulationData; }
+ GeneralData GetGeneralPropertiesData() const { return m_genData; }
+ void SetGeneralPropertiesData(GeneralData generalData) { m_genData = generalData; }
+ protected:
+ SimulationData m_simulData;
+ GeneralData m_genData;
+};
+
+#endif // PROPERTIESDATA_H