LBL logo


Library with models for comfort


This package contains models for comfort.

Extends from Modelica.Icons.VariantsPackage (Icon for package containing variants).

Package Content

Buildings.Utilities.Comfort.Fanger Fanger Thermal comfort model according to Fanger
Buildings.Utilities.Comfort.Examples Examples Collection of models that illustrate model use and test models

Buildings.Utilities.Comfort.Fanger Buildings.Utilities.Comfort.Fanger

Thermal comfort model according to Fanger



Thermal comfort model according to Fanger, as described in the ASHRAE Fundamentals (1997).

The thermal sensation of a human being is mainly related to the thermal balance of its body as a whole. This balance is influenced by two groups of factors, personal and physical. The activity level and clothing thermal insulation of the subject form the group of personal factors, while the environmental parameters: air temperature, mean radiant temperature, air velocity, and air humidity compose the group of physical factors. When the personal factors have been estimated and the physical factors have been measured the thermal sensation for the body as a whole (general thermal comfort) can be predicted by calculating the PMV index. The PPD index, obtained from the PMV index, provides information on thermal discomfort (thermal dissatisfaction) by predicting the percentage of people likely to feel too hot or too cold in the given thermal environment.

The Predicted Mean Vote (PMV) model combines four physical variables (air temperature, air velocity, mean radiant temperature, and relative humidity), and two personal variables (clothing insulation and activity level) into an index that can be used to predict the average thermal sensation of a large group of people.

To determine appropriate thermal conditions, practitioners refer to standards such as ASHRAE Standard 55 (ASHRAE, 1992) and ISO Standard 7730 (ISO, 1994). These standards define temperature ranges that should result in thermal satisfaction for at least 80% of occupants in a space.

PMV thermal sensation scale

The PMV index predicts the mean value of the votes of a large group of people on the following 7-point thermal sensation scale:
Cold Cool Slightly cool Neutral Slightly warm Warm Hot
-3 -2 -1 0 +1 +2 +3

Operative temperature

For a given space there exists an optimum operative temperature corresponding to PMV=0 (neutral). The operative temperature is defined as: The uniform temperature of an imaginary black enclosure in which an occupant would exchange the same amount of heat by radiation plus convection as in the actual nonuniform environment. The operative temperature is computed as the average of the air temperature and the mean radiant temperature, weighted by their respective heat transfer coefficients (see ASHRAE Fundamentals, 1997, page 8.3, eq (8)).

Optimum operative temperatures

Winter: activity 1.2 met,
clothing = 0.9 clo (sweater, long sleeve shirt, heavy pants),
air flow = 30 fpm (0.15 m/sec),
mean radiant temperature equal to air temperature,
Optimum Operative Temperature (top) = 22.7° C (71° F)

Summer: clothing = 0.5 clo,
air flow = 50 fpm (0.25 m/sec),
Optimum Operative Temperature (top) = 24.4° C (76° F).

All equation numbers in the model refer to the ASHRAE Handbook Fundamentals, Chapter 8, Thermal Comfort, 1997.

Usual ranges of variables (ISO)

M = 46 to 232 W/m^2 (0.8 to 4 met)
ICl = 0 to 2 clo (0 to 0.310 m^2*K/W)
TAir_degC = 10 to 30° C
TRad_degC = 10 to 40° C
vAir = 0 to 1 m/s
pSte = 0 to 2700 Pa

Insulation for clothing ensembles

Clothing is defined in terms of clo units. Clo is a unit used to express the thermal insulation provided by garments and clothing ensembles, where 1 clo = 0.155 (m^2*K/W) (ASHRAE 55-92).

The following table is obtained from ASHRAE page 8.8
Clothing ensembleclo
ASHRAE Standard 55 Winter0.90
ASHRAE Standard 55 Summer0.50
Walking shorts, short-sleeve shirt 0.36
Trousers, long-sleeve shirt 0.61
Trousers, long-sleeve shirt, suit jacket 0.96
Trousers, long-sleeve shirt, suit jacket, T-shirt 1.14
Trousers, long-sleeve shirt, long-sleeve sweater, T-shirt 1.01
Same as above + suit jacket, long underwear bottoms 1.30
Sweat pants, sweat shirt 0.74
Knee-length skirt, short-sleeve shirt, panty hose, sandals 0.54
Knee-length skirt, long-sleeve shirt, full slip, panty hose 0.67
Knee-length skirt, long-sleeve shirt, half slip, panty hose, long sleeve sweater 1.10
Long-sleeve coveralls, T-shirt 0.72
Insulated coveralls, long-sleeve, thermal underwear, long underwear bottoms 1.37

Metabolic rates

