GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 69.1% 442 / 0 / 640
Functions: 75.4% 101 / 0 / 134
Branches: 46.6% 381 / 0 / 817

src/model/AirTerminalSingleDuctParallelPIUReheat.cpp
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 #include "AirTerminalSingleDuctParallelPIUReheat.hpp"
7 #include "AirTerminalSingleDuctParallelPIUReheat_Impl.hpp"
8 #include "AirLoopHVACReturnPlenum.hpp"
9 #include "AirLoopHVACReturnPlenum_Impl.hpp"
10 #include "FanConstantVolume.hpp"
11 #include "FanConstantVolume_Impl.hpp"
12 #include "FanVariableVolume.hpp"
13 #include "FanVariableVolume_Impl.hpp"
14 #include "FanOnOff.hpp"
15 #include "FanOnOff_Impl.hpp"
16 #include "FanSystemModel.hpp"
17 #include "FanSystemModel_Impl.hpp"
18 #include "Schedule.hpp"
19 #include "Schedule_Impl.hpp"
20 #include "Node.hpp"
21 #include "Node_Impl.hpp"
22 #include "PortList.hpp"
23 #include "PortList_Impl.hpp"
24 #include "ThermalZone.hpp"
25 #include "ThermalZone_Impl.hpp"
26 #include "AirLoopHVACZoneSplitter.hpp"
27 #include "AirLoopHVACZoneSplitter_Impl.hpp"
28 #include "AirLoopHVACZoneMixer.hpp"
29 #include "AirLoopHVACZoneMixer_Impl.hpp"
30 #include "Model.hpp"
31 #include <utilities/idd/IddFactory.hxx>
32
33 #include <utilities/idd/OS_AirTerminal_SingleDuct_ParallelPIU_Reheat_FieldEnums.hxx>
34 #include <utilities/idd/IddEnums.hxx>
35 #include "../utilities/core/Assert.hpp"
36 #include "../utilities/data/DataEnums.hpp"
37
38 namespace openstudio {
39
40 namespace model {
41
42 namespace detail {
43
44 11 AirTerminalSingleDuctParallelPIUReheat_Impl::AirTerminalSingleDuctParallelPIUReheat_Impl(const IdfObject& idfObject, Model_Impl* model,
45 11 bool keepHandle)
46 11 : StraightComponent_Impl(idfObject, model, keepHandle) {
47
4/6
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
✓ Branch 7 taken 11 times.
✗ Branch 10 not taken.
✓ Branch 11 taken 11 times.
✗ Branch 13 not taken.
11 OS_ASSERT(idfObject.iddObject().type() == AirTerminalSingleDuctParallelPIUReheat::iddObjectType());
48 11 }
49
50 1 AirTerminalSingleDuctParallelPIUReheat_Impl::AirTerminalSingleDuctParallelPIUReheat_Impl(const openstudio::detail::WorkspaceObject_Impl& other,
51 1 Model_Impl* model, bool keepHandle)
52 1 : StraightComponent_Impl(other, model, keepHandle) {
53
4/6
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
✗ Branch 10 not taken.
✓ Branch 11 taken 1 time.
✗ Branch 13 not taken.
1 OS_ASSERT(other.iddObject().type() == AirTerminalSingleDuctParallelPIUReheat::iddObjectType());
54 1 }
55
56 7 AirTerminalSingleDuctParallelPIUReheat_Impl::AirTerminalSingleDuctParallelPIUReheat_Impl(const AirTerminalSingleDuctParallelPIUReheat_Impl& other,
57 7 Model_Impl* model, bool keepHandle)
58 7 : StraightComponent_Impl(other, model, keepHandle) {}
59
60 ✗ const std::vector<std::string>& AirTerminalSingleDuctParallelPIUReheat_Impl::outputVariableNames() const {
61 static const std::vector<std::string> result{
62 // These apply to all AirTerminals
63 "Zone Air Terminal Sensible Heating Energy",
64 "Zone Air Terminal Sensible Heating Rate",
65 "Zone Air Terminal Sensible Cooling Energy",
66 "Zone Air Terminal Sensible Cooling Rate",
67
68 // Specific output for this one
69 "Zone Air Terminal Current Operation Control Stage",
70 "Zone Air Terminal Heating Energy",
71 "Zone Air Terminal Heating Rate",
72 "Zone Air Terminal Outdoor Air Volume Flow Rate",
73 "Zone Air Terminal Outlet Discharge Air Temperature",
74 "Zone Air Terminal Primary Air Mass Flow Rate",
75 "Zone Air Terminal Primary Damper Position",
76 "Zone Air Terminal Secondary Air Mass Flow Rate",
77 "Zone Air Terminal Sensible Cooling Energy",
78 "Zone Air Terminal Sensible Cooling Rate",
79 "Zone Air Terminal Total Air Mass Flow Rate",
80 ✗ };
81 ✗ return result;
82 ✗ }
83
84 16 IddObjectType AirTerminalSingleDuctParallelPIUReheat_Impl::iddObjectType() const {
85 16 return AirTerminalSingleDuctParallelPIUReheat::iddObjectType();
86 }
87
88 ✗ std::vector<ScheduleTypeKey> AirTerminalSingleDuctParallelPIUReheat_Impl::getScheduleTypeKeys(const Schedule& schedule) const {
89 ✗ std::vector<ScheduleTypeKey> result;
90 ✗ UnsignedVector fieldIndices = getSourceIndices(schedule.handle());
91 ✗ UnsignedVector::const_iterator b(fieldIndices.begin());
92 ✗ UnsignedVector::const_iterator e(fieldIndices.end());
93 ✗ if (std::find(b, e, OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::AvailabilityScheduleName) != e) {
94 ✗ result.push_back(ScheduleTypeKey("AirTerminalSingleDuctParallelPIUReheat", "Availability"));
95 }
96 ✗ return result;
97 ✗ }
98
99 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::maximumPrimaryAirFlowRate() const {
100 1 return getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumPrimaryAirFlowRate, true);
101 }
102
103 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::isMaximumPrimaryAirFlowRateAutosized() const {
104 1 bool result = false;
105
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumPrimaryAirFlowRate, true);
106
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
107
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "Autosize");
108 }
109 1 return result;
110 1 }
111
112 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::maximumSecondaryAirFlowRate() const {
113 1 return getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumSecondaryAirFlowRate, true);
114 }
115
116 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::isMaximumSecondaryAirFlowRateAutosized() const {
117 1 bool result = false;
118
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumSecondaryAirFlowRate, true);
119
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
120
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "Autosize");
121 }
122 1 return result;
123 1 }
124
125 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::minimumPrimaryAirFlowFraction() const {
126 1 return getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumPrimaryAirFlowFraction, true);
127 }
128
129 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::isMinimumPrimaryAirFlowFractionAutosized() const {
130 1 bool result = false;
131
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumPrimaryAirFlowFraction, true);
132
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
133
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "Autosize");
134 }
135 1 return result;
136 1 }
137
138 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::fanOnFlowFraction() const {
139 1 return getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanOnFlowFraction, true);
140 }
141
142 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::isFanOnFlowFractionAutosized() const {
143 1 bool result = false;
144
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanOnFlowFraction, true);
145
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
146
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "Autosize");
147 }
148 1 return result;
149 1 }
150
151 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::maximumHotWaterorSteamFlowRate() const {
152 1 return getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, true);
153 }
154
155 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::isMaximumHotWaterorSteamFlowRateAutosized() const {
156 1 bool result = false;
157
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, true);
158
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
159
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "Autosize");
160 }
161 1 return result;
162 1 }
163
164 1 double AirTerminalSingleDuctParallelPIUReheat_Impl::minimumHotWaterorSteamFlowRate() const {
165
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumHotWaterorSteamFlowRate, true);
166
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
167
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
168 }
169
170 ✗ bool AirTerminalSingleDuctParallelPIUReheat_Impl::isMinimumHotWaterorSteamFlowRateDefaulted() const {
171 ✗ return isEmpty(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumHotWaterorSteamFlowRate);
172 }
173
174 1 double AirTerminalSingleDuctParallelPIUReheat_Impl::convergenceTolerance() const {
175
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ConvergenceTolerance, true);
176
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
177
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
178 }
179
180 ✗ bool AirTerminalSingleDuctParallelPIUReheat_Impl::isConvergenceToleranceDefaulted() const {
181 ✗ return isEmpty(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ConvergenceTolerance);
182 }
183
184 6 std::string AirTerminalSingleDuctParallelPIUReheat_Impl::fanControlType() const {
185
1/1
✓ Branch 1 taken 6 times.
6 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanControlType, true);
186
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 6 times.
✗ Branch 4 not taken.
6 OS_ASSERT(value);
187
2/2
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
12 return value.get();
188 6 }
189
190 3 double AirTerminalSingleDuctParallelPIUReheat_Impl::minimumFanTurnDownRatio() const {
191
1/1
✓ Branch 1 taken 3 times.
3 boost::optional<double> value = getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumFanTurnDownRatio, true);
192
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
✗ Branch 4 not taken.
3 OS_ASSERT(value);
193
1/1
✓ Branch 1 taken 3 times.
6 return value.get();
194 }
195
196 3 std::string AirTerminalSingleDuctParallelPIUReheat_Impl::heatingControlType() const {
197
1/1
✓ Branch 1 taken 3 times.
3 boost::optional<std::string> value = getString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::HeatingControlType, true);
198
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
✗ Branch 4 not taken.
3 OS_ASSERT(value);
199
2/2
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
6 return value.get();
200 3 }
201
202 3 double AirTerminalSingleDuctParallelPIUReheat_Impl::designHeatingDischargeAirTemperature() const {
203
1/1
✓ Branch 1 taken 3 times.
3 boost::optional<double> value = getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::DesignHeatingDischargeAirTemperature, true);
204
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
✗ Branch 4 not taken.
3 OS_ASSERT(value);
205
1/1
✓ Branch 1 taken 3 times.
6 return value.get();
206 }
207
208 3 double AirTerminalSingleDuctParallelPIUReheat_Impl::highLimitHeatingDischargeAirTemperature() const {
209
1/1
✓ Branch 1 taken 3 times.
3 boost::optional<double> value = getDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::HighLimitHeatingDischargeAirTemperature, true);
210
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
✗ Branch 4 not taken.
3 OS_ASSERT(value);
211
1/1
✓ Branch 1 taken 3 times.
6 return value.get();
212 }
213
214 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMaximumPrimaryAirFlowRate(boost::optional<double> maximumPrimaryAirFlowRate) {
215 1 bool result = false;
216
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (maximumPrimaryAirFlowRate) {
217 1 result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumPrimaryAirFlowRate, maximumPrimaryAirFlowRate.get());
218 } else {
219 ✗ result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumPrimaryAirFlowRate, "");
220 }
221
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
1 OS_ASSERT(result);
222 1 return result;
223 }
224
225 10 void AirTerminalSingleDuctParallelPIUReheat_Impl::autosizeMaximumPrimaryAirFlowRate() {
226
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
20 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumPrimaryAirFlowRate, "Autosize");
227
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 OS_ASSERT(result);
228 10 }
229
230 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMaximumSecondaryAirFlowRate(boost::optional<double> maximumSecondaryAirFlowRate) {
231 1 bool result = false;
232
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (maximumSecondaryAirFlowRate) {
233 1 result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumSecondaryAirFlowRate, maximumSecondaryAirFlowRate.get());
234 } else {
235 ✗ result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumSecondaryAirFlowRate, "");
236 }
237
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
1 OS_ASSERT(result);
238 1 return result;
239 }
240
241 10 void AirTerminalSingleDuctParallelPIUReheat_Impl::autosizeMaximumSecondaryAirFlowRate() {
242
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
20 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumSecondaryAirFlowRate, "Autosize");
243
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 OS_ASSERT(result);
244 10 }
245
246 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMinimumPrimaryAirFlowFraction(boost::optional<double> minimumPrimaryAirFlowFraction) {
247 1 bool result = false;
248
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (minimumPrimaryAirFlowFraction) {
249 1 result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumPrimaryAirFlowFraction, minimumPrimaryAirFlowFraction.get());
250 } else {
251 ✗ result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumPrimaryAirFlowFraction, "");
252 }
253
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
1 OS_ASSERT(result);
254 1 return result;
255 }
256
257 10 void AirTerminalSingleDuctParallelPIUReheat_Impl::autosizeMinimumPrimaryAirFlowFraction() {
258
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
20 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumPrimaryAirFlowFraction, "Autosize");
259
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 OS_ASSERT(result);
260 10 }
261
262 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setFanOnFlowFraction(boost::optional<double> fanOnFlowFraction) {
263 1 bool result = false;
264
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (fanOnFlowFraction) {
265 1 result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanOnFlowFraction, fanOnFlowFraction.get());
266 } else {
267 ✗ result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanOnFlowFraction, "");
268 }
269
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
1 OS_ASSERT(result);
270 1 return result;
271 }
272
273 10 void AirTerminalSingleDuctParallelPIUReheat_Impl::autosizeFanOnFlowFraction() {
274
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
20 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanOnFlowFraction, "Autosize");
275
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 OS_ASSERT(result);
276 10 }
277
278 1 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMaximumHotWaterorSteamFlowRate(boost::optional<double> maximumHotWaterorSteamFlowRate) {
279 1 bool result = false;
280
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (maximumHotWaterorSteamFlowRate) {
281 1 result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, maximumHotWaterorSteamFlowRate.get());
282 } else {
283 ✗ result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, "");
284 }
285
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
1 OS_ASSERT(result);
286 1 return result;
287 }
288
289 ✗ void AirTerminalSingleDuctParallelPIUReheat_Impl::resetMaximumHotWaterorSteamFlowRate() {
290 ✗ bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, "");
291 ✗ OS_ASSERT(result);
292 ✗ }
293
294 10 void AirTerminalSingleDuctParallelPIUReheat_Impl::autosizeMaximumHotWaterorSteamFlowRate() {
295
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
20 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MaximumHotWaterorSteamFlowRate, "Autosize");
296
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 OS_ASSERT(result);
297 10 }
298
299 11 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMinimumHotWaterorSteamFlowRate(double minimumHotWaterorSteamFlowRate) {
300 11 bool result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumHotWaterorSteamFlowRate, minimumHotWaterorSteamFlowRate);
301 11 return result;
302 }
303
304 ✗ void AirTerminalSingleDuctParallelPIUReheat_Impl::resetMinimumHotWaterorSteamFlowRate() {
305 ✗ bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumHotWaterorSteamFlowRate, "");
306 ✗ OS_ASSERT(result);
307 ✗ }
308
309 11 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setConvergenceTolerance(double convergenceTolerance) {
310 11 bool result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ConvergenceTolerance, convergenceTolerance);
311 11 return result;
312 }
313
314 ✗ void AirTerminalSingleDuctParallelPIUReheat_Impl::resetConvergenceTolerance() {
315 ✗ bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ConvergenceTolerance, "");
316 ✗ OS_ASSERT(result);
317 ✗ }
318
319 25 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setFanControlType(const std::string& fanControlType) {
320
1/1
✓ Branch 1 taken 25 times.
25 auto hvacComponent = fan();
321
4/4
✓ Branch 1 taken 25 times.
✓ Branch 4 taken 25 times.
✓ Branch 7 taken 21 times.
✓ Branch 8 taken 4 times.
25 if (hvacComponent.iddObjectType() == IddObjectType::OS_Fan_ConstantVolume) {
322
4/4
✓ Branch 1 taken 21 times.
✓ Branch 4 taken 21 times.
✓ Branch 7 taken 1 time.
✓ Branch 8 taken 20 times.
42 if (istringEqual(fanControlType, "VariableSpeed")) {
323 1 return false;
324 }
325 }
326
327
1/1
✓ Branch 1 taken 24 times.
24 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanControlType, fanControlType);
328 24 return result;
329 25 }
330
331 12 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setMinimumFanTurnDownRatio(double minimumFanTurnDownRatio) {
332 12 bool result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::MinimumFanTurnDownRatio, minimumFanTurnDownRatio);
333 12 return result;
334 }
335
336 12 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setHeatingControlType(const std::string& heatingControlType) {
337 12 bool result = setString(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::HeatingControlType, heatingControlType);
338 12 return result;
339 }
340
341 12 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setDesignHeatingDischargeAirTemperature(double designHeatingDischargeAirTemperature) {
342 bool result =
343 12 setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::DesignHeatingDischargeAirTemperature, designHeatingDischargeAirTemperature);
344 12 return result;
345 }
346
347 12 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setHighLimitHeatingDischargeAirTemperature(double highLimitHeatingDischargeAirTemperature) {
348 12 bool result = setDouble(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::HighLimitHeatingDischargeAirTemperature,
349 highLimitHeatingDischargeAirTemperature);
350 12 return result;
351 }
352
353 17 unsigned AirTerminalSingleDuctParallelPIUReheat_Impl::inletPort() const {
354 17 return OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::SupplyAirInletNodeName;
355 }
356
357 78 unsigned AirTerminalSingleDuctParallelPIUReheat_Impl::outletPort() const {
358 78 return OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::OutletNodeName;
359 }
360
361 11 HVACComponent AirTerminalSingleDuctParallelPIUReheat_Impl::reheatCoil() const {
362
1/1
✓ Branch 1 taken 11 times.
11 boost::optional<HVACComponent> hvacComponent = optionalReheatCoil();
363
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 11 times.
✗ Branch 4 not taken.
11 OS_ASSERT(hvacComponent);
364
2/2
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
22 return hvacComponent.get();
365 11 }
366
367 41 HVACComponent AirTerminalSingleDuctParallelPIUReheat_Impl::fan() const {
368
1/1
✓ Branch 1 taken 41 times.
41 boost::optional<HVACComponent> hvacComponent = optionalFan();
369
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 41 times.
✗ Branch 4 not taken.
41 OS_ASSERT(hvacComponent);
370
2/2
✓ Branch 1 taken 41 times.
✓ Branch 4 taken 41 times.
82 return hvacComponent.get();
371 41 }
372
373 1 Schedule AirTerminalSingleDuctParallelPIUReheat_Impl::availabilitySchedule() const {
374
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<Schedule> value = optionalAvailabilitySchedule();
375
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
1 if (!value) {
376 // it is an error if we get here, however we don't want to crash
377 // so we hook up to global always on schedule
378 ✗ LOG(Error, "Required availability schedule not set, using 'Always On' schedule");
379 ✗ value = this->model().alwaysOnDiscreteSchedule();
380 ✗ OS_ASSERT(value);
381 ✗ const_cast<AirTerminalSingleDuctParallelPIUReheat_Impl*>(this)->setAvailabilitySchedule(*value);
382 ✗ value = optionalAvailabilitySchedule();
383 }
384
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
385
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
2 return value.get();
386 1 }
387
388 13 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setReheatCoil(HVACComponent& hvacComponent) {
389 13 bool isTypeCorrect = false;
390
391
4/4
✓ Branch 1 taken 13 times.
✓ Branch 4 taken 13 times.
✓ Branch 7 taken 11 times.
✓ Branch 8 taken 2 times.
13 if (hvacComponent.iddObjectType() == IddObjectType::OS_Coil_Heating_Electric) {
392 11 isTypeCorrect = true;
393
3/4
✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
✗ Branch 7 not taken.
✓ Branch 8 taken 2 times.
2 } else if (hvacComponent.iddObjectType() == IddObjectType::OS_Coil_Heating_Gas) {
394 ✗ isTypeCorrect = true;
395
3/4
✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
✓ Branch 7 taken 2 times.
✗ Branch 8 not taken.
2 } else if (hvacComponent.iddObjectType() == IddObjectType::OS_Coil_Heating_Water) {
396 2 isTypeCorrect = true;
397 }
398
399
1/2
✓ Branch 0 taken 13 times.
✗ Branch 1 not taken.
13 if (isTypeCorrect) {
400
2/2
✓ Branch 1 taken 13 times.
✓ Branch 4 taken 13 times.
13 return setPointer(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ReheatCoilName, hvacComponent.handle());
401 } else {
402 ✗ LOG(Warn, "Invalid Heating Coil Type (expected CoilHeatingGas, CoilHeatingElectric, or CoilHeatingWater, not '"
403 << hvacComponent.iddObjectType().valueName() << "') for " << briefDescription());
404 ✗ return false;
405 }
406 }
407
408 15 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setFan(HVACComponent& hvacComponent) {
409 15 bool isTypeCorrect = false;
410
411
4/4
✓ Branch 1 taken 15 times.
✓ Branch 4 taken 15 times.
✓ Branch 7 taken 12 times.
✓ Branch 8 taken 3 times.
15 if (hvacComponent.iddObjectType() == IddObjectType::OS_Fan_ConstantVolume) {
412 12 isTypeCorrect = true;
413
3/4
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
✗ Branch 8 not taken.
3 } else if (hvacComponent.iddObjectType() == IddObjectType::OS_Fan_SystemModel) {
414 3 isTypeCorrect = true;
415 }
416
417
1/2
✓ Branch 0 taken 15 times.
✗ Branch 1 not taken.
15 if (isTypeCorrect) {
418
2/2
✓ Branch 1 taken 15 times.
✓ Branch 4 taken 15 times.
15 bool result = setPointer(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanName, hvacComponent.handle());
419
420
1/2
✓ Branch 0 taken 15 times.
✗ Branch 1 not taken.
15 if (result) {
421
4/4
✓ Branch 1 taken 15 times.
✓ Branch 4 taken 15 times.
✓ Branch 7 taken 12 times.
✓ Branch 8 taken 3 times.
15 if (hvacComponent.iddObjectType() == IddObjectType::OS_Fan_ConstantVolume) {
422
2/2
✓ Branch 1 taken 12 times.
✓ Branch 4 taken 12 times.
24 setFanControlType("ConstantSpeed");
423 }
424 }
425
426 15 return result;
427
428 } else {
429 ✗ LOG(Warn, "Invalid Fan Type (expected FanConstantVolume or FanSystemModel, not '" << hvacComponent.iddObjectType().valueName() << "') for "
430 << briefDescription());
431 ✗ return false;
432 }
433 }
434
435 10 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setAvailabilitySchedule(Schedule& schedule) {
436
3/3
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 7 taken 10 times.
60 return setSchedule(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::AvailabilityScheduleName, "AirTerminalSingleDuctParallelPIUReheat",
437 20 "Availability", schedule);
438 }
439
440 2 std::vector<ModelObject> AirTerminalSingleDuctParallelPIUReheat_Impl::children() const {
441 2 std::vector<ModelObject> result;
442
2/3
✓ Branch 1 taken 2 times.
✓ Branch 3 taken 2 times.
✗ Branch 4 not taken.
4 if (OptionalHVACComponent intermediate = optionalReheatCoil()) {
443
2/2
✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
2 result.push_back(*intermediate);
444 2 }
445
2/3
✓ Branch 1 taken 2 times.
✓ Branch 3 taken 2 times.
✗ Branch 4 not taken.
4 if (OptionalHVACComponent intermediate = optionalFan()) {
446
2/2
✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
2 result.push_back(*intermediate);
447 2 }
448 2 return result;
449 ✗ }
450
451 3 ModelObject AirTerminalSingleDuctParallelPIUReheat_Impl::clone(Model model) const {
452
3/3
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
3 auto modelObjectClone = StraightComponent_Impl::clone(model).cast<AirTerminalSingleDuctParallelPIUReheat>();
453
454
3/3
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
3 modelObjectClone.setString(modelObjectClone.secondaryAirInletPort(), "");
455
456 // clone coil
457
458
1/1
✓ Branch 1 taken 3 times.
3 HVACComponent coil = this->reheatCoil();
459
460
3/3
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
3 auto coilClone = coil.clone(model).cast<HVACComponent>();
461
462
1/1
✓ Branch 1 taken 3 times.
3 modelObjectClone.setReheatCoil(coilClone);
463
464 // clone fan
465
466
1/1
✓ Branch 1 taken 3 times.
3 HVACComponent fan = this->fan();
467
468
3/3
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
3 auto fanClone = fan.clone(model).cast<HVACComponent>();
469
470
1/1
✓ Branch 1 taken 3 times.
3 modelObjectClone.setFan(fanClone);
471
472 6 return std::move(modelObjectClone);
473 3 }
474
475 14 bool AirTerminalSingleDuctParallelPIUReheat_Impl::addToNode(Node& node) {
476
1/1
✓ Branch 1 taken 14 times.
14 Model _model = node.model();
477
478
2/3
✓ Branch 1 taken 14 times.
✓ Branch 3 taken 14 times.
✗ Branch 4 not taken.
28 if (boost::optional<ModelObject> outlet = node.outletModelObject()) {
479 14 boost::optional<ThermalZone> thermalZone;
480
481
4/4
✓ Branch 1 taken 14 times.
✓ Branch 4 taken 14 times.
✓ Branch 6 taken 6 times.
✓ Branch 7 taken 8 times.
28 if (boost::optional<PortList> portList = outlet->optionalCast<PortList>()) {
482
3/3
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
✓ Branch 7 taken 6 times.
6 thermalZone = portList->thermalZone();
483 14 }
484
485
14/19
✓ Branch 1 taken 8 times.
✓ Branch 2 taken 6 times.
✓ Branch 4 taken 8 times.
✓ Branch 7 taken 8 times.
✓ Branch 10 taken 4 times.
✓ Branch 11 taken 4 times.
✓ Branch 13 taken 4 times.
✓ Branch 16 taken 4 times.
✗ Branch 17 not taken.
✓ Branch 18 taken 4 times.
✓ Branch 19 taken 10 times.
✓ Branch 21 taken 8 times.
✓ Branch 22 taken 6 times.
✓ Branch 24 taken 10 times.
✓ Branch 25 taken 4 times.
✗ Branch 26 not taken.
✗ Branch 27 not taken.
✗ Branch 29 not taken.
✗ Branch 30 not taken.
40 if (thermalZone || (outlet->optionalCast<Mixer>() && node.airLoopHVAC())) {
486
2/3
✓ Branch 1 taken 10 times.
✓ Branch 3 taken 10 times.
✗ Branch 4 not taken.
20 if (boost::optional<ModelObject> inlet = node.inletModelObject()) {
487
3/4
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 6 taken 10 times.
✗ Branch 7 not taken.
20 if (boost::optional<Splitter> splitter = inlet->optionalCast<Splitter>()) {
488
1/1
✓ Branch 1 taken 10 times.
10 boost::optional<ModelObject> sourceModelObject = inlet;
489
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
10 boost::optional<unsigned> sourcePort = node.connectedObjectPort(node.inletPort());
490
491
3/6
✓ Branch 0 taken 10 times.
✗ Branch 1 not taken.
✓ Branch 2 taken 10 times.
✗ Branch 3 not taken.
✓ Branch 4 taken 10 times.
✗ Branch 5 not taken.
20 if (sourcePort && sourceModelObject) {
492
1/1
✓ Branch 1 taken 10 times.
10 Node inletNode(_model);
493
494
1/1
✓ Branch 1 taken 10 times.
10 auto thisObject = getObject<ModelObject>();
495
496
6/6
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 7 taken 10 times.
✓ Branch 10 taken 10 times.
✓ Branch 13 taken 10 times.
✓ Branch 16 taken 10 times.
10 _model.connect(sourceModelObject.get(), sourcePort.get(), inletNode, inletNode.inletPort());
497
498
5/5
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 7 taken 10 times.
✓ Branch 10 taken 10 times.
✓ Branch 13 taken 10 times.
10 _model.connect(inletNode, inletNode.outletPort(), thisObject, inletPort());
499
500
5/5
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 7 taken 10 times.
✓ Branch 10 taken 10 times.
✓ Branch 13 taken 10 times.
10 _model.connect(thisObject, outletPort(), node, node.inletPort());
501
502
2/2
✓ Branch 0 taken 6 times.
✓ Branch 1 taken 4 times.
10 if (thermalZone) {
503
1/1
✓ Branch 1 taken 6 times.
6 Node secondaryInletNode(_model);
504
505
2/2
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
6 PortList exhaustPortList = thermalZone->exhaustPortList();
506
507
5/5
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
✓ Branch 7 taken 6 times.
✓ Branch 10 taken 6 times.
✓ Branch 13 taken 6 times.
6 _model.connect(exhaustPortList, exhaustPortList.nextPort(), secondaryInletNode, secondaryInletNode.inletPort());
508
509
5/5
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
✓ Branch 7 taken 6 times.
✓ Branch 10 taken 6 times.
✓ Branch 13 taken 6 times.
6 _model.connect(secondaryInletNode, secondaryInletNode.outletPort(), thisObject, secondaryAirInletPort());
510
511
1/1
✓ Branch 1 taken 6 times.
6 auto mo = this->getObject<ModelObject>();
512
513
2/2
✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
6 thermalZone->addEquipment(mo);
514 6 }
515
516
2/3
✓ Branch 1 taken 10 times.
✓ Branch 3 taken 10 times.
✗ Branch 4 not taken.
20 if (auto airLoopHVAC = node.airLoopHVAC()) {
517
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
10 auto schedule = airLoopHVAC->availabilitySchedule();
518
1/1
✓ Branch 1 taken 10 times.
10 setFanAvailabilitySchedule(schedule);
519 20 }
520
521 10 return true;
522 10 }
523 20 }
524 10 }
525 }
526 28 }
527
528 4 return false;
529 14 }
530
531 1 std::vector<IdfObject> AirTerminalSingleDuctParallelPIUReheat_Impl::remove() {
532
1/1
✓ Branch 1 taken 1 time.
1 Model _model = this->model();
533
1/1
✓ Branch 1 taken 1 time.
1 auto thisObject = this->getObject<ModelObject>();
534
535
1/1
✓ Branch 1 taken 1 time.
1 HVACComponent _reheatCoil = reheatCoil();
536
537
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<ModelObject> sourceModelObject = this->inletModelObject();
538
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 boost::optional<unsigned> sourcePort = this->connectedObjectPort(this->inletPort());
539
540
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<ModelObject> targetModelObject = this->outletModelObject();
541
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 boost::optional<unsigned> targetPort = this->connectedObjectPort(this->outletPort());
542
543
1/1
✓ Branch 1 taken 1 time.
1 std::vector<ThermalZone> thermalZones = _model.getConcreteModelObjects<ThermalZone>();
544
1/2
✓ Branch 5 taken 1 time.
✗ Branch 6 not taken.
1 for (auto& thermalZone : thermalZones) {
545
1/1
✓ Branch 1 taken 1 time.
1 std::vector<ModelObject> equipment = thermalZone.equipment();
546
547
2/3
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
✗ Branch 8 not taken.
1 if (std::find(equipment.begin(), equipment.end(), thisObject) != equipment.end()) {
548
1/1
✓ Branch 1 taken 1 time.
1 thermalZone.removeEquipment(thisObject);
549
550 1 break;
551 }
552 1 }
553
554
2/3
✓ Branch 1 taken 1 time.
✓ Branch 3 taken 1 time.
✗ Branch 4 not taken.
2 if (boost::optional<Node> secondaryAirInletNode = this->secondaryAirInletNode()) {
555
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 secondaryAirInletNode->disconnect();
556
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 secondaryAirInletNode->remove();
557 1 }
558
559
5/10
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 3 not taken.
✓ Branch 4 taken 1 time.
✗ Branch 5 not taken.
✓ Branch 6 taken 1 time.
✗ Branch 7 not taken.
✓ Branch 8 taken 1 time.
✗ Branch 9 not taken.
4 if (sourcePort && sourceModelObject && targetPort && targetModelObject) {
560
3/4
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 6 taken 1 time.
✗ Branch 7 not taken.
2 if (boost::optional<Node> inletNode = sourceModelObject->optionalCast<Node>()) {
561
3/4
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 6 taken 1 time.
✗ Branch 7 not taken.
2 if (boost::optional<ModelObject> source2ModelObject = inletNode->inletModelObject()) {
562
5/6
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
✓ Branch 10 taken 1 time.
✓ Branch 12 taken 1 time.
✗ Branch 13 not taken.
2 if (boost::optional<unsigned> source2Port = inletNode->connectedObjectPort(inletNode->inletPort())) {
563
7/7
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
✓ Branch 10 taken 1 time.
✓ Branch 13 taken 1 time.
✓ Branch 16 taken 1 time.
✓ Branch 19 taken 1 time.
1 _model.connect(source2ModelObject.get(), source2Port.get(), targetModelObject.get(), targetPort.get());
564
565
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 inletNode->disconnect();
566
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 inletNode->remove();
567
568
2/3
✓ Branch 1 taken 1 time.
✗ Branch 3 not taken.
✓ Branch 4 taken 1 time.
2 if (boost::optional<PlantLoop> loop = _reheatCoil.plantLoop()) {
569 ✗ loop->removeDemandBranchWithComponent(_reheatCoil);
570 1 }
571
572
1/1
✓ Branch 1 taken 1 time.
2 return StraightComponent_Impl::remove();
573 }
574 1 }
575 1 }
576 }
577
578 ✗ model().disconnect(getObject<ModelObject>(), inletPort());
579 ✗ model().disconnect(getObject<ModelObject>(), outletPort());
580
581 ✗ if (boost::optional<PlantLoop> loop = _reheatCoil.plantLoop()) {
582 ✗ loop->removeDemandBranchWithComponent(_reheatCoil);
583 ✗ }
584
585 ✗ return StraightComponent_Impl::remove();
586 1 }
587
588 11 boost::optional<Node> AirTerminalSingleDuctParallelPIUReheat_Impl::secondaryAirInletNode() const {
589
2/2
✓ Branch 1 taken 11 times.
✓ Branch 4 taken 11 times.
11 boost::optional<ModelObject> mo = connectedObject(secondaryAirInletPort());
590
591
2/2
✓ Branch 0 taken 9 times.
✓ Branch 1 taken 2 times.
11 if (mo) {
592
3/4
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
✓ Branch 6 taken 9 times.
✗ Branch 7 not taken.
18 if (boost::optional<Node> node = mo->optionalCast<Node>()) {
593 9 return node;
594 9 }
595 }
596
597 2 return boost::none;
598 11 }
599
600 21 unsigned AirTerminalSingleDuctParallelPIUReheat_Impl::secondaryAirInletPort() const {
601 21 return OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::SecondaryAirInletNodeName;
602 }
603
604 1 boost::optional<Schedule> AirTerminalSingleDuctParallelPIUReheat_Impl::optionalAvailabilitySchedule() const {
605
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 return getObject<ModelObject>().getModelObjectTarget<Schedule>(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::AvailabilityScheduleName);
606 }
607
608 43 boost::optional<HVACComponent> AirTerminalSingleDuctParallelPIUReheat_Impl::optionalFan() const {
609
2/2
✓ Branch 1 taken 43 times.
✓ Branch 4 taken 43 times.
43 return getObject<ModelObject>().getModelObjectTarget<HVACComponent>(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanName);
610 }
611
612 13 boost::optional<HVACComponent> AirTerminalSingleDuctParallelPIUReheat_Impl::optionalReheatCoil() const {
613
2/2
✓ Branch 1 taken 13 times.
✓ Branch 4 taken 13 times.
13 return getObject<ModelObject>().getModelObjectTarget<HVACComponent>(OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::ReheatCoilName);
614 }
615
616 ✗ boost::optional<ModelObject> AirTerminalSingleDuctParallelPIUReheat_Impl::availabilityScheduleAsModelObject() const {
617 ✗ OptionalModelObject result = availabilitySchedule();
618 ✗ return result;
619 }
620
621 ✗ bool AirTerminalSingleDuctParallelPIUReheat_Impl::setAvailabilityScheduleAsModelObject(const boost::optional<ModelObject>& modelObject) {
622 ✗ if (modelObject) {
623 ✗ OptionalSchedule intermediate = modelObject->optionalCast<Schedule>();
624 ✗ if (intermediate) {
625 ✗ Schedule schedule(*intermediate);
626 ✗ return setAvailabilitySchedule(schedule);
627 ✗ }
628 ✗ }
629 ✗ return false;
630 }
631
632 ✗ bool AirTerminalSingleDuctParallelPIUReheat_Impl::setInducedAirPlenumZone(ThermalZone& plenumZone) {
633 ✗ bool result = true;
634
635 ✗ if (!plenumZone.isPlenum()) {
636 ✗ result = false;
637 }
638
639 ✗ boost::optional<Node> t_secondaryAirInletNode;
640 ✗ if (result) {
641 ✗ t_secondaryAirInletNode = secondaryAirInletNode();
642 ✗ if (!t_secondaryAirInletNode) {
643 ✗ result = false;
644 }
645 }
646
647 ✗ boost::optional<AirLoopHVACReturnPlenum> plenum;
648 ✗ if (result) {
649 ✗ plenum = plenumZone.getImpl<detail::ThermalZone_Impl>()->airLoopHVACReturnPlenum();
650 ✗ if (!plenum) {
651 ✗ result = false;
652 }
653 }
654
655 ✗ if (result) {
656 ✗ Model t_model = model();
657 ✗ PortList pl = plenum->getImpl<detail::AirLoopHVACReturnPlenum_Impl>()->inducedAirOutletPortList();
658 ✗ t_model.connect(pl, pl.nextPort(), t_secondaryAirInletNode.get(), t_secondaryAirInletNode->inletPort());
659 ✗ }
660
661 ✗ return result;
662 ✗ }
663
664 11 bool AirTerminalSingleDuctParallelPIUReheat_Impl::setFanAvailabilitySchedule(Schedule& schedule) {
665
1/1
✓ Branch 1 taken 11 times.
11 auto component = fan();
666 // TODO: from E+ 9.2.0 IDD: \note Fan type must be Fan:SystemModel or Fan:ConstantVolume
667
3/3
✓ Branch 1 taken 11 times.
✓ Branch 3 taken 10 times.
✓ Branch 4 taken 1 time.
22 if (auto constantFan = component.optionalCast<FanConstantVolume>()) {
668
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
10 return constantFan->setAvailabilitySchedule(schedule);
669
2/3
✓ Branch 1 taken 1 time.
✓ Branch 3 taken 1 time.
✗ Branch 4 not taken.
2 } else if (auto systemModelFan = component.optionalCast<FanSystemModel>()) {
670
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 return systemModelFan->setAvailabilitySchedule(schedule);
671 ✗ } else if (auto onOffFan = component.optionalCast<FanOnOff>()) {
672 ✗ return onOffFan->setAvailabilitySchedule(schedule);
673 ✗ } else if (auto variableFan = component.optionalCast<FanVariableVolume>()) {
674 ✗ return variableFan->setAvailabilitySchedule(schedule);
675 } else {
676 // Should never get here!
677 ✗ LOG(Error, "Unknown assigned Fan Type ('" << component.iddObjectType().valueName() << "') for " << briefDescription());
678 ✗ return false;
679 12 }
680 11 };
681
682 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::autosizedMaximumPrimaryAirFlowRate() const {
683 ✗ return getAutosizedValue("Design Size Maximum Primary Air Flow Rate", "m3/s");
684 }
685
686 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::autosizedMaximumSecondaryAirFlowRate() const {
687 ✗ return getAutosizedValue("Design Size Maximum Secondary Air Flow Rate", "m3/s");
688 }
689
690 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::autosizedMinimumPrimaryAirFlowFraction() const {
691 ✗ return getAutosizedValue("Design Size Minimum Primary Air Flow Fraction", "");
692 }
693
694 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::autosizedFanOnFlowFraction() const {
695 ✗ return getAutosizedValue("Design Size Fan On Flow Fraction", "");
696 }
697
698 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat_Impl::autosizedMaximumHotWaterorSteamFlowRate() const {
699 ✗ return getAutosizedValue("Design Size Maximum Reheat Water Flow Rate", "m3/s");
700 }
701
702 ✗ void AirTerminalSingleDuctParallelPIUReheat_Impl::autosize() {
703 ✗ autosizeMaximumPrimaryAirFlowRate();
704 ✗ autosizeMaximumSecondaryAirFlowRate();
705 ✗ autosizeMinimumPrimaryAirFlowFraction();
706 ✗ autosizeFanOnFlowFraction();
707 ✗ autosizeMaximumHotWaterorSteamFlowRate();
708 ✗ }
709
710 ✗ void AirTerminalSingleDuctParallelPIUReheat_Impl::applySizingValues() {
711 ✗ boost::optional<double> val;
712 ✗ val = autosizedMaximumPrimaryAirFlowRate();
713 ✗ if (val) {
714 ✗ setMaximumPrimaryAirFlowRate(val.get());
715 }
716
717 ✗ val = autosizedMaximumSecondaryAirFlowRate();
718 ✗ if (val) {
719 ✗ setMaximumSecondaryAirFlowRate(val.get());
720 }
721
722 ✗ val = autosizedMinimumPrimaryAirFlowFraction();
723 ✗ if (val) {
724 ✗ setMinimumPrimaryAirFlowFraction(val.get());
725 }
726
727 ✗ val = autosizedFanOnFlowFraction();
728 ✗ if (val) {
729 ✗ setFanOnFlowFraction(val.get());
730 }
731
732 ✗ val = autosizedMaximumHotWaterorSteamFlowRate();
733 ✗ if (val) {
734 ✗ setMaximumHotWaterorSteamFlowRate(val.get());
735 }
736 ✗ }
737
738 ✗ ComponentType AirTerminalSingleDuctParallelPIUReheat_Impl::componentType() const {
739 ✗ ComponentType loopType = ComponentType::None;
740 ✗ if (auto a_ = airLoopHVAC()) {
741 ✗ loopType = a_->componentType();
742 ✗ }
743 ✗ if ((loopType == ComponentType::Both) or (loopType == ComponentType::Cooling)) {
744 ✗ return ComponentType::Both;
745 }
746
747 ✗ return ComponentType::Heating;
748 }
749
750 ✗ std::vector<FuelType> AirTerminalSingleDuctParallelPIUReheat_Impl::coolingFuelTypes() const {
751 ✗ if (auto a_ = airLoopHVAC()) {
752 ✗ return a_->coolingFuelTypes();
753 ✗ }
754 ✗ return {};
755 }
756
757 ✗ std::vector<FuelType> AirTerminalSingleDuctParallelPIUReheat_Impl::heatingFuelTypes() const {
758 ✗ std::set<FuelType> result;
759 ✗ for (auto ft : reheatCoil().heatingFuelTypes()) {
760 ✗ result.insert(ft);
761 ✗ }
762 ✗ if (auto a_ = airLoopHVAC()) {
763 ✗ for (auto ft : a_->heatingFuelTypes()) {
764 ✗ result.insert(ft);
765 ✗ }
766 ✗ }
767 ✗ return {result.begin(), result.end()};
768 ✗ }
769
770 ✗ std::vector<AppGFuelType> AirTerminalSingleDuctParallelPIUReheat_Impl::appGHeatingFuelTypes() const {
771 ✗ std::set<AppGFuelType> result;
772 ✗ for (auto ft : reheatCoil().appGHeatingFuelTypes()) {
773 ✗ result.insert(ft);
774 ✗ }
775 ✗ if (auto a_ = airLoopHVAC()) {
776 ✗ for (auto ft : a_->appGHeatingFuelTypes()) {
777 ✗ result.insert(ft);
778 ✗ }
779 ✗ }
780 ✗ return {result.begin(), result.end()};
781 ✗ }
782
783 } // namespace detail
784
785 10 AirTerminalSingleDuctParallelPIUReheat::AirTerminalSingleDuctParallelPIUReheat(const Model& model, Schedule& schedule, HVACComponent& fan,
786 10 HVACComponent& reheatCoil)
787 10 : StraightComponent(AirTerminalSingleDuctParallelPIUReheat::iddObjectType(), model) {
788
1/3
✗ Branch 2 not taken.
✓ Branch 3 taken 10 times.
✗ Branch 5 not taken.
10 OS_ASSERT(getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>());
789
790
1/1
✓ Branch 1 taken 10 times.
10 bool test = setAvailabilitySchedule(schedule);
791
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 if (!test) {
792 ✗ remove();
793 ✗ LOG_AND_THROW("Could not construct " << briefDescription() << ", because could not set its " << "availability schedule to "
794 << schedule.briefDescription() << ".");
795 }
796
797
1/1
✓ Branch 1 taken 10 times.
10 test = setFan(fan);
798
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 if (!test) {
799 ✗ remove();
800 ✗ LOG_AND_THROW("Could not construct " << briefDescription() << ", because could not set its Fan to " << fan.briefDescription() << ".");
801 }
802
803
1/1
✓ Branch 1 taken 10 times.
10 test = setReheatCoil(reheatCoil);
804
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 10 times.
10 if (!test) {
805 ✗ remove();
806 ✗ LOG_AND_THROW("Could not construct " << briefDescription() << ", because could not set its reheatCoil to " << reheatCoil.briefDescription()
807 << ".");
808 }
809
810
1/1
✓ Branch 1 taken 10 times.
10 autosizeMaximumHotWaterorSteamFlowRate();
811
812
1/1
✓ Branch 1 taken 10 times.
10 setMinimumHotWaterorSteamFlowRate(0.0);
813
814
1/1
✓ Branch 1 taken 10 times.
10 setConvergenceTolerance(0.001);
815
816
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
10 setFanControlType("ConstantSpeed");
817
1/1
✓ Branch 1 taken 10 times.
10 setMinimumFanTurnDownRatio(0.3);
818
2/2
✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
10 setHeatingControlType("Staged");
819
1/1
✓ Branch 1 taken 10 times.
10 setDesignHeatingDischargeAirTemperature(32.1);
820
1/1
✓ Branch 1 taken 10 times.
10 setHighLimitHeatingDischargeAirTemperature(37.7);
821
822
1/1
✓ Branch 1 taken 10 times.
10 autosizeMaximumPrimaryAirFlowRate();
823
824
1/1
✓ Branch 1 taken 10 times.
10 autosizeMaximumSecondaryAirFlowRate();
825
826
1/1
✓ Branch 1 taken 10 times.
10 autosizeMinimumPrimaryAirFlowFraction();
827
828
1/1
✓ Branch 1 taken 10 times.
10 autosizeFanOnFlowFraction();
829 10 }
830
831 8514 IddObjectType AirTerminalSingleDuctParallelPIUReheat::iddObjectType() {
832
1/1
✓ Branch 1 taken 8514 times.
8514 return {IddObjectType::OS_AirTerminal_SingleDuct_ParallelPIU_Reheat};
833 }
834
835 ✗ std::vector<std::string> AirTerminalSingleDuctParallelPIUReheat::fanControlTypeValues() {
836 ✗ return getIddKeyNames(IddFactory::instance().getObject(iddObjectType()).get(),
837 ✗ OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::FanControlType);
838 }
839
840 ✗ std::vector<std::string> AirTerminalSingleDuctParallelPIUReheat::heatingControlTypeValues() {
841 ✗ return getIddKeyNames(IddFactory::instance().getObject(iddObjectType()).get(),
842 ✗ OS_AirTerminal_SingleDuct_ParallelPIU_ReheatFields::HeatingControlType);
843 }
844
845 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::maximumPrimaryAirFlowRate() const {
846
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->maximumPrimaryAirFlowRate();
847 }
848
849 1 bool AirTerminalSingleDuctParallelPIUReheat::isMaximumPrimaryAirFlowRateAutosized() const {
850
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isMaximumPrimaryAirFlowRateAutosized();
851 }
852
853 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::maximumSecondaryAirFlowRate() const {
854
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->maximumSecondaryAirFlowRate();
855 }
856
857 1 bool AirTerminalSingleDuctParallelPIUReheat::isMaximumSecondaryAirFlowRateAutosized() const {
858
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isMaximumSecondaryAirFlowRateAutosized();
859 }
860
861 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::minimumPrimaryAirFlowFraction() const {
862
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->minimumPrimaryAirFlowFraction();
863 }
864
865 1 bool AirTerminalSingleDuctParallelPIUReheat::isMinimumPrimaryAirFlowFractionAutosized() const {
866
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isMinimumPrimaryAirFlowFractionAutosized();
867 }
868
869 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::fanOnFlowFraction() const {
870
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->fanOnFlowFraction();
871 }
872
873 1 bool AirTerminalSingleDuctParallelPIUReheat::isFanOnFlowFractionAutosized() const {
874
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isFanOnFlowFractionAutosized();
875 }
876
877 1 boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::maximumHotWaterorSteamFlowRate() const {
878
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->maximumHotWaterorSteamFlowRate();
879 }
880
881 1 bool AirTerminalSingleDuctParallelPIUReheat::isMaximumHotWaterorSteamFlowRateAutosized() const {
882
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isMaximumHotWaterorSteamFlowRateAutosized();
883 }
884
885 1 double AirTerminalSingleDuctParallelPIUReheat::minimumHotWaterorSteamFlowRate() const {
886
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->minimumHotWaterorSteamFlowRate();
887 }
888
889 ✗ bool AirTerminalSingleDuctParallelPIUReheat::isMinimumHotWaterorSteamFlowRateDefaulted() const {
890 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isMinimumHotWaterorSteamFlowRateDefaulted();
891 }
892
893 1 double AirTerminalSingleDuctParallelPIUReheat::convergenceTolerance() const {
894
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->convergenceTolerance();
895 }
896
897 ✗ bool AirTerminalSingleDuctParallelPIUReheat::isConvergenceToleranceDefaulted() const {
898 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->isConvergenceToleranceDefaulted();
899 }
900
901 6 std::string AirTerminalSingleDuctParallelPIUReheat::fanControlType() const {
902
1/1
✓ Branch 3 taken 6 times.
6 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->fanControlType();
903 }
904
905 3 double AirTerminalSingleDuctParallelPIUReheat::minimumFanTurnDownRatio() const {
906
1/1
✓ Branch 3 taken 3 times.
3 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->minimumFanTurnDownRatio();
907 }
908
909 3 std::string AirTerminalSingleDuctParallelPIUReheat::heatingControlType() const {
910
1/1
✓ Branch 3 taken 3 times.
3 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->heatingControlType();
911 }
912
913 3 double AirTerminalSingleDuctParallelPIUReheat::designHeatingDischargeAirTemperature() const {
914
1/1
✓ Branch 3 taken 3 times.
3 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->designHeatingDischargeAirTemperature();
915 }
916
917 3 double AirTerminalSingleDuctParallelPIUReheat::highLimitHeatingDischargeAirTemperature() const {
918
1/1
✓ Branch 3 taken 3 times.
3 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->highLimitHeatingDischargeAirTemperature();
919 }
920
921 1 bool AirTerminalSingleDuctParallelPIUReheat::setMaximumPrimaryAirFlowRate(double maximumPrimaryAirFlowRate) {
922
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMaximumPrimaryAirFlowRate(maximumPrimaryAirFlowRate);
923 }
924
925 10 void AirTerminalSingleDuctParallelPIUReheat::autosizeMaximumPrimaryAirFlowRate() {
926
1/1
✓ Branch 3 taken 10 times.
10 getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizeMaximumPrimaryAirFlowRate();
927 10 }
928
929 1 bool AirTerminalSingleDuctParallelPIUReheat::setMaximumSecondaryAirFlowRate(double maximumSecondaryAirFlowRate) {
930
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMaximumSecondaryAirFlowRate(maximumSecondaryAirFlowRate);
931 }
932
933 10 void AirTerminalSingleDuctParallelPIUReheat::autosizeMaximumSecondaryAirFlowRate() {
934
1/1
✓ Branch 3 taken 10 times.
10 getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizeMaximumSecondaryAirFlowRate();
935 10 }
936
937 1 bool AirTerminalSingleDuctParallelPIUReheat::setMinimumPrimaryAirFlowFraction(double minimumPrimaryAirFlowFraction) {
938
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMinimumPrimaryAirFlowFraction(minimumPrimaryAirFlowFraction);
939 }
940
941 10 void AirTerminalSingleDuctParallelPIUReheat::autosizeMinimumPrimaryAirFlowFraction() {
942
1/1
✓ Branch 3 taken 10 times.
10 getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizeMinimumPrimaryAirFlowFraction();
943 10 }
944
945 1 bool AirTerminalSingleDuctParallelPIUReheat::setFanOnFlowFraction(double fanOnFlowFraction) {
946
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setFanOnFlowFraction(fanOnFlowFraction);
947 }
948
949 10 void AirTerminalSingleDuctParallelPIUReheat::autosizeFanOnFlowFraction() {
950
1/1
✓ Branch 3 taken 10 times.
10 getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizeFanOnFlowFraction();
951 10 }
952
953 1 bool AirTerminalSingleDuctParallelPIUReheat::setMaximumHotWaterorSteamFlowRate(double maximumHotWaterorSteamFlowRate) {
954
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMaximumHotWaterorSteamFlowRate(maximumHotWaterorSteamFlowRate);
955 }
956
957 ✗ void AirTerminalSingleDuctParallelPIUReheat::resetMaximumHotWaterorSteamFlowRate() {
958 ✗ getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->resetMaximumHotWaterorSteamFlowRate();
959 ✗ }
960
961 10 void AirTerminalSingleDuctParallelPIUReheat::autosizeMaximumHotWaterorSteamFlowRate() {
962
1/1
✓ Branch 3 taken 10 times.
10 getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizeMaximumHotWaterorSteamFlowRate();
963 10 }
964
965 11 bool AirTerminalSingleDuctParallelPIUReheat::setMinimumHotWaterorSteamFlowRate(double minimumHotWaterorSteamFlowRate) {
966
1/1
✓ Branch 3 taken 11 times.
11 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMinimumHotWaterorSteamFlowRate(minimumHotWaterorSteamFlowRate);
967 }
968
969 ✗ void AirTerminalSingleDuctParallelPIUReheat::resetMinimumHotWaterorSteamFlowRate() {
970 ✗ getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->resetMinimumHotWaterorSteamFlowRate();
971 ✗ }
972
973 11 bool AirTerminalSingleDuctParallelPIUReheat::setConvergenceTolerance(double convergenceTolerance) {
974
1/1
✓ Branch 3 taken 11 times.
11 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setConvergenceTolerance(convergenceTolerance);
975 }
976
977 ✗ void AirTerminalSingleDuctParallelPIUReheat::resetConvergenceTolerance() {
978 ✗ getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->resetConvergenceTolerance();
979 ✗ }
980
981 13 bool AirTerminalSingleDuctParallelPIUReheat::setFanControlType(const std::string& fanControlType) {
982
1/1
✓ Branch 3 taken 13 times.
13 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setFanControlType(fanControlType);
983 }
984
985 12 bool AirTerminalSingleDuctParallelPIUReheat::setMinimumFanTurnDownRatio(double minimumFanTurnDownRatio) {
986
1/1
✓ Branch 3 taken 12 times.
12 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setMinimumFanTurnDownRatio(minimumFanTurnDownRatio);
987 }
988
989 12 bool AirTerminalSingleDuctParallelPIUReheat::setHeatingControlType(const std::string& heatingControlType) {
990
1/1
✓ Branch 3 taken 12 times.
12 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setHeatingControlType(heatingControlType);
991 }
992
993 12 bool AirTerminalSingleDuctParallelPIUReheat::setDesignHeatingDischargeAirTemperature(double designHeatingDischargeAirTemperature) {
994
1/1
✓ Branch 3 taken 12 times.
24 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setDesignHeatingDischargeAirTemperature(
995 24 designHeatingDischargeAirTemperature);
996 }
997
998 12 bool AirTerminalSingleDuctParallelPIUReheat::setHighLimitHeatingDischargeAirTemperature(double highLimitHeatingDischargeAirTemperature) {
999
1/1
✓ Branch 3 taken 12 times.
24 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setHighLimitHeatingDischargeAirTemperature(
1000 24 highLimitHeatingDischargeAirTemperature);
1001 }
1002
1003 7 HVACComponent AirTerminalSingleDuctParallelPIUReheat::reheatCoil() const {
1004
1/1
✓ Branch 3 taken 7 times.
7 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->reheatCoil();
1005 }
1006
1007 2 HVACComponent AirTerminalSingleDuctParallelPIUReheat::fan() const {
1008
1/1
✓ Branch 3 taken 2 times.
2 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->fan();
1009 }
1010
1011 1 Schedule AirTerminalSingleDuctParallelPIUReheat::availabilitySchedule() const {
1012
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->availabilitySchedule();
1013 }
1014
1015 13 bool AirTerminalSingleDuctParallelPIUReheat::setReheatCoil(HVACComponent& hvacComponent) {
1016
1/1
✓ Branch 3 taken 13 times.
13 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setReheatCoil(hvacComponent);
1017 }
1018
1019 15 bool AirTerminalSingleDuctParallelPIUReheat::setFan(HVACComponent& hvacComponent) {
1020
1/1
✓ Branch 3 taken 15 times.
15 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setFan(hvacComponent);
1021 }
1022
1023 10 bool AirTerminalSingleDuctParallelPIUReheat::setAvailabilitySchedule(Schedule& schedule) {
1024
1/1
✓ Branch 3 taken 10 times.
10 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->setAvailabilitySchedule(schedule);
1025 }
1026
1027 10 boost::optional<Node> AirTerminalSingleDuctParallelPIUReheat::secondaryAirInletNode() const {
1028
1/1
✓ Branch 3 taken 10 times.
10 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->secondaryAirInletNode();
1029 }
1030
1031 4 unsigned AirTerminalSingleDuctParallelPIUReheat::secondaryAirInletPort() const {
1032
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->secondaryAirInletPort();
1033 }
1034
1035 /// @cond
1036
1037 18 AirTerminalSingleDuctParallelPIUReheat::AirTerminalSingleDuctParallelPIUReheat(
1038 18 std::shared_ptr<detail::AirTerminalSingleDuctParallelPIUReheat_Impl> impl)
1039
1/1
✓ Branch 3 taken 18 times.
18 : StraightComponent(std::move(impl)) {}
1040
1041 /// @endcond
1042
1043 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::autosizedMaximumPrimaryAirFlowRate() const {
1044 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizedMaximumPrimaryAirFlowRate();
1045 }
1046
1047 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::autosizedMaximumSecondaryAirFlowRate() const {
1048 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizedMaximumSecondaryAirFlowRate();
1049 }
1050
1051 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::autosizedMinimumPrimaryAirFlowFraction() const {
1052 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizedMinimumPrimaryAirFlowFraction();
1053 }
1054
1055 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::autosizedFanOnFlowFraction() const {
1056 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizedFanOnFlowFraction();
1057 }
1058
1059 ✗ boost::optional<double> AirTerminalSingleDuctParallelPIUReheat::autosizedMaximumHotWaterorSteamFlowRate() const {
1060 ✗ return getImpl<detail::AirTerminalSingleDuctParallelPIUReheat_Impl>()->autosizedMaximumHotWaterorSteamFlowRate();
1061 }
1062
1063 } // namespace model
1064
1065 } // namespace openstudio
1066