MEASUR-Tools-Suite v1.0.11
The MEASUR Tools Suite is a collection of industrial efficiency calculations written in C++ and with bindings for compilation to WebAssembly.
Loading...
Searching...
No Matches
MediumToLowPressureTurbineCalculator.h
1#ifndef TOOLS_SUITE_MEDIUMTOLOWPRESSURETURBINECALCULATOR_H
2#define TOOLS_SUITE_MEDIUMTOLOWPRESSURETURBINECALCULATOR_H
3
4#include <steamModeler/api/HeaderInput.h>
5#include <steamModeler/api/TurbineInput.h>
6#include <steamModeler/service/medium_pressure_header/ReducedSteamException.h>
7#include <steamModeler/service/RestarterService.h>
8#include <steamModeler/service/SteamReducer.h>
9#include <steamModeler/SteamSystemModelerTool.h>
11
12#include "SteamBalanceCheckerService.h"
13#include "steamModeler/domain/TurbineFactory.h"
14#include "steamModeler/service/TurbineCalculator.h"
15
16// TODO extract this as separate class
18 public:
19 std::shared_ptr<Turbine> mediumToLowPressureTurbine;
20 std::shared_ptr<Turbine> mediumToLowPressureTurbineIdeal;
21 std::shared_ptr<Turbine> highToLowPressureTurbineUpdated;
22 std::shared_ptr<Turbine> highToLowPressureTurbineIdealUpdated;
23
24 friend std::ostream& operator<<(std::ostream& stream, const MediumToLowPressureTurbineCalculatorOutput& domain) {
25 stream << "MediumToLowPressureTurbineCalculatorOutput["
26 << "mediumToLowPressureTurbine=" << domain.mediumToLowPressureTurbine
27 << ", mediumToLowPressureTurbineIdeal=" << domain.mediumToLowPressureTurbineIdeal
28 << ", highToLowPressureTurbineUpdated=" << domain.highToLowPressureTurbineUpdated
29 << ", highToLowPressureTurbineIdealUpdated=" << domain.highToLowPressureTurbineIdealUpdated << "]";
30 return stream;
31 }
32};
33
35 public:
37 calc(const PressureTurbine& highToLowTurbineInput, const std::shared_ptr<Turbine>& highToLowPressureTurbine,
38 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal, const PressureTurbine& mediumToLowTurbineInput,
39 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput,
40 const std::shared_ptr<HeaderNotHighestPressure>& mediumPressureHeaderInput,
41 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
42 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler) const;
43
44 private:
45 const SteamBalanceCheckerService steamBalanceCheckerService = SteamBalanceCheckerService();
46 const TurbineFactory turbineFactory = TurbineFactory();
47
49 calc(const double availableMassFlow, const PressureTurbine& highToLowTurbineInput,
50 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
51 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal,
52 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput,
53 const PressureTurbine& mediumToLowTurbineInput,
54 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
55 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler) const;
56
58 calcFlowRange(const double availableMassFlow, const PressureTurbine& mediumToLowTurbineInput,
59 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
60 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler,
61 const PressureTurbine& highToLowTurbineInput,
62 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
63 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal,
64 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput) const;
65
67 calcPowerRange(const double availableMassFlow, const PressureTurbine& mediumToLowTurbineInput,
68 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
69 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler,
70 const PressureTurbine& highToLowTurbineInput,
71 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
72 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal,
73 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput) const;
74
76 calcPowerGeneration(const double availableMassFlow, const PressureTurbine& mediumToLowTurbineInput,
77 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
78 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler,
79 const PressureTurbine& highToLowTurbineInput,
80 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
81 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal,
82 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput) const;
83
85 calcSteamFlow(const double availableMassFlow, const PressureTurbine& mediumToLowTurbineInput,
86 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
87 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput, const Boiler& boiler,
88 const PressureTurbine& highToLowTurbineInput,
89 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
90 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal,
91 const SteamSystemModelerTool::FluidProperties& highPressureHeaderOutput) const;
92
94 calcBalanceHeader(const double availableMassFlow, const PressureTurbine& mediumToLowTurbineInput,
95 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput,
96 const std::shared_ptr<HeaderNotHighestPressure>& lowPressureHeaderInput,
97 const std::shared_ptr<Turbine>& highToLowPressureTurbine,
98 const std::shared_ptr<Turbine>& highToLowPressureTurbineIdeal) const;
99
100 double calcAvailableMassFlow(const std::shared_ptr<HeaderNotHighestPressure>& mediumPressureHeaderInput,
101 const SteamSystemModelerTool::FluidProperties& mediumPressureHeaderOutput) const;
102};
103
104#endif // TOOLS_SUITE_MEDIUMTOLOWPRESSURETURBINECALCULATOR_H
Calculator for turbines for steam systems.