cloudy  trunk
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
two_photon.h
Go to the documentation of this file.
1 /* This file is part of Cloudy and is copyright (C)1978-2017 by Gary J. Ferland and
2  * others. For conditions of distribution and use see copyright notice in license.txt */
3 
4 #ifndef TWO_PHOTON_H_
5 #define TWO_PHOTON_H_
6 
7 class TransitionProxy;
8 
9 class two_photon
10 {
11 public:
13  {
14  ipHi = -1;
15  ipLo = -1;
16  Pop = NULL;
17  E2nu = 0.;
18  AulTotal = 0.f;
19  ipTwoPhoE = -1;
20  ipSym2nu.clear();
21  As2nu.clear();
22  local_emis.clear();
23  induc_up = 0.;
24  induc_dn = 0.;
25  induc_dn_max = 0.;
26  }
27 
28  void Reset()
29  {
30  induc_up = 0.;
31  induc_dn = 0.;
32  induc_dn_max = 0.;
33  }
34 
35  long ipHi, ipLo;
36  double* Pop;
37  double E2nu;
39 
40  // pointer to the energy representing the two-photon gap,
41  long ipTwoPhoE;
42 
43  // series of symmetric indices for two photon
44  vector<long> ipSym2nu;
45  // two photon transition probabilities per energy bin
46  vector<realnum> As2nu;
47  // local emission per ( photons cm-3 s-1 bin-1 )
48  vector<realnum> local_emis;
49 
50  // the induced upward two-photon rate
51  double induc_up;
52  // the induced downward two-photon rate
53  double induc_dn;
54  // the largest induced downward two photon rate
55  double induc_dn_max;
56 };
57 
59 
66 double atmdat_2phot_shapefunction( double EbyE2nu, long ipISO, long nelem );
67 
68 void CalcTwoPhotonRates( two_photon& tnu, bool lgDoInduced );
69 void CalcTwoPhotonEmission( two_photon& tnu, bool lgDoInduced );
70 
71 void PrtTwoPhotonEmissCoef( const two_photon& tnu, const double& densityProduct );
72 
73 // note the default values for the last two parameters -- the code uses HI 2s-1s shapefunctions by default
74 void TwoPhotonSetup( vector<two_photon> &tnu_vec, const long &ipHi, const long &ipLo, const double &Aul, const TransitionProxy &tr, const long ipISO, const long nelem );
75 
76 #endif /* TWO_PHOTON_H_ */
double induc_dn
Definition: two_photon.h:53
double induc_up
Definition: two_photon.h:51
realnum AulTotal
Definition: two_photon.h:38
double induc_dn_max
Definition: two_photon.h:55
long ipTwoPhoE
Definition: two_photon.h:41
void PrtTwoPhotonEmissCoef(const two_photon &tnu, const double &densityProduct)
Definition: two_photon.cpp:157
long ipHi
Definition: two_photon.h:35
float realnum
Definition: cddefines.h:124
double * Pop
Definition: two_photon.h:36
void Reset()
Definition: two_photon.h:28
vector< long > ipSym2nu
Definition: two_photon.h:44
void CalcTwoPhotonRates(two_photon &tnu, bool lgDoInduced)
Definition: two_photon.cpp:84
void atmdat_2phot_setSplineCoefs()
long ipLo
Definition: two_photon.h:35
void TwoPhotonSetup(vector< two_photon > &tnu_vec, const long &ipHi, const long &ipLo, const double &Aul, const TransitionProxy &tr, const long ipISO, const long nelem)
Definition: two_photon.cpp:10
vector< realnum > local_emis
Definition: two_photon.h:48
vector< realnum > As2nu
Definition: two_photon.h:46
double E2nu
Definition: two_photon.h:37
void CalcTwoPhotonEmission(two_photon &tnu, bool lgDoInduced)
Definition: two_photon.cpp:125
double atmdat_2phot_shapefunction(double EbyE2nu, long ipISO, long nelem)