Modeling and Advanced Control of HVAC Systems

Modeling and Advanced Control of HVAC Systems Topic: HVAC Modeling & Control Truong Nghiem ESE, University of Pennsylvania [email protected] Jan...
Author: Nathan Carr
2 downloads 0 Views 2MB Size
Modeling and Advanced Control of HVAC Systems Topic: HVAC Modeling & Control

Truong Nghiem ESE, University of Pennsylvania [email protected]

January 26, 2011

Outline

T. Nghiem

I

Part I: Modeling of HVAC Systems

I

Part II: Advanced Control of HVAC Systems

HVAC Modeling & Control

2

Part I Modeling of HVAC Systems

Fundamentals Zone Model

T. Nghiem

HVAC Modeling & Control

3

HVAC Modeling: Overview

set-point

supply air

heat gain

VAV

Zone

reheat Thermostat damper zone temperature Sensor

T. Nghiem

I

Mathematical model of the plant (Zone block).

I

HVAC system: exact models are complex (nonlinear, PDE, stochastic, etc.).

I

Focus: simplified (linearized) first-principles models derived from heat transfer and thermodynamics theories.

I

Other types of models: regression models, neural networks, look-up tables, etc.

HVAC Modeling & Control

4

HVAC Modeling: Fundamental Equation First Law of Thermodynamics (Conservation of Energy) Heat balance equation: H − W = ∆E Heat H Energy input to the system. Work W Energy extracted from the system. Internal heat E Energy stored in the system (can only measure/calculate its change).

T. Nghiem

Heat input

Zone

Heat extracted

(Supply air, radiation, internal heat gain, etc.)

(Zone air)

(Conduction, infiltration, etc.)

HVAC Modeling & Control

5

Heat Transfer: Concepts I

I I

Heat flux: heat flow rate through a surface. Heat flux density is heat flux per unit area (W/m2 ).

I

Heat capacity C : heat needed to raise temperature of a body mass by 1◦ C (J/K). Also called thermal mass, thermal capacitance.

I

Specific heat (capacity) Cp : heat needed to raise temperature of 1 kg of material by 1◦ C (J/kg K); C = mCp = ρVCp .

I

Energy change by temperature change ∆E = ρVCp ∆T . Mass flow rate m ˙ (kg/s) and volume flow rate V˙ (m2 /s); m ˙ = ρV˙ .

I

T. Nghiem

Heat Q: energy transferred across system boundary by temperature difference (J). ˙ heat transfer rate (W). Heat flow (rate) Q:

HVAC Modeling & Control

6

Heat Transfer: Mass Transfer Heating Supply air temperature Ts , return air temperature Tr < Ts , volume flow rate V˙ . Heat transfer to the zone is: Q˙ = H˙ = ρV˙ Cp (Ts − Tr )

( W)

Cooling Similarly, with Ts < Tr , heat extracted from the zone is: ˙ = ρV˙ Cp (Tr − Ts ) Q˙ = W

T. Nghiem

HVAC Modeling & Control

( W)

7

Heat Transfer: Conduction Conduction is the process of heat transfer through a substance such as a wall, from higher to lower temperature. Fourier’s equation (3-dimensional PDE with time):  2  dT ∂ T ∂2T ∂2T ρCp =k + + dt ∂x 2 ∂y 2 ∂z 2 where k: thermal conductivity ( W/mK). Simplified equation (timeless, one-dimensional): ∆T Th − Tl Q˙ = kA = kA ∆x l where A: cross-sectional area ( m2 ), Th : high temperature, Tl : low temperature, l: thickness/length of material.

T. Nghiem

HVAC Modeling & Control

8

Heat Transfer: Conduction Define Rth =

1 kA

(thermal resistance) then ˙ th = Th − Tl QR

Equivalent to an electric circuit: T = potential, ∆T = voltage, Q˙ = current, Rth = resistance. Th

T. Nghiem



Rth

HVAC Modeling & Control

Tl

9

Heat Transfer: Convection Convection is the heat transfer between a surface and fluid/gas by the movement of the fluid/gas. I

Natural convection: heat transfer from a radiator to room air.

I