One met is defined as 58.2 Watts per square meter which is equal to the energy produced per unit surface area of a seated person at rest.

The following table is obtained from ASHRAE page 8.6.
ActivityW/m2 body surface area
ASHRAE Standard 5558.2
reclining 45
seated and quiet 60
sedentary activity (reading, writing) 60
standing, relaxed 70
office (filling while standing)80
office (walking)100
Sleeping 40
Seated quiet 60
Standing Relaxed 70
Walking 3.2 - 6.4km/h 115-220
Reading 55
Writing 60
Typing 65
Lifting/packing 120
Driving Car 60-115
Driving Heavy vehicle 185
Cooking 95-115
Housecleaning 115-200
Machine work 105-235
Pick and shovel work 235-280
Dancing-Social 140-225
Calisthenics 175-235
Basketball 290-440
Wrestling 410-505


Extends from Buildings.BaseClasses.BaseIcon (Base icon).


HeatFluxW0Rate of mechanical work accomplished (must be non-positive, typically equal to 0) [W/m2]
CoefficientOfHeatTransferhRad0.8*4.7Radiative heat transfer coefficient [W/(m2.K)]
Conditional inputs
Booleanuse_vAir_infalseGet the air velocity from the input connector
Booleanuse_M_infalseGet the metabolic rate from the input connector
Booleanuse_ICl_intrueGet the clothing insulation from the input connector
Booleanuse_pAir_infalseGet the air pressure from the input connector
VelocityvAir0.05Fixed value for air velocity [m/s]
HeatFluxM60Fixed value for metabolic rate [W/m2]
RealICl Fixed value for clothing insulation in units of clo (summer=0.5; winter=0.9)
PressurepAir101325Fixed value for air pressure [Pa]


output RealOutputPMVPMV
output RealOutputPPDPPD [0.05...1]
input RealInputTAirAir temperature [K]
input RealInputTRadRadiation temperature [K]
input RealInputphiRelative humidity
input RealInputpAir_inAir pressure [Pa]
input RealInputICl_inClothing thermal resistance in clo
input RealInputvAir_inAir velocity
input RealInputM_inMetabolic heat generation in W/m2 (not in met) [W/m2]

Modelica definition

model Fanger "Thermal comfort model according to Fanger"
extends Buildings.BaseClasses.BaseIcon;

  Modelica.Blocks.Interfaces.RealOutput PMV "PMV";
  Modelica.Blocks.Interfaces.RealOutput PPD "PPD [0.05...1]";

  parameter Modelica.SIunits.HeatFlux W(max=0)=0 
    "Rate of mechanical work accomplished (must be non-positive, typically equal to 0)";
  parameter Modelica.SIunits.CoefficientOfHeatTransfer hRad(
    max=10)=0.8*4.7 "Radiative heat transfer coefficient";

  parameter Boolean use_vAir_in=false 
    "Get the air velocity from the input connector";
  parameter Boolean use_M_in= false 
    "Get the metabolic rate from the input connector";
  parameter Boolean use_ICl_in= true 
    "Get the clothing insulation from the input connector";
  parameter Boolean use_pAir_in= false 
    "Get the air pressure from the input connector";

  parameter Modelica.SIunits.Velocity vAir= 0.05 "Fixed value for air velocity";
  parameter Modelica.SIunits.HeatFlux M = 60 "Fixed value for metabolic rate";
  parameter Real ICl 
    "Fixed value for clothing insulation in units of clo (summer=0.5; winter=0.9)";
  parameter Modelica.SIunits.Pressure pAir = 101325 
    "Fixed value for air pressure";

  Modelica.Blocks.Interfaces.RealInput TAir(final quantity="Temperature",
                                          final unit = "K", displayUnit = "degC") 
    "Air temperature";
  Modelica.Blocks.Interfaces.RealInput TRad(final quantity="Temperature",
                                          final unit = "K", displayUnit = "degC") 
    "Radiation temperature";

  Modelica.SIunits.Temperature TOpe "Operative temperature";
  Modelica.SIunits.Temperature TClo "Surface temperature of clothing";
  Modelica.SIunits.Temperature TSki(
    max=273.15+42) "Skin temperature";

  Modelica.Blocks.Interfaces.RealInput phi(min=0, max=1) "Relative humidity";
  Modelica.Blocks.Interfaces.RealInput pAir_in(
    final quantity="Pressure",
    final unit="Pa",
    min=0) if use_pAir_in "Air pressure";
  Modelica.Blocks.Interfaces.RealInput ICl_in if use_ICl_in 
    "Clothing thermal resistance in clo";
  Modelica.Blocks.Interfaces.RealInput vAir_in if 
       use_vAir_in "Air velocity";
  Modelica.Blocks.Interfaces.RealInput M_in(
    final quantity="HeatFlux",
    final unit="W/m2") if use_M_in 
    "Metabolic heat generation in W/m2 (not in met)";

  Modelica.SIunits.CoefficientOfHeatTransfer hCom(
    max=10) "Combined heat transfer coefficient";

  Modelica.SIunits.CoefficientOfHeatTransfer hCon(
    max=10) "Convective heat transfer coefficient";

  Modelica.SIunits.Pressure pSte(
    max=3000) "Partial pressure of water vapor in ambient air";

  Modelica.SIunits.HeatFlux L "Thermal load of the body";
  Real fCl(min=0) "Clothing area factor (61)";
  Modelica.SIunits.ThermalInsulance RCl "Thermal resistance of clothing (10)";

  Buildings.Utilities.Psychrometrics.X_pTphi steRat(
   redeclare package Medium = Buildings.Media.PerfectGases.MoistAir) 
    "Model to compute the steam mass fraction";
  Real fCl1 "work variable for fCl";
  Real fCl2 "work variable for fCl";
  Real aux "Auxiliary variable used to eliminate common subexpressions";

  Modelica.Blocks.Interfaces.RealInput vAir_in_internal 
    "Needed to connect to conditional connector";
    Modelica.Blocks.Interfaces.RealInput M_in_internal(
    final quantity="HeatFlux",
    final unit="W/m2") "Needed to connect to conditional connector";
  Modelica.Blocks.Interfaces.RealInput ICl_in_internal 
    "Needed to connect to conditional connector";
  Modelica.Blocks.Interfaces.RealInput pAir_in_internal(
    final quantity="Pressure",
    final unit="Pa",
    min=0) "Needed to connect to conditional connector";

