Line data Source code
1 : // EnergyPlus, Copyright (c) 1996-2023, The Board of Trustees of the University of Illinois,
2 : // The Regents of the University of California, through Lawrence Berkeley National Laboratory
3 : // (subject to receipt of any required approvals from the U.S. Dept. of Energy), Oak Ridge
4 : // National Laboratory, managed by UT-Battelle, Alliance for Sustainable Energy, LLC, and other
5 : // contributors. All rights reserved.
6 : //
7 : // NOTICE: This Software was developed under funding from the U.S. Department of Energy and the
8 : // U.S. Government consequently retains certain rights. As such, the U.S. Government has been
9 : // granted for itself and others acting on its behalf a paid-up, nonexclusive, irrevocable,
10 : // worldwide license in the Software to reproduce, distribute copies to the public, prepare
11 : // derivative works, and perform publicly and display publicly, and to permit others to do so.
12 : //
13 : // Redistribution and use in source and binary forms, with or without modification, are permitted
14 : // provided that the following conditions are met:
15 : //
16 : // (1) Redistributions of source code must retain the above copyright notice, this list of
17 : // conditions and the following disclaimer.
18 : //
19 : // (2) Redistributions in binary form must reproduce the above copyright notice, this list of
20 : // conditions and the following disclaimer in the documentation and/or other materials
21 : // provided with the distribution.
22 : //
23 : // (3) Neither the name of the University of California, Lawrence Berkeley National Laboratory,
24 : // the University of Illinois, U.S. Dept. of Energy nor the names of its contributors may be
25 : // used to endorse or promote products derived from this software without specific prior
26 : // written permission.
27 : //
28 : // (4) Use of EnergyPlus(TM) Name. If Licensee (i) distributes the software in stand-alone form
29 : // without changes from the version obtained under this License, or (ii) Licensee makes a
30 : // reference solely to the software portion of its product, Licensee must refer to the
31 : // software as "EnergyPlus version X" software, where "X" is the version number Licensee
32 : // obtained under this License and may not use a different name for the software. Except as
33 : // specifically required in this Section (4), Licensee shall not use in a company name, a
34 : // product name, in advertising, publicity, or other promotional activities any name, trade
35 : // name, trademark, logo, or other designation of "EnergyPlus", "E+", "e+" or confusingly
36 : // similar designation, without the U.S. Department of Energy's prior written consent.
37 : //
38 : // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR
39 : // IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY
40 : // AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR
41 : // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
42 : // CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
43 : // SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
44 : // THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
45 : // OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
46 : // POSSIBILITY OF SUCH DAMAGE.
47 :
48 : #ifndef ENERGYPLUS_COILS_COILCOOLINGDXCURVEFITPERFORMANCE
49 : #define ENERGYPLUS_COILS_COILCOOLINGDXCURVEFITPERFORMANCE
50 :
51 : #include <string>
52 : #include <vector>
53 :
54 : #include <EnergyPlus/Coils/CoilCoolingDXCurveFitOperatingMode.hh>
55 : #include <EnergyPlus/DataGlobalConstants.hh>
56 : #include <EnergyPlus/DataLoopNode.hh>
57 : #include <EnergyPlus/EnergyPlus.hh>
58 :
59 : namespace EnergyPlus {
60 :
61 : // Forward declarations
62 : struct EnergyPlusData;
63 :
64 622 : struct CoilCoolingDXCurveFitPerformanceInputSpecification
65 : {
66 : std::string name;
67 : Real64 crankcase_heater_capacity;
68 : Real64 minimum_outdoor_dry_bulb_temperature_for_compressor_operation;
69 : Real64 maximum_outdoor_dry_bulb_temperature_for_crankcase_heater_operation;
70 : Real64 unit_internal_static_air_pressure;
71 : Real64 basin_heater_capacity;
72 : Real64 basin_heater_setpoint_temperature;
73 : std::string basin_heater_operating_schedule_name;
74 : std::string compressor_fuel_type;
75 : std::string base_operating_mode_name;
76 : std::string alternate_operating_mode_name;
77 : std::string alternate_operating_mode2_name;
78 : std::string capacity_control;
79 : };
80 :
81 367 : struct CoilCoolingDXCurveFitPerformance
82 : {
83 : std::string object_name = "Coil:Cooling:DX:CurveFit:Performance";
84 : std::string parentName;
85 : void instantiateFromInputSpec(EnergyPlusData &state, const CoilCoolingDXCurveFitPerformanceInputSpecification &input_data);
86 : void simulate(EnergyPlusData &state,
87 : const DataLoopNode::NodeData &inletNode,
88 : DataLoopNode::NodeData &outletNode,
89 : int useAlternateMode,
90 : Real64 &PLR,
91 : int &speedNum,
92 : Real64 &speedRatio,
93 : int const fanOpMode,
94 : DataLoopNode::NodeData &condInletNode,
95 : DataLoopNode::NodeData &condOutletNode,
96 : bool const singleMode,
97 : Real64 LoadSHR = 0.0);
98 :
99 : void calculate(EnergyPlusData &state,
100 : CoilCoolingDXCurveFitOperatingMode ¤tMode,
101 : const DataLoopNode::NodeData &inletNode,
102 : DataLoopNode::NodeData &outletNode,
103 : Real64 &PLR,
104 : int &speedNum,
105 : Real64 &speedRatio,
106 : int const fanOpMode,
107 : DataLoopNode::NodeData &condInletNode,
108 : DataLoopNode::NodeData &condOutletNode,
109 : bool const singleMode);
110 : void calcStandardRatings210240(EnergyPlusData &state);
111 : CoilCoolingDXCurveFitPerformanceInputSpecification original_input_specs;
112 51 : CoilCoolingDXCurveFitPerformance() = default;
113 : explicit CoilCoolingDXCurveFitPerformance(EnergyPlusData &state, const std::string &name);
114 : void size(EnergyPlusData &state);
115 : void setOperMode(EnergyPlusData &state, CoilCoolingDXCurveFitOperatingMode ¤tMode, int const mode);
116 :
117 : std::string name;
118 : Real64 crankcaseHeaterCap = 0.0;
119 : Real64 crankcaseHeaterPower = 0.0;
120 : Real64 crankcaseHeaterElectricityConsumption = 0.0;
121 : Real64 minOutdoorDrybulb = 0.0;
122 : Real64 maxOutdoorDrybulbForBasin = 0.0;
123 : bool mySizeFlag = true;
124 : DataGlobalConstants::ResourceType compressorFuelType = DataGlobalConstants::ResourceType::None;
125 : std::string compressorFuelTypeForOutput;
126 : Real64 compressorFuelRate = 0.0;
127 : Real64 compressorFuelConsumption = 0.0;
128 :
129 : enum CapControlMethod
130 : {
131 : CONTINUOUS,
132 : DISCRETE
133 : };
134 : CapControlMethod capControlMethod = CapControlMethod::DISCRETE;
135 :
136 : Real64 evapCondBasinHeatCap = 0.0;
137 : Real64 evapCondBasinHeatSetpoint = 0.0;
138 : int evapCondBasinHeatSchedulIndex = 0;
139 : Real64 basinHeaterElectricityConsumption = 0.0;
140 : Real64 basinHeaterPower = 0.0;
141 : Real64 powerUse = 0.0;
142 : Real64 electricityConsumption = 0.0;
143 : Real64 RTF = 0.0;
144 : bool oneTimeEIOHeaderWrite = true;
145 : Real64 wasteHeatRate = 0.0;
146 : int OperatingMode = 0;
147 : Real64 ModeRatio = 0.0;
148 : Real64 recoveredEnergyRate = 0.0;
149 : Real64 NormalSHR = 0.0;
150 :
151 : // standard rating stuff -- for now just 210/240
152 : Real64 standardRatingCoolingCapacity = 0.0; // net cooling capacity of single speed DX cooling coil
153 : Real64 standardRatingSEER = 0.0; // seasonal energy efficiency ratio of single speed DX cooling coil
154 : Real64 standardRatingEER = 0.0; // energy efficiency ratio of single speed DX cooling coil
155 : Real64 standardRatingIEER = 0.0; // Integrated energy efficiency ratio of single speed DX cooling coil
156 :
157 : // standard rating stuff -- for now just 210/240 2023
158 : Real64 standardRatingCoolingCapacity2023 = 0.0; // net cooling capacity of single speed DX cooling coil
159 : Real64 standardRatingSEER2_User = 0.0; // seasonal energy efficiency ratio of single speed DX cooling coil
160 : Real64 standardRatingSEER2_Standard = 0.0;
161 : Real64 standardRatingEER2 = 0.0; // energy efficiency ratio of single speed DX cooling coil
162 :
163 : CoilCoolingDXCurveFitOperatingMode normalMode;
164 : int hasAlternateMode = 0; // 0 Normal, 1 Enhanced, 2 SubcoolReheat
165 : CoilCoolingDXCurveFitOperatingMode alternateMode; // enhanced dehumidifcation or Subcool mode
166 : CoilCoolingDXCurveFitOperatingMode alternateMode2; // Reheat mode
167 : };
168 :
169 : } // namespace EnergyPlus
170 :
171 : #endif // ENERGYPLUS_COILS_COILCOOLINGDXCURVEFITPERFORMANCE
|