Forced convection: from a heat exchanger to fluid being pumped through.

Newton’s law of cooling: Q˙ = hA∆T where h: heat transfer coefficient ( W/ m2 K2 ); A: surface area ( m2 ), ∆T : temperature difference between surface and fluid. Define Rcv =

1 hA

˙ cv = ∆T . and write QR Q˙

Rcv

Tsurf

T. Nghiem

Tfluid

HVAC Modeling & Control

10

Heat Transfer: Radiation Radiation is the heat transfer through space by electromagnetic waves. Example: radiation between a radiator and a wall that faces it. Fourth-order equation given by the Stefan-Boltzman law (cf. heat transfer textbooks). Approximate linearized equation: Q˙ = hr A(T1 − T2 ) where : emissivity of the surface (0.9 for most building materials); hr : radiation heat transfer coefficient ( W/ m2 K2 ). Define Rr =

1 hr A

˙ r = ∆T . and write QR T1

T. Nghiem



Rr

HVAC Modeling & Control

T2

11

Heat Transfer: Solar Radiation Solar radiation is the radiation heat transfer by sun light.

T. Nghiem

I

Direct radiation to the walls, furnitures, etc. in the room.

I

Then heat transfer from walls, furnitures, etc. to room air.

I

No direct heat transfer to room air but indirectly through walls, furnitures, etc. ⇒ large time lag.

HVAC Modeling & Control

12

Part I Modeling of HVAC Systems

Fundamentals Zone Model

T. Nghiem

HVAC Modeling & Control

13

Zone Temperature Model T1

T33 T29

Door 2

Room 1

Rwindow,1

Room 2

Window 2

Door 1

Window 1 T13

T21 T

T17 T6 T9 T19

Room 3

Room 4

T15

Window 4

Door 4

Door 3

T23 T

T35 T31

Outside

T3

Source: [Deng et al., 2010]

(a) I

Ignore latent load (humidity), (temperature). Fig. 1. (a)only Layoutsensible of a 4-roomload building and (b) the RC-network representation o

I

No infiltration.

I

on the thermal models. Simplified model with simplified heat transfer equations.

I

T. Nghiem

HVAC

The outline of this paper is as follows. In Section II, system of model VAV type. the thermal is formally defined and its Markov chain representation is presented. In Section III, the KL divergence rate and the model reduction method from [9] is briefly reviewed. In Section IV, the methodology is applied to reduce the thermal models. In Section V, two examples are HVAC Modeling & Control