initial equation 
 assert(W <= 0, "Parameter W must be equal to zero or negative.");
  // Conditional connectors
  connect(vAir_in, vAir_in_internal);
  if not use_vAir_in then
    vAir_in_internal = vAir;
  end if;
  connect(M_in, M_in_internal);
  if not use_M_in then
    M_in_internal = M;
  end if;
  connect(ICl_in, ICl_in_internal);
  if not use_ICl_in then
    ICl_in_internal = ICl;
  end if;
  connect(pAir_in, pAir_in_internal);
  if not use_pAir_in then
    pAir_in_internal = pAir;
  end if;

  TSki = 308.85 - 0.0275*(M_in_internal - W);

  // partial pressure of steam
  steRat.p_in = pAir_in_internal;
  connect(steRat.T, TAir);
  connect(steRat.phi, phi);
  pSte = Psychrometrics.Functions.pW_X(X_w=steRat.X[1], p=pAir_in_internal);

  // clothing insulation value
  RCl = 0.155 * ICl_in_internal;
  // clothing area factor
  fCl1 = 1.00 + 0.2*ICl_in_internal;
  fCl2 = 1.05 + 0.1*ICl_in_internal;

  // fcl eq (61)
  fCl = fCl1 + (fCl2 - fCl1)*Buildings.Utilities.Math.Functions.smoothHeaviside(
                                 x=(ICl_in_internal - 0.5), delta=0.01);
  // hCon, table 6, Mitchell
  hCon = 8.3*Buildings.Utilities.Math.Functions.smoothMax(x1=vAir_in_internal*vAir_in_internal,
  hCom = hRad + hCon;

  // operative temperature (8)
  TOpe = (hRad*TRad + hCon*TAir)/hCom;

  // Clothing temperature (59)
  aux = - 3.05*(5.73 - 0.007*(M_in_internal - W) - pSte*1E-3)
        - 0.42*((M_in_internal - W) - 58.15)
        - 0.0173*M_in_internal*(5.87 - pSte*1E-3)
        - 0.0014*M_in_internal*(307.15 - TAir);

  TClo = Modelica.SIunits.Conversions.from_degC(35.7 - 0.0275 * (M_in_internal-W)
                 - RCl * (  (M_in_internal-W)
                 + aux));
  // heat load on body, see (58)
  L = (M_in_internal - W)
      - 3.96*1e-8*fCl*(TClo^4 - TRad^4)
      - fCl*hCon*(TClo - TAir)
      + aux;

  // PMV (62)
  PMV = (0.303*Modelica.Math.exp(-0.036*M) + 0.028)*L;
  // PPD (64)
  PPD = 1 - 0.95*Modelica.Math.exp(-(0.03353*PMV^4 + 0.2179*PMV^2));
end Fanger;

Automatically generated Wed Feb 29 16:55:13 2012.