src/model/ChillerElectricReformulatedEIR_Impl.hpp
| Line | Branch | Exec | Source |
|---|---|---|---|
| 1 | /*********************************************************************************************************************** | ||
| 2 | * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC. | ||
| 3 | * See also https://openstudio.net/license | ||
| 4 | ***********************************************************************************************************************/ | ||
| 5 | |||
| 6 | #ifndef MODEL_CHILLERELECTRICREFORMULATEDEIR_IMPL_HPP | ||
| 7 | #define MODEL_CHILLERELECTRICREFORMULATEDEIR_IMPL_HPP | ||
| 8 | |||
| 9 | #include "WaterToWaterComponent_Impl.hpp" | ||
| 10 | |||
| 11 | namespace openstudio { | ||
| 12 | |||
| 13 | namespace model { | ||
| 14 | |||
| 15 | class Curve; | ||
| 16 | class Schedule; | ||
| 17 | class Node; | ||
| 18 | |||
| 19 | namespace detail { | ||
| 20 | |||
| 21 | class MODEL_API ChillerElectricReformulatedEIR_Impl : public WaterToWaterComponent_Impl | ||
| 22 | { | ||
| 23 | |||
| 24 | public: | ||
| 25 | ChillerElectricReformulatedEIR_Impl(const IdfObject& idfObject, Model_Impl* model, bool keepHandle); | ||
| 26 | |||
| 27 | ChillerElectricReformulatedEIR_Impl(const openstudio::detail::WorkspaceObject_Impl& other, Model_Impl* model, bool keepHandle); | ||
| 28 | |||
| 29 | ChillerElectricReformulatedEIR_Impl(const ChillerElectricReformulatedEIR_Impl& other, Model_Impl* model, bool keepHandle); | ||
| 30 | |||
| 31 | 17 | virtual ~ChillerElectricReformulatedEIR_Impl() override = default; | |
| 32 | |||
| 33 | /** @name Virtual Methods */ | ||
| 34 | //@{ | ||
| 35 | |||
| 36 | virtual ModelObject clone(Model model) const override; | ||
| 37 | |||
| 38 | virtual std::vector<ModelObject> children() const override; | ||
| 39 | |||
| 40 | virtual IddObjectType iddObjectType() const override; | ||
| 41 | |||
| 42 | virtual std::vector<ScheduleTypeKey> getScheduleTypeKeys(const Schedule& schedule) const override; | ||
| 43 | |||
| 44 | virtual const std::vector<std::string>& outputVariableNames() const override; | ||
| 45 | |||
| 46 | // chilledWaterLoop | ||
| 47 | virtual unsigned supplyInletPort() const override; | ||
| 48 | virtual unsigned supplyOutletPort() const override; | ||
| 49 | |||
| 50 | // condenserWaterLoop | ||
| 51 | virtual unsigned demandInletPort() const override; | ||
| 52 | virtual unsigned demandOutletPort() const override; | ||
| 53 | |||
| 54 | // heatRecoveryLoop | ||
| 55 | virtual unsigned tertiaryInletPort() const override; | ||
| 56 | virtual unsigned tertiaryOutletPort() const override; | ||
| 57 | |||
| 58 | /* This function will perform a check if trying to add it to a node that is on the demand side of a plant loop. | ||
| 59 | * If: | ||
| 60 | * - the node is on the demand side of a loop | ||
| 61 | * - the node isn't on the current condenser water loop itself | ||
| 62 | * - the chiller doesn't already have a heat recovery (tertiary) loop, | ||
| 63 | * then it tries to add it to the Tertiary loop. | ||
| 64 | * In all other cases, it will call the base class' method WaterToWaterComponent_Impl::addToNode() | ||
| 65 | */ | ||
| 66 | virtual bool addToNode(Node& node) override; | ||
| 67 | |||
| 68 | /* Restricts addToTertiaryNode to a node that is on the demand side of a plant loop (tertiary = Heat Recovery Loop) */ | ||
| 69 | virtual bool addToTertiaryNode(Node& node) override; | ||
| 70 | |||
| 71 | /** Override to switch the condenser type to 'AirCooled' **/ | ||
| 72 | virtual bool removeFromSecondaryPlantLoop() override; | ||
| 73 | |||
| 74 | virtual void autosize() override; | ||
| 75 | |||
| 76 | virtual void applySizingValues() override; | ||
| 77 | |||
| 78 | virtual ComponentType componentType() const override; | ||
| 79 | virtual std::vector<FuelType> coolingFuelTypes() const override; | ||
| 80 | virtual std::vector<FuelType> heatingFuelTypes() const override; | ||
| 81 | virtual std::vector<AppGFuelType> appGHeatingFuelTypes() const override; | ||
| 82 | |||
| 83 | //@} | ||
| 84 | /** @name Getters */ | ||
| 85 | //@{ | ||
| 86 | |||
| 87 | boost::optional<double> referenceCapacity() const; | ||
| 88 | |||
| 89 | bool isReferenceCapacityAutosized() const; | ||
| 90 | |||
| 91 | double referenceCOP() const; | ||
| 92 | |||
| 93 | double referenceLeavingChilledWaterTemperature() const; | ||
| 94 | |||
| 95 | bool isReferenceLeavingChilledWaterTemperatureDefaulted() const; | ||
| 96 | |||
| 97 | double referenceLeavingCondenserWaterTemperature() const; | ||
| 98 | |||
| 99 | bool isReferenceLeavingCondenserWaterTemperatureDefaulted() const; | ||
| 100 | |||
| 101 | boost::optional<double> referenceChilledWaterFlowRate() const; | ||
| 102 | |||
| 103 | bool isReferenceChilledWaterFlowRateAutosized() const; | ||
| 104 | |||
| 105 | boost::optional<double> referenceCondenserWaterFlowRate() const; | ||
| 106 | |||
| 107 | bool isReferenceCondenserWaterFlowRateAutosized() const; | ||
| 108 | |||
| 109 | Curve coolingCapacityFunctionOfTemperature() const; | ||
| 110 | |||
| 111 | Curve electricInputToCoolingOutputRatioFunctionOfTemperature() const; | ||
| 112 | |||
| 113 | std::string electricInputToCoolingOutputRatioFunctionOfPLRType() const; | ||
| 114 | |||
| 115 | Curve electricInputToCoolingOutputRatioFunctionOfPLR() const; | ||
| 116 | |||
| 117 | double minimumPartLoadRatio() const; | ||
| 118 | |||
| 119 | bool isMinimumPartLoadRatioDefaulted() const; | ||
| 120 | |||
| 121 | double maximumPartLoadRatio() const; | ||
| 122 | |||
| 123 | bool isMaximumPartLoadRatioDefaulted() const; | ||
| 124 | |||
| 125 | double optimumPartLoadRatio() const; | ||
| 126 | |||
| 127 | bool isOptimumPartLoadRatioDefaulted() const; | ||
| 128 | |||
| 129 | double minimumUnloadingRatio() const; | ||
| 130 | |||
| 131 | bool isMinimumUnloadingRatioDefaulted() const; | ||
| 132 | |||
| 133 | double fractionofCompressorElectricConsumptionRejectedbyCondenser() const; | ||
| 134 | |||
| 135 | bool isFractionofCompressorElectricConsumptionRejectedbyCondenserDefaulted() const; | ||
| 136 | |||
| 137 | double leavingChilledWaterLowerTemperatureLimit() const; | ||
| 138 | |||
| 139 | bool isLeavingChilledWaterLowerTemperatureLimitDefaulted() const; | ||
| 140 | |||
| 141 | std::string chillerFlowMode() const; | ||
| 142 | |||
| 143 | bool isChillerFlowModeDefaulted() const; | ||
| 144 | |||
| 145 | boost::optional<double> designHeatRecoveryWaterFlowRate() const; | ||
| 146 | |||
| 147 | bool isDesignHeatRecoveryWaterFlowRateAutosized() const; | ||
| 148 | |||
| 149 | double sizingFactor() const; | ||
| 150 | |||
| 151 | bool isSizingFactorDefaulted() const; | ||
| 152 | |||
| 153 | double condenserHeatRecoveryRelativeCapacityFraction() const; | ||
| 154 | |||
| 155 | boost::optional<Schedule> heatRecoveryInletHighTemperatureLimitSchedule() const; | ||
| 156 | |||
| 157 | boost::optional<Node> heatRecoveryLeavingTemperatureSetpointNode() const; | ||
| 158 | |||
| 159 | std::string endUseSubcategory() const; | ||
| 160 | |||
| 161 | std::string condenserFlowControl() const; | ||
| 162 | |||
| 163 | boost::optional<Curve> condenserLoopFlowRateFractionFunctionofLoopPartLoadRatioCurve() const; | ||
| 164 | |||
| 165 | boost::optional<Schedule> temperatureDifferenceAcrossCondenserSchedule() const; | ||
| 166 | |||
| 167 | double condenserMinimumFlowFraction() const; | ||
| 168 | |||
| 169 | boost::optional<Curve> thermosiphonCapacityFractionCurve() const; | ||
| 170 | |||
| 171 | double thermosiphonMinimumTemperatureDifference() const; | ||
| 172 | |||
| 173 | //@} | ||
| 174 | /** @name Setters */ | ||
| 175 | //@{ | ||
| 176 | |||
| 177 | bool setReferenceCapacity(boost::optional<double> referenceCapacity); | ||
| 178 | |||
| 179 | bool setReferenceCapacity(double referenceCapacity); | ||
| 180 | |||
| 181 | void autosizeReferenceCapacity(); | ||
| 182 | |||
| 183 | bool setReferenceCOP(double referenceCOP); | ||
| 184 | |||
| 185 | bool setReferenceLeavingChilledWaterTemperature(double referenceLeavingChilledWaterTemperature); | ||
| 186 | |||
| 187 | void resetReferenceLeavingChilledWaterTemperature(); | ||
| 188 | |||
| 189 | bool setReferenceLeavingCondenserWaterTemperature(double referenceLeavingCondenserWaterTemperature); | ||
| 190 | |||
| 191 | void resetReferenceLeavingCondenserWaterTemperature(); | ||
| 192 | |||
| 193 | bool setReferenceChilledWaterFlowRate(boost::optional<double> referenceChilledWaterFlowRate); | ||
| 194 | |||
| 195 | bool setReferenceChilledWaterFlowRate(double referenceChilledWaterFlowRate); | ||
| 196 | |||
| 197 | void resetReferenceChilledWaterFlowRate(); | ||
| 198 | |||
| 199 | void autosizeReferenceChilledWaterFlowRate(); | ||
| 200 | |||
| 201 | bool setReferenceCondenserWaterFlowRate(boost::optional<double> referenceCondenserWaterFlowRate); | ||
| 202 | |||
| 203 | bool setReferenceCondenserWaterFlowRate(double referenceCondenserWaterFlowRate); | ||
| 204 | |||
| 205 | void resetReferenceCondenserWaterFlowRate(); | ||
| 206 | |||
| 207 | void autosizeReferenceCondenserWaterFlowRate(); | ||
| 208 | |||
| 209 | bool setCoolingCapacityFunctionOfTemperature(const Curve&); | ||
| 210 | |||
| 211 | bool setElectricInputToCoolingOutputRatioFunctionOfTemperature(const Curve&); | ||
| 212 | |||
| 213 | bool setElectricInputToCoolingOutputRatioFunctionOfPLRType(const std::string& electricInputToCoolingOutputRatioFunctionOfPLRType); | ||
| 214 | |||
| 215 | void resetElectricInputToCoolingOutputRatioFunctionOfPLRType(); | ||
| 216 | |||
| 217 | bool setElectricInputToCoolingOutputRatioFunctionOfPLR(const Curve&); | ||
| 218 | |||
| 219 | bool setMinimumPartLoadRatio(double minimumPartLoadRatio); | ||
| 220 | |||
| 221 | void resetMinimumPartLoadRatio(); | ||
| 222 | |||
| 223 | bool setMaximumPartLoadRatio(double maximumPartLoadRatio); | ||
| 224 | |||
| 225 | void resetMaximumPartLoadRatio(); | ||
| 226 | |||
| 227 | bool setOptimumPartLoadRatio(double optimumPartLoadRatio); | ||
| 228 | |||
| 229 | void resetOptimumPartLoadRatio(); | ||
| 230 | |||
| 231 | bool setMinimumUnloadingRatio(double minimumUnloadingRatio); | ||
| 232 | |||
| 233 | void resetMinimumUnloadingRatio(); | ||
| 234 | |||
| 235 | bool setFractionofCompressorElectricConsumptionRejectedbyCondenser(double fractionofCompressorElectricConsumptionRejectedbyCondenser); | ||
| 236 | |||
| 237 | void resetFractionofCompressorElectricConsumptionRejectedbyCondenser(); | ||
| 238 | |||
| 239 | bool setLeavingChilledWaterLowerTemperatureLimit(double leavingChilledWaterLowerTemperatureLimit); | ||
| 240 | |||
| 241 | void resetLeavingChilledWaterLowerTemperatureLimit(); | ||
| 242 | |||
| 243 | bool setChillerFlowMode(const std::string& chillerFlowMode); | ||
| 244 | |||
| 245 | void resetChillerFlowMode(); | ||
| 246 | |||
| 247 | bool setDesignHeatRecoveryWaterFlowRate(double designHeatRecoveryWaterFlowRate); | ||
| 248 | |||
| 249 | void autosizeDesignHeatRecoveryWaterFlowRate(); | ||
| 250 | |||
| 251 | bool setSizingFactor(double sizingFactor); | ||
| 252 | |||
| 253 | void resetSizingFactor(); | ||
| 254 | |||
| 255 | bool setCondenserHeatRecoveryRelativeCapacityFraction(double condenserHeatRecoveryRelativeCapacityFraction); | ||
| 256 | |||
| 257 | bool setHeatRecoveryInletHighTemperatureLimitSchedule(Schedule& s); | ||
| 258 | void resetHeatRecoveryInletHighTemperatureLimitSchedule(); | ||
| 259 | |||
| 260 | bool setHeatRecoveryLeavingTemperatureSetpointNode(const Node& node); | ||
| 261 | void resetHeatRecoveryLeavingTemperatureSetpointNode(); | ||
| 262 | |||
| 263 | bool setEndUseSubcategory(const std::string& endUseSubcategory); | ||
| 264 | |||
| 265 | bool setCondenserFlowControl(const std::string& condenserFlowControl); | ||
| 266 | |||
| 267 | bool | ||
| 268 | setCondenserLoopFlowRateFractionFunctionofLoopPartLoadRatioCurve(const Curve& condenserLoopFlowRateFractionFunctionofLoopPartLoadRatioCurve); | ||
| 269 | void resetCondenserLoopFlowRateFractionFunctionofLoopPartLoadRatioCurve(); | ||
| 270 | |||
| 271 | bool setTemperatureDifferenceAcrossCondenserSchedule(Schedule& temperatureDifferenceAcrossCondenserSchedule); | ||
| 272 | void resetTemperatureDifferenceAcrossCondenserSchedule(); | ||
| 273 | |||
| 274 | bool setCondenserMinimumFlowFraction(double condenserMinimumFlowFraction); | ||
| 275 | |||
| 276 | bool setThermosiphonCapacityFractionCurve(const Curve& thermosiphonCapacityFractionCurve); | ||
| 277 | void resetThermosiphonCapacityFractionCurve(); | ||
| 278 | |||
| 279 | bool setThermosiphonMinimumTemperatureDifference(double thermosiphonMinimumTemperatureDifference); | ||
| 280 | |||
| 281 | //@} | ||
| 282 | /** @name Other */ | ||
| 283 | //@{ | ||
| 284 | |||
| 285 | boost::optional<double> autosizedReferenceCapacity() const; | ||
| 286 | |||
| 287 | boost::optional<double> autosizedReferenceChilledWaterFlowRate() const; | ||
| 288 | |||
| 289 | boost::optional<double> autosizedReferenceCondenserWaterFlowRate() const; | ||
| 290 | |||
| 291 | boost::optional<double> autosizedDesignHeatRecoveryWaterFlowRate() const; | ||
| 292 | |||
| 293 | /** Convenience Function to return the Chilled Water Loop (chiller on supply) **/ | ||
| 294 | boost::optional<PlantLoop> chilledWaterLoop() const; | ||
| 295 | // Same as supplyInletModelObject, but cast to a Node | ||
| 296 | boost::optional<Node> chilledWaterInletNode() const; | ||
| 297 | boost::optional<Node> chilledWaterOutletNode() const; | ||
| 298 | |||
| 299 | /** Convenience Function to return the Condenser Water Loop (chiller on demand side) **/ | ||
| 300 | boost::optional<PlantLoop> condenserWaterLoop() const; | ||
| 301 | boost::optional<Node> condenserInletNode() const; | ||
| 302 | boost::optional<Node> condenserOutletNode() const; | ||
| 303 | |||
| 304 | /** Convenience Function to return the Heat Recovery Loop (chiller on demand side - tertiary) **/ | ||
| 305 | boost::optional<PlantLoop> heatRecoveryLoop() const; | ||
| 306 | boost::optional<Node> heatRecoveryInletNode() const; | ||
| 307 | boost::optional<Node> heatRecoveryOutletNode() const; | ||
| 308 | |||
| 309 | //@} | ||
| 310 | protected: | ||
| 311 | private: | ||
| 312 | − | REGISTER_LOGGER("openstudio.model.ChillerElectricReformulatedEIR"); | |
| 313 | |||
| 314 | boost::optional<ModelObject> basinHeaterScheduleAsModelObject() const; | ||
| 315 | |||
| 316 | bool setBasinHeaterScheduleAsModelObject(const boost::optional<ModelObject>& modelObject); | ||
| 317 | }; | ||
| 318 | |||
| 319 | } // namespace detail | ||
| 320 | |||
| 321 | } // namespace model | ||
| 322 | |||
| 323 | } // namespace openstudio | ||
| 324 | |||
| 325 | #endif // MODEL_CHILLERELECTRICREFORMULATEDEIR_IMPL_HPP | ||
| 326 |