GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 20.0% 1 / 0 / 5
Functions: 20.0% 1 / 0 / 5
Branches: -% 0 / 0 / 0

src/model/CoolingTowerSingleSpeed.hpp
Line Branch Exec Source
1 /***********************************************************************************************************************
2 * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC.
3 * See also https://openstudio.net/license
4 ***********************************************************************************************************************/
5
6 #ifndef MODEL_COOLINGTOWERSINGLESPEED_HPP
7 #define MODEL_COOLINGTOWERSINGLESPEED_HPP
8
9 #include "ModelAPI.hpp"
10 #include "StraightComponent.hpp"
11
12 namespace openstudio {
13
14 namespace model {
15
16 class Schedule;
17
18 namespace detail {
19
20 class CoolingTowerSingleSpeed_Impl;
21
22 } // namespace detail
23
24 /** CoolingTowerSingleSpeed is a StraightComponent that wraps the OpenStudio IDD object
25 * 'OS:CoolingTower:SingleSpeed'. */
26 class MODEL_API CoolingTowerSingleSpeed : public StraightComponent
27 {
28 public:
29 /** @name Constructors and Destructors */
30 //@{
31
32 explicit CoolingTowerSingleSpeed(const Model& model);
33
34 14 virtual ~CoolingTowerSingleSpeed() override = default;
35 // Default the copy and move operators because the virtual dtor is explicit
36 ✗ CoolingTowerSingleSpeed(const CoolingTowerSingleSpeed& other) = default;
37 ✗ CoolingTowerSingleSpeed(CoolingTowerSingleSpeed&& other) = default;
38 ✗ CoolingTowerSingleSpeed& operator=(const CoolingTowerSingleSpeed&) = default;
39 ✗ CoolingTowerSingleSpeed& operator=(CoolingTowerSingleSpeed&&) = default;
40
41 //@}
42
43 static IddObjectType iddObjectType();
44
45 static std::vector<std::string> performanceInputMethodValues();
46
47 static std::vector<std::string> evaporationLossModeValues();
48
49 static std::vector<std::string> blowdownCalculationModeValues();
50
51 static std::vector<std::string> capacityControlValues();
52
53 static std::vector<std::string> cellControlValues();
54
55 /** @name Getters */
56 //@{
57
58 boost::optional<double> designWaterFlowRate() const;
59
60 bool isDesignWaterFlowRateAutosized() const;
61
62 boost::optional<double> designAirFlowRate() const;
63
64 bool isDesignAirFlowRateAutosized() const;
65
66 boost::optional<double> fanPoweratDesignAirFlowRate() const;
67
68 bool isFanPoweratDesignAirFlowRateAutosized() const;
69
70 boost::optional<double> uFactorTimesAreaValueatDesignAirFlowRate() const;
71
72 bool isUFactorTimesAreaValueatDesignAirFlowRateAutosized() const;
73
74 boost::optional<double> airFlowRateinFreeConvectionRegime() const;
75
76 bool isAirFlowRateinFreeConvectionRegimeDefaulted() const;
77
78 bool isAirFlowRateinFreeConvectionRegimeAutosized() const;
79
80 boost::optional<double> uFactorTimesAreaValueatFreeConvectionAirFlowRate() const;
81
82 bool isUFactorTimesAreaValueatFreeConvectionAirFlowRateDefaulted() const;
83
84 bool isUFactorTimesAreaValueatFreeConvectionAirFlowRateAutosized() const;
85
86 std::string performanceInputMethod() const;
87
88 bool isPerformanceInputMethodDefaulted() const;
89
90 boost::optional<double> nominalCapacity() const;
91
92 boost::optional<double> freeConvectionCapacity() const;
93
94 double basinHeaterCapacity() const;
95
96 bool isBasinHeaterCapacityDefaulted() const;
97
98 double basinHeaterSetpointTemperature() const;
99
100 bool isBasinHeaterSetpointTemperatureDefaulted() const;
101
102 boost::optional<Schedule> basinHeaterOperatingSchedule() const;
103
104 std::string evaporationLossMode() const;
105
106 bool isEvaporationLossModeDefaulted() const;
107
108 double evaporationLossFactor() const;
109
110 bool isEvaporationLossFactorDefaulted() const;
111
112 double driftLossPercent() const;
113
114 bool isDriftLossPercentDefaulted() const;
115
116 std::string blowdownCalculationMode() const;
117
118 bool isBlowdownCalculationModeDefaulted() const;
119
120 double blowdownConcentrationRatio() const;
121
122 bool isBlowdownConcentrationRatioDefaulted() const;
123
124 boost::optional<Schedule> blowdownMakeupWaterUsageSchedule() const;
125
126 std::string capacityControl() const;
127
128 bool isCapacityControlDefaulted() const;
129
130 int numberofCells() const;
131
132 bool isNumberofCellsDefaulted() const;
133
134 std::string cellControl() const;
135
136 bool isCellControlDefaulted() const;
137
138 double cellMinimumWaterFlowRateFraction() const;
139
140 bool isCellMinimumWaterFlowRateFractionDefaulted() const;
141
142 double cellMaximumWaterFlowRateFraction() const;
143
144 bool isCellMaximumWaterFlowRateFractionDefaulted() const;
145
146 double sizingFactor() const;
147
148 bool isSizingFactorDefaulted() const;
149
150 //@}
151 /** @name Setters */
152 //@{
153
154 bool setDesignWaterFlowRate(double designWaterFlowRate);
155
156 void resetDesignWaterFlowRate();
157
158 void autosizeDesignWaterFlowRate();
159
160 bool setDesignAirFlowRate(double designAirFlowRate);
161
162 void autosizeDesignAirFlowRate();
163
164 bool setFanPoweratDesignAirFlowRate(double fanPoweratDesignAirFlowRate);
165
166 void autosizeFanPoweratDesignAirFlowRate();
167
168 bool setUFactorTimesAreaValueatDesignAirFlowRate(double uFactorTimesAreaValueatDesignAirFlowRate);
169
170 void resetUFactorTimesAreaValueatDesignAirFlowRate();
171
172 void autosizeUFactorTimesAreaValueatDesignAirFlowRate();
173
174 bool setAirFlowRateinFreeConvectionRegime(double airFlowRateinFreeConvectionRegime);
175
176 void resetAirFlowRateinFreeConvectionRegime();
177
178 void autosizeAirFlowRateinFreeConvectionRegime();
179
180 bool setUFactorTimesAreaValueatFreeConvectionAirFlowRate(double uFactorTimesAreaValueatFreeConvectionAirFlowRate);
181
182 void resetUFactorTimesAreaValueatFreeConvectionAirFlowRate();
183
184 void autosizeUFactorTimesAreaValueatFreeConvectionAirFlowRate();
185
186 bool setPerformanceInputMethod(const std::string& performanceInputMethod);
187
188 void resetPerformanceInputMethod();
189
190 bool setNominalCapacity(double nominalCapacity);
191
192 void resetNominalCapacity();
193
194 bool setFreeConvectionCapacity(double freeConvectionCapacity);
195
196 void resetFreeConvectionCapacity();
197
198 bool setBasinHeaterCapacity(double basinHeaterCapacity);
199
200 void resetBasinHeaterCapacity();
201
202 bool setBasinHeaterSetpointTemperature(double basinHeaterSetpointTemperature);
203
204 void resetBasinHeaterSetpointTemperature();
205
206 bool setBasinHeaterOperatingSchedule(Schedule& basinHeaterOperatingSchedule);
207
208 void resetBasinHeaterOperatingSchedule();
209
210 bool setEvaporationLossMode(const std::string& evaporationLossMode);
211
212 void resetEvaporationLossMode();
213
214 bool setEvaporationLossFactor(double evaporationLossFactor);
215
216 void resetEvaporationLossFactor();
217
218 bool setDriftLossPercent(double driftLossPercent);
219
220 void resetDriftLossPercent();
221
222 bool setBlowdownCalculationMode(const std::string& blowdownCalculationMode);
223
224 void resetBlowdownCalculationMode();
225
226 bool setBlowdownConcentrationRatio(double blowdownConcentrationRatio);
227
228 void resetBlowdownConcentrationRatio();
229
230 bool setBlowdownMakeupWaterUsageSchedule(Schedule& blowdownMakeupWaterUsageSchedule);
231
232 void resetBlowdownMakeupWaterUsageSchedule();
233
234 bool setCapacityControl(const std::string& capacityControl);
235
236 void resetCapacityControl();
237
238 bool setNumberofCells(int numberofCells);
239
240 void resetNumberofCells();
241
242 bool setCellControl(const std::string& cellControl);
243
244 void resetCellControl();
245
246 bool setCellMinimumWaterFlowRateFraction(double cellMinimumWaterFlowRateFraction);
247
248 void resetCellMinimumWaterFlowRateFraction();
249
250 bool setCellMaximumWaterFlowRateFraction(double cellMaximumWaterFlowRateFraction);
251
252 void resetCellMaximumWaterFlowRateFraction();
253
254 bool setSizingFactor(double sizingFactor);
255
256 void resetSizingFactor();
257
258 boost::optional<double> autosizedDesignWaterFlowRate() const;
259
260 boost::optional<double> autosizedDesignAirFlowRate() const;
261
262 boost::optional<double> autosizedFanPoweratDesignAirFlowRate() const;
263
264 boost::optional<double> autosizedUFactorTimesAreaValueatDesignAirFlowRate() const;
265
266 boost::optional<double> autosizedAirFlowRateinFreeConvectionRegime() const;
267
268 boost::optional<double> autosizedUFactorTimesAreaValueatFreeConvectionAirFlowRate() const;
269
270 /* This method mimics what E+ does because this value it isn't reported in the SQL file:
271 * It gets the input from the Sizing:Plant attached to the loop and the entered design inlet air wet-bulb temperature
272 */
273 boost::optional<double> autosizedDesignApproachTemperature() const;
274
275 /* This method mimics what E+ does because this value it isn't reported in the SQL file:
276 * It gets the input from the Sizing:Plant attached to the loop
277 */
278 boost::optional<double> autosizedDesignRangeTemperature() const;
279
280 double freeConvectionAirFlowRateSizingFactor() const;
281 bool setFreeConvectionAirFlowRateSizingFactor(double freeConvectionAirFlowRateSizingFactor);
282
283 double freeConvectionUFactorTimesAreaValueSizingFactor() const;
284 bool setFreeConvectionUFactorTimesAreaValueSizingFactor(double freeConvectionUFactorTimesAreaValueSizingFactor);
285
286 double heatRejectionCapacityAndNominalCapacitySizingRatio() const;
287 bool setHeatRejectionCapacityAndNominalCapacitySizingRatio(double heatRejectionCapacityAndNominalCapacitySizingRatio);
288
289 double freeConvectionNominalCapacitySizingFactor() const;
290 bool setFreeConvectionNominalCapacitySizingFactor(double freeConvectionNominalCapacitySizingFactor);
291
292 double designInletAirDryBulbTemperature() const;
293 bool setDesignInletAirDryBulbTemperature(double designInletAirDryBulbTemperature);
294
295 double designInletAirWetBulbTemperature() const;
296 bool setDesignInletAirWetBulbTemperature(double designInletAirWetBulbTemperature);
297
298 boost::optional<double> designApproachTemperature() const;
299 bool isDesignApproachTemperatureAutosized() const;
300 bool setDesignApproachTemperature(double designApproachTemperature);
301 void autosizeDesignApproachTemperature();
302
303 boost::optional<double> designRangeTemperature() const;
304 bool isDesignRangeTemperatureAutosized() const;
305 bool setDesignRangeTemperature(double designRangeTemperature);
306 void autosizeDesignRangeTemperature();
307
308 std::string endUseSubcategory() const;
309 bool setEndUseSubcategory(const std::string& endUseSubcategory);
310
311 //@}
312 protected:
313 /// @cond
314 using ImplType = detail::CoolingTowerSingleSpeed_Impl;
315
316 explicit CoolingTowerSingleSpeed(std::shared_ptr<detail::CoolingTowerSingleSpeed_Impl> impl);
317
318 friend class detail::CoolingTowerSingleSpeed_Impl;
319 friend class Model;
320 friend class IdfObject;
321 friend class openstudio::detail::IdfObject_Impl;
322 /// @endcond
323
324 private:
325 REGISTER_LOGGER("openstudio.model.CoolingTowerSingleSpeed");
326 };
327
328 /** \relates CoolingTowerSingleSpeed*/
329 using OptionalCoolingTowerSingleSpeed = boost::optional<CoolingTowerSingleSpeed>;
330
331 /** \relates CoolingTowerSingleSpeed*/
332 using CoolingTowerSingleSpeedVector = std::vector<CoolingTowerSingleSpeed>;
333
334 } // namespace model
335 } // namespace openstudio
336
337 #endif // MODEL_COOLINGTOWERSINGLESPEED_HPP
338