/* * physical constants used by Cloudy, taken from * Physics Today Aug '96, BG 10 * Cohen Taylor 1986 Codata, see physics today, Aug '96, p BG11 */ /*#include "physconst.h"*/ /********************************************************************* * first come math constants * *********************************************************************/ /* pi */ #define PI 3.141592654 /* 4\pi */ #define PI4 12.566371 /* sqrt(pi) */ #define SQRTPI 1.7724539 /********************************************************************* * astronomical constants go here * *********************************************************************/ /* solar mass in grams */ #define SOLAR_MASS 1.9892e33 /* cm in parsec */ #define PARSEC 3.085678e18 /********************************************************************* * fundamental constants go next, eventually rest should be defined * * in terms of these * *********************************************************************/ /* atomic mass unit, grams */ #define ATOMIC_MASS_UNIT 1.6605402e-24 /* electron mass, grams */ #define ELECTRON_MASS 9.109389754e-28 /* proton mass, grams */ #define PROTON_MASS 1.672623110e-24 /* this is the Boltzmann factor, erg/K */ #define BOLTZMANN 1.380658e-16 /* speed of light, cm/s */ #define SPEEDLIGHT 2.99792458e10 /* Planck's constant */ #define HPLANCK 6.6260755E-27 /********************************************************************* * below here should be derived constants * *********************************************************************/ /* this is the factor that appears in front of boltzmann factor to get * LTE level populations for hydrogenic ions. It is givin in the * first parts of section 5 of part 2 of hazy, and is actually * ( planck^2 / (2 pi m_e k ) )^3/2, but cannot evaluate powers here, * must raise this to 3/2 when used */ #define HION_LTE_POP (HPLANCK*HPLANCK/2./PI/BOLTZMANN/ELECTRON_MASS) /* 1 cm wavenumber in ergs */ #define ERG1CM 1.98644746e-16 /* ionization potential of real hydrogen atom, in inf mass ryd */ #define HIONPOT 0.999466508 /* saha is ( h^2/2/pi/m/k )^1.5, is correct constant for free electron */ #define SAHA 4.141296e-16 /* degrees kelvin per unit wavenumber */ #define T1CM 1.438769 /* conversion factor from wavenumbers to degrees kelvin - never used */ /*#define WAVNKELV 1.43883*/ /* 1 infinite mass Rydberg unit in Angrstroms */ #define RYDLAM 911.26732 /* the temperature of 1 Rydberg */ /* te1ryd is h/k is temp of 1 Rydberg, HOKCGS*nu(912), note that RYDLAM is * in Ang but SPEEDLIGHT in cm/s */ #define TE1RYD (HPLANCK*SPEEDLIGHT*1e8/RYDLAM/BOLTZMANN) /*1.578866e5*/ /* number of Ryd per wavenumber, from Physics Today '96, BG 10 */ #define WAVNRYD 9.112670534e-6 /* 1 eV in Kelvin, from Physics Today Aug '96, BG13 */ #define EVDEGK 1.1604448e4 /* inf mass energy of 1 Ryd in ergs */ #define EN1RYD 2.179874e-11 /* 1 Ryd (inf mass nucleus) in eV */ #define EVRYD 13.6056982 /* frequency of one Ryd for infinite mass nuclei */ #define FR1RYD 3.289841950e15 /* frequency of ionization potential of Hydrogen */ #define FR1RYDHYD 3.289841950e15 /*2 h nu^2 /c^2 for infinite mass nucleus */ #define HNU3C2 0.52501302 /* wavelength (A) of ionization potential of Hydrogen */ #define RYDLAMHYD 911.6