src/model/CoilWaterHeatingAirToWaterHeatPumpVariableSpeed.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 "CoilWaterHeatingAirToWaterHeatPumpVariableSpeed.hpp" | ||
| 7 | #include "CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl.hpp" | ||
| 8 | |||
| 9 | #include "CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData.hpp" | ||
| 10 | #include "CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData_Impl.hpp" | ||
| 11 | #include "Model.hpp" | ||
| 12 | #include "Model_Impl.hpp" | ||
| 13 | #include "Curve.hpp" | ||
| 14 | #include "Curve_Impl.hpp" | ||
| 15 | #include "CurveQuadratic.hpp" | ||
| 16 | #include "CurveQuadratic_Impl.hpp" | ||
| 17 | #include "ModelObjectList.hpp" | ||
| 18 | #include "ModelObjectList_Impl.hpp" | ||
| 19 | #include "Schedule.hpp" | ||
| 20 | #include "Schedule_Impl.hpp" | ||
| 21 | #include "CoilSystemIntegratedHeatPumpAirSource.hpp" | ||
| 22 | #include "CoilSystemIntegratedHeatPumpAirSource_Impl.hpp" | ||
| 23 | #include "WaterHeaterHeatPump.hpp" | ||
| 24 | #include "WaterHeaterHeatPump_Impl.hpp" | ||
| 25 | #include "ScheduleTypeRegistry.hpp" | ||
| 26 | |||
| 27 | #include <utilities/idd/IddFactory.hxx> | ||
| 28 | #include <utilities/idd/IddEnums.hxx> | ||
| 29 | #include <utilities/idd/OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeed_FieldEnums.hxx> | ||
| 30 | #include "../utilities/core/Assert.hpp" | ||
| 31 | #include "../utilities/data/DataEnums.hpp" | ||
| 32 | |||
| 33 | namespace openstudio { | ||
| 34 | namespace model { | ||
| 35 | |||
| 36 | namespace detail { | ||
| 37 | |||
| 38 | 63 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl(const IdfObject& idfObject, | |
| 39 | 63 | Model_Impl* model, bool keepHandle) | |
| 40 | 63 | : HVACComponent_Impl(idfObject, model, keepHandle) { | |
| 41 |
4/6✓ Branch 1 taken 63 times.
✓ Branch 4 taken 63 times.
✓ Branch 7 taken 63 times.
✗ Branch 10 not taken.
✓ Branch 11 taken 63 times.
✗ Branch 13 not taken.
|
63 | OS_ASSERT(idfObject.iddObject().type() == CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::iddObjectType()); |
| 42 | 63 | } | |
| 43 | |||
| 44 | 2 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl( | |
| 45 | 2 | const openstudio::detail::WorkspaceObject_Impl& other, Model_Impl* model, bool keepHandle) | |
| 46 | 2 | : HVACComponent_Impl(other, model, keepHandle) { | |
| 47 |
4/6✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
✓ Branch 7 taken 2 times.
✗ Branch 10 not taken.
✓ Branch 11 taken 2 times.
✗ Branch 13 not taken.
|
2 | OS_ASSERT(other.iddObject().type() == CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::iddObjectType()); |
| 48 | 2 | } | |
| 49 | |||
| 50 | 41 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl( | |
| 51 | 41 | const CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl& other, Model_Impl* model, bool keepHandle) | |
| 52 | 41 | : HVACComponent_Impl(other, model, keepHandle) {} | |
| 53 | |||
| 54 | ✗ | const std::vector<std::string>& CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::outputVariableNames() const { | |
| 55 | static const std::vector<std::string> result{ | ||
| 56 | "Cooling Coil Electricity Energy", | ||
| 57 | "Cooling Coil Sensible Cooling Energy", | ||
| 58 | "Cooling Coil Latent Cooling Energy", | ||
| 59 | "Cooling Coil Water Side Heat Transfer Energy", | ||
| 60 | "Cooling Coil Cooling Energy", | ||
| 61 | "Cooling Coil Water Heating Electricity Rate", | ||
| 62 | "Cooling Coil Total Cooling Rate", | ||
| 63 | "Cooling Coil Sensible Cooling Rate", | ||
| 64 | "Cooling Coil Latent Cooling Rate", | ||
| 65 | "Cooling Coil Total Water Heating Rate", | ||
| 66 | "Cooling Coil Part Load Ratio", | ||
| 67 | "Cooling Coil Runtime Fraction", | ||
| 68 | "Cooling Coil Air Mass Flow Rate", | ||
| 69 | "Cooling Coil Air Inlet Temperature", | ||
| 70 | "Cooling Coil Air Inlet Humidity Ratio", | ||
| 71 | "Cooling Coil Air Outlet Temperature", | ||
| 72 | "Cooling Coil Air Outlet Humidity Ratio", | ||
| 73 | "Cooling Coil Water Mass Flow Rate", | ||
| 74 | "Cooling Coil Water Inlet Temperature", | ||
| 75 | "Cooling Coil Water Outlet Temperature", | ||
| 76 | "Cooling Coil Crankcase Heater Electricity Rate", | ||
| 77 | "Cooling Coil Crankcase Heater Electricity Energy", | ||
| 78 | "Cooling Coil Upper Speed Level", | ||
| 79 | "Cooling Coil Neighboring Speed Levels Ratio", | ||
| 80 | "Cooling Coil Water Heating Pump Electricity Rate", | ||
| 81 | "Cooling Coil Water Heating Pump Electricity Energy", | ||
| 82 | ✗ | }; | |
| 83 | ✗ | return result; | |
| 84 | ✗ | } | |
| 85 | |||
| 86 | 2 | IddObjectType CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::iddObjectType() const { | |
| 87 | 2 | return CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::iddObjectType(); | |
| 88 | } | ||
| 89 | |||
| 90 | ✗ | std::vector<ScheduleTypeKey> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::getScheduleTypeKeys(const Schedule& schedule) const { | |
| 91 | ✗ | std::vector<ScheduleTypeKey> result; | |
| 92 | ✗ | UnsignedVector fieldIndices = getSourceIndices(schedule.handle()); | |
| 93 | ✗ | UnsignedVector::const_iterator b(fieldIndices.begin()); | |
| 94 | ✗ | UnsignedVector::const_iterator e(fieldIndices.end()); | |
| 95 | ✗ | if (std::find(b, e, OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::AvailabilityScheduleName) != e) { | |
| 96 | ✗ | result.push_back(ScheduleTypeKey("CoilWaterHeatingAirToWaterHeatPumpVariableSpeed", "Availability Schedule")); | |
| 97 | } | ||
| 98 | ✗ | return result; | |
| 99 | ✗ | } | |
| 100 | |||
| 101 | 10 | std::vector<ModelObject> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::children() const { | |
| 102 | 10 | std::vector<ModelObject> result; | |
| 103 | |||
| 104 |
2/3✓ Branch 1 taken 10 times.
✓ Branch 3 taken 10 times.
✗ Branch 4 not taken.
|
20 | if (OptionalCurve intermediate = optionalPartLoadFractionCorrelationCurve()) { |
| 105 |
2/2✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
|
10 | result.push_back(*intermediate); |
| 106 | 10 | } | |
| 107 |
3/3✓ Branch 1 taken 10 times.
✓ Branch 3 taken 1 time.
✓ Branch 4 taken 9 times.
|
20 | if (auto c_ = crankcaseHeaterCapacityFunctionofTemperatureCurve()) { |
| 108 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 5 taken 1 time.
|
1 | result.emplace_back(std::move(*c_)); |
| 109 | 10 | } | |
| 110 | |||
| 111 |
2/3✓ Branch 1 taken 10 times.
✓ Branch 3 taken 10 times.
✗ Branch 4 not taken.
|
20 | if (auto const _stageDataList = speedDataList()) { |
| 112 |
4/4✓ Branch 1 taken 10 times.
✓ Branch 4 taken 10 times.
✓ Branch 11 taken 6 times.
✓ Branch 12 taken 10 times.
|
16 | for (const auto& mo : _stageDataList->modelObjects()) { |
| 113 |
1/1✓ Branch 1 taken 6 times.
|
6 | result.push_back(mo); |
| 114 | 10 | } | |
| 115 | 10 | } | |
| 116 | 10 | return result; | |
| 117 | ✗ | } | |
| 118 | |||
| 119 | 18 | ModelObject CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::clone(Model model) const { | |
| 120 |
3/3✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
✓ Branch 7 taken 18 times.
|
18 | auto t_clone = ModelObject_Impl::clone(model).cast<CoilWaterHeatingAirToWaterHeatPumpVariableSpeed>(); |
| 121 | |||
| 122 |
2/3✓ Branch 1 taken 18 times.
✓ Branch 3 taken 18 times.
✗ Branch 4 not taken.
|
36 | if (auto speedDataList_ = this->speedDataList()) { |
| 123 |
4/4✓ Branch 1 taken 18 times.
✓ Branch 4 taken 18 times.
✓ Branch 7 taken 18 times.
✓ Branch 10 taken 18 times.
|
18 | auto speedDataListClone = speedDataList_->clone(model).cast<ModelObjectList>(); |
| 124 |
2/2✓ Branch 3 taken 18 times.
✓ Branch 6 taken 18 times.
|
18 | t_clone.getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setSpeedDataList(speedDataListClone); |
| 125 | 36 | } | |
| 126 | |||
| 127 | 36 | return std::move(t_clone); | |
| 128 | 18 | } | |
| 129 | |||
| 130 | 1 | std::vector<IdfObject> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::remove() { | |
| 131 |
1/1✓ Branch 1 taken 1 time.
|
1 | auto speedDataList_ = speedDataList(); |
| 132 |
1/1✓ Branch 1 taken 1 time.
|
1 | auto result = HVACComponent_Impl::remove(); |
| 133 |
3/6✓ Branch 1 taken 1 time.
✗ Branch 2 not taken.
✓ Branch 3 taken 1 time.
✗ Branch 4 not taken.
✓ Branch 5 taken 1 time.
✗ Branch 6 not taken.
|
2 | if ((!result.empty()) && speedDataList_) { |
| 134 |
2/2✓ Branch 1 taken 1 time.
✓ Branch 4 taken 1 time.
|
1 | speedDataList_->remove(); |
| 135 | } | ||
| 136 | |||
| 137 | 2 | return result; | |
| 138 | 1 | } | |
| 139 | |||
| 140 | 19 | boost::optional<HVACComponent> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::containingHVACComponent() const { | |
| 141 | // OS:WaterHeater:HeatPump (PumpedCondenser) | ||
| 142 | { | ||
| 143 |
2/2✓ Branch 1 taken 19 times.
✓ Branch 4 taken 19 times.
|
19 | auto systems = this->model().getConcreteModelObjects<WaterHeaterHeatPump>(); |
| 144 | |||
| 145 |
2/2✓ Branch 5 taken 2 times.
✓ Branch 6 taken 17 times.
|
19 | for (auto const& system : systems) { |
| 146 |
5/6✓ Branch 1 taken 2 times.
✓ Branch 4 taken 2 times.
✓ Branch 7 taken 2 times.
✓ Branch 10 taken 2 times.
✓ Branch 13 taken 2 times.
✗ Branch 14 not taken.
|
2 | if (system.dXCoil().handle() == this->handle()) { |
| 147 |
1/1✓ Branch 1 taken 2 times.
|
2 | return system; |
| 148 | } | ||
| 149 | } | ||
| 150 | 19 | } | |
| 151 | |||
| 152 | // CoilSystemIntegratedHeatPumpAirSource | ||
| 153 | { | ||
| 154 |
2/2✓ Branch 1 taken 17 times.
✓ Branch 4 taken 17 times.
|
17 | auto coilSystems = this->model().getConcreteModelObjects<CoilSystemIntegratedHeatPumpAirSource>(); |
| 155 |
2/2✓ Branch 5 taken 14 times.
✓ Branch 6 taken 3 times.
|
17 | for (const auto& coilSystem : coilSystems) { |
| 156 |
6/6✓ Branch 1 taken 14 times.
✓ Branch 4 taken 14 times.
✓ Branch 7 taken 14 times.
✓ Branch 10 taken 14 times.
✓ Branch 13 taken 5 times.
✓ Branch 14 taken 9 times.
|
14 | if (coilSystem.dedicatedWaterHeatingCoil().handle() == this->handle()) { |
| 157 |
1/1✓ Branch 1 taken 5 times.
|
19 | return coilSystem; |
| 158 | } | ||
| 159 |
6/6✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
✓ Branch 7 taken 9 times.
✓ Branch 10 taken 9 times.
✓ Branch 13 taken 3 times.
✓ Branch 14 taken 6 times.
|
9 | if (coilSystem.scwhCoil().handle() == this->handle()) { |
| 160 |
1/1✓ Branch 1 taken 3 times.
|
3 | return coilSystem; |
| 161 | } | ||
| 162 |
6/6✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
✓ Branch 7 taken 6 times.
✓ Branch 10 taken 6 times.
✓ Branch 13 taken 3 times.
✓ Branch 14 taken 3 times.
|
6 | if (coilSystem.scdwhWaterHeatingCoil().handle() == this->handle()) { |
| 163 |
1/1✓ Branch 1 taken 3 times.
|
3 | return coilSystem; |
| 164 | } | ||
| 165 |
5/6✓ Branch 1 taken 3 times.
✓ Branch 4 taken 3 times.
✓ Branch 7 taken 3 times.
✓ Branch 10 taken 3 times.
✓ Branch 13 taken 3 times.
✗ Branch 14 not taken.
|
3 | if (coilSystem.shdwhWaterHeatingCoil().handle() == this->handle()) { |
| 166 |
1/1✓ Branch 1 taken 3 times.
|
3 | return coilSystem; |
| 167 | } | ||
| 168 | } | ||
| 169 | 17 | } | |
| 170 | |||
| 171 | 3 | return boost::none; | |
| 172 | } | ||
| 173 | |||
| 174 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::autosize() { | |
| 175 | ✗ | autocalculateRatedEvaporatorAirFlowRate(); | |
| 176 | ✗ | autocalculateRatedCondenserWaterFlowRate(); | |
| 177 | ✗ | } | |
| 178 | |||
| 179 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::applySizingValues() { | |
| 180 | ✗ | boost::optional<double> val; | |
| 181 | ✗ | val = autocalculatedRatedEvaporatorAirFlowRate(); | |
| 182 | ✗ | if (val) { | |
| 183 | ✗ | setRatedEvaporatorAirFlowRate(val.get()); | |
| 184 | } | ||
| 185 | |||
| 186 | ✗ | val = autocalculatedRatedCondenserWaterFlowRate(); | |
| 187 | ✗ | if (val) { | |
| 188 | ✗ | setRatedCondenserWaterFlowRate(val.get()); | |
| 189 | } | ||
| 190 | ✗ | } | |
| 191 | |||
| 192 | 7 | boost::optional<Schedule> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::optionalAvailabilitySchedule() const { | |
| 193 |
1/1✓ Branch 1 taken 7 times.
|
14 | return getObject<ModelObject>().getModelObjectTarget<Schedule>( |
| 194 |
1/1✓ Branch 1 taken 7 times.
|
14 | OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::AvailabilityScheduleName); |
| 195 | } | ||
| 196 | |||
| 197 | 7 | Schedule CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::availabilitySchedule() const { | |
| 198 |
1/1✓ Branch 1 taken 7 times.
|
7 | boost::optional<Schedule> value = optionalAvailabilitySchedule(); |
| 199 |
1/2✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
|
7 | if (!value) { |
| 200 | // it is an error if we get here, however we don't want to crash | ||
| 201 | // so we hook up to global always on schedule | ||
| 202 | ✗ | LOG(Error, "Required availability schedule not set, using 'Always On' schedule"); | |
| 203 | ✗ | value = this->model().alwaysOnDiscreteSchedule(); | |
| 204 | ✗ | OS_ASSERT(value); | |
| 205 | ✗ | const_cast<CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl*>(this)->setAvailabilitySchedule(*value); | |
| 206 | ✗ | value = optionalAvailabilitySchedule(); | |
| 207 | } | ||
| 208 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 209 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 210 | 7 | } | |
| 211 | |||
| 212 | 7 | int CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::nominalSpeedLevel() const { | |
| 213 |
1/1✓ Branch 1 taken 7 times.
|
7 | boost::optional<int> value = getInt(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::NominalSpeedLevel, true); |
| 214 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 215 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 216 | } | ||
| 217 | |||
| 218 | 9 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedWaterHeatingCapacity() const { | |
| 219 |
1/1✓ Branch 1 taken 9 times.
|
9 | boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedWaterHeatingCapacity, true); |
| 220 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 9 times.
✗ Branch 4 not taken.
|
9 | OS_ASSERT(value); |
| 221 |
1/1✓ Branch 1 taken 9 times.
|
18 | return value.get(); |
| 222 | } | ||
| 223 | |||
| 224 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedEvaporatorInletAirDryBulbTemperature() const { | |
| 225 | boost::optional<double> value = | ||
| 226 |
1/1✓ Branch 1 taken 7 times.
|
7 | getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorInletAirDryBulbTemperature, true); |
| 227 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 228 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 229 | } | ||
| 230 | |||
| 231 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedEvaporatorInletAirWetBulbTemperature() const { | |
| 232 | boost::optional<double> value = | ||
| 233 |
1/1✓ Branch 1 taken 7 times.
|
7 | getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorInletAirWetBulbTemperature, true); |
| 234 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 235 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 236 | } | ||
| 237 | |||
| 238 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedCondenserInletWaterTemperature() const { | |
| 239 | boost::optional<double> value = | ||
| 240 |
1/1✓ Branch 1 taken 7 times.
|
7 | getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserInletWaterTemperature, true); |
| 241 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 242 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 243 | } | ||
| 244 | |||
| 245 | 4 | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedEvaporatorAirFlowRate() const { | |
| 246 | 4 | return getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorAirFlowRate, true); | |
| 247 | } | ||
| 248 | |||
| 249 | 8 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::isRatedEvaporatorAirFlowRateAutocalculated() const { | |
| 250 | 8 | bool result = false; | |
| 251 |
1/1✓ Branch 1 taken 8 times.
|
8 | boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorAirFlowRate, true); |
| 252 |
1/2✓ Branch 0 taken 8 times.
✗ Branch 1 not taken.
|
8 | if (value) { |
| 253 |
3/3✓ Branch 1 taken 8 times.
✓ Branch 4 taken 8 times.
✓ Branch 7 taken 8 times.
|
16 | result = openstudio::istringEqual(value.get(), "autocalculate"); |
| 254 | } | ||
| 255 | 8 | return result; | |
| 256 | 8 | } | |
| 257 | |||
| 258 | 4 | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::ratedCondenserWaterFlowRate() const { | |
| 259 | 4 | return getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserWaterFlowRate, true); | |
| 260 | } | ||
| 261 | |||
| 262 | 8 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::isRatedCondenserWaterFlowRateAutocalculated() const { | |
| 263 | 8 | bool result = false; | |
| 264 |
1/1✓ Branch 1 taken 8 times.
|
8 | boost::optional<std::string> value = getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserWaterFlowRate, true); |
| 265 |
1/2✓ Branch 0 taken 8 times.
✗ Branch 1 not taken.
|
8 | if (value) { |
| 266 |
3/3✓ Branch 1 taken 8 times.
✓ Branch 4 taken 8 times.
✓ Branch 7 taken 8 times.
|
16 | result = openstudio::istringEqual(value.get(), "autocalculate"); |
| 267 | } | ||
| 268 | 8 | return result; | |
| 269 | 8 | } | |
| 270 | |||
| 271 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::evaporatorFanPowerIncludedinRatedCOP() const { | |
| 272 | boost::optional<std::string> value = | ||
| 273 |
1/1✓ Branch 1 taken 7 times.
|
7 | getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::EvaporatorFanPowerIncludedinRatedCOP, true); |
| 274 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 275 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 276 | 7 | } | |
| 277 | |||
| 278 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::condenserPumpPowerIncludedinRatedCOP() const { | |
| 279 | boost::optional<std::string> value = | ||
| 280 |
1/1✓ Branch 1 taken 7 times.
|
7 | getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CondenserPumpPowerIncludedinRatedCOP, true); |
| 281 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 282 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 283 | 7 | } | |
| 284 | |||
| 285 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP() const { | |
| 286 | boost::optional<std::string> value = | ||
| 287 |
1/1✓ Branch 1 taken 7 times.
|
7 | getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP, true); |
| 288 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 289 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 290 | 7 | } | |
| 291 | |||
| 292 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::fractionofCondenserPumpHeattoWater() const { | |
| 293 | boost::optional<double> value = | ||
| 294 |
1/1✓ Branch 1 taken 7 times.
|
7 | getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::FractionofCondenserPumpHeattoWater, true); |
| 295 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 296 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 297 | } | ||
| 298 | |||
| 299 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::crankcaseHeaterCapacity() const { | |
| 300 |
1/1✓ Branch 1 taken 7 times.
|
7 | boost::optional<double> value = getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CrankcaseHeaterCapacity, true); |
| 301 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 302 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 303 | } | ||
| 304 | |||
| 305 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::maximumAmbientTemperatureforCrankcaseHeaterOperation() const { | |
| 306 | boost::optional<double> value = | ||
| 307 |
1/1✓ Branch 1 taken 7 times.
|
7 | getDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::MaximumAmbientTemperatureforCrankcaseHeaterOperation, true); |
| 308 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 309 |
1/1✓ Branch 1 taken 7 times.
|
14 | return value.get(); |
| 310 | } | ||
| 311 | |||
| 312 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::evaporatorAirTemperatureTypeforCurveObjects() const { | |
| 313 | boost::optional<std::string> value = | ||
| 314 |
1/1✓ Branch 1 taken 7 times.
|
7 | getString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::EvaporatorAirTemperatureTypeforCurveObjects, true); |
| 315 |
1/3✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
✗ Branch 4 not taken.
|
7 | OS_ASSERT(value); |
| 316 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 317 | 7 | } | |
| 318 | |||
| 319 | 17 | boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::optionalPartLoadFractionCorrelationCurve() const { | |
| 320 |
1/1✓ Branch 1 taken 17 times.
|
34 | return getObject<ModelObject>().getModelObjectTarget<Curve>( |
| 321 |
1/1✓ Branch 1 taken 17 times.
|
34 | OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::PartLoadFractionCorrelationCurveName); |
| 322 | } | ||
| 323 | |||
| 324 | 7 | Curve CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::partLoadFractionCorrelationCurve() const { | |
| 325 |
1/1✓ Branch 1 taken 7 times.
|
7 | boost::optional<Curve> value = optionalPartLoadFractionCorrelationCurve(); |
| 326 |
1/2✗ Branch 1 not taken.
✓ Branch 2 taken 7 times.
|
7 | if (!value) { |
| 327 | ✗ | LOG_AND_THROW(briefDescription() << " does not have a Part Load Fraction Correlation Curve attached."); | |
| 328 | } | ||
| 329 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
14 | return value.get(); |
| 330 | 7 | } | |
| 331 | |||
| 332 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setAvailabilitySchedule(Schedule& schedule) { | |
| 333 |
3/3✓ Branch 1 taken 62 times.
✓ Branch 4 taken 62 times.
✓ Branch 7 taken 62 times.
|
248 | bool result = setSchedule(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::AvailabilityScheduleName, |
| 334 | "CoilWaterHeatingAirToWaterHeatPumpVariableSpeed", "Availability Schedule", schedule); | ||
| 335 | 62 | return result; | |
| 336 | } | ||
| 337 | |||
| 338 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setNominalSpeedLevel(int nominalSpeedLevel) { | |
| 339 | 62 | bool result = setInt(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::NominalSpeedLevel, nominalSpeedLevel); | |
| 340 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 62 times.
|
62 | OS_ASSERT(result); |
| 341 | 62 | return result; | |
| 342 | } | ||
| 343 | |||
| 344 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedWaterHeatingCapacity(double ratedWaterHeatingCapacity) { | |
| 345 | 63 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedWaterHeatingCapacity, ratedWaterHeatingCapacity); | |
| 346 | 63 | return result; | |
| 347 | } | ||
| 348 | |||
| 349 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedEvaporatorInletAirDryBulbTemperature( | |
| 350 | double ratedEvaporatorInletAirDryBulbTemperature) { | ||
| 351 | 62 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorInletAirDryBulbTemperature, | |
| 352 | ratedEvaporatorInletAirDryBulbTemperature); | ||
| 353 | 62 | return result; | |
| 354 | } | ||
| 355 | |||
| 356 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedEvaporatorInletAirWetBulbTemperature( | |
| 357 | double ratedEvaporatorInletWetDryBulbTemperature) { | ||
| 358 | 62 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorInletAirWetBulbTemperature, | |
| 359 | ratedEvaporatorInletWetDryBulbTemperature); | ||
| 360 | 62 | return result; | |
| 361 | } | ||
| 362 | |||
| 363 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedCondenserInletWaterTemperature(double ratedCondenserInletWaterTemperature) { | |
| 364 | 62 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserInletWaterTemperature, | |
| 365 | ratedCondenserInletWaterTemperature); | ||
| 366 | 62 | return result; | |
| 367 | } | ||
| 368 | |||
| 369 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedEvaporatorAirFlowRate(boost::optional<double> ratedEvaporatorAirFlowRate) { | |
| 370 | 1 | bool result(false); | |
| 371 |
1/2✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
|
1 | if (ratedEvaporatorAirFlowRate) { |
| 372 | 1 | result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorAirFlowRate, ratedEvaporatorAirFlowRate.get()); | |
| 373 | } | ||
| 374 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
|
1 | OS_ASSERT(result); |
| 375 | 1 | return result; | |
| 376 | } | ||
| 377 | |||
| 378 | 62 | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::autocalculateRatedEvaporatorAirFlowRate() { | |
| 379 |
2/2✓ Branch 1 taken 62 times.
✓ Branch 4 taken 62 times.
|
124 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedEvaporatorAirFlowRate, "autocalculate"); |
| 380 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 62 times.
|
62 | OS_ASSERT(result); |
| 381 | 62 | } | |
| 382 | |||
| 383 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setRatedCondenserWaterFlowRate(boost::optional<double> ratedCondenserWaterFlowRate) { | |
| 384 | 1 | bool result(false); | |
| 385 |
1/2✓ Branch 0 taken 1 time.
✗ Branch 1 not taken.
|
1 | if (ratedCondenserWaterFlowRate) { |
| 386 | result = | ||
| 387 | 1 | setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserWaterFlowRate, ratedCondenserWaterFlowRate.get()); | |
| 388 | } | ||
| 389 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 1 time.
|
1 | OS_ASSERT(result); |
| 390 | 1 | return result; | |
| 391 | } | ||
| 392 | |||
| 393 | 62 | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::autocalculateRatedCondenserWaterFlowRate() { | |
| 394 |
2/2✓ Branch 1 taken 62 times.
✓ Branch 4 taken 62 times.
|
124 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::RatedCondenserWaterFlowRate, "autocalculate"); |
| 395 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 62 times.
|
62 | OS_ASSERT(result); |
| 396 | 62 | } | |
| 397 | |||
| 398 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setEvaporatorFanPowerIncludedinRatedCOP( | |
| 399 | const std::string& evaporatorFanPowerIncludedinRatedCOP) { | ||
| 400 | 62 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::EvaporatorFanPowerIncludedinRatedCOP, | |
| 401 | evaporatorFanPowerIncludedinRatedCOP); | ||
| 402 | 62 | return result; | |
| 403 | } | ||
| 404 | |||
| 405 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setCondenserPumpPowerIncludedinRatedCOP( | |
| 406 | const std::string& condenserPumpPowerIncludedinRatedCOP) { | ||
| 407 | 62 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CondenserPumpPowerIncludedinRatedCOP, | |
| 408 | condenserPumpPowerIncludedinRatedCOP); | ||
| 409 | 62 | return result; | |
| 410 | } | ||
| 411 | |||
| 412 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP( | |
| 413 | const std::string& condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP) { | ||
| 414 | 62 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP, | |
| 415 | condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP); | ||
| 416 | 62 | return result; | |
| 417 | } | ||
| 418 | |||
| 419 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setFractionofCondenserPumpHeattoWater(double fractionofCondenserPumpHeattoWater) { | |
| 420 | 62 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::FractionofCondenserPumpHeattoWater, | |
| 421 | fractionofCondenserPumpHeattoWater); | ||
| 422 | 62 | return result; | |
| 423 | } | ||
| 424 | |||
| 425 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setCrankcaseHeaterCapacity(double crankcaseHeaterCapacity) { | |
| 426 | 63 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CrankcaseHeaterCapacity, crankcaseHeaterCapacity); | |
| 427 | 63 | return result; | |
| 428 | } | ||
| 429 | |||
| 430 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setMaximumAmbientTemperatureforCrankcaseHeaterOperation( | |
| 431 | double maximumAmbientTemperatureforCrankcaseHeaterOperation) { | ||
| 432 | 63 | bool result = setDouble(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::MaximumAmbientTemperatureforCrankcaseHeaterOperation, | |
| 433 | maximumAmbientTemperatureforCrankcaseHeaterOperation); | ||
| 434 | 63 | return result; | |
| 435 | } | ||
| 436 | |||
| 437 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setEvaporatorAirTemperatureTypeforCurveObjects( | |
| 438 | const std::string& evaporatorAirTemperatureTypeforCurveObjects) { | ||
| 439 | 62 | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::EvaporatorAirTemperatureTypeforCurveObjects, | |
| 440 | evaporatorAirTemperatureTypeforCurveObjects); | ||
| 441 | 62 | return result; | |
| 442 | } | ||
| 443 | |||
| 444 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setPartLoadFractionCorrelationCurve(const Curve& partLoadFractionCorrelationCurve) { | |
| 445 |
1/1✓ Branch 1 taken 62 times.
|
62 | bool result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::PartLoadFractionCorrelationCurveName, |
| 446 |
1/1✓ Branch 1 taken 62 times.
|
62 | partLoadFractionCorrelationCurve.handle()); |
| 447 |
1/2✗ Branch 0 not taken.
✓ Branch 1 taken 62 times.
|
62 | OS_ASSERT(result); |
| 448 | 62 | return result; | |
| 449 | } | ||
| 450 | |||
| 451 | 15 | boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::crankcaseHeaterCapacityFunctionofTemperatureCurve() const { | |
| 452 |
1/1✓ Branch 1 taken 15 times.
|
30 | return getObject<ModelObject>().getModelObjectTarget<Curve>( |
| 453 |
1/1✓ Branch 1 taken 15 times.
|
30 | OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName); |
| 454 | } | ||
| 455 | |||
| 456 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setCrankcaseHeaterCapacityFunctionofTemperatureCurve(const Curve& curve) { | |
| 457 |
1/1✓ Branch 1 taken 1 time.
|
1 | const bool result = setPointer( |
| 458 |
1/1✓ Branch 1 taken 1 time.
|
1 | OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName, curve.handle()); |
| 459 | 1 | return result; | |
| 460 | } | ||
| 461 | |||
| 462 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::resetCrankcaseHeaterCapacityFunctionofTemperatureCurve() { | |
| 463 | const bool result = | ||
| 464 | ✗ | setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::CrankcaseHeaterCapacityFunctionofTemperatureCurveName, ""); | |
| 465 | ✗ | OS_ASSERT(result); | |
| 466 | ✗ | } | |
| 467 | |||
| 468 | 79 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::setSpeedDataList(const boost::optional<ModelObjectList>& modelObjectList) { | |
| 469 | 79 | bool result(false); | |
| 470 |
1/2✓ Branch 0 taken 79 times.
✗ Branch 1 not taken.
|
79 | if (modelObjectList) { |
| 471 |
3/3✓ Branch 1 taken 79 times.
✓ Branch 4 taken 79 times.
✓ Branch 7 taken 79 times.
|
79 | result = setPointer(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::SpeedDataList, modelObjectList.get().handle()); |
| 472 | } else { | ||
| 473 | ✗ | resetSpeedDataList(); | |
| 474 | ✗ | result = true; | |
| 475 | } | ||
| 476 | 79 | return result; | |
| 477 | } | ||
| 478 | |||
| 479 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::resetSpeedDataList() { | |
| 480 | ✗ | bool result = setString(OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::SpeedDataList, ""); | |
| 481 | ✗ | OS_ASSERT(result); | |
| 482 | ✗ | } | |
| 483 | |||
| 484 | 44 | boost::optional<ModelObjectList> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::speedDataList() const { | |
| 485 |
1/1✓ Branch 1 taken 44 times.
|
88 | return getObject<ModelObject>().getModelObjectTarget<ModelObjectList>( |
| 486 |
1/1✓ Branch 1 taken 44 times.
|
88 | OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeedFields::SpeedDataList); |
| 487 | } | ||
| 488 | |||
| 489 | 6 | std::vector<CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::speeds() const { | |
| 490 | 6 | std::vector<CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData> result; | |
| 491 |
1/1✓ Branch 1 taken 6 times.
|
6 | auto const modelObjectList = speedDataList(); |
| 492 |
1/2✓ Branch 0 taken 6 times.
✗ Branch 1 not taken.
|
6 | if (modelObjectList) { |
| 493 |
2/2✓ Branch 1 taken 6 times.
✓ Branch 4 taken 6 times.
|
6 | auto const modelObjects = modelObjectList->modelObjects(); |
| 494 | |||
| 495 |
2/2✓ Branch 5 taken 7 times.
✓ Branch 6 taken 6 times.
|
13 | for (const auto& elem : modelObjects) { |
| 496 |
1/1✓ Branch 1 taken 7 times.
|
7 | auto const modelObject = elem.optionalCast<CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData>(); |
| 497 |
1/2✓ Branch 0 taken 7 times.
✗ Branch 1 not taken.
|
7 | if (modelObject) { |
| 498 |
2/2✓ Branch 1 taken 7 times.
✓ Branch 4 taken 7 times.
|
7 | result.push_back(modelObject.get()); |
| 499 | } | ||
| 500 | 7 | } | |
| 501 | 6 | } | |
| 502 | 12 | return result; | |
| 503 | 6 | } | |
| 504 | |||
| 505 | 9 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::addSpeed(const CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData& speed) { | |
| 506 | 9 | bool result = false; | |
| 507 |
1/1✓ Branch 1 taken 9 times.
|
9 | auto modelObjectList = speedDataList(); |
| 508 |
1/2✓ Branch 0 taken 9 times.
✗ Branch 1 not taken.
|
9 | if (modelObjectList) { |
| 509 |
2/2✓ Branch 1 taken 9 times.
✓ Branch 4 taken 9 times.
|
9 | result = modelObjectList->addModelObject(speed); |
| 510 | } | ||
| 511 | 9 | return result; | |
| 512 | 9 | } | |
| 513 | |||
| 514 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::removeSpeed(const CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData& speed) { | |
| 515 | ✗ | auto modelObjectList = speedDataList(); | |
| 516 | ✗ | if (modelObjectList) { | |
| 517 | ✗ | modelObjectList->removeModelObject(speed); | |
| 518 | } | ||
| 519 | ✗ | } | |
| 520 | |||
| 521 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::removeAllSpeeds() { | |
| 522 | ✗ | auto modelObjectList = speedDataList(); | |
| 523 | ✗ | if (modelObjectList) { | |
| 524 | ✗ | auto const modelObjects = modelObjectList->modelObjects(); | |
| 525 | |||
| 526 | ✗ | for (const auto& elem : modelObjects) { | |
| 527 | ✗ | auto const modelObject = elem.optionalCast<CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData>(); | |
| 528 | ✗ | if (modelObject) { | |
| 529 | ✗ | modelObjectList->removeModelObject(elem); | |
| 530 | } | ||
| 531 | ✗ | } | |
| 532 | ✗ | } | |
| 533 | ✗ | } | |
| 534 | |||
| 535 | ✗ | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::autocalculatedRatedEvaporatorAirFlowRate() const { | |
| 536 | // TODO: pending NREL/EnergyPlus#8611 | ||
| 537 | ✗ | return getAutosizedValue("TODO", "W"); | |
| 538 | } | ||
| 539 | |||
| 540 | ✗ | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::autocalculatedRatedCondenserWaterFlowRate() const { | |
| 541 | // TODO: pending NREL/EnergyPlus#8611 | ||
| 542 | ✗ | return getAutosizedValue("TODO", "m3/s"); | |
| 543 | } | ||
| 544 | |||
| 545 | ✗ | ComponentType CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::componentType() const { | |
| 546 | ✗ | return ComponentType::Heating; | |
| 547 | } | ||
| 548 | |||
| 549 | ✗ | std::vector<FuelType> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::coolingFuelTypes() const { | |
| 550 | ✗ | return {}; | |
| 551 | } | ||
| 552 | |||
| 553 | ✗ | std::vector<FuelType> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::heatingFuelTypes() const { | |
| 554 | ✗ | return {FuelType::Electricity}; | |
| 555 | } | ||
| 556 | |||
| 557 | ✗ | std::vector<AppGFuelType> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl::appGHeatingFuelTypes() const { | |
| 558 | ✗ | return {AppGFuelType::HeatPump}; // TODO: openstudio-standards uses Electric | |
| 559 | } | ||
| 560 | |||
| 561 | } // namespace detail | ||
| 562 | |||
| 563 | 61 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed(const Model& model) | |
| 564 | 61 | : HVACComponent(CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::iddObjectType(), model) { | |
| 565 |
1/3✗ Branch 2 not taken.
✓ Branch 3 taken 61 times.
✗ Branch 5 not taken.
|
61 | OS_ASSERT(getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()); |
| 566 | |||
| 567 |
1/1✓ Branch 1 taken 61 times.
|
61 | CurveQuadratic partLoadFraction = CurveQuadratic(model); |
| 568 |
1/1✓ Branch 1 taken 61 times.
|
61 | partLoadFraction.setCoefficient1Constant(0.75); |
| 569 |
1/1✓ Branch 1 taken 61 times.
|
61 | partLoadFraction.setCoefficient2x(0.25); |
| 570 |
1/1✓ Branch 1 taken 61 times.
|
61 | partLoadFraction.setCoefficient3xPOW2(0.0); |
| 571 |
1/1✓ Branch 1 taken 61 times.
|
61 | partLoadFraction.setMinimumValueofx(0.0); |
| 572 |
1/1✓ Branch 1 taken 61 times.
|
61 | partLoadFraction.setMaximumValueofx(1.0); |
| 573 | |||
| 574 |
1/1✓ Branch 1 taken 61 times.
|
61 | auto always_on = model.alwaysOnDiscreteSchedule(); |
| 575 |
1/1✓ Branch 1 taken 61 times.
|
61 | bool ok = setAvailabilitySchedule(always_on); |
| 576 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 577 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setNominalSpeedLevel(1); |
| 578 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 579 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setRatedWaterHeatingCapacity(4000.0); // ASIHPMixedTank.idf |
| 580 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 581 | // Values here are not IDD defaults or the Curve won't evaluate to 1.0 +- 0.1 at rated conditions | ||
| 582 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setRatedEvaporatorInletAirDryBulbTemperature(29.44); // ASIHPMixedTank.idf, not 19.7 idd default |
| 583 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 584 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setRatedEvaporatorInletAirWetBulbTemperature(22.22); // ASIHPMixedTank.idf, not 13.5 idd default |
| 585 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 586 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setRatedCondenserInletWaterTemperature(55.72); // ASIHPMixedTank.idf, not 57.5 idd default |
| 587 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 588 |
1/1✓ Branch 1 taken 61 times.
|
61 | autocalculateRatedEvaporatorAirFlowRate(); |
| 589 |
1/1✓ Branch 1 taken 61 times.
|
61 | autocalculateRatedCondenserWaterFlowRate(); |
| 590 |
2/2✓ Branch 1 taken 61 times.
✓ Branch 4 taken 61 times.
|
61 | ok = setEvaporatorFanPowerIncludedinRatedCOP("Yes"); |
| 591 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 592 |
2/2✓ Branch 1 taken 61 times.
✓ Branch 4 taken 61 times.
|
61 | ok = setCondenserPumpPowerIncludedinRatedCOP("No"); |
| 593 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 594 |
2/2✓ Branch 1 taken 61 times.
✓ Branch 4 taken 61 times.
|
61 | ok = setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP("No"); |
| 595 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 596 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setFractionofCondenserPumpHeattoWater(0.2); |
| 597 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 598 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setCrankcaseHeaterCapacity(0); |
| 599 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 600 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setMaximumAmbientTemperatureforCrankcaseHeaterOperation(10); |
| 601 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 602 |
2/2✓ Branch 1 taken 61 times.
✓ Branch 4 taken 61 times.
|
61 | ok = setEvaporatorAirTemperatureTypeforCurveObjects("WetBulbTemperature"); |
| 603 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 604 |
1/1✓ Branch 1 taken 61 times.
|
61 | ok = setPartLoadFractionCorrelationCurve(partLoadFraction); // ASIHPMixedTank.idf |
| 605 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 606 | |||
| 607 |
1/1✓ Branch 1 taken 61 times.
|
61 | auto speedDataList = ModelObjectList(model); |
| 608 |
4/4✓ Branch 1 taken 61 times.
✓ Branch 4 taken 61 times.
✓ Branch 7 taken 61 times.
✓ Branch 10 taken 61 times.
|
61 | speedDataList.setName(this->name().get() + " Speed Data List"); |
| 609 |
2/2✓ Branch 3 taken 61 times.
✓ Branch 6 taken 61 times.
|
61 | ok = getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setSpeedDataList(speedDataList); |
| 610 |
1/3✗ Branch 0 not taken.
✓ Branch 1 taken 61 times.
✗ Branch 3 not taken.
|
61 | OS_ASSERT(ok); |
| 611 | 61 | } | |
| 612 | |||
| 613 | 7739 | IddObjectType CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::iddObjectType() { | |
| 614 |
1/1✓ Branch 1 taken 7739 times.
|
7739 | return {IddObjectType::OS_Coil_WaterHeating_AirToWaterHeatPump_VariableSpeed}; |
| 615 | } | ||
| 616 | |||
| 617 | 7 | Schedule CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::availabilitySchedule() const { | |
| 618 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->availabilitySchedule(); |
| 619 | } | ||
| 620 | |||
| 621 | 7 | int CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::nominalSpeedLevel() const { | |
| 622 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->nominalSpeedLevel(); |
| 623 | } | ||
| 624 | |||
| 625 | 9 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedWaterHeatingCapacity() const { | |
| 626 |
1/1✓ Branch 3 taken 9 times.
|
9 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedWaterHeatingCapacity(); |
| 627 | } | ||
| 628 | |||
| 629 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedEvaporatorInletAirDryBulbTemperature() const { | |
| 630 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedEvaporatorInletAirDryBulbTemperature(); |
| 631 | } | ||
| 632 | |||
| 633 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedEvaporatorInletAirWetBulbTemperature() const { | |
| 634 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedEvaporatorInletAirWetBulbTemperature(); |
| 635 | } | ||
| 636 | |||
| 637 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedCondenserInletWaterTemperature() const { | |
| 638 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedCondenserInletWaterTemperature(); |
| 639 | } | ||
| 640 | |||
| 641 | 4 | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedEvaporatorAirFlowRate() const { | |
| 642 |
1/1✓ Branch 3 taken 4 times.
|
4 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedEvaporatorAirFlowRate(); |
| 643 | } | ||
| 644 | |||
| 645 | 8 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::isRatedEvaporatorAirFlowRateAutocalculated() const { | |
| 646 |
1/1✓ Branch 3 taken 8 times.
|
8 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->isRatedEvaporatorAirFlowRateAutocalculated(); |
| 647 | } | ||
| 648 | |||
| 649 | 4 | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::ratedCondenserWaterFlowRate() const { | |
| 650 |
1/1✓ Branch 3 taken 4 times.
|
4 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->ratedCondenserWaterFlowRate(); |
| 651 | } | ||
| 652 | |||
| 653 | 8 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::isRatedCondenserWaterFlowRateAutocalculated() const { | |
| 654 |
1/1✓ Branch 3 taken 8 times.
|
8 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->isRatedCondenserWaterFlowRateAutocalculated(); |
| 655 | } | ||
| 656 | |||
| 657 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::evaporatorFanPowerIncludedinRatedCOP() const { | |
| 658 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->evaporatorFanPowerIncludedinRatedCOP(); |
| 659 | } | ||
| 660 | |||
| 661 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::condenserPumpPowerIncludedinRatedCOP() const { | |
| 662 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->condenserPumpPowerIncludedinRatedCOP(); |
| 663 | } | ||
| 664 | |||
| 665 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP() const { | |
| 666 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP(); |
| 667 | } | ||
| 668 | |||
| 669 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::fractionofCondenserPumpHeattoWater() const { | |
| 670 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->fractionofCondenserPumpHeattoWater(); |
| 671 | } | ||
| 672 | |||
| 673 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::crankcaseHeaterCapacity() const { | |
| 674 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->crankcaseHeaterCapacity(); |
| 675 | } | ||
| 676 | |||
| 677 | 7 | double CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::maximumAmbientTemperatureforCrankcaseHeaterOperation() const { | |
| 678 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->maximumAmbientTemperatureforCrankcaseHeaterOperation(); |
| 679 | } | ||
| 680 | |||
| 681 | 7 | std::string CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::evaporatorAirTemperatureTypeforCurveObjects() const { | |
| 682 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->evaporatorAirTemperatureTypeforCurveObjects(); |
| 683 | } | ||
| 684 | |||
| 685 | 7 | Curve CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::partLoadFractionCorrelationCurve() const { | |
| 686 |
1/1✓ Branch 3 taken 7 times.
|
7 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->partLoadFractionCorrelationCurve(); |
| 687 | } | ||
| 688 | |||
| 689 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setAvailabilitySchedule(Schedule& schedule) { | |
| 690 |
1/1✓ Branch 3 taken 62 times.
|
62 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setAvailabilitySchedule(schedule); |
| 691 | } | ||
| 692 | |||
| 693 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setNominalSpeedLevel(int nominalSpeedLevel) { | |
| 694 |
1/1✓ Branch 3 taken 62 times.
|
62 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setNominalSpeedLevel(nominalSpeedLevel); |
| 695 | } | ||
| 696 | |||
| 697 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedWaterHeatingCapacity(double ratedWaterHeatingCapacity) { | |
| 698 |
1/1✓ Branch 3 taken 63 times.
|
63 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedWaterHeatingCapacity(ratedWaterHeatingCapacity); |
| 699 | } | ||
| 700 | |||
| 701 | bool | ||
| 702 | 62 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedEvaporatorInletAirDryBulbTemperature(double ratedEvaporatorInletAirDryBulbTemperature) { | |
| 703 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedEvaporatorInletAirDryBulbTemperature( |
| 704 | 124 | ratedEvaporatorInletAirDryBulbTemperature); | |
| 705 | } | ||
| 706 | |||
| 707 | bool | ||
| 708 | 62 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedEvaporatorInletAirWetBulbTemperature(double ratedEvaporatorInletWetDryBulbTemperature) { | |
| 709 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedEvaporatorInletAirWetBulbTemperature( |
| 710 | 124 | ratedEvaporatorInletWetDryBulbTemperature); | |
| 711 | } | ||
| 712 | |||
| 713 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedCondenserInletWaterTemperature(double ratedCondenserInletWaterTemperature) { | |
| 714 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedCondenserInletWaterTemperature( |
| 715 | 124 | ratedCondenserInletWaterTemperature); | |
| 716 | } | ||
| 717 | |||
| 718 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedEvaporatorAirFlowRate(double ratedEvaporatorAirFlowRate) { | |
| 719 |
2/2✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
|
1 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedEvaporatorAirFlowRate(ratedEvaporatorAirFlowRate); |
| 720 | } | ||
| 721 | |||
| 722 | 62 | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::autocalculateRatedEvaporatorAirFlowRate() { | |
| 723 |
1/1✓ Branch 3 taken 62 times.
|
62 | getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->autocalculateRatedEvaporatorAirFlowRate(); |
| 724 | 62 | } | |
| 725 | |||
| 726 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setRatedCondenserWaterFlowRate(double ratedCondenserWaterFlowRate) { | |
| 727 |
2/2✓ Branch 3 taken 1 time.
✓ Branch 6 taken 1 time.
|
1 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setRatedCondenserWaterFlowRate(ratedCondenserWaterFlowRate); |
| 728 | } | ||
| 729 | |||
| 730 | 62 | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::autocalculateRatedCondenserWaterFlowRate() { | |
| 731 |
1/1✓ Branch 3 taken 62 times.
|
62 | getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->autocalculateRatedCondenserWaterFlowRate(); |
| 732 | 62 | } | |
| 733 | |||
| 734 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setEvaporatorFanPowerIncludedinRatedCOP( | |
| 735 | const std::string& evaporatorFanPowerIncludedinRatedCOP) { | ||
| 736 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setEvaporatorFanPowerIncludedinRatedCOP( |
| 737 | 124 | evaporatorFanPowerIncludedinRatedCOP); | |
| 738 | } | ||
| 739 | |||
| 740 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setCondenserPumpPowerIncludedinRatedCOP( | |
| 741 | const std::string& condenserPumpPowerIncludedinRatedCOP) { | ||
| 742 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setCondenserPumpPowerIncludedinRatedCOP( |
| 743 | 124 | condenserPumpPowerIncludedinRatedCOP); | |
| 744 | } | ||
| 745 | |||
| 746 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP( | |
| 747 | const std::string& condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP) { | ||
| 748 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setCondenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP( |
| 749 | 124 | condenserPumpHeatIncludedinRatedHeatingCapacityandRatedCOP); | |
| 750 | } | ||
| 751 | |||
| 752 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setFractionofCondenserPumpHeattoWater(double fractionofCondenserPumpHeattoWater) { | |
| 753 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setFractionofCondenserPumpHeattoWater( |
| 754 | 124 | fractionofCondenserPumpHeattoWater); | |
| 755 | } | ||
| 756 | |||
| 757 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setCrankcaseHeaterCapacity(double crankcaseHeaterCapacity) { | |
| 758 |
1/1✓ Branch 3 taken 63 times.
|
63 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setCrankcaseHeaterCapacity(crankcaseHeaterCapacity); |
| 759 | } | ||
| 760 | |||
| 761 | 63 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setMaximumAmbientTemperatureforCrankcaseHeaterOperation( | |
| 762 | double maximumAmbientTemperatureforCrankcaseHeaterOperation) { | ||
| 763 |
1/1✓ Branch 3 taken 63 times.
|
126 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setMaximumAmbientTemperatureforCrankcaseHeaterOperation( |
| 764 | 126 | maximumAmbientTemperatureforCrankcaseHeaterOperation); | |
| 765 | } | ||
| 766 | |||
| 767 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setEvaporatorAirTemperatureTypeforCurveObjects( | |
| 768 | const std::string& evaporatorAirTemperatureTypeforCurveObjects) { | ||
| 769 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setEvaporatorAirTemperatureTypeforCurveObjects( |
| 770 | 124 | evaporatorAirTemperatureTypeforCurveObjects); | |
| 771 | } | ||
| 772 | |||
| 773 | 62 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setPartLoadFractionCorrelationCurve(const Curve& partLoadFractionCorrelationCurve) { | |
| 774 |
1/1✓ Branch 3 taken 62 times.
|
124 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setPartLoadFractionCorrelationCurve( |
| 775 | 124 | partLoadFractionCorrelationCurve); | |
| 776 | } | ||
| 777 | |||
| 778 | 5 | boost::optional<Curve> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::crankcaseHeaterCapacityFunctionofTemperatureCurve() const { | |
| 779 |
1/1✓ Branch 3 taken 5 times.
|
5 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->crankcaseHeaterCapacityFunctionofTemperatureCurve(); |
| 780 | } | ||
| 781 | |||
| 782 | 1 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::setCrankcaseHeaterCapacityFunctionofTemperatureCurve(const Curve& curve) { | |
| 783 |
1/1✓ Branch 3 taken 1 time.
|
1 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->setCrankcaseHeaterCapacityFunctionofTemperatureCurve(curve); |
| 784 | } | ||
| 785 | |||
| 786 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::resetCrankcaseHeaterCapacityFunctionofTemperatureCurve() { | |
| 787 | ✗ | getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->resetCrankcaseHeaterCapacityFunctionofTemperatureCurve(); | |
| 788 | ✗ | } | |
| 789 | |||
| 790 | 6 | std::vector<CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::speeds() const { | |
| 791 |
1/1✓ Branch 3 taken 6 times.
|
6 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->speeds(); |
| 792 | } | ||
| 793 | |||
| 794 | 9 | bool CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::addSpeed(const CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData& speed) { | |
| 795 |
1/1✓ Branch 3 taken 9 times.
|
9 | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->addSpeed(speed); |
| 796 | } | ||
| 797 | |||
| 798 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::removeSpeed(const CoilWaterHeatingAirToWaterHeatPumpVariableSpeedSpeedData& speed) { | |
| 799 | ✗ | getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->removeSpeed(speed); | |
| 800 | ✗ | } | |
| 801 | |||
| 802 | ✗ | void CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::removeAllSpeeds() { | |
| 803 | ✗ | getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->removeAllSpeeds(); | |
| 804 | ✗ | } | |
| 805 | |||
| 806 | ✗ | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::autocalculatedRatedEvaporatorAirFlowRate() const { | |
| 807 | ✗ | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->autocalculatedRatedEvaporatorAirFlowRate(); | |
| 808 | } | ||
| 809 | |||
| 810 | ✗ | boost::optional<double> CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::autocalculatedRatedCondenserWaterFlowRate() const { | |
| 811 | ✗ | return getImpl<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl>()->autocalculatedRatedCondenserWaterFlowRate(); | |
| 812 | } | ||
| 813 | |||
| 814 | /// @cond | ||
| 815 | 56 | CoilWaterHeatingAirToWaterHeatPumpVariableSpeed::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed( | |
| 816 | 56 | std::shared_ptr<detail::CoilWaterHeatingAirToWaterHeatPumpVariableSpeed_Impl> impl) | |
| 817 |
1/1✓ Branch 3 taken 56 times.
|
56 | : HVACComponent(std::move(impl)) {} |
| 818 | /// @endcond | ||
| 819 | |||
| 820 | } // namespace model | ||
| 821 | } // namespace openstudio | ||
| 822 |