# This file was automatically generated by SWIG (http://www.swig.org).
# Version 2.0.8
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.



from sys import version_info
if version_info >= (2,6,0):
    def swig_import_helper():
        from os.path import dirname
        import imp
        fp = None
        try:
            fp, pathname, description = imp.find_module('_HumidAirProp', [dirname(__file__)])
        except ImportError:
            import _HumidAirProp
            return _HumidAirProp
        if fp is not None:
            try:
                _mod = imp.load_module('_HumidAirProp', fp, pathname, description)
            finally:
                fp.close()
            return _mod
    _HumidAirProp = swig_import_helper()
    del swig_import_helper
else:
    import _HumidAirProp
del version_info
try:
    _swig_property = property
except NameError:
    pass # Python < 2.2 doesn't have 'property'.
def _swig_setattr_nondynamic(self,class_type,name,value,static=1):
    if (name == "thisown"): return self.this.own(value)
    if (name == "this"):
        if type(value).__name__ == 'SwigPyObject':
            self.__dict__[name] = value
            return
    method = class_type.__swig_setmethods__.get(name,None)
    if method: return method(self,value)
    if (not static):
        self.__dict__[name] = value
    else:
        raise AttributeError("You cannot add attributes to %s" % self)

def _swig_setattr(self,class_type,name,value):
    return _swig_setattr_nondynamic(self,class_type,name,value,0)

def _swig_getattr(self,class_type,name):
    if (name == "thisown"): return self.this.own()
    method = class_type.__swig_getmethods__.get(name,None)
    if method: return method(self)
    raise AttributeError(name)

def _swig_repr(self):
    try: strthis = "proxy of " + self.this.__repr__()
    except: strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)

try:
    _object = object
    _newclass = 1
except AttributeError:
    class _object : pass
    _newclass = 0


GIVEN_TDP = _HumidAirProp.GIVEN_TDP
GIVEN_HUMRAT = _HumidAirProp.GIVEN_HUMRAT
GIVEN_TWB = _HumidAirProp.GIVEN_TWB
GIVEN_RH = _HumidAirProp.GIVEN_RH
GIVEN_ENTHALPY = _HumidAirProp.GIVEN_ENTHALPY
GIVEN_T = _HumidAirProp.GIVEN_T
GIVEN_P = _HumidAirProp.GIVEN_P
GIVEN_VISC = _HumidAirProp.GIVEN_VISC
GIVEN_COND = _HumidAirProp.GIVEN_COND

def HAProps(*args):
  """
    Copyright Ian Bell, 2011 email: ian.h.bell@gmail.com

    The function is called like

    HAProps('H','T',298.15,'P',101.325,'R',0.5)

    which will return the enthalpy of the air for a set of inputs of dry bulb temperature of 25C, atmospheric pressure, and a relative humidity of 50%.

    This function implements humid air properties based on the analysis in ASHRAE RP-1845 which is available online: http://rp.ashrae.biz/page/ASHRAE-D-RP-1485-20091216.pdf

    It employs real gas properties for both air and water, as well as the most accurate interaction parameters and enhancement factors.  The IAPWS-95 formulation for the properties of water is used throughout in preference to the industrial formulation.  It is unclear why the industrial formulation is used in the first place.

    Since humid air is nominally a binary mixture, three variables are needed to fix the state.  At least one of the input parameters must be dry-bulb temperature, relative humidity, dew-point temperature, or humidity ratio.  The others will be calculated.  If the output variable is a transport property (conductivity or viscosity), the state must be able to be found directly - i.e. make sure you give temperature and relative humidity or humidity ratio.  The list of possible input variables are

    ========  ========    ========================================
    String    Aliases     Description
    ========  ========    ========================================
    T         Tdb         Dry-Bulb Temperature [K]
    B         Twb         Wet-Bulb Temperature [K]
    D         Tdp         Dew-Point Temperature [K]
    P                     Pressure [kPa]
    V         Vda         Mixture volume [m3/kg dry air]
    R         RH          Relative humidity in (0,1) [-]
    W         Omega       Humidity Ratio [kg water/kg dry air]
    H         Hda         Mixture enthalpy [kJ/kg dry air]
    C         cp          Mixture specific heat [kJ/kg dry air/K]
    M         Visc        Mixture viscosity [Pa-s]
    K                     Mixture thermal conductivity [W/m/K]
    ========  ========    ========================================

    There are also strings for the mixture volume and mixture enthalpy that will return the properties on a total humid air flow rate basis, they are given by 'Vha' [units of m^3/kg humid air] and 'Cha' [units of kJ/kg humid air/K] and 'Hha' [units of kJ/kg humid air] respectively.

    For more information, go to http://coolprop.sourceforge.net

    """
  return _HumidAirProp.HAProps(*args)

def HAProps_Aux(*args):
  """
    Allows low-level access to some of the routines employed in HumidAirProps

    Returns tuples of the form (Value, Units) where value is the actual value and Units is a string that describes the units

    The list of possible inputs is

    * Baa
    * Caaa
    * Bww
    * Cwww
    * Baw
    * Caww
    * Caaw
    * beta_H
    * kT
    * vbar_ws
    * p_ws
    * f

    """
  return _HumidAirProp.HAProps_Aux(*args)

def IceProps(*args):
  """IceProps(char * Name, double T, double p) -> double"""
  return _HumidAirProp.IceProps(*args)

def UseVirialCorrelations(*args):
  """
    To turn on the use of virial correlations rather than the EOS for air and water Baa Caaa Bww Cwww, call UseVirialCorrelations(True), or to turn off, call UseVirialCorrelations(False).  The error in virial coefficients is usually less than 1e-6 relative error.

    The default value is to use the full EOS - i.e. UseVirialCorrelations(False).

    """
  return _HumidAirProp.UseVirialCorrelations(*args)

def UseIsothermCompressCorrelation(*args):
  """UseIsothermCompressCorrelation(int flag)"""
  return _HumidAirProp.UseIsothermCompressCorrelation(*args)

def UseIdealGasEnthalpyCorrelations(*args):
  """UseIdealGasEnthalpyCorrelations(int flag)"""
  return _HumidAirProp.UseIdealGasEnthalpyCorrelations(*args)

def HAHelp():
  """HAHelp()"""
  return _HumidAirProp.HAHelp()

def returnHumAirCode(*args):
  """returnHumAirCode(char * Code) -> int"""
  return _HumidAirProp.returnHumAirCode(*args)

def cair_sat(*args):
  """cair_sat(double T) -> double"""
  return _HumidAirProp.cair_sat(*args)
# This file is compatible with both classic and new-style classes.


