1 Systems 533 HVAC: Final Project Introduction Project Overview When one hears the acronym HVAC most people would be able to state that HVAC stand for heating, ventilation, and air conditioning, but what a vast majority of the population fails to realize is that there is much more to an HVAC than the average person is aware of. Heating, ventilating, and air conditioning systems are based on the principles of thermodynamics, fluid mechanics, and heat transfer, as well as other discoveries and inventions made by many individuals. The actual invention of the components of an HVAC system have come along in direct relation to the industrial revaluation as well as with other modernizations of technology that improve efficiency and control of HVAC system. An HVAC system is not simply a collection of vents that blow in hot or cold air depending on the season. On the contrary it is there are many more parts to the overall system, such as heating units, cooling units, fans, ducts, and many more. Overall, the basic function of an HVAC system is to provide comfortable indoor atmospheric conditions and maintain indoor air quality within an acceptable cost range. For example, in a small-sized building an experienced engineer will be able to determine the best equipment for that building to meet the occupant’s needs and stay within their experienced cost of operation, while in a large building this task will be much more difficult because several HVAC systems will have to be utilized in order to meet a customer’s requirements and stay within their accepted monthly cost. The basic process for choosing the proper HVAC system is to: 1. Determine the required indoor atmospheric conditions a. Calculate nominal temperature and humidity levels b. Work in the proper amount of ventilation 2. Determination the loads that will be required for heating and cooling a. Heat transmission through building walls b. Heat gains from occupants within rooms. c. Heat gains from lighting and equipment in the building. d. Ventilation and infiltration/ex-filtration 3. Choose an HVAC system type a. Will be a factor of: i. Building size and number of of subdivisions ii. Local energy prices vs. how much a customer can pay iii. Local climate iv. Initial cost versus life cycle cost 2 4. Other considerations to consider are: a. Energy usage b. Indoor air quality Project Statement In this project the HVAC system that maintains the atmospheric conditions and quality in a classroom is modeled. The goal of the model is to demonstrate how the HVAC system works as a whole and how each of its sub-components work individually. Understanding how each of the sub-components of the system work will be essential to demonstrating how the system will function as a whole. The basic components that make up this model are PID controller blocks, blocks to simulate heating units, air dampers, dimensions of the classroom, and air flow into and out of the room. The data provided by the model will show a vast array of information about the atmosphere that is created for the classroom and how this atmospheres can be controlled and set to achieve the optimum classroom atmosphere conditions. In light of this, the model will have to be able to show how the system will react to changes in air temperatures outside of the classroom and inside the classroom in order to maintain a nominal temperature within the classroom. Background of a simple HVAC system Terminology • Heating Coil: Equipment that performs heat transfer when mounted inside an Air Handling unit or ductwork. It is heated or cooled by electrical means or by circulating liquid or steam within it. Air flowing across it is heated or cooled. • Damper: A plate or gate placed in a duct to control air flow by introducing a constriction in the duct • Unit Ventilator: the central piece to a classroom HVAC system and is comprised of a fan, heating coil, and dampers • BTU: British thermal unit, most commonly used as the SI unit for energy In this model the HVAC system will be responsible for maintaining comfortable atmospheric conditions within a single class room. The unit ventilator is responsible for mixing 3 the inside air and outside air in a ratio that will provide the correct ventilation or CFM (cubic feet of air a minute) back into the room. It is also responsible for heating the air over a heating coil to the proper temperature so the supply air returned to the classroom will maintain a stable air temperature within. Once the supply air is blown back into the classroom it will remain there until it moves back into the return air duct and is then re-mixed and distributed again, or it escapes through the outside air vent. The unit ventilator is the main component of the HVAC system used in the classroom. It is normally located on the outside wall of a building in order to receive outside air which will be mixed with the return air of the room in a specific ratio to maintain proper atmospheric conditions within the classroom. This is achievable through the use of dampers which control how much of each type of air will be allowed into the system. Once the air has passed through the dampers and is mixed, it flows through a heating coil which heats the air to a certain temperature. Finally, the air is blown back into the classroom at a preset CFM value by a fan. 4 Figure 1-Unit Ventilator Specifications for the system Assumptions: The following assumptions where made in the construction of this HVAC system for a single classroom. 1) There are 30 people in the room 2) Each person requires 10 CFM / Person a. Therefore the room will have 300 CFM total minutes 3) 72 degrees is the nominal room temperature. 4) Max CFM for the unit ventilator = 1000 CFM 5 Model Terminology Qnet = Total heat added to room (BTUH) Qin = Heat from supply air (BTUH) Qout = Heat loss to outside (BTUH) Vrm = Room volume (ft.3) Trm = Room Temp. (ºF) Vstaying = Volume of air in room not lost to fan or outside air vent (ft. 3) Tsa = supply air temp (ºF) CFMfan = Fan air flow (ft. 3/min) Tma = mixed air temp (ºF) ΔTma = change in mixed air temp (ºF) OA = outside air temperature (ºF) %DM_open = % outside air damper is open HW_CMD = %Hot Water Valve is open GPMmax = Max flow of Hot Water through coil (gallons/min) ΔThw =change in hot water temp through coil (ºF) Thwblr = Hot water temp. from boiler (ºF) Awindow, Awall, Aroof = area of windows, walls, roof to the outside air only(ft. 2) Uwindow, wall, roof = U – Factor (coefficient of heat transmission) of surface (BTUH /ft. 2/ ºF) 6 Figure 2 - Unit Ventilator for Classroom 7 Equations For any system involving thermodynamic equations, it is often useful to start with the known fact that the net amount of heat gained by the system is equal to the difference between the heat entering the system and the heat leaving the system: Qnet = Qin − Qout In the case of our classroom, we are assuming that the only heat added to the room is from the heating system itself. A future higher-fidelity study would include the effects of people, lights, heat-generating equipment such as computers, etc. However, for our purposes, we will say that: Qin = 1.08 * (Vrm ) * ∆T The value of 1.08 has to do with the specific heat and density of air as follows: min 1.08 = ( Spec.HeatofAir )( DensityofAir ) hour BTU .075lb min * = .24 * 3 * 60 lb ft hr F In the case of heat gain, the ΔT that we are concerned with is the difference between the starting room air and the final room air temperatures. The room air temperature is a weighted average of the supply air temperature and the remaining (staying) room air temperature as follows: ∆T = (Trm )(Vstaying ) + (Tsm )(CFM fan ) Vrm _ Trm 8 The supply air temperature is the sum of the mixed air temperature and the change in mixed air temperature as it travels over the heating coil. The mixed air is nothing more than the outside air mixed with returning room air in amounts described by the position of the outside air damper. The mixed air is heated over the hot water heating coil before being pushed into the room as supply air. Tsa = Tma + ∆Tma Tma = OA(% DM open ) + Trm (1 − % DM open ) The change in temperature of the mixed air as it passes over the coil and becomes supply air is a function of the amount of air flowing over the coil, the specific heats and densities of both air and water, the temperature of the water flowing through the coil, the amount of water flowing through the coil, and the temperature of the mixed air. All of the coefficients have been combined and this calculation is presented in simplified form as: ∆Tma = 0.16 * 500( HVcmo * GPM max )(∆Thw ) 1.08 * CFM fan ∆Thw =T hw _ blr−Tma The only heat that is leaving the room does so by “leaking” through the walls, windows, and roof to the outside air. The heat loss is a function of the difference in temperature between the room and the outside air, the areas of each surface, and the associated U-values (coefficients of heat transfer). All area values are represented in square feet. For the purpose of this model, the classroom design was modeled loosely on the classroom used in this course: Room 225 at Penn State Great Valley. There is a relatively small amount of windows and walls facing the outside air, and the U-values for each surface were estimates based on the HVAC Handbook. 9 Qout = ∆TTrm − Roa ( Awindow * U window + Awall * U wall + Aroof *U roof ) Once the Qnet (the total heat added to the room) is determined, the change in room air temperature can be calculated as: ∆Trm = dTrm Qnet = dt 1.08 * 60min s The room temperature as a function of time is equal to the sum of the initial room temperature and change in room temperature, as represented in the differential equation: Trm = Trm ( 0 ) + dTrm dt 10 HVAC Classroom Model Overview Figure 3 - Overview of Classroom HVAC Model 11 PID Controllers In this model PID controllers were used to calibrate and limit the amount of outside air and inside air allowed into the unit ventilator. The PID controllers are able to do this by opening and closing the dampers that control air flow to a certain ratio in order to achieve the desired atmospheric conditions and ventilation within the room. A standard PID controller is the sum of three inputs, a proportional term, an integral term, and a derivative term. The proportional term is equal to: Pout = k p e(t ) where: • Pout: Proportional term of output • Kp: Proportional gain, a tuning parameter • e: Error = SP – PV (setpoint – process value) • t: Time or instantaneous time (the present) t The integral term is equal to: I out = K i ∫ e(τ )dτ where: 0 • Iout: Integral term of output • Ki: Integral gain, a tuning parameter • e: Error = SP − PV • t: Time or instantaneous time (the present) • τ: A dummy integration variable 12 The derivative term is equal to: Dout = K d de (t ) where: dt • Dout: Derivative term of output • Kd: Derivative gain, a tuning parameter • e: Error = SP − PV • t: Time or instantaneous time (the present) Thus the final output of the PID controller u(t) is equal to: t u (t ) = K p e(t ) + K i ∫ e(τ )dτ + k d 0 de (t ) dt Where Kp is the constant used to calibrate the PID controller and e(t) is the standard error 13 Room Configuration Since all HVAC systems are dependent on the size and configuration of the room or building in which they are implemented, it was necessary for this model to pass room parameters in. The parameters used in the model describe the dimensions of the room as well as the heat loss suffered through the windows, walls, and roof of the room. This is known as the total BTU loss and is the sum of products of the areas of the windows, walls, and doors times there U-value or coefficient of heat transmission value. The A and U values for the classroom are listed below. Heat loss through windows: 170*.69*(Rm_T - OA_T) Heat loss through walls: 102*.36*(Rm_T - OA_T) Heat loss through roof: 630*.21*(Rm_T - OA_T) Sum is total heat loss in BTU/hr. divided by 60 is BTU/min. Room volume = 5040 ft3 Room air temperature = [(4040 ft^3)*(RM_T) + (1000 ft^3)*(SA_T)]/(5040 ft3) 14 PID Controls / Parameters Overview The heating valve and outside air damper for the unit ventilator must each have a separate control system to determine the position of each component so that the room temperature rests at a steady-state value at the user-defined set-point. We chose a PID control loop for the heating valve. The heating valve is opened and closed to control the amount of hot water through the heating coil, which determines how much heat is transferred to the supply air. We chose a simpler PI control loop for the outside air damper. The outside air damper is opened and closed to control the amount of outside air that enters the room. The sum of the outside air flow and the return air (room air) flow is equal to the total air flow through the fan which is constant, so the damper is controlling the ratio of room air to outside air, which is known as mixed air. The temperature of the mixed air is function of the temperature of outside air, room air, and the amount of each. Tuning – Heating Valve For the hot water valve, the error that is used as the input to the PID loop is calculated as: Error(t) = Room Set-point – Room Temperature(t) To open the hot water valve, we are interested in only the times when the room is too cold, so we set a minimum for the Error input to 0 degrees. That is, when the room is at set-point or above, opening the hot water valve do to the current error would be a waste of hot water energy, so we limit the input. Similarly, when the room is 3 degrees too cold or more, we use the proportional gain to drive the heating valve fully open, so we set the maximum for the error input to 3 degrees. That is, when the room is 3 or more degrees too cold, we will drive the heating valve fully open. The above section describes the proportional gain of our heating valve controller to be 1/3 = 0.33, since the heating valve will be commanded fully open (to a value of 1) when the error input is at 3 degrees. The integral and derivative outputs must be limited in the PID loop. During heat up, which occurs every morning in the winter months, the integral will have an output value that grows very quickly, since the room will be more than 3 degrees too cold for a significant amount of time. Because of this, even after the room achieves set-point the integral contribution to the control signal would keep the control signal at a value of 1 (maximum output: heating valve fully open) and cause the room to overheat. We mitigate this problem by limiting the integral output to 0.35. This value was chosen because it allows the room to heat up to a steady state within a half degree of set-point while reducing overshoot. The derivative is limited to 0.1 and plays the small role in the control of the system. 15 The value for the integral gain is set to 0.1 and the value for the derivative gain is set to 1. In a system like this room, where a quick response to error in the room is not a major concern (since a change of 1-2 degrees from steady-state is barely noticeable by occupants), the larger part of the problem is the overshoot, which is addressed by limiting the contribution of these controls. Tuning – Outside Air Damper For the outside air damper control, the error that is used as the input to the PID loop is calculated as: Error(t) = Room Set-point – Room Temperature(t) The outside air damper has a unique restriction that it must be open at least 30% while the room is occupied for ventilation (30 Occupants * 10 OA CFM / Occupant / 1000 Fan CFM). We therefore set a minimum value of the control output of the outside air damper PI loop at 0.3*Occupancy, where Occupancy = 1 when the room is occupied and 0 when the room is unoccupied. To open the outside air damper for comfort (and not ventilation), we are interested only in those times when the room is too warm, so we set a maximum for the error input to the PI loop at 0. When the room is 3 degrees too warm or more, we want the outside air damper to be completely open, allowing maximum cooling to the room. When the room is 3 degrees too warm, the error signal is at a value of -3, which means that the proportional gain of our controller must be -1/3 = -0.33. Similarly to the integral component of the heating valve PID loop, the output of the integral component of the outside air damper PI loop must be limited. During cool down, which occurs every morning during the summer months, the integral will have an output value that grows very quickly, since the room will be more than 3 degrees too warm for a significant amount of time. Because of this, even after the room achieves set-point the integral contribution to the control signal would keep the control signal at a value of 1 (maximum output: outside air damper fully open) and cause the room to overcool. We mitigate this problem by limiting the integral output to 0.2. This value was chosen because it allows the room to cool down to a steady state within a half degree of set-point while reducing overshoot. Like the proportional gain, the integral gain for the outside air damper PI loop must be negative since we desire a positive output for a negative error signal. The value for the integral gain is set to -0.1. In a system like this room, where a quick response to error in the room is not a major concern (since a change of 1-2 degrees from steady-state is barely noticeable by occupants), the larger part of the problem is the overshoot, which is addressed by limiting the contribution of the integral control. 16 PID Controller Graphs Room Temperature - Warmup 100 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 95 90 85 80 75 70 65 60 0 100 200 300 400 500 600 700 800 900 1000 Hot Water Valve PID output - Warmup 1 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 0.9 0.8 0.7 0.6 0.5 0.4 0 100 200 300 400 500 600 700 800 900 1000 17 Room Temperature - Setpoint Change 78 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 77 76 75 74 73 72 71 70 69 0 100 200 300 400 500 600 700 800 900 1000 Hot Water Valve PID output - Setpoint Change 1 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 0.95 0.9 0.85 0.8 0.75 0.7 0.65 0 100 200 300 400 500 600 700 800 900 1000 18 Room Temperature - Cooldown 85 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 80 75 70 65 60 0 100 200 300 400 500 600 700 800 900 1000 OA Damper Control PID output - Cooldown 1 Desired Integrator Limit No Integrator Limit Too Much Integrator Limit 0.9 0.8 0.7 0.6 0.5 0.4 0.3 0.2 0.1 0 100 200 300 400 500 600 700 800 900 1000 19 Simulation (Case Studies) Notes: The following case-studies investigate some of the differences between the system at different times of the year, namely winter and spring. The outside air temperatures are based on outside temperature data from Malvern, PA on January 1, 2009 (winter) and 4/10/2009 (spring). The hot water is assumed to be kept at a constant temperature equal to 180 degrees minus the outside air temperature. This is a simple and common setpoint for heating hot water (HHW) among school buildings. Future applications of these studies could investigate the boiler run time to maintain these temperatures, but the following case-studies are interested in only the effects on the room temperature. The standard classroom setpoint is assumed to be 72 degrees, and one second of simulation time represents one minute of real-time. Case Study 1: In this case-study, the system user is interested in the warmup time of the room in the winter months versus the spring months. A starting room temperature is assumed to be 60 degrees, as the school would likely have an automation scheme that would not allow the temperature to drop below 60 degrees even when the classroom is unoccupied (this will be investigated further in case-study 3). To determine how long it takes the room to heat up to the setpoint of 72 degrees in winter vs. spring, the system was simulated with the hot water valve fully open and fan on at time 0. What is shown below is that the rise time to the room setpoint of 72 degrees takes approximately 4 hours regardless of the season, due to the difference in hot water supply temperature of the boiler. This is ideal since the classroom could be programmed during all seasons to start 4 hours prior to occupancy time, and the boiler would be run to maintain a constant hot water temperature based on the outside air temperature. Room & HHW Temperatures, Winter vs. Spring 180 Winter Room Temperature Spring Room Temperature Winter HHW Temperature Spring HHW Temperature 160 140 120 100 80 60 0 100 200 300 400 500 600 700 800 900 1000 20 Case Study 2: Similarly to the first case-study, the interest of this case study is to determine the amount of time it would take the room to cool down in the case of overheating to 85 degrees (room temperature at time 0) in both winter and spring. Although overheating is unlikely in the winter, it is possible as a valve could be manually or accidentally stuck open, someone could leave a space heater on overnight, etc. Maintaining all of the assumptions from case-study 1 except for the starting room temperature, the hot water valve is commanded fully closed and the damper is allowed to modulate based on its PI output. Note that, as expected, the room cools much faster in the winter months than in the spring due to the tremendous difference in room air temperature and outside air temperature. Also note that if the heating valve is forced closed in the winter months (or heat is unavailable because of boiler maintenance, etc.), it is impossible to maintain comfortable room temperatures, even with the outside air damper fully closed. In the spring, the room temperature can be kept at a more comfortable level even without heat. Room & Supply Temperatures, Winter vs. Spring 90 Winter Room Temperature Spring Room Temperature Winter Supply Temperature Spring Supply Temperature 80 70 60 50 40 30 20 10 0 100 200 300 400 500 600 700 800 900 1000 21 Case Study 3: This case-study is concerned with the room temperature of the classroom over a 24-hour period, again comparing the classroom in the winter to the classroom in the spring. Simulation time 0 is set to 4:00 AM, four hours before occupancy at 8:00 AM. The initial temperature of the room is set again to 60 degrees, and the four hours is the time assumed to heat the room to a comfortable level by the beginning of occupancy (based on case study 1). When the occupants enter the room, the outside air dampers will be forced open 30% to meet the minimum ventilation requirements, and the hot water valve PID loop and outside air damper PI loop controls will attempt to maintain room temperature. At 3:00 PM, the fans will shut off as the occupants leave, and the outside air dampers and heating valves will close. Note that at the beginning of occupancy (8:00AM = simulation time 240s), the room temperatures are just about to setpoint in both cases. The mandatory opening of the outside air damper in the winter has a larger affect on the room temperature in the winter months, and the PID loop of the heating valve struggles to maintain setpoint. The room remains within 2 degrees of its setpoint at all times. In the spring case, since the outside air is much closer to the room air temperature, the mandatory opening of the damper has a more minimal impact on the room temperature, and the room temperature is able to recover and meet setpoint with the PID controller. This suggests that it would be desirable to have PID gains based on outside air temperature, so that the gains could be set higher when it is cooler outside, and lower when it is warm. After occupancy ends at 3:00PM (simulation time 660s), the classroom temperature begins to fall as the heating system is turned off. As expected, the room temperature falls much faster in the cold winter air then at the mild spring temperatures. Since most schools have some type of unoccupied (setback) temperature that is maintained at all times regardless of occupancy, the graph below (which ends at Day 2, 4:00AM – simulation time 1440s) suggests that the heat would need to be run several times overnight during the winter months and not at all during the spring months. This results in large energy savings in the spring versus the winter. Not only does the hot water need to be maintained at a higher temperature in the winter (which means more energy), but it also needs to run overnight when no one is even in the building. 22 75 Winter Room Temperature Spring Room Temperature 70 65 60 55 50 45 0 500 1000 1500 Conclusion In this project the HVAC system that maintains the atmospheric conditions and quality in a classroom was modeled. The goal of the model is to demonstrate how the HVAC system works as a whole and how each of its sub-components work individually. In order to simulate this system it was necessary to understand the heating differential equations that are in the background of them system. Once this was accomplished the model could be built in MATLAB and simulations could be run. We are confident that out model represents the classroom it was designed with a high level of fidelity and it can be used for future applications in the HVAC field of study. 23 Sources Cooling and Heating Equations - Latent and sensible cooling and heating equations - in imperial units. 2005. The Engineering Toolbox. Apr. 2009 <http://www.engineeringtoolbox.com/cooling-heating-equations-d_747.html>. Heating and Cooling Equations. 2005. The Engineering Toolbox. Apr. 2009 <http://www.engineeringtoolbox.com/cooling-heating-equations-d_747.html>. Hydronic Unit Ventilator. Aug. 1998. Dunham-Bush. Apr. 2009 <http://www.dunhambush.com/US/pdfs/3090.pdf>. HVAC. Apr. 2009. Wikipedia. Apr. 2009 <http://en.wikipedia.org/wiki/HVAC>. PID Controller. Apr. 2009. Wikipedia. Apr. 2009 <http://en.wikipedia.org/wiki/PID_controller>. Overall Heat Transfer Coefficients for some common Fluids and Heat Exchanger Surfaces. Apr. 2005. The Engineering Toolbox. Apr. 2009 <http://www.engineeringtoolbox.com/overallheat-transfer-coefficientsd_284.html>. The HVAC Handbook. 2005. Powells Books. Apr. 2009 <http://www.powells.com/biblio?isbn=9780071402026>. Weather: Malvern Pa. Apr. 2009. Weather Underground. Apr. 2009 <http://www.wunderground.com/cgibin/findweather/hdfForecast?query=malvern%2C +pa&searchType=WEATHER>.