PartMC  2.1.5
constants.F90
Go to the documentation of this file.
00001 ! Copyright (C) 2005-2009 Nicole Riemer and Matthew West
00002 ! Licensed under the GNU General Public License version 2 or (at your
00003 ! option) any later version. See the file COPYING for details.
00004 
00005 !> \file
00006 !> The pmc_constants module.
00007 
00008 !> Physical constants.
00009 module pmc_constants
00010 
00011   !> Kind of a double precision real number.
00012   integer, parameter :: dp = kind(0.d0)
00013   !> Kind of a double precision complex number.
00014   integer, parameter :: dc = dp
00015 
00016   !> Physical constants.
00017   !!
00018   !! These are all absolute constants. Environment parameters that in
00019   !! principle could change should go in env_data.f90.
00020   !!
00021   !! To access a constant in a subroutine you should <tt>use
00022   !! pmc_constants</tt> and then the constant value is accessed with
00023   !! \c const%%pi or similar. Note that the type is called \c const_t
00024   !! (with a trailing _t) but the single saved variable to access them
00025   !! is just called \c const.
00026   type const_t
00027      !> Pi.
00028      real(kind=dp) :: pi = 3.14159265358979323846d0
00029      !> Boltzmann constant (J K^{-1}).
00030      real(kind=dp) :: boltzmann = 1.3806505d-23
00031      !> Avogadro's number (mole^{-1}).
00032      real(kind=dp) :: avagadro = 6.02214179d23
00033      !> Universal gas constant (J mole^{-1} K^{-1}).
00034      real(kind=dp) :: univ_gas_const = 8.314472d0
00035      !> Accomodation coefficient (have also used 0.045).
00036      real(kind=dp) :: accom_coeff = 1d0
00037 
00038      !> Equilibrium water vapor pressure at 273 K (Pa).
00039      real(kind=dp) :: water_eq_vap_press = 611d0
00040      !> Freezing point of water (K).
00041      real(kind=dp) :: water_freeze_temp = 273.15d0
00042      !> Surface energy of water (J m^{-2}).
00043      real(kind=dp) :: water_surf_eng = 0.073d0
00044      !> Latent heat of water (J kg^{-1}).
00045      real(kind=dp) :: water_latent_heat = 2.272d6
00046      !> Specific heat of air (J kg^{-1} K^{-1}).
00047      real(kind=dp) :: air_spec_heat = 1005d0
00048      !> Molecular weight of water (kg mole^{-1}).
00049      real(kind=dp) :: water_molec_weight = 18d-3
00050      !> Density of water (kg m^{-3}).
00051      real(kind=dp) :: water_density = 1d3
00052 
00053      !> Molecular weight of air (kg mole^{-1}).
00054      real(kind=dp) :: air_molec_weight = 2.89644d-2
00055      !> Atmospheric standard sea level pressure (Pa).
00056      real(kind=dp) :: air_std_press = 101325d0
00057      !> Dynamic viscosity of air (kg m^{-1} s^{-1}).
00058      real(kind=dp) :: air_dyn_visc = 1.78d-5
00059   end type const_t
00060 
00061   !> Fixed variable for accessing the constant's values.
00062   !!
00063   !! To access a constant in a subroutine you should <tt>use
00064   !! pmc_constants</tt> and then the constant value is accessed with
00065   !! \c const%%pi or similar. Note that the type is called \c const_t
00066   !! (with a trailing _t) but the single saved variable to access them
00067   !! is just called \c const.
00068   type(const_t), save :: const
00069 
00070 end module pmc_constants