A LIBRARY OF HVAC COMPONENT MODELS FOR USE IN AUTOMATED DIAGNOSTICS. Peng Xu, Philip Haves, Dimitri Curtil Lawrence Berkeley National Laboratory

Similar documents
THE EFFECTS OF COUPLED INDUCTORS IN PARALLEL INTERLEAVED BUCK CONVERTERS

Characterization of Refrigeration System Compressor Performance

SPH4U Transmission of Waves in One and Two Dimensions LoRusso

Load Calculation and Design of Roller Crowning of Truck Hub Bearing

This report presents an assessment of existing and future parking & traffic requirements, for the site based on the current development proposal.

Available online at ScienceDirect. Procedia Engineering 113 (2015 )

Basic Gas Spring Theory

DFC NIST DIGITAL MASS FLOW CONTROLLERS. DFC with optional LCD readout PROG RS485. Programmable Mass Flow Controller with Digital Signal Processing

Series 600 Accessories

A Comparative Investigation of Reheat In Gas Turbine Cycles

THE LATENT DEMAND METHOD

GFC NIST MASS FLOW CONTROLLERS. Typical Stainless Steel GFC Mass Flow Controller. Design Features. General Description. Principles of Operation

GFC NIST MASS FLOW CONTROLLERS. Typical Stainless Steel GFC Mass Flow Controller. Design Features. General Description. Principles of Operation

SPEED OF SOUND MEASUREMENTS IN GAS-MIXTURES AT VARYING COMPOSITION USING AN ULTRASONIC GAS FLOW METER WITH SILICON BASED TRANSDUCERS

Flygt low-speed mixers. Outstanding efficiency

Chilled Mirror Dew Point Instrument

1. Write down the ideal gas law and define all its variable and parameters. 2. Calculate the values and units of the ideal gas law constant R.

operate regenerator top without boiling aq. amine solution.

The structure of the Fibonacci numbers in the modular ring Z 5

XFM DIGITAL MASS FLOW METER. XFM with Profibus Interface. XFM without. Readout. XFM with. Readout. Option

Coal Pulveriser. Global Solutions

8.5. Solving Equations II. Goal Solve equations by balancing.

SYMMETRY AND VARIABILITY OF VERTICAL GROUND REACTION FORCE AND CENTER OF PRESSURE IN ABLE-BODIED GAIT

Seated valves (PN 16) VF 2-2-way valve, flange VF 3-3-way valve, flange

Capacity of Shared-Short Lanes at Unsignalised Intersections

n UL Listed and FM Approved for n Solenoid control n Quick pressure relief valve 73Q n Pressure sustaining & reducing valve 723

A SECOND SOLUTION FOR THE RHIND PAPYRUS UNIT FRACTION DECOMPOSITIONS

Energy-efficient mixing

DAMAGE ASSESSMENT OF FIBRE ROPES FOR OFFSHORE MOORING

ASSESSMENT SCORING SYSTEM OF ROAD SAFETY INFRASTRUCTURE

ELIGIBILITY / LEVELS / VENUES

ELIGIBILITY / LEVELS / VENUES

-H- Note. Flow control valve. Key features

ELIGIBILITY / LEVELS / VENUES

Catenary Analysis and Calculation Method of Track Rope of Cargo Cableway with Multiple Loads

WhisperFit EZ Ventilation Fans

ELIGIBILITY / LEVELS / VENUES

number in a data set adds (or subtracts) that value to measures of center but does not affect measures of spread.

WIND TUNNEL EXPERIMENT ON THE EFFECT OF WIND ON SMOKE EXHAUST SYSTEMS FOR A HIGH RISE BUILDING

Footwork is the foundation for a skilled basketball player, involving moves

"The twisting movement of any hoof should, for physiological reasons, not be hindered by Shoeing." (Lungwitz 1884)

ANALYSIS AND MODELING TIME HEADWAY DISTRIBUTIONS UNDER HEAVY TRAFFIC FLOW CONDITIONS IN THE URBAN HIGHWAYS: CASE OF ISFAHAN

Cooling of a Reciprocating Compressor through Oil Atomization in the Cylinder

Research Article. Relative analysis of Taekwondo back kick skills biomechanics based on 3D photograph parsing. Mingming Guo

Hazard Identificaiton of Railway Signaling System Using PHA and HAZOP Methods