Remark 1 (Conservati matrix are all zeros, its its non-diagonal entrie $ V (t) = i∈N Ci Ti (t) thermal model (1) at tim

dV (t) = dt 14

Body Mass Temperature At what point is room air temperature (or wall surface temperature) measured?

T. Nghiem

I

Exact temperature distribution in a body mass is complex (PDE).

I

Simplification: mean temperature of all points.

I

How to measure mean temperature? Sensor placement.

I

Mean temperature 6= temperature that occupants feel.

HVAC Modeling & Control

15

RC Network of a Wall Model heat transfer processes using resistance-capacitance equivalent models (RC network). Zone – wall surface model Rr Ts

T

reduces to

T

R

Ts

Rcv

where T : zone air temperature, Ts : wall surface temperature, Rr : radiation resistance, Rcv : convection resistance, and R1 = R1r + R1cv .

T. Nghiem

HVAC Modeling & Control

16

RC Network of a Wall Model heat transfer processes using resistance-capacitance equivalent models (RC network).

R1

T1

C1

Zone 1

Ts1

Rc1

Rc2

Tw 1

Tw 2

Cw 1

Twn

Cw 2

Wall

Rc(n+1)

Ts2

R2

T2

Cwn

C2

Zone 2

More accurate model of conduction with large n. Usually use n = 2 or simplify to a single thermal resistance between Ts1 and Ts2 (n = 0).

T. Nghiem

HVAC Modeling & Control

17

RC Network for Four Rooms RC network of conduction, convection and radiation between rooms and outside air. T33 T29

T1

T2

T30 T34

T5 T7

Rwindow,1

T13

T21 T25

T26 T22

Rwindow,2

Window 2

T14

T17

T18

T37

T6

T8

T37

T12

T9 T20

T19

T16

Window 4

T15 T23 T27

Rwindow,4

T28 T24 T10 T11

T35 T31

T3

T4

T32 T36

T37

Source: [Deng et al., 2010]

(b)

m building and (b) the RC-network representation of the same building. T. Nghiem

HVAC Modeling & Control

18

Heating/Cooling and Other Gains Add heating/cooling, internal gain and solar radiation to the network. Q˙ sa1 R1

T1

Ts1

Rc1

Rc2

Tw 1

Rc3

Tw 2

Q˙ i1 C1

Q˙ r 1

Zone

Cw 1

Cw 2

Ts2 = Toa Outside Air

Wall

Q˙ sa1 : HVAC heat flow; Q˙ i1 : internal heat gain; Q˙ r 1 : radiation heat gain

Q˙ sa1 = ρV˙ sa1 Cp (Tsa − T1 ) Q˙ i1 , Q˙ r 1 : disturbance/prediction

T. Nghiem

1 1 ˙ ˙ C1 dT dt = Qsa + Qi − R1 (T1 − Ts1 ) 0 = Q˙ r + R11 (T1 − Ts1 )− R1c1 (Ts1 − Tw 1 )

HVAC Modeling & Control

19

State-space Thermal Model of Zone Define variables: I

State variables x: all temperature variables.

I

Disturbance variables w : internal gain, solar radiation, outside air temperature, etc. Input variables u: defined by application.

I

I I

T. Nghiem

Supply air flow rate u1 = V˙ sa1 : Q˙ sa1 = ρu1 Cp (Tsa − x1 ) Blind control u1b ∈ [0, 1]: Q˙ r 1 = u1b w1

I

Output variables y : e.g., y are all zone air temperatures.

I

Parameters: capacitances and resistances.

HVAC Modeling & Control

20

State-space Thermal Model of Zone Gather all RC networks and all differential/algebraic equations: d x(t) = Ax(t) + Bu(t) + Kw (t) + (Lx x(t) + Lw w (t)) u(t) dt Discretize the state-space model:   ˆ ˆ ˆ w (k) + L ˆx x(k) + L ˆw w (k) u(k) x(k + 1) = Ax(k) + Bu(k) +K y (k) = Cx(k)

Linearize the model at some operating point: ˜ ˜ ˜ w (k) x(k + 1) = Ax(k) + Bu(k) +K y (k) = Cx(k) Model reduction techniques to reduce the dimension of the model. T. Nghiem

HVAC Modeling & Control

21

Part II Advanced Control of HVAC Systems

Overview Introduction to Model Predictive Control Model Predictive Control of HVAC Systems

T. Nghiem

HVAC Modeling & Control

22

Advanced Control of HVAC Systems In this lecture, advanced control = optimal supervisory control of HVAC system to minimize some objective function (e.g., energy consumption, energy cost). General optimization problem: minimize u0...N

subject to

J = f (x0...N , u0...N , w0...N ) xk+1 = g (xk , uk , wk ) constraints on xk , uk wk ∼ disturbance model

T. Nghiem

HVAC Modeling & Control

23

Ingredients of Optimal Control System model g Mathematical model of the HVAC system (Part 1). Disturbance model of wk I I

T. Nghiem

Constrained in a bounded set wk ∈ Wk . ¯oa , σ 2 ) where T ¯oa : predicted Stochastic model, e.g., Toa ∼ N (T outside air temperature (weather forecast).

HVAC Modeling & Control

24

Ingredients of Optimal Control Constraints I I I

Safety and mechanical constraints: uk ∈ Uk . Air quality: V˙ sa ≥ V˙ sa,min . Thermal comfort: I

I

I

I I

T. Nghiem

Predicted Mean Vote (PMV) index: predicts mean of thermal comfort responses by occupants, on the scale: +3 (hot), +2 (warm), +1 (slightly warm), 0 (neutral), −1 (slightly cool), −2 (cool), −3 (cold). PMV should be close to 0. Predicted Percentage Dissatisfied (PPD) index: predicted percentage of dissatisfied people. PMV and PPD has a nonlinear relation (in perfect condition PPD(PMV = 0) = 5%). PMV/PPD can be calculated as nonlinear functions of temperature, humidity, pressure, air velocity, etc. (cf. ASHRAE manuals). Constraint on PMV/PPD gives (nonlinear) constraint on xk . Simplified as xk ∈ Xk (convex).

HVAC Modeling & Control

25

Ingredients of Optimal Control Objective function f I

Minimize energy consumption: often a linear function of control variables u.

I

Minimize peak demand: a minimax optimization problem where f (x0...N , u0...N , w0...N ) = max c T uk k∈P

T. Nghiem

I

Minimize energy cost: weighted sum of energy consumption and peak demand.

I

Maximize thermal comfort by minimizing PMV squared.

HVAC Modeling & Control

26

HVAC Optimal Supervisory Control Approaches Two approaches to optimal supervisory control of HVAC systems: 1. Optimal controller controls and coordinates all field devices (valves, dampers, etc.); conventional local control loops are replaced. I I

I

Is a complete re-implementation of the control system. Requires high computational power because of the time scale of field devices. Good optimization but costly implementation.

2. Optimal controller sets set-points and modes of local control loops. I

I I

T. Nghiem

Adds optimization software to supervisory control layer; keep local control loops. Requires less computational power because of slower time scale. Less expensive implementation, (slightly worse) optimization.

HVAC Modeling & Control

27

Difficulties of HVAC Optimal Supervisory Control Theoretical difficulties: I

Large-scale system: hundreds of variables times dozens time steps.

I

Stochastic nature of the system due to weather, occupancy, etc.

I

Long optimization horizon (e.g., billing period).

I

Non-linearity of system ⇒ linearization.

I

T. Nghiem

Complex objective function, e.g., energy cost.

HVAC Modeling & Control

28

Part II Advanced Control of HVAC Systems

Overview Introduction to Model Predictive Control Model Predictive Control of HVAC Systems

T. Nghiem

HVAC Modeling & Control

29

Introduction to Model Predictive Control Source: “Model Predictive Control of Hybrid Systems” Presentation by Prof. Alberto Bemporad

T. Nghiem

HVAC Modeling & Control

30

Part II Advanced Control of HVAC Systems

Overview Introduction to Model Predictive Control Model Predictive Control of HVAC Systems

T. Nghiem

HVAC Modeling & Control

31

MPC of HVAC Systems: Formulation ut ,...,ut+T −1

minimize

J = f (xt , . . . , xt+T , ut , . . . , ut+T −1 )

subject to

xk+1 = g (xk , uk , wk ), xk ∈ Xk , uk ∈ Uk ,

k = t, . . . , t + T − 1

k = t, . . . , t + T

wk ∼ disturbance model where I I

Horizon T  N.

Objective function f (·): X

c T uk

(energy consumption)

k=t,...,t+T −1

 max Dt ,

max

k∈P∩{t,...,t+T −1}

c T uk



(peak demand)

with Dt : peak demand from time 0 to t. T. Nghiem

HVAC Modeling & Control

32

MPC of HVAC Systems: Formulation ut ,...,ut+T −1

minimize

J = f (xt , . . . , xt+T , ut , . . . , ut+T −1 )

subject to

xk+1 = g (xk , uk , wk ), xk ∈ Xk , uk ∈ Uk ,

k = t, . . . , t + T − 1

k = t, . . . , t + T

wk ∼ disturbance model where I

Disturbance wk : I I

I

Bounded constraint wk ∈ Wk ⇒ robust MPC. Probabilistic model wk ∼ Pk ⇒ stochastic MPC.

Optional demand-limiting constraint: for every k ∈ P c T uk ≤ D ? with D ? : maximum demand.

T. Nghiem

HVAC Modeling & Control

33

MPC of HVAC Systems: Optimization Solving the MPC optimization problem: I

If it is convex, use standard algorithms and tools.

I

If it is non-convex, use approximation technique (Lagrangian dual problem).

Some practical considerations: I I

Large-scale system ⇒ distributed optimization. For better performance: I I I

T. Nghiem

Initialize with previous solution. Use heuristics to guess initial solution. Further constrain variables using rules, e.g., during peak hours, VAV box should close more.

HVAC Modeling & Control

34

B isthatlarge. investigation is violations than SMPC This has smaller and less frequent RBC. Furthermore, the diurnal temperature variations are B. Practical Potential Analysis large-scale factorial simulation much smaller with SMPC, which is a much more favourable MPC of HVAC Systems: Examples ge ofbehavior casesforrepresenting different the room comfort. With real weather predictions, it can happen that t weather conditions as described traints are being Therefore, perfor Fig. 7. violated. Tradeoff for SMPC and CE betweencontroller energy use and violation and comparison with PB and RBC. ails see [7], [8]. is assessed in terms of both energy usage and con this investigation we compare violation. and which low/high-cost energy sources are needed to keep RBC and MPC strategies only the room temperature in the required comfort levels. SMPC m the theoretical potential study. was shown to outperform both rule-based control (RBC) as well as a predictive non-stochastic controller (CE). Further found in [12]. Time step [h] Fig. 5.

Room temperature profile of RBC for one year.

benefits or SMPC are easy tunability with a single tuning parameter describing the level of constraint violation as wel as comparatively small diurnal temperature variations.

nt there were on total 1228 cases VII. ACKNOWLEDGMENTS ere done for the HVAC system, Swisselectric Research, CCEM-CH and Siemens Building Technologies are gratefully acknowledged for their financia requirements, and the weather Typical violation support of the OptiControl project.level riants are listed here: R EFERENCES dered are five building system [1] A. Ben-Tal and A. Goryashko and E. Guslitzer and A. Nemirovski “Adjustable robust solutions of uncertain linear programs”, in Mathe A). matical Programming, vol. 99(2), 2004, pp. 351-376. Fig. Comparison of and SMPC and RBC.“Optimization [2] P. J.4. Goulart and E. C. Kerrigan J. M. Maciejowski, Time step [h] ary in building standard (Passive over state feedback policies for robust control with constraints” Fig. 6. Room temperature profile of SMPC for one year. Automatica, vol. 42(4), 2006, pp. 523-533. construction type (light/heavy), [3] R. E. Griffith and R. A. Steward, “A nonlinear programming technique Source: [Oldewurtel et comparison al., 2010] for the optimization of continuous systems”, Journal Usage of CE for the six selected cases generally yield 4 depicts (low/high), internal gains level Figure the result of theprocessing of oS Management Science, vol. 7, 1961, pp. 379-392. much more violations than allowed in the standards (results ances; low/high; also associated and RBC for the selected set of experiments: [4] M. Gwerder, J. Toedtli, “Predictive control for integrated roomMP auto not shown). One can however tune CE by assuming a mation”, CLIMA 2005, Lausanne, 2005. de orientation forcontroller, normalwhich always clearly energy than “Ruled-based RBC and instrategies” four [5] less M. Gwerder, J. Toedtli,use D. Gyalistras, control tighter comfort(N bandorforSthe results in less in [6]. violations and more energy use. Thus, for different comfort WT.for corner offices). casesHVAC smaller violations. This indicates th [6]amounts D. Gyalistras, of M. Gwerder (Eds.), “Use of weather and occupancy Nghiem Modeling & Control 35 band widths one gets a tradeoff curve between energy use and

References Deng, Kun, Barooah, Prabir, Mehta, Prashant G., & Meyn, Sean P. 2010. Building thermal model reduction via aggregation of states. Pages 5118–5123 of: Proceedings of the 2010 American Control Conference, ACC 2010. Oldewurtel, Frauke, Parisio, Alessandra, Jones, Colin N., Morari, Manfred, Gyalistras, Dimitrios, Gwerder, Markus, Stauch, Vanessa, Lehmann, Beat, & Wirth, Katharina. 2010 (Jun.). Energy efficient building climate control using Stochastic Model Predictive Control and weather predictions. Pages 5100 –5105 of: American Control Conference (ACC) 2010.

T. Nghiem

HVAC Modeling & Control

36

Thank You!

Q&A

Suggest Documents