GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 87.9% 503 / 0 / 572
Functions: 88.7% 125 / 0 / 141
Branches: 58.1% 342 / 0 / 589

src/model/CoilWaterHeatingAirToWaterHeatPump.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 "CoilWaterHeatingAirToWaterHeatPump.hpp"
7 #include "CoilWaterHeatingAirToWaterHeatPump_Impl.hpp"
8 #include "Model.hpp"
9 #include "Model_Impl.hpp"
10 #include "Curve.hpp"
11 #include "Curve_Impl.hpp"
12 #include "CurveBiquadratic.hpp"
13 #include "CurveBiquadratic_Impl.hpp"
14 #include "CurveQuadratic.hpp"
15 #include "CurveQuadratic_Impl.hpp"
16 #include "Schedule.hpp"
17 #include "Schedule_Impl.hpp"
18 #include "ScheduleTypeRegistry.hpp"
19
20 #include <utilities/idd/IddFactory.hxx>
21 #include <utilities/idd/OS_Coil_WaterHeating_AirToWaterHeatPump_FieldEnums.hxx>
22 #include "../utilities/core/Assert.hpp"
23 #include "../utilities/data/DataEnums.hpp"
24
25 namespace openstudio {
26 namespace model {
27
28 namespace detail {
29
30 23 CoilWaterHeatingAirToWaterHeatPump_Impl::CoilWaterHeatingAirToWaterHeatPump_Impl(const IdfObject& idfObject, Model_Impl* model, bool keepHandle)
31 23 : HVACComponent_Impl(idfObject, model, keepHandle) {
32
4/6
✓ Branch 1 taken 23 times.
✓ Branch 4 taken 23 times.
✓ Branch 7 taken 23 times.
✗ Branch 10 not taken.
✓ Branch 11 taken 23 times.
✗ Branch 13 not taken.
23 OS_ASSERT(idfObject.iddObject().type() == CoilWaterHeatingAirToWaterHeatPump::iddObjectType());
33 23 }
34
35 4 CoilWaterHeatingAirToWaterHeatPump_Impl::CoilWaterHeatingAirToWaterHeatPump_Impl(const openstudio::detail::WorkspaceObject_Impl& other,
36 4 Model_Impl* model, bool keepHandle)
37 4 : HVACComponent_Impl(other, model, keepHandle) {
38
4/6
✓ Branch 1 taken 4 times.
✓ Branch 4 taken 4 times.
✓ Branch 7 taken 4 times.
✗ Branch 10 not taken.
✓ Branch 11 taken 4 times.
✗ Branch 13 not taken.
4 OS_ASSERT(other.iddObject().type() == CoilWaterHeatingAirToWaterHeatPump::iddObjectType());
39 4 }
40
41 4 CoilWaterHeatingAirToWaterHeatPump_Impl::CoilWaterHeatingAirToWaterHeatPump_Impl(const CoilWaterHeatingAirToWaterHeatPump_Impl& other,
42 4 Model_Impl* model, bool keepHandle)
43 4 : HVACComponent_Impl(other, model, keepHandle) {}
44
45 ✗ const std::vector<std::string>& CoilWaterHeatingAirToWaterHeatPump_Impl::outputVariableNames() const {
46 static const std::vector<std::string> result{
47 // As of EnergyPlus version 8.4.0 this object maps to Coil:WaterHeating:AirToWaterHeatPump:Pumped in idf format.
48 // TODO: Make sure this is right (it's Cooling, I expected Heating...)
49 // Taken from the I/O for v 8.7
50 "Cooling Coil Total Cooling Rate",
51 "Cooling Coil Total Cooling Energy",
52 "Cooling Coil Sensible Cooling Rate",
53 "Cooling Coil Sensible Cooling Energy",
54 "Cooling Coil Latent Cooling Rate",
55 "Cooling Coil Latent Cooling Energy",
56 "Cooling Coil Runtime Fraction",
57 "DX Cooling Coil Crankcase Heater Electricity Rate",
58 "Cooling Coil Crankcase Heater Electricity Energy",
59 "Cooling Coil Total Water Heating Rate",
60 "Cooling Coil Total Water Heating Energy",
61 "Cooling Coil Water Heating Electricity Rate",
62 ✗ "Cooling Coil Water Heating Electricity Energy"};
63 ✗ return result;
64 ✗ }
65
66 1 IddObjectType CoilWaterHeatingAirToWaterHeatPump_Impl::iddObjectType() const {
67 1 return CoilWaterHeatingAirToWaterHeatPump::iddObjectType();
68 }
69
70 ✗ std::vector<ScheduleTypeKey> CoilWaterHeatingAirToWaterHeatPump_Impl::getScheduleTypeKeys(const Schedule& schedule) const {
71 ✗ std::vector<ScheduleTypeKey> result;
72 ✗ UnsignedVector fieldIndices = getSourceIndices(schedule.handle());
73 ✗ UnsignedVector::const_iterator b(fieldIndices.begin());
74 ✗ UnsignedVector::const_iterator e(fieldIndices.end());
75 ✗ if (std::find(b, e, OS_Coil_WaterHeating_AirToWaterHeatPumpFields::AvailabilityScheduleName) != e) {
76 ✗ result.push_back(ScheduleTypeKey("CoilWaterHeatingAirToWaterHeatPump", "Availability Schedule"));
77 }
78 ✗ return result;
79 ✗ }
80
81 3 boost::optional<Schedule> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalAvailabilitySchedule() const {
82
2/2
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
3 return getObject<ModelObject>().getModelObjectTarget<Schedule>(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::AvailabilityScheduleName);
83 }
84
85 3 Schedule CoilWaterHeatingAirToWaterHeatPump_Impl::availabilitySchedule() const {
86
1/1
✓ Branch 1 taken 3 times.
3 boost::optional<Schedule> value = optionalAvailabilitySchedule();
87
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
3 if (!value) {
88 // it is an error if we get here, however we don't want to crash
89 // so we hook up to global always on schedule
90 ✗ LOG(Error, "Required availability schedule not set, using 'Always On' schedule");
91 ✗ value = this->model().alwaysOnDiscreteSchedule();
92 ✗ OS_ASSERT(value);
93 ✗ const_cast<CoilWaterHeatingAirToWaterHeatPump_Impl*>(this)->setAvailabilitySchedule(*value);
94 ✗ value = optionalAvailabilitySchedule();
95 }
96
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 3 times.
✗ Branch 4 not taken.
3 OS_ASSERT(value);
97
2/2
✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
6 return value.get();
98 3 }
99
100 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedHeatingCapacity() const {
101
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedHeatingCapacity, true);
102
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
103
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
104 }
105
106 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedCOP() const {
107
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCOP, true);
108
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
109
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
110 }
111
112 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedSensibleHeatRatio() const {
113
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedSensibleHeatRatio, true);
114
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
115
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
116 }
117
118 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedEvaporatorInletAirDryBulbTemperature() const {
119
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorInletAirDryBulbTemperature, true);
120
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
121
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
122 }
123
124 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedEvaporatorInletAirWetBulbTemperature() const {
125
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorInletAirWetBulbTemperature, true);
126
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
127
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
128 }
129
130 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::ratedCondenserInletWaterTemperature() const {
131
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserInletWaterTemperature, true);
132
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
133
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
134 }
135
136 1 boost::optional<double> CoilWaterHeatingAirToWaterHeatPump_Impl::ratedEvaporatorAirFlowRate() const {
137 1 return getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorAirFlowRate, true);
138 }
139
140 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::isRatedEvaporatorAirFlowRateAutosized() const {
141 1 bool result = false;
142
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorAirFlowRate, true);
143
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
144
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "autosize");
145 }
146 1 return result;
147 1 }
148
149 1 boost::optional<double> CoilWaterHeatingAirToWaterHeatPump_Impl::ratedCondenserWaterFlowRate() const {
150 1 return getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserWaterFlowRate, true);
151 }
152
153 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::isRatedCondenserWaterFlowRateAutosized() const {
154 1 bool result = false;
155
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserWaterFlowRate, true);
156
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (value) {
157
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 result = openstudio::istringEqual(value.get(), "autosize");
158 }
159 1 return result;
160 1 }
161
162 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::evaporatorFanPowerIncludedinRatedCOP() const {
163
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::EvaporatorFanPowerIncludedinRatedCOP, true);
164
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
165
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 return openstudio::istringEqual(value.get(), "Yes");
166 1 }
167
168 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::condenserPumpPowerIncludedinRatedCOP() const {
169
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserPumpPowerIncludedinRatedCOP, true);
170
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
171
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 return openstudio::istringEqual(value.get(), "Yes");
172 1 }
173
174 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP() const {
175 boost::optional<std::string> value =
176
1/1
✓ Branch 1 taken 1 time.
1 getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP, true);
177
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
178
3/3
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
✓ Branch 7 taken 1 time.
2 return openstudio::istringEqual(value.get(), "Yes");
179 1 }
180
181 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::condenserWaterPumpPower() const {
182
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserWaterPumpPower, true);
183
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
184
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
185 }
186
187 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::fractionofCondenserPumpHeattoWater() const {
188
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::FractionofCondenserPumpHeattoWater, true);
189
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
190
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
191 }
192
193 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::crankcaseHeaterCapacity() const {
194
1/1
✓ Branch 1 taken 1 time.
1 boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CrankcaseHeaterCapacity, true);
195
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
196
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
197 }
198
199 1 double CoilWaterHeatingAirToWaterHeatPump_Impl::maximumAmbientTemperatureforCrankcaseHeaterOperation() const {
200 boost::optional<double> value =
201
1/1
✓ Branch 1 taken 1 time.
1 getDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::MaximumAmbientTemperatureforCrankcaseHeaterOperation, true);
202
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
203
1/1
✓ Branch 1 taken 1 time.
2 return value.get();
204 }
205
206 1 std::string CoilWaterHeatingAirToWaterHeatPump_Impl::evaporatorAirTemperatureTypeforCurveObjects() const {
207 boost::optional<std::string> value =
208
1/1
✓ Branch 1 taken 1 time.
1 getString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::EvaporatorAirTemperatureTypeforCurveObjects, true);
209
1/3
✗ Branch 1 not taken.
✓ Branch 2 taken 1 time.
✗ Branch 4 not taken.
1 OS_ASSERT(value);
210
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
2 return value.get();
211 1 }
212
213 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCapacityFunctionofTemperatureCurve() const {
214
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCapacityFunctionofTemperatureCurve();
215
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
216 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating Capacity Functionof Temperature Curve attached.");
217 }
218
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
219 9 }
220
221 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCapacityFunctionofAirFlowFractionCurve() const {
222
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCapacityFunctionofAirFlowFractionCurve();
223
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
224 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating Capacity Functionof Air Flow Fraction Curve attached.");
225 }
226
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
227 9 }
228
229 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCapacityFunctionofWaterFlowFractionCurve() const {
230
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCapacityFunctionofWaterFlowFractionCurve();
231
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
232 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating Capacity Functionof Water Flow Fraction Curve attached.");
233 }
234
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
235 9 }
236
237 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCOPFunctionofTemperatureCurve() const {
238
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCOPFunctionofTemperatureCurve();
239
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
240 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating COPFunctionof Temperature Curve attached.");
241 }
242
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
243 9 }
244
245 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCOPFunctionofAirFlowFractionCurve() const {
246
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCOPFunctionofAirFlowFractionCurve();
247
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
248 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating COPFunctionof Air Flow Fraction Curve attached.");
249 }
250
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
251 9 }
252
253 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::heatingCOPFunctionofWaterFlowFractionCurve() const {
254
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalHeatingCOPFunctionofWaterFlowFractionCurve();
255
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
256 ✗ LOG_AND_THROW(briefDescription() << " does not have an Heating COPFunctionof Water Flow Fraction Curve attached.");
257 }
258
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
259 9 }
260
261 9 Curve CoilWaterHeatingAirToWaterHeatPump_Impl::partLoadFractionCorrelationCurve() const {
262
1/1
✓ Branch 1 taken 9 times.
9 boost::optional<Curve> value = optionalPartLoadFractionCorrelationCurve();
263
1/2
✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
9 if (!value) {
264 ✗ LOG_AND_THROW(briefDescription() << " does not have an Part Load Fraction Correlation Curve attached.");
265 }
266
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
18 return value.get();
267 9 }
268
269 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setAvailabilitySchedule(Schedule& schedule) {
270
3/3
✓ Branch 1 taken 20 times.
✓ Branch 4 taken 20 times.
✓ Branch 7 taken 20 times.
80 bool result = setSchedule(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::AvailabilityScheduleName, "CoilWaterHeatingAirToWaterHeatPump",
271 "Availability Schedule", schedule);
272 20 return result;
273 }
274
275 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedHeatingCapacity(double ratedHeatingCapacity) {
276 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedHeatingCapacity, ratedHeatingCapacity);
277 20 return result;
278 }
279
280 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedCOP(double ratedCOP) {
281 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCOP, ratedCOP);
282 20 return result;
283 }
284
285 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedSensibleHeatRatio(double ratedSensibleHeatRatio) {
286 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedSensibleHeatRatio, ratedSensibleHeatRatio);
287 20 return result;
288 }
289
290 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedEvaporatorInletAirDryBulbTemperature(double ratedEvaporatorInletAirDryBulbTemperature) {
291 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorInletAirDryBulbTemperature,
292 ratedEvaporatorInletAirDryBulbTemperature);
293 20 return result;
294 }
295
296 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedEvaporatorInletAirWetBulbTemperature(double ratedEvaporatorInletAirWetBulbTemperature) {
297 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorInletAirWetBulbTemperature,
298 ratedEvaporatorInletAirWetBulbTemperature);
299 20 return result;
300 }
301
302 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedCondenserInletWaterTemperature(double ratedCondenserInletWaterTemperature) {
303 bool result =
304 20 setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserInletWaterTemperature, ratedCondenserInletWaterTemperature);
305 20 return result;
306 }
307
308 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedEvaporatorAirFlowRate(boost::optional<double> ratedEvaporatorAirFlowRate) {
309 1 bool result(false);
310
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (ratedEvaporatorAirFlowRate) {
311 1 result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorAirFlowRate, ratedEvaporatorAirFlowRate.get());
312 }
313 1 return result;
314 }
315
316 19 void CoilWaterHeatingAirToWaterHeatPump_Impl::autosizeRatedEvaporatorAirFlowRate() {
317
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
38 bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedEvaporatorAirFlowRate, "autosize");
318
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 19 times.
19 OS_ASSERT(result);
319 19 }
320
321 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setRatedCondenserWaterFlowRate(boost::optional<double> ratedCondenserWaterFlowRate) {
322 1 bool result(false);
323
1/2
✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
1 if (ratedCondenserWaterFlowRate) {
324 1 result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserWaterFlowRate, ratedCondenserWaterFlowRate.get());
325 }
326 1 return result;
327 }
328
329 19 void CoilWaterHeatingAirToWaterHeatPump_Impl::autosizeRatedCondenserWaterFlowRate() {
330
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
38 bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::RatedCondenserWaterFlowRate, "autosize");
331
1/2
✗ Branch 0 not taken.
✓ Branch 1 taken 19 times.
19 OS_ASSERT(result);
332 19 }
333
334 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setEvaporatorFanPowerIncludedinRatedCOP(bool evaporatorFanPowerIncludedinRatedCOP) {
335 20 return setBooleanFieldValue(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::EvaporatorFanPowerIncludedinRatedCOP,
336 20 evaporatorFanPowerIncludedinRatedCOP);
337 ;
338 }
339
340 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setCondenserPumpPowerIncludedinRatedCOP(bool condenserPumpPowerIncludedinRatedCOP) {
341 20 return setBooleanFieldValue(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserPumpPowerIncludedinRatedCOP,
342 20 condenserPumpPowerIncludedinRatedCOP);
343 ;
344 }
345
346 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(
347 bool condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP) {
348 20 return setBooleanFieldValue(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP,
349 20 condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP);
350 ;
351 }
352
353 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setCondenserWaterPumpPower(double condenserWaterPumpPower) {
354 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CondenserWaterPumpPower, condenserWaterPumpPower);
355 20 return result;
356 }
357
358 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setFractionofCondenserPumpHeattoWater(double fractionofCondenserPumpHeattoWater) {
359 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::FractionofCondenserPumpHeattoWater, fractionofCondenserPumpHeattoWater);
360 20 return result;
361 }
362
363 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setCrankcaseHeaterCapacity(double crankcaseHeaterCapacity) {
364 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CrankcaseHeaterCapacity, crankcaseHeaterCapacity);
365 20 return result;
366 }
367
368 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setMaximumAmbientTemperatureforCrankcaseHeaterOperation(
369 double maximumAmbientTemperatureforCrankcaseHeaterOperation) {
370 20 bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::MaximumAmbientTemperatureforCrankcaseHeaterOperation,
371 maximumAmbientTemperatureforCrankcaseHeaterOperation);
372 20 return result;
373 }
374
375 20 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setEvaporatorAirTemperatureTypeforCurveObjects(
376 const std::string& evaporatorAirTemperatureTypeforCurveObjects) {
377 20 bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::EvaporatorAirTemperatureTypeforCurveObjects,
378 evaporatorAirTemperatureTypeforCurveObjects);
379 20 return result;
380 }
381
382 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCapacityFunctionofTemperatureCurve(const Curve& curve) {
383
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofTemperatureCurve, curve.handle());
384 19 return result;
385 }
386
387 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCapacityFunctionofAirFlowFractionCurve(const Curve& curve) {
388
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofAirFlowFractionCurve, curve.handle());
389 19 return result;
390 }
391
392 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCapacityFunctionofWaterFlowFractionCurve(const Curve& curve) {
393
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofWaterFlowFractionCurve, curve.handle());
394 19 return result;
395 }
396
397 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCOPFunctionofTemperatureCurve(const Curve& curve) {
398
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofTemperatureCurve, curve.handle());
399 19 return result;
400 }
401
402 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCOPFunctionofAirFlowFractionCurve(const Curve& curve) {
403
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofAirFlowFractionCurve, curve.handle());
404 19 return result;
405 }
406
407 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setHeatingCOPFunctionofWaterFlowFractionCurve(const Curve& curve) {
408
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofWaterFlowFractionCurve, curve.handle());
409 19 return result;
410 }
411
412 19 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setPartLoadFractionCorrelationCurve(const Curve& curve) {
413
2/2
✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
19 bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::PartLoadFractionCorrelationCurve, curve.handle());
414 19 return result;
415 }
416
417 6 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::crankcaseHeaterCapacityFunctionofTemperatureCurve() const {
418
1/1
✓ Branch 1 taken 6 times.
12 return getObject<ModelObject>().getModelObjectTarget<Curve>(
419
1/1
✓ Branch 1 taken 6 times.
12 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName);
420 }
421
422 1 bool CoilWaterHeatingAirToWaterHeatPump_Impl::setCrankcaseHeaterCapacityFunctionofTemperatureCurve(const Curve& curve) {
423 const bool result =
424
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 setPointer(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName, curve.handle());
425 1 return result;
426 }
427
428 ✗ void CoilWaterHeatingAirToWaterHeatPump_Impl::resetCrankcaseHeaterCapacityFunctionofTemperatureCurve() {
429 ✗ const bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName, "");
430 ✗ OS_ASSERT(result);
431 ✗ }
432
433 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCapacityFunctionofTemperatureCurve() const {
434
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
435
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofTemperatureCurve);
436 }
437
438 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCapacityFunctionofAirFlowFractionCurve() const {
439
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
440
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofAirFlowFractionCurve);
441 }
442
443 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCapacityFunctionofWaterFlowFractionCurve() const {
444
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
445
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCapacityFunctionofWaterFlowFractionCurve);
446 }
447
448 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCOPFunctionofTemperatureCurve() const {
449
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
450
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofTemperatureCurve);
451 }
452
453 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCOPFunctionofAirFlowFractionCurve() const {
454
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
455
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofAirFlowFractionCurve);
456 }
457
458 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalHeatingCOPFunctionofWaterFlowFractionCurve() const {
459
1/1
✓ Branch 1 taken 9 times.
18 return getObject<ModelObject>().getModelObjectTarget<Curve>(
460
1/1
✓ Branch 1 taken 9 times.
18 OS_Coil_WaterHeating_AirToWaterHeatPumpFields::HeatingCOPFunctionofWaterFlowFractionCurve);
461 }
462
463 9 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump_Impl::optionalPartLoadFractionCorrelationCurve() const {
464
2/2
✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
9 return getObject<ModelObject>().getModelObjectTarget<Curve>(OS_Coil_WaterHeating_AirToWaterHeatPumpFields::PartLoadFractionCorrelationCurve);
465 }
466
467 ✗ ModelObject CoilWaterHeatingAirToWaterHeatPump_Impl::clone(Model model) const {
468 ✗ auto newCoil = ModelObject_Impl::clone(model).cast<CoilWaterHeatingAirToWaterHeatPump>();
469
470 ✗ return std::move(newCoil);
471 ✗ }
472
473 5 std::vector<ModelObject> CoilWaterHeatingAirToWaterHeatPump_Impl::children() const {
474 5 std::vector<ModelObject> result;
475
476
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCapacityFunctionofTemperatureCurve());
477
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCapacityFunctionofAirFlowFractionCurve());
478
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCapacityFunctionofWaterFlowFractionCurve());
479
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCOPFunctionofTemperatureCurve());
480
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCOPFunctionofAirFlowFractionCurve());
481
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(heatingCOPFunctionofWaterFlowFractionCurve());
482
2/2
✓ Branch 1 taken 5 times.
✓ Branch 4 taken 5 times.
5 result.push_back(partLoadFractionCorrelationCurve());
483
3/3
✓ Branch 1 taken 5 times.
✓ Branch 3 taken 1 time.
✓ Branch 4 taken 4 times.
10 if (auto c_ = crankcaseHeaterCapacityFunctionofTemperatureCurve()) {
484
2/2
✓ Branch 1 taken 1 time.
✓ Branch 5 taken 1 time.
1 result.emplace_back(std::move(*c_));
485 5 }
486
487 5 return result;
488 ✗ }
489
490 ✗ boost::optional<double> CoilWaterHeatingAirToWaterHeatPump_Impl::autosizedRatedEvaporatorAirFlowRate() const {
491 // This is an OS naming issue really, not an EPLUS-SQL-INCONSISTENCY
492 ✗ return getAutosizedValue("Design Size Rated Evaporator Air Flow Rate", "m3/s", "Coil:WaterHeating:AirToWaterHeatPump:Pumped");
493 }
494
495 ✗ boost::optional<double> CoilWaterHeatingAirToWaterHeatPump_Impl::autosizedRatedCondenserWaterFlowRate() const {
496 // This is an OS naming issue really, not an EPLUS-SQL-INCONSISTENCY
497 ✗ return getAutosizedValue("Design Size Rated Condenser Water Flow Rate", "m3/s", "Coil:WaterHeating:AirToWaterHeatPump:Pumped");
498 }
499
500 ✗ void CoilWaterHeatingAirToWaterHeatPump_Impl::autosize() {
501 ✗ autosizeRatedEvaporatorAirFlowRate();
502 ✗ autosizeRatedCondenserWaterFlowRate();
503 ✗ }
504
505 ✗ void CoilWaterHeatingAirToWaterHeatPump_Impl::applySizingValues() {
506 ✗ boost::optional<double> val;
507 ✗ val = autosizedRatedEvaporatorAirFlowRate();
508 ✗ if (val) {
509 ✗ setRatedEvaporatorAirFlowRate(val.get());
510 }
511
512 ✗ val = autosizedRatedCondenserWaterFlowRate();
513 ✗ if (val) {
514 ✗ setRatedCondenserWaterFlowRate(val.get());
515 }
516 ✗ }
517
518 ✗ ComponentType CoilWaterHeatingAirToWaterHeatPump_Impl::componentType() const {
519 ✗ return ComponentType::Heating;
520 }
521
522 ✗ std::vector<FuelType> CoilWaterHeatingAirToWaterHeatPump_Impl::coolingFuelTypes() const {
523 ✗ return {};
524 }
525
526 ✗ std::vector<FuelType> CoilWaterHeatingAirToWaterHeatPump_Impl::heatingFuelTypes() const {
527 ✗ return {FuelType::Electricity};
528 }
529
530 ✗ std::vector<AppGFuelType> CoilWaterHeatingAirToWaterHeatPump_Impl::appGHeatingFuelTypes() const {
531 ✗ return {AppGFuelType::HeatPump}; // TODO: openstudio-standards uses Electric
532 }
533
534 } // namespace detail
535
536 18 CoilWaterHeatingAirToWaterHeatPump::CoilWaterHeatingAirToWaterHeatPump(const Model& model)
537 18 : HVACComponent(CoilWaterHeatingAirToWaterHeatPump::iddObjectType(), model) {
538
1/3
✗ Branch 2 not taken.
✓ Branch 3 taken 18 times.
✗ Branch 5 not taken.
18 OS_ASSERT(getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>());
539
540
1/1
✓ Branch 1 taken 18 times.
18 auto always_on = model.alwaysOnDiscreteSchedule();
541
1/1
✓ Branch 1 taken 18 times.
18 bool ok = setAvailabilitySchedule(always_on);
542
1/3
✗ Branch 0 not taken.
✓ Branch 1 taken 18 times.
✗ Branch 3 not taken.
18 OS_ASSERT(ok);
543
544
1/1
✓ Branch 1 taken 18 times.
18 setRatedHeatingCapacity(4000.0);
545
1/1
✓ Branch 1 taken 18 times.
18 setRatedCOP(3.2);
546
1/1
✓ Branch 1 taken 18 times.
18 setRatedSensibleHeatRatio(0.6956);
547
1/1
✓ Branch 1 taken 18 times.
18 setRatedEvaporatorInletAirDryBulbTemperature(29.44);
548
1/1
✓ Branch 1 taken 18 times.
18 setRatedEvaporatorInletAirWetBulbTemperature(22.22);
549
1/1
✓ Branch 1 taken 18 times.
18 setRatedCondenserInletWaterTemperature(55.72);
550
1/1
✓ Branch 1 taken 18 times.
18 autosizeRatedEvaporatorAirFlowRate();
551
1/1
✓ Branch 1 taken 18 times.
18 autosizeRatedCondenserWaterFlowRate();
552
1/1
✓ Branch 1 taken 18 times.
18 setEvaporatorFanPowerIncludedinRatedCOP(false);
553
1/1
✓ Branch 1 taken 18 times.
18 setCondenserPumpPowerIncludedinRatedCOP(false);
554
1/1
✓ Branch 1 taken 18 times.
18 setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(false);
555
1/1
✓ Branch 1 taken 18 times.
18 setCondenserWaterPumpPower(150.0);
556
1/1
✓ Branch 1 taken 18 times.
18 setFractionofCondenserPumpHeattoWater(0.1);
557
1/1
✓ Branch 1 taken 18 times.
18 setCrankcaseHeaterCapacity(100.0);
558
1/1
✓ Branch 1 taken 18 times.
18 setMaximumAmbientTemperatureforCrankcaseHeaterOperation(5.0);
559
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
18 setEvaporatorAirTemperatureTypeforCurveObjects("WetBulbTemperature");
560
561 {
562
1/1
✓ Branch 1 taken 18 times.
18 CurveBiquadratic curve(model);
563
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(0.369827);
564
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.043341);
565
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(-0.00023);
566
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient4y(0.000466);
567
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient5yPOW2(0.000026);
568
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient6xTIMESY(-0.00027);
569
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
570
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(40.0);
571
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofy(20.0);
572
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofy(90.0);
573
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
36 curve.setInputUnitTypeforX("Temperature");
574
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
36 curve.setInputUnitTypeforY("Temperature");
575
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
18 curve.setOutputUnitType("Dimensionless");
576
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCapacityFunctionofTemperatureCurve(curve);
577 18 }
578
579 {
580
1/1
✓ Branch 1 taken 18 times.
18 CurveQuadratic curve(model);
581
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(1.0);
582
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.0);
583
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(0.0);
584
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
585
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(1.0);
586
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCapacityFunctionofAirFlowFractionCurve(curve);
587 18 }
588
589 {
590
1/1
✓ Branch 1 taken 18 times.
18 CurveQuadratic curve(model);
591
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(1.0);
592
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.0);
593
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(0.0);
594
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
595
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(1.0);
596
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCapacityFunctionofWaterFlowFractionCurve(curve);
597 18 }
598
599 {
600
1/1
✓ Branch 1 taken 18 times.
18 CurveBiquadratic curve(model);
601
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(1.19713);
602
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.077849);
603
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(-0.0000016);
604
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient4y(-0.02675);
605
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient5yPOW2(0.000296);
606
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient6xTIMESY(-0.00112);
607
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
608
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(40.0);
609
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofy(20.0);
610
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofy(90.0);
611
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
36 curve.setInputUnitTypeforX("Temperature");
612
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
36 curve.setInputUnitTypeforY("Temperature");
613
2/2
✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
18 curve.setOutputUnitType("Dimensionless");
614
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCOPFunctionofTemperatureCurve(curve);
615 18 }
616
617 {
618
1/1
✓ Branch 1 taken 18 times.
18 CurveQuadratic curve(model);
619
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(1.0);
620
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.0);
621
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(0.0);
622
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
623
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(1.0);
624
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCOPFunctionofAirFlowFractionCurve(curve);
625 18 }
626
627 {
628
1/1
✓ Branch 1 taken 18 times.
18 CurveQuadratic curve(model);
629
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(1.0);
630
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.0);
631
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(0.0);
632
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
633
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(1.0);
634
1/1
✓ Branch 1 taken 18 times.
18 setHeatingCOPFunctionofWaterFlowFractionCurve(curve);
635 18 }
636
637 {
638
1/1
✓ Branch 1 taken 18 times.
18 CurveQuadratic curve(model);
639
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient1Constant(0.75);
640
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient2x(0.25);
641
1/1
✓ Branch 1 taken 18 times.
18 curve.setCoefficient3xPOW2(0.0);
642
1/1
✓ Branch 1 taken 18 times.
18 curve.setMinimumValueofx(0.0);
643
1/1
✓ Branch 1 taken 18 times.
18 curve.setMaximumValueofx(1.0);
644
1/1
✓ Branch 1 taken 18 times.
18 setPartLoadFractionCorrelationCurve(curve);
645 18 }
646 18 }
647
648 1 CoilWaterHeatingAirToWaterHeatPump::CoilWaterHeatingAirToWaterHeatPump(
649 const Model& model, Curve& heatingCapacityFunctionofTemperatureCurve, Curve& heatingCapacityFunctionofAirFlowFractionCurve,
650 Curve& heatingCapacityFunctionofWaterFlowFractionCurve, Curve& heatingCOPFunctionofTemperatureCurve,
651 1 Curve& heatingCOPFunctionofAirFlowFractionCurve, Curve& heatingCOPFunctionofWaterFlowFractionCurve, Curve& partLoadFractionCorrelationCurve)
652 1 : HVACComponent(CoilWaterHeatingAirToWaterHeatPump::iddObjectType(), model) {
653
1/3
✗ Branch 2 not taken.
✓ Branch 3 taken 1 time.
✗ Branch 5 not taken.
1 OS_ASSERT(getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>());
654
655
1/1
✓ Branch 1 taken 1 time.
1 auto always_on = model.alwaysOnDiscreteSchedule();
656
1/1
✓ Branch 1 taken 1 time.
1 bool ok = setAvailabilitySchedule(always_on);
657
1/3
✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
✗ Branch 3 not taken.
1 OS_ASSERT(ok);
658
659
1/1
✓ Branch 1 taken 1 time.
1 setRatedHeatingCapacity(4000.0);
660
1/1
✓ Branch 1 taken 1 time.
1 setRatedCOP(3.2);
661
1/1
✓ Branch 1 taken 1 time.
1 setRatedSensibleHeatRatio(0.6956);
662
1/1
✓ Branch 1 taken 1 time.
1 setRatedEvaporatorInletAirDryBulbTemperature(29.44);
663
1/1
✓ Branch 1 taken 1 time.
1 setRatedEvaporatorInletAirWetBulbTemperature(22.22);
664
1/1
✓ Branch 1 taken 1 time.
1 setRatedCondenserInletWaterTemperature(55.72);
665
1/1
✓ Branch 1 taken 1 time.
1 autosizeRatedEvaporatorAirFlowRate();
666
1/1
✓ Branch 1 taken 1 time.
1 autosizeRatedCondenserWaterFlowRate();
667
1/1
✓ Branch 1 taken 1 time.
1 setEvaporatorFanPowerIncludedinRatedCOP(false);
668
1/1
✓ Branch 1 taken 1 time.
1 setCondenserPumpPowerIncludedinRatedCOP(false);
669
1/1
✓ Branch 1 taken 1 time.
1 setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(false);
670
1/1
✓ Branch 1 taken 1 time.
1 setCondenserWaterPumpPower(150.0);
671
1/1
✓ Branch 1 taken 1 time.
1 setFractionofCondenserPumpHeattoWater(0.1);
672
1/1
✓ Branch 1 taken 1 time.
1 setCrankcaseHeaterCapacity(100.0);
673
1/1
✓ Branch 1 taken 1 time.
1 setMaximumAmbientTemperatureforCrankcaseHeaterOperation(5.0);
674
2/2
✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
1 setEvaporatorAirTemperatureTypeforCurveObjects("WetBulbTemperature");
675
676
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCapacityFunctionofTemperatureCurve(heatingCapacityFunctionofTemperatureCurve);
677
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCapacityFunctionofAirFlowFractionCurve(heatingCapacityFunctionofAirFlowFractionCurve);
678
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCapacityFunctionofWaterFlowFractionCurve(heatingCapacityFunctionofWaterFlowFractionCurve);
679
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCOPFunctionofTemperatureCurve(heatingCOPFunctionofTemperatureCurve);
680
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCOPFunctionofAirFlowFractionCurve(heatingCOPFunctionofAirFlowFractionCurve);
681
1/1
✓ Branch 1 taken 1 time.
1 setHeatingCOPFunctionofWaterFlowFractionCurve(heatingCOPFunctionofWaterFlowFractionCurve);
682
1/1
✓ Branch 1 taken 1 time.
1 setPartLoadFractionCorrelationCurve(partLoadFractionCorrelationCurve);
683 1 }
684
685 7648 IddObjectType CoilWaterHeatingAirToWaterHeatPump::iddObjectType() {
686
1/1
✓ Branch 1 taken 7648 times.
7648 return {IddObjectType::OS_Coil_WaterHeating_AirToWaterHeatPump};
687 }
688
689 ✗ std::vector<std::string> CoilWaterHeatingAirToWaterHeatPump::evaporatorAirTemperatureTypeforCurveObjectsValues() {
690 ✗ return getIddKeyNames(IddFactory::instance().getObject(iddObjectType()).get(),
691 ✗ OS_Coil_WaterHeating_AirToWaterHeatPumpFields::EvaporatorAirTemperatureTypeforCurveObjects);
692 }
693
694 3 Schedule CoilWaterHeatingAirToWaterHeatPump::availabilitySchedule() const {
695
1/1
✓ Branch 3 taken 3 times.
3 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->availabilitySchedule();
696 }
697
698 1 double CoilWaterHeatingAirToWaterHeatPump::ratedHeatingCapacity() const {
699
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedHeatingCapacity();
700 }
701
702 1 double CoilWaterHeatingAirToWaterHeatPump::ratedCOP() const {
703
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedCOP();
704 }
705
706 1 double CoilWaterHeatingAirToWaterHeatPump::ratedSensibleHeatRatio() const {
707
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedSensibleHeatRatio();
708 }
709
710 1 double CoilWaterHeatingAirToWaterHeatPump::ratedEvaporatorInletAirDryBulbTemperature() const {
711
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedEvaporatorInletAirDryBulbTemperature();
712 }
713
714 1 double CoilWaterHeatingAirToWaterHeatPump::ratedEvaporatorInletAirWetBulbTemperature() const {
715
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedEvaporatorInletAirWetBulbTemperature();
716 }
717
718 1 double CoilWaterHeatingAirToWaterHeatPump::ratedCondenserInletWaterTemperature() const {
719
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedCondenserInletWaterTemperature();
720 }
721
722 1 boost::optional<double> CoilWaterHeatingAirToWaterHeatPump::ratedEvaporatorAirFlowRate() const {
723
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedEvaporatorAirFlowRate();
724 }
725
726 1 bool CoilWaterHeatingAirToWaterHeatPump::isRatedEvaporatorAirFlowRateAutosized() const {
727
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->isRatedEvaporatorAirFlowRateAutosized();
728 }
729
730 1 boost::optional<double> CoilWaterHeatingAirToWaterHeatPump::ratedCondenserWaterFlowRate() const {
731
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->ratedCondenserWaterFlowRate();
732 }
733
734 1 bool CoilWaterHeatingAirToWaterHeatPump::isRatedCondenserWaterFlowRateAutosized() const {
735
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->isRatedCondenserWaterFlowRateAutosized();
736 }
737
738 1 bool CoilWaterHeatingAirToWaterHeatPump::evaporatorFanPowerIncludedinRatedCOP() const {
739
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->evaporatorFanPowerIncludedinRatedCOP();
740 }
741
742 1 bool CoilWaterHeatingAirToWaterHeatPump::condenserPumpPowerIncludedinRatedCOP() const {
743
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->condenserPumpPowerIncludedinRatedCOP();
744 }
745
746 1 bool CoilWaterHeatingAirToWaterHeatPump::condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP() const {
747
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP();
748 }
749
750 1 double CoilWaterHeatingAirToWaterHeatPump::condenserWaterPumpPower() const {
751
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->condenserWaterPumpPower();
752 }
753
754 1 double CoilWaterHeatingAirToWaterHeatPump::fractionofCondenserPumpHeattoWater() const {
755
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->fractionofCondenserPumpHeattoWater();
756 }
757
758 1 double CoilWaterHeatingAirToWaterHeatPump::crankcaseHeaterCapacity() const {
759
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->crankcaseHeaterCapacity();
760 }
761
762 1 double CoilWaterHeatingAirToWaterHeatPump::maximumAmbientTemperatureforCrankcaseHeaterOperation() const {
763
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->maximumAmbientTemperatureforCrankcaseHeaterOperation();
764 }
765
766 1 std::string CoilWaterHeatingAirToWaterHeatPump::evaporatorAirTemperatureTypeforCurveObjects() const {
767
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->evaporatorAirTemperatureTypeforCurveObjects();
768 }
769
770 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCapacityFunctionofTemperatureCurve() const {
771
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCapacityFunctionofTemperatureCurve();
772 }
773
774 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCapacityFunctionofAirFlowFractionCurve() const {
775
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCapacityFunctionofAirFlowFractionCurve();
776 }
777
778 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCapacityFunctionofWaterFlowFractionCurve() const {
779
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCapacityFunctionofWaterFlowFractionCurve();
780 }
781
782 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCOPFunctionofTemperatureCurve() const {
783
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCOPFunctionofTemperatureCurve();
784 }
785
786 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCOPFunctionofAirFlowFractionCurve() const {
787
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCOPFunctionofAirFlowFractionCurve();
788 }
789
790 4 Curve CoilWaterHeatingAirToWaterHeatPump::heatingCOPFunctionofWaterFlowFractionCurve() const {
791
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->heatingCOPFunctionofWaterFlowFractionCurve();
792 }
793
794 4 Curve CoilWaterHeatingAirToWaterHeatPump::partLoadFractionCorrelationCurve() const {
795
1/1
✓ Branch 3 taken 4 times.
4 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->partLoadFractionCorrelationCurve();
796 }
797
798 20 bool CoilWaterHeatingAirToWaterHeatPump::setAvailabilitySchedule(Schedule& schedule) {
799
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setAvailabilitySchedule(schedule);
800 }
801
802 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedHeatingCapacity(double ratedHeatingCapacity) {
803
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedHeatingCapacity(ratedHeatingCapacity);
804 }
805
806 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedCOP(double ratedCOP) {
807
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedCOP(ratedCOP);
808 }
809
810 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedSensibleHeatRatio(double ratedSensibleHeatRatio) {
811
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedSensibleHeatRatio(ratedSensibleHeatRatio);
812 }
813
814 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedEvaporatorInletAirDryBulbTemperature(double ratedEvaporatorInletAirDryBulbTemperature) {
815
1/1
✓ Branch 3 taken 20 times.
40 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedEvaporatorInletAirDryBulbTemperature(
816 40 ratedEvaporatorInletAirDryBulbTemperature);
817 }
818
819 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedEvaporatorInletAirWetBulbTemperature(double ratedEvaporatorInletAirWetBulbTemperature) {
820
1/1
✓ Branch 3 taken 20 times.
40 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedEvaporatorInletAirWetBulbTemperature(
821 40 ratedEvaporatorInletAirWetBulbTemperature);
822 }
823
824 20 bool CoilWaterHeatingAirToWaterHeatPump::setRatedCondenserInletWaterTemperature(double ratedCondenserInletWaterTemperature) {
825
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedCondenserInletWaterTemperature(ratedCondenserInletWaterTemperature);
826 }
827
828 1 bool CoilWaterHeatingAirToWaterHeatPump::setRatedEvaporatorAirFlowRate(double ratedEvaporatorAirFlowRate) {
829
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedEvaporatorAirFlowRate(ratedEvaporatorAirFlowRate);
830 }
831
832 19 void CoilWaterHeatingAirToWaterHeatPump::autosizeRatedEvaporatorAirFlowRate() {
833
1/1
✓ Branch 3 taken 19 times.
19 getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->autosizeRatedEvaporatorAirFlowRate();
834 19 }
835
836 1 bool CoilWaterHeatingAirToWaterHeatPump::setRatedCondenserWaterFlowRate(double ratedCondenserWaterFlowRate) {
837
2/2
✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setRatedCondenserWaterFlowRate(ratedCondenserWaterFlowRate);
838 }
839
840 19 void CoilWaterHeatingAirToWaterHeatPump::autosizeRatedCondenserWaterFlowRate() {
841
1/1
✓ Branch 3 taken 19 times.
19 getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->autosizeRatedCondenserWaterFlowRate();
842 19 }
843
844 20 bool CoilWaterHeatingAirToWaterHeatPump::setEvaporatorFanPowerIncludedinRatedCOP(bool evaporatorFanPowerIncludedinRatedCOP) {
845
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setEvaporatorFanPowerIncludedinRatedCOP(evaporatorFanPowerIncludedinRatedCOP);
846 }
847
848 20 bool CoilWaterHeatingAirToWaterHeatPump::setCondenserPumpPowerIncludedinRatedCOP(bool condenserPumpPowerIncludedinRatedCOP) {
849
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setCondenserPumpPowerIncludedinRatedCOP(condenserPumpPowerIncludedinRatedCOP);
850 }
851
852 20 bool CoilWaterHeatingAirToWaterHeatPump::setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(
853 bool condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP) {
854
1/1
✓ Branch 3 taken 20 times.
40 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(
855 40 condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP);
856 }
857
858 20 bool CoilWaterHeatingAirToWaterHeatPump::setCondenserWaterPumpPower(double condenserWaterPumpPower) {
859
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setCondenserWaterPumpPower(condenserWaterPumpPower);
860 }
861
862 20 bool CoilWaterHeatingAirToWaterHeatPump::setFractionofCondenserPumpHeattoWater(double fractionofCondenserPumpHeattoWater) {
863
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setFractionofCondenserPumpHeattoWater(fractionofCondenserPumpHeattoWater);
864 }
865
866 20 bool CoilWaterHeatingAirToWaterHeatPump::setCrankcaseHeaterCapacity(double crankcaseHeaterCapacity) {
867
1/1
✓ Branch 3 taken 20 times.
20 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setCrankcaseHeaterCapacity(crankcaseHeaterCapacity);
868 }
869
870 20 bool CoilWaterHeatingAirToWaterHeatPump::setMaximumAmbientTemperatureforCrankcaseHeaterOperation(
871 double maximumAmbientTemperatureforCrankcaseHeaterOperation) {
872
1/1
✓ Branch 3 taken 20 times.
40 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setMaximumAmbientTemperatureforCrankcaseHeaterOperation(
873 40 maximumAmbientTemperatureforCrankcaseHeaterOperation);
874 }
875
876 20 bool CoilWaterHeatingAirToWaterHeatPump::setEvaporatorAirTemperatureTypeforCurveObjects(
877 const std::string& evaporatorAirTemperatureTypeforCurveObjects) {
878
1/1
✓ Branch 3 taken 20 times.
40 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setEvaporatorAirTemperatureTypeforCurveObjects(
879 40 evaporatorAirTemperatureTypeforCurveObjects);
880 }
881
882 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCapacityFunctionofTemperatureCurve(const Curve& curve) {
883
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCapacityFunctionofTemperatureCurve(curve);
884 }
885
886 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCapacityFunctionofAirFlowFractionCurve(const Curve& curve) {
887
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCapacityFunctionofAirFlowFractionCurve(curve);
888 }
889
890 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCapacityFunctionofWaterFlowFractionCurve(const Curve& curve) {
891
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCapacityFunctionofWaterFlowFractionCurve(curve);
892 }
893
894 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCOPFunctionofTemperatureCurve(const Curve& curve) {
895
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCOPFunctionofTemperatureCurve(curve);
896 }
897
898 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCOPFunctionofAirFlowFractionCurve(const Curve& curve) {
899
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCOPFunctionofAirFlowFractionCurve(curve);
900 }
901
902 19 bool CoilWaterHeatingAirToWaterHeatPump::setHeatingCOPFunctionofWaterFlowFractionCurve(const Curve& curve) {
903
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setHeatingCOPFunctionofWaterFlowFractionCurve(curve);
904 }
905
906 19 bool CoilWaterHeatingAirToWaterHeatPump::setPartLoadFractionCorrelationCurve(const Curve& curve) {
907
1/1
✓ Branch 3 taken 19 times.
19 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setPartLoadFractionCorrelationCurve(curve);
908 }
909
910 1 boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPump::crankcaseHeaterCapacityFunctionofTemperatureCurve() const {
911
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->crankcaseHeaterCapacityFunctionofTemperatureCurve();
912 }
913
914 1 bool CoilWaterHeatingAirToWaterHeatPump::setCrankcaseHeaterCapacityFunctionofTemperatureCurve(const Curve& curve) {
915
1/1
✓ Branch 3 taken 1 time.
1 return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->setCrankcaseHeaterCapacityFunctionofTemperatureCurve(curve);
916 }
917
918 ✗ void CoilWaterHeatingAirToWaterHeatPump::resetCrankcaseHeaterCapacityFunctionofTemperatureCurve() {
919 ✗ getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->resetCrankcaseHeaterCapacityFunctionofTemperatureCurve();
920 ✗ }
921
922 /// @cond
923 1 CoilWaterHeatingAirToWaterHeatPump::CoilWaterHeatingAirToWaterHeatPump(std::shared_ptr<detail::CoilWaterHeatingAirToWaterHeatPump_Impl> impl)
924
1/1
✓ Branch 3 taken 1 time.
1 : HVACComponent(std::move(impl)) {}
925 /// @endcond
926
927 ✗ boost::optional<double> CoilWaterHeatingAirToWaterHeatPump::autosizedRatedEvaporatorAirFlowRate() const {
928 ✗ return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->autosizedRatedEvaporatorAirFlowRate();
929 }
930
931 ✗ boost::optional<double> CoilWaterHeatingAirToWaterHeatPump::autosizedRatedCondenserWaterFlowRate() const {
932 ✗ return getImpl<detail::CoilWaterHeatingAirToWaterHeatPump_Impl>()->autosizedRatedCondenserWaterFlowRate();
933 }
934
935 } // namespace model
936 } // namespace openstudio
937