draft final report NGSIM Arterial-Lane Selection Mode Federal Highway Administration Cambridge Systematics, Inc.

University of California, Los Angeles Department of Statistics. Measures of central tendency and variation Data display

Real time lane departure warning system based on principal component analysis of grayscale distribution and risk evaluation model

GENETICS 101 GLOSSARY

The Prediction of Dynamic Strain in Leaf-Type Compressor Valves With Variable Mass and Stiffness

Extensible Detection and Indexing of Highlight Events in Broadcasted Sports Video

Human-Robot Interaction: Group Behavior Level

Developing process safety indicators

Impacts of Typhoon on Wave Height at Bangkhuntien Shoreline

Intersleek Pro. Divers Manual. Our World is Water CONTENTS

DEPARTMENT OF ELECTRICAL AND COMPUTER ENGINEERING, THE UNIVERSITY OF NEW MEXICO ECE-238L: Computer Logic Design Fall Notes - Chapter 6.

Version IV: April a publication from

Headfirst Entry - Diving and Sliding

A Different View on TBM Face Equilibrium in Permeable Ground

Patrick Boston (Leeds University) and Mark Chapman (Edinburgh University)

ICC WORLD TWENTY ( WORLD CUP-2014 )- A CASE STUDY

STRUCTURAL FILL, SONOTUBES, CONCRETE, GRAVEL, CLEAR SILICONE, ENGINEERED WOOD FIBRE (E.W.F.), GEO-TEXTILE, SOIL, PLANTS & MULCH ARE NOT SUPPLIED.

Polynomial functions have graphs that are smooth and continuous. c) Use your knowledge of quadratic functions to sketch the graph.

AN ESTIMATION OF INTER-ZONAL BUS DEMAND ON COLOMBO - KALUTARA TRANSPORT CORRIDOR

PERFORMANCE TEAM EVALUATION IN 2008 BEIJING OLYMPIC GAMES

Adaptive Neuro-Fuzzy control of an unmanned bicycle

ZD ZD Self-balance Multistage Centrifugal Pumps

Policy sensitivity analysis of Karachi commuters

10 th International Congress of the International Maritime Association of the Mediterranean (IMAM), Rethymno, Crete, May 2002

HYDRAULIC MOTORS MM APPLICATION CONTENTS GENERAL MOTORS

Computation of the inviscid drift force caused by nonlinear waves on a submerged circular cylinder

The Application of Simulating WAves Nearshore Model for Wave Height Simulation at Bangkhuntien Shoreline

A Comparison of MOEA/D, NSGA II and SPEA2 Algorithms

2) What s the Purpose of Your Project?

ELIGIBILITY / LEVELS / VENUES

Influences of Teaching Styles and Motor Educability on Learning Outcomes of Volleyball

EFFECTS OF ROTOR CONTAMINATION ON GYROPLANE FLIGHT PERFORMANCE

Climbing/Rappelling NATIONAL STANDARDS BOY SCOUTS OF AMERICA

Analytical and numerical prediction of water sorptivity in cement-based materials

Controlling noise at work

Introduction to Algorithms 6.046J/18.401J/SMA5503

Modelling Lane Changing Behaviour of Heavy Commercial Vehicles

securing your safety

HEEL RETENTION SYSTEMS

WATER VALVES REPLACEMENT PROJECT

Operating Instructions SURGICAL POWER & ACCESSORIES

Simulation Study of a Bus Signal Priority Strategy Based on GPS/AVL and Wireless Communications

P h o t o g r a p h i c L i g h t i n g ( 1 1 B )

STRUCTURAL FILL, SONOTUBES, CONCRETE, GRAVEL, CLEAR SILICONE, ENGINEERED WOOD FIBRE (E.W.F.), GEO-TEXTILE, SOIL, PLANTS & MULCH ARE NOT SUPPLIED.

Characteristics of CNG Bubbles in Diesel Flow under the Influence of the Magnetic Field

EQUIPEX NAOS WP5 : Deep oxygen floats in the North- Atlantic

Acta Geophysica vol. 57, no. 4, pp DOI: /s

MST 121: Supplementary resource material for Chapter A1, Sequences

Avoiding danger from underground services

Design, construction and installation of gas service pipes

Obstacle Avoidance for Visually Impaired Using Auto-adaptive Thresholding on Kinect s Depth Image

City of Valdez REQUEST FOR QUOTES. Project Name: Lowe River Levee Certification Groin 1 Freeboard Repairs PO Number: Cost Code:

Active Travel The Role of Self-Selection in Explaining the Effect of Built Environment on Active Travel

A Data Envelopment Analysis Evaluation and Financial Resources Reallocation for Brazilian Olympic Sports

Maximizing. Potential in the 4x100 Relay. 4x100 - Entire Race. A Review of Relay Basics. NFHS Relay Zone Measurements

Transcription:

Secod Natioal IBPSA-USA Coferece Cambridge, MA August -4, 006 3 4 5 6 7 8 9 0 A LIBRARY OF HVAC COMPONENT MODELS FOR USE IN AUTOMATED DIAGNOSTICS ABSTRACT The paper describes ad documets a library of euipmet referece models developed for automated fault detectio ad diagosis of secodary HVAC system (air hadlig uits ad air distributio systems. The models are used to predict the performace that would be expected i the absece of faults. The paper icludes a descriptio of the use of automatic documetatio methods i the library. INTRODUCTION The icreasig complexity of buildig HVAC cotrol ad maagemet systems heightes the eed for the devolvemet of tools to assist i moitorig the performace of these systems. The applicatio of these tools is expected to lead to improved comfort, eergy performace ad reduced maiteace costs. The fuctio of these tools may be limited to collectig raw data from sesors ad cotrol system outputs ad displayig it for maual aalysis by operators or egieers. Alteratively, the tools may aalyze the data i order to determie whether the operatio is correct or faulty (automated fault detectio ad may also idetify the locatio or ature of the physical cause of a problem (automated fault diagosis. The work reported here is part of a ogoig effort to develop model-based automated fault detectio ad diagosis methods ad tools for HVAC systems. The referece model is used to predict performace that would be expected i the absece of faults. A comparator is used to determie the sigificace of ay differeces betwee the predicted ad measured performace ad hece the level of cofidece that a fault has bee detected. The model-based approach facilitates a buildig life cycle approach. I fuctioal testig as part of iitial commissioig, a baselie model of correct operatios is first cofigured ad calibrated agaist desig iformatio ad maufacturers data. Next, the model is fied-tued to match the actual performace after ay faults have bee fixed ad the model is the used as part of a performace moitorig diagostic tool for operatios. Peg Xu, Philip Haves, Dimitri Curtil Lawrece Berkeley Natioal Laboratory The paper describes the library of euipmet models, icludig coolig coil, cotrol valve, mixig box ad system models. The models are simple eough so that their parameters ca be determied from iformatio usually available to commissioig agets or buildig operators. Simple preprocessors were developed to calculate the model parameters from this iformatio. A method of geeratig model documetatio automatically from meta-iformatio embedded i commets i the source code is described. REFERENCE MODELS Simulatio Software: SPARK The simulatio program SPARK (SPARK 003 has bee used to develop ad implemet the referece model library. SPARK is a object-based software system that ca be used to simulate physical systems that ca be modeled usig sets of differetial ad algebraic euatios. Object-based meas that compoets ad subsystems are modeled as objects that ca be itercoected to form a model of the etire system. SPARK differs from earlier objectbased simulatio programs such as HVACSIM+ (Clark 985 ad TRNSYS (Klei et al. 976 i that the graularity exteds dow to the euatio level, allowig the user to chage which variables are iputs ad which are outputs without chagig the models ad facilitatig the use of graph-theoretic methods to improve simulatio speed ad robustess. SPARK models have a hierarchical structure. The smallest programmig elemet is a class cosistig of a idividual euatio, called a atomic class. A macro class cosists of several atomic classes (ad possibly other macro classes combied together ito a higher level uit. The process of describig a system i order to produce a SPARK system model begis by determiig which compoets ca be represeted usig existig models. New models ca be created relatively easily from the atomic classes i the SPARK library that embody commoly used thermofluid relatioships. Sice there may be - 34 -

several compoets of the same type i a system, SPARK object models, i.e., euatios or groups of euatios, are defied i a geeric maer, called classes. Classes serve as templates for creatig ay umber of like objects that may be eeded i a problem. The problem model is the completed by likig objects together, thus defiig how they iteract, specifyig parameter values that specialize the system model to represet the actual problem to be solved ad providig boudary values. Coolig Coil The challeges i coolig coil modelig are to treat the variatio i surface resistace with flow rate ad to treat partially wet operatio. The most commo fault i both heatig or coolig coils is foulig of the heat exchage surface, either o the air or the water side. I order to detect loss of peak load capacity due to foulig whe it occurs, it is oly ecessary to model full load operatio. However, i order to be able to predict loss of capacity before it occurs, it is ecessary to model part load operatio as well. Aother sigificat fault i coil subsystems is cotrol valve leakage. Correct operatio of the coil subsystem is modeled by combiig the coil model described i this sectio with the valve model described i the ext sectio. A sigificat umber of coil models have bee developed over the last few decades; oe of the models that treat partly wet operatio is etirely suitable for fault detectio. I particular, there are two coolig coil models i the ASHRAE Secodary Toolkit (Brademuehl et al., 993. The simple model approximates partially wet operatio as all wet or all dry. The detailed model treats the dry ad wet regios separately ad iterates to fid the positio of the boudary. Testig of this model performed as part of the work described here showed that the iterative scheme employed i the model sometimes fails to coverge uder coditios of high humidity. Recetly, a dyamic coolig cool model has bee developed (Zhou, 005. The model ca predict the dyamic performace of coolig coil withi a reasoable rage of accuracy. However, the model is too detailed ad complicated for it to be used o site for fault diagosis. For this reaso, it was decided to develop a ew model of partially wet coil operatio. I the ew model, the coil is divided ito discrete sectios alog the directio of fluid flow, as show i Figure. I each sectio, heat ad mass balace euatios are established for each fluid, together with rate euatios describig the heat ad mass trasfer. If the dew poit temperature of the air is lower tha the metal surface temperature, that sectio of the coil is treated as dry. If ot, the water codesatio rate is assumed to be proportioal to the differece betwee the humidity ratio of the bulk air stream ad the humidity ratio of saturated air at the temperature of the coil metal surface. The coefficiet of proportioality is determied by assumig the value of the Lewis Number is uity. The sectios that make up the coil are liked together by associatig the fluid ilet coditios of oe sectio with the outlet coditios for the adjacet upstream sectio. The resultig set of coupled euatios is the solved by SPARK. Although the computatioal burde of the ew coil model is sigificatly greater tha that of the ASHRAE Toolkit models, the model is more robust, ad it has the additioal advatage of beig a suitable startig poit for a dyamic coolig coil model. SPARK caot simulate a model with a dyamically varyig umber of objects so the umber of layers of the coil is hard-wired to 0 istead of beig variable. Dividig the coolig coil ito 0 layers provides sufficiet accuracy because, uder the commo operatio rage of the cool coil, the drivig temperature differece i each layer is oe order of magitude lower tha the temperature chage alog the flow directio. The thermal coductaces of the exteral ad iteral surfaces are modeled usig the turbulet flow approximatio: 0.8 UAext Cext vair 0.8 where v is the fluid velocity. UAit Cit vli airflow T air,lvg,i- T air,et,i T air,lvg,i T air,et,i+ T air,lvg,i+ i- i i+ T li,et,i- T li,lvg,i T li,et,i T li,lvg,i+ T li,et,i+ water flow Figure : Discrete sectios i the coolig coil model - 35 -

For each layer of the coolig coil, the sesible ad latet heat trasfer rates betwee the air ad coolig coil surface are give by: air, et air, lvg se, layer ( Tsur wair, et + wair, lvg lat, layer max 0, ( wsur h fg hmass where T is the temperature, w is the humidity ratio, h fg is the latet heat of vaporizatio of water ad h mass is the mass trasfer coefficiet. Heat trasfer betwee the coolig coil surface ad the water is give by: Ethalpy ad sesible heat balaces yield: li, et li, lvg tot, layer Tsur tot, layer m m + T se, layer li li air, dry ( T ( h se, layer mair, dryc p ( Tair, et Tair, lvg where h the specific ethalpy. T T + T ( UA c + lat, layer li, lvg air, et UA T h li, et Iformatio for differet operatig poits is reuired to estimate the coefficiets C it ad C ext. Typically, oly performace iformatio at desig coditios is available to commissioig agets ad buildig operators; this is sufficiet to estimate the total UA but ot the air-side ad water-side compoets. However, empirical correlatios developed by Holmes (98 ca be used to estimate the ratio of the air-side ad water-side coductaces at specified coditios ad hece determie the coefficiets C it ad C ext whe combied with the desig coditio iformatio usually provided o the mechaical drawigs. Cotrol valve A cotrol valve varies the fluid flow rate i a circuit by varyig its flow resistace. A exteral actuator is used to move a plug coected to the valve stem that restricts the flow to varyig degrees depedig o its positio. There are three distict valve flow types based o the geometry of the plug: uick opeig, liear, ad eual percetage. The eual percetage characteristic is used to compesate for the o-liear characteristic of heatig ad coolig coils ad the effect of the series resistace of the coil. The most commo faults associated with cotrol valves are: leakage, stuck valve/actuator, actuator/valve rage mismatch ad ustable cotrol. ext air, lvg it I order to detect these faults, it is more importat to model the valve behavior at each ed of the operatio tha i the middle. However, as discussed i the Coil sectio, it is desirable to be able to predict the part load performace of coils i order to aticipate loss of peak capacity before it occurs. Sice the water flow rate through a coil is ot geerally measured i HVAC systems, it is ecessary to treat the behavior of the cotrol valve at itermediate flow rates by modelig its iheret ad istalled characteristics i order to predict the water flow rate through the coil. The water flow rate is a fuctio of the valve positio, the flow rate through the valve whe fully ope ad the leakage. The flow characteristic is assumed to be parabolic (see below, which is a adeuate ad coveiet approximatio to the eual percetage characteristic. I order to model the istalled characteristic of the valve, it is ecessary to treat the effect of the series resistace of the coil ad other compoets i the brach. This is covetioally expressed i terms of the authority of the valve. Authority is the ratio of the pressure drop across the valve whe it is fully ope to the pressure drop across the whole of the brach whe the valve is fully ope. Whe the authority is eual to uity, the pressure drop across the valve domiates the pressure drop i the brach ad there is o distortio of the valve flow characteristic. Whe the authority is eual to zero, the pressure drop across the valve is egligible uless it is fully closed ad so the valve has essetially o effect o the flow rate except whe it is fully closed. A more detailed descriptio of valve authority is give i ASHRAE (004. The fractioal leakage is give by m& leak liher m& ope where m& is the mass flow rate through the cotrol port at costat pressure drop. The iheret flow characteristic is the f iher where f iher is the ratio of the flow rate at stem positio s to the flow rate whe the valve is fully ope whe the pressure drop across the valve is costat. (s is i the rage 0-. The istalled flow characteristic is the f istall l iher + ( l s A + ( A f iher iher - 36 -

where A is the authority of the valve. I geeral, the leakage of a ew cotrol valve is egligibly small; however, there may be situatios where it is ecessary to model a sigificat amout of leakage, e.g. whe moitorig a existig valve to determie whether the leakage gets worse over time. Fa The most commoly used s i large air hadlig uits are cetrifugal s. I VAV systems, capacity is cotrolled by varyig either the rotatio speed or, i older istallatios, the positio of a ilet guide vae. There is a pressure sesor i the supply duct ad a feedback cotrol loop to maitai the air pressure i the duct costat by adjustig the supply capacity. The retur capacity is varied i order to cotrol the pressure of the part of the buildig served by the particular air hadlig uit (AHU. The model described here applies to VAV systems i which the capacity of each is cotrolled by varyig the rotatio speed. As with all the models preseted here, oly the behavior of the mechaical euipmet is treated i the model. The most commo faults associated with s are: variable speed drive malfuctio, icorrect rotatio directio, ad pressure sesor offset. The model treats either the supply or the retur, together with the appropriate sectio of the distributio system, as show i Figure. The flow rate i a system is determied by the characteristics of the ad the characteristics of the system, as show i Figure 3. Fa performace is modeled by usig the similarity laws to ormalize the flow rate, pressure rise ad power i terms of rotatio speed ad diameter. Over the limited rage of ormalized flow rate used i ormal operatio, the relatioship betwee pressure rise ad flow rate at costat speed (the head curve ca be approximated usig a costat term ad a suared term: PRESSURE p 0 p Stat system curve head curve FLOW RATE Figure 3 Schematic of the model system operatio poit (Note that the rage of ormalized flow rates ecoutered i VAV systems is much less tha the rage of u-ormalized flow rates. The costat term is the pressure rise extrapolated to zero flow, which is proportioal to the suare of the rotatio speed,, ad the suared term correspods to the iteral pressure drop iside the. (m m is used rather tha m to yield the correct behavior at egative flows. The model is writte i terms of total pressure (i.e. static pressure plus velocity pressure sice the eergy losses are directly related to chages i total pressure. The system curve, which represets the pressure drop through all the air hadlig uit ad distributio system compoets, also cosists of a costat term ad a suared term. For the supply subsystem, the costat term is the static pressure set-poit. The suared term represets the pressure drop through the AHU ad distributio system compoets ad the velocity pressure at the static pressure sesor, both of which are proportioal to the suare of the air mass flow rate. where ρ air is the desity of air ad A is the cross sectioal area of the duct at the pressure sesor. Δ psys pstat + ( + Csys m m ρ A air Δp k 0 C mm p stat 0 Resistace C sys Supply Fa + Zoe 0 Retur Fa Resistace C sys Figure : System diagram of the -air system simulated i the model - 37 -

For the retur subsystem, p stat is the measured or assumed pressure i the occupied space ad appears as a egative term, sice a positive pressure i the space reduces the pressure rise reuired. The correctio for the velocity pressure i the room is very small ad ca be igored. p sys -p stat + C sys m m The operatig poit is where the pressure drop across the system euals the pressure icrease across the, as show i Figure 3. The air flowig through the icreases i temperature because of the heat added to the air stream due to iefficiecy ad due to motor iefficiecy, if the is i the air stream. Because air is a compressible fluid ad ca be treated as a perfect gas, it ca be show that the fluid work performed by the results i the same temperature icrease that would be obtaied if the fluid work were completely coverted to heat. (The opposite is true for icompressible fluids, such as water. I the case of icompressible fluids, the fluid work oly appears as heat whe the fluid passes through a dissipative elemet. Euatig the pressure rise ad system pressure drop yields: k p stat + ( + C sys + C m m ρ A for the supply ad a similar relatioship for the retur. The shaft power is: P shaft air m p η ρ air The efficiecy as a fuctio of ormalized airflow rate is assumed to vary uadratically about its maximum value: η max η, max Cη, ( The total electric power is: P tot P η VFDη m p η ρ where η tot is the combied efficiecy of the variable freuecy drive, motor, belt ad. The heat gai to the air stream is: T air shaft motor gai P Tot [η T +(- η motor η belt f motor&belt ] where f motor&belt idicates whether the motor is i the airstream ( or out of the airstream (0. The temperature rise across the is determied from: Mixig box A mixig box is the sectio of a air-hadlig uit used to mix the retur air stream with the outside air stream. It cosists of three sets of dampers whose operatio is coordiated to cotrol the fractio of the outside air i the supply air while maitaiig the supply airflow rate approximately costat. Figure 4 is a simplified diagram of the mixig box simulated i the model. A variat of this desig has a separate outside air damper that is adjusted to provide the miimum outside airflow reuired durig occupacy. η belt m m ( Tair, out Tair, i loss / c p m where η is the efficiecy of the. exhaust air T exh exhaust damper T ret retur air recirculatio damper outside air m out T out outside T mix m sup damper Figure 4: Flow directios ad temperatures i a mixig box supply air - 38 -

Figure 5 shows ideal behavior ad the rage of acceptable behavior of a mixig box. The vertical axis is the outside air fractio, defied as: m OAF out m sup OAF ideal behavior upper boud l ret To a good approximatio, the temperatures i the mixig box are related to the outside air fractio by: t OAF t ret ret t t Uder the ideal coditios, the outside air fractio should rage from 0 to whe the damper positio varies from 0 to 00%. However, i geeral, there is leakage of both the outside air ad the retur air dampers; the outside air fractio the rages betwee a miimum value that is greater tha 0 ad a maximum value that is less tha. I additio, the air-flow rate is ot ecessarily liearly related to the damper positio ad therefore the mixed air temperature ad humidity ratio are ot liearly related to damper positio. Theoretically, it is possible to predict the airflow rates of both the outside air ad recirculatio air streams as a fuctio of damper positio. The airflow rates could the be used to determie the outside air fractio ad hece the mixed air temperature ad humidity ratio. However, it is impractical to simulate the mixed air temperature accurately i this way because the pressure boudary coditios chage with speed as a result of wid effects ad because of the difficulty of estimatig the authority of the dampers. This said, the behavior i the middle of the operatig rage is relatively uimportat compared to the behavior at the eds of the operatig rage. Figure 5 shows the forms of the models to be used durig commissioig ad durig routie operatio followig commissioig. I the model to be used at the commissioig stage, whe oly desig iformatio is available, the rage of acceptable behavior is modeled. A 3: gai variatio is used by default; whe the damper positio is 50%, the upper limit of the outside air fractio is 5% lower tha its maximum ad the lower limit is 5% above its miimum: OAF OAF lower upper d ( l l out ret + (d d where d is the damper positio (0- ad l is the maximum acceptable fractioal leakage. The suare law relatioships betwee OAF ad d are used as a coveiet approximatio to the likely limits of acceptable performace i the absece of ay recogized stadard. mix out ( l out l out The maximum acceptable deviatios from 0 ad 00% outside air fractio at each ed of the operatig rage should ideally be specified by the desiger. Oce the mixig box has bee commissioed, the results of the fuctioal test ca be used to fit a polyomial to the measured variatio of outside air fractio with the cotrol sigal: OAF where the order,, is costraied by <m, where m is the umber of measuremets. The costrait esures that the fitted curve passes through the measured value OAF max at d as well as through OAF mi at d0. lower boud damper positio Figure 5: Mixig box performace i mod el OAFmax OAFmi Cid + ( OAF C i SELF-CONSISTENT DOCUMENTATION PROCESS A itegral part of developig a library of euipmet referece models is the provisio of detailed documetatio of each model, icludig the euatios, physical assumptios ad umerical limitatios, if applicable. Ideally, the documetatio should always be up-to-date i the sese that it reflects the actual implemetatio of the model. It should also be clear ad cosistet, both for viewig ad pritig, ad provide active cross-liks to facilitate browsig, either withi the documet itself or to other exteral cotextually-related documetatio sources. Such reuiremets usually imply the eed to geerate documetatio i differet formats (e.g., MS Word, HTML ad/or PDF from the same meta-iformatio. Such a task ca easily become burdesome for the library writer, which typically results i a icomplete or icosistet documetatio effort. I order to esure self-cosistecy, ad avoid possible discrepacies betwee differet versios as well as likely duplicatio of effort, we propose a mi - 39 -

automated approach to geeratig documetatio by embeddig meta-iformatio directly withi the commets i the files cotaiig the source code for the compoet models. The model writer specifies the documetatio meta-iformatio as part of the ormal developmet ad maiteace process. The commets ca the be parsed so that the iformatio is made available i customized formats for various outputs. Sice the SPARK defiitio laguage essetially follows the same sytax as C/C++, with the additio of a few simulatio-specific keywords, it is possible to use ay automated documetatio geeratio tool capable of parsig C/C++ source code to perform this task. We briefly describe how this has bee accomplished usig the widely-used doxyge tool (Doxyge 006. Doxyge, mostly writte by Dimitri va Heesch, is a ope-source documetatio geerator for C++, C, Java, Objective-C, Pytho, ad IDL. Beig highly portable, it rus o most Uix systems as well as o Widows ad Mac OS X. Doxyge is a userfriedly tool that extracts specific source code commets ad aalyzes the declaratios of the code, to create a comprehesive olie documetatio with active liks. Doxyge also geerates depedecy graphs, iheritace diagrams, ad collaboratio diagrams to help i visualizig the relatios betwee the various elemets. If eeded, it is possible to icorporate directed ad udirected graphs i the documetatio by directly embeddig textual Graphviz (Graphviz 006 declaratios withi the commets. By default, the output format is HTML but it ca also be CHM (Microsoft compressed HTML, RTF (Microsoft Rich Text Format, PDF (Adobe Portable Documet Format, LaTeX, PostScript or ma pages. Because doxyge automatically takes care of geeratig the documetatio i the differet output formats from the same meta-descriptio, the library writer does ot eed to be familiar with the formattig issues of each eviromet, thereby allowig attetio to be focused o the cotet as opposed to the form. With a few simple markups i the commets ad maipulatio of the optios i the doxyge cofiguratio files, it is possible to geerate selfcosistet ad professioal-lookig documetatio of the SPARK files automatically. Predefied style sheets ca be used to further customize the look-adfeel ad layout of the documetatio i CHM (ideal for browsig o Widows platform, HTML (suitable for viewig i ay browser ad PDF (ideal for pritig. The code sippet i Appedix demostrates how a SPARK atomic class, valve.cc, ca be made doxyge-aware by usig doxyge keywords (show with a bold typeface withi the C++-like commet blocks startig with the reserved toke ///. The result from applyig doxyge to this SPARK atomic class is show i Appedix i the form of successive screeshots of the correspodig HTML output. CONCLUSION A set of models of the mai compoets of HVAC air hadlig uits ad air distributio systems has bee developed for use i model-based diagostic tools. The models use simple first priciples relatioships, supplemeted by empirical relatioships, ad have bee desiged to be cofigured usig readily available performace data. The models are implemeted i the freely distributed object-based simulatio eviromet SPARK ad documeted usig the doxyge automated documetatio geerator. The models will be made available at http://cbs.lbl.gov/diagostics/model_library. ACKNOWLEDGMENT This work was supported by the Califoria Eergy Commissio PIER Buildigs Program through the Califoria Istitute for Eergy ad Eviromet ad by the Assistat Secretary for Eergy Efficiecy ad Reewable Eergy, Office of Federal Eergy Maagemet of the U.S. Departmet of Eergy uder Cotract No. DE-AC03-76SF00098. REFERENCES ASHRAE. 004. HVAC Systems ad Euipmet Hadbook, p4.7, America Society of Heatig, Refrigeratig ad Air Coditioig Egieers, Atlata, GA. Brademuehl, M. J., S. Gabel, I. Aderse. 993. A toolkit for secodary HVAC system eergy calculatios, HVAC Toolkit. Prepared for The America Society of Heatig, Refrigeratig ad Air Coditioig Egieers. TC 4.7 Eergy Calculatios. Atlata, GA. ASHRAE. Clark, D. R. 985. HVACSIM+ Buildig Systems ad Euipmet Simulatio Program Referece Maual, US Natioal Istitute for Stadards ad Techology, Gaithersburg, MD 0899. Doxyge 006. http://www.stack.l/~dimitri/doxyge/. Graphviz 006. http://www.graphviz.org/. Holmes, M. J. 98. The simulatio of heatig ad coolig coils for performace aalysis, Proceedigs of System Simulatio i Buildigs '8, Liège, Belgium, December. Klei, S. A., Beckma, W. A. J. A. Duffie. 976. TRNSYS - a trasiet simulatio program, ASHRAE Trasactios, Vol 8, Pt. - 40 -

SPARK 003. Simulatio Problem Aalysis ad Research Kerel. Lawrece Berkeley Natioal Laboratory ad Ayres Sowell Associates, Ic. Dowloadable from http://simulatioresearch.lbl.gov/ Sreedhara, P. ad Haves, P. 00. Compariso of Chiller Models for use i Model-Based Fault Detectio, Proc. Iteratioal Coferece for Ehacig Buildig Operatios, Austi, TX, July Zhou, X.T. 005. Dyamic modelig of chilled water coolig coils. Ph.D. Thesis. Purdue Uiversity. APPENDIX : HTML DOCUMENTATION FOR VALVE.CC APPENDIX I: ATOMIC CLASS VALVE.CC /// \file valve.cc /// \brief Atomic class describig a flow circuit /// with o-liear/suare valve ad series flow /// resistace. /// A cotrol valve varies the fluid flow rate i a /// circuit by varyig its flow resistace. A /// exteral actuator is used to move a plug /// coected to the valve stem /// that restricts the flow to varyig degrees /////////////////////////////////////////////////// /// \par Iterface variables /// - pos Valve positio, betwee 0- /// - mli Mass flow rate /// - A Valve authority, betwee 0- /// - mliope Mass flow rate for ope valve /// - mleak Fractio of m_ope for closed /////////////////////////////////////////////////// /// \par Euatios /// Pseudo-code sippet: /// \code /// Leakpar mleak/mliope /// fiher ((-Leakpar*pos^ + Leakpar^ /// if (fiher!0 fistall /(A/(fIher^ + (-A^0.5 /// else fistall 0 /// mli mliope *fistall /// \edcode /////////////////////////////////////////////////// /// \brief Iverse computig the mass flow rate /// mli from the valve positio pos. /// \retur Mass flow rate [kg/s] /// \param pos Valve positio, betwee 0- /// \param A Valve authority, betwee 0- /// \param mliope Mass flow rate for ope EVALUATE(valve_mLi { } - 4 -