cloudy  trunk
cool_magn.cpp
Go to the documentation of this file.
1 /* This file is part of Cloudy and is copyright (C)1978-2013 by Gary J. Ferland and
2  * others. For conditions of distribution and use see copyright notice in license.txt */
3 /*CoolMagn compute magnesium cooling */
4 #include "cddefines.h"
5 #include "coolheavy.h"
6 #include "taulines.h"
7 #include "phycon.h"
8 #include "dense.h"
9 #include "ligbar.h"
10 #include "lines_service.h"
11 #include "atoms.h"
12 #include "cooling.h"
13 
14 void CoolMagn(void)
15 {
16  realnum cs,
17  csdum,
18  csoi;
19  double cs2s2p,
20  cs2s3p;
21 
22  DEBUG_ENTRY( "CoolMagn()" );
23 
24  /* Mg I 2853
25  * fit to Dima's integration of
26  * >>refer mg1 cs Leep, D., & Gallagher, A. 1976, Phys Rev A, 13, 148 */
27  cs = (realnum)(5.21e-4*phycon.te/phycon.te10);
30 
31  /* Mg I 2026, */
34 
35  /* Mg 1 4571, data from Mendoza
36  * >>refer mg1 as Mendoza, C. 1982, in Planetary Nebulae, IAU Symp No. 103,
37  * >>refercon ed by D.R. Flower, (D. Reidel: Holland), 143
38  * cs set to O I */
39  csoi = (realnum)(2.68e-5*phycon.te*(1. + 1.67e-6*phycon.te - 2.95e-10*phycon.te*
40  phycon.te));
41  csoi = (realnum)MAX2(0.1,csoi);
42  PutCS(csoi/9.,TauLines[ipT4561]);
44 
45  /* Mg II 2798
46  * cs from
47  * >>refer mg2 cs Sigut, A., & Pradhan, A.K., 1994, J Phys B sub
48  * refer not publ as of '97, cs agrees fairly well with Harrington et al.
49  * previous reference (~'82) */
50  cs2s2p = 4.50*phycon.te10;
51  PutCS(cs2s2p,TauLines[ipT2796]);
52  PutCS(cs2s2p*0.5,TauLines[ipT2804]);
53  PutCS(1.0,*TauDummy);
55  /* call PutCS( cs , t2800 )
56  * call atom_level2( t2800 )
57  *
58  * following used in MAGNES for photo destruction rate */
59  if( atoms.PopLevels[0] > 0. )
60  {
62  atoms.PopLevels[0]);
63  }
64  else
65  {
66  atoms.popmg2 = 0.;
67  }
68 
69  /* MG IV 4.487 MIC
70  * cs
71  * >>referold mg4 cs Saraph, H.E. & Tully, J.A. 1994, A&AS, 107, 29 */
72  /*cs = (realnum)MIN2(0.425,0.180*phycon.te05*phycon.te02);
73  cs = (realnum)MAX2(0.356,cs);*/
74  /* >>chng 06 jul 06-Humeshkar Nemala*/
75  /*>> refer Mg IV cs Berrington,K.A., Saraph,H. E., & Tully, J.A. 1998,A&AS,129,161 */
76  /*This is the cs of the transition between the levels of 2P^o term(J=1/2 - J=3/2)*/
77  if(phycon.te < 4E5)
78  {
79  cs = (realnum)(0.155*phycon.te07*phycon.te01*
81  }
82  else
83  {
84  cs = (realnum)(5.124/((phycon.te20/phycon.te02)*
86  }
87  PutCS(cs,TauLines[ipTMg4]);
88 
90 
91  /* MG V 5.61, 13.54 micron,
92  * >>refer mg5 cs Butler, K., & Zeippen, C.J. 1994, A&AS, 108, 1
93  * >>chng 96 jul 16 had been constant 0.3 */
94  cs = (realnum)MIN2(0.311,0.11*phycon.te10);
95  PutCS(cs,TauLines[ipTMg14]);
96 
97  cs = (realnum)MIN2(1.06,0.339*phycon.te10);
98  PutCS(cs,TauLines[ipTMg6]);
99  /* >>chng 96 jul 16 had been constant 0.3 */
100  cs = (realnum)MIN2(0.297,0.0745*phycon.te10*phycon.te02);
101  PutCS(cs,*TauDummy);
103 
104  /* [Mg V] 2751+2893- Ne III-like, cs
105  * >>refer mg5 as Mendoza, C., & Zeippen, C.J. 1987, MNRAS, 224, 7p
106  * >>chng 96 aug 5 to three level atom
107  * c2751 = atom_pop2(1.33,9.,5.,2.4,5.14e4,xmg(5))*7.11e-12
108  * dCooldT = dCooldT + c2751*5.14e4*tsq1
109  * call CoolAdd( 'Mg 5' , 2751 , C2751 )
110  *
111  * following is 2-1 transition, both 2928 and 2783,
112  * >>refer mg5 cs Butler, K., & Zeippen, C.J. 1994, A&AS, 108, 1 */
113  PutCS(1.187,TauLines[ipxMg52855]);
114 
115  cs = (realnum)MIN2(0.278,0.0171*phycon.te20*phycon.te05/
117  cs = (realnum)MAX2(0.182,cs);
118 
119  /* 3-2 transition, 2417.5 */
121 
122  /* 3-1 transition, 1324.58 */
123  PutCS(0.153,TauLines[ipxMg51325]);
124 
126 
127  /* Mg VI, 1806- OII like, data
128  * >>refer mg6 all Kafatos, M., & Lynch, J.P. 1980, ApJS, 42, 611 */
129  /* >>refer mg6 as Becker, Butler, Zeippen, 1989, A&A 221, 375
130  * >>refer mg6 cs Ramsbottom & Bell 1997, A&AS 125, 543 */
131  CoolHeavy.c1806 = atom_pop2(0.6,4.,10.,0.1,7.974e4,dense.xIonDense[ipMAGNESIUM][5])*
132  1.11e-11;
133  CoolAdd("Mg 6",1806,CoolHeavy.c1806);
134 
135  /* [Mg VII] IR lines at 5.517 and 9.03 microns,
136  * carbon-like,
137  * >>refer mg7 cs Lennon, D.J. Burke, V.M. 1994, A&AS, 103, 273 */
138  if( phycon.alogte < 4.4 )
139  {
141  }
142  else
143  {
144  cs = 0.44f;
145  }
146  PutCS(cs,TauLines[ipfsMg790]);
147  if( phycon.alogte < 4.6 )
148  {
149  cs = (realnum)(MIN2(1.456,0.0577*phycon.te30*phycon.te02/phycon.te001/
150  phycon.te001));
151  csdum = (realnum)(8.275e-3*phycon.sqrte/phycon.te10/phycon.te001);
152  }
153  else
154  {
156  csdum = (realnum)(1.456/(phycon.te10*phycon.te01*phycon.te005));
157  }
158  PutCS(cs,TauLines[ipfsMg755]);
159  PutCS(csdum,*TauDummy);
160  /* atom_level3( t10,t21,t20) */
162 
163  /* [mg vii] 2510, 2629
164  * c2596 = atom_pop2( 1.7,9.,5.,10.,5.76e4,dense.xIonDense(12,7))*7.96e-12
165  * dCooldT = dCooldT + c2596 * 5.76e4*tsq1
166  * call CoolAdd( 'Mg 7' , 2596 , C2596 )
167  *
168  * >>chng 96 aug 5, converted to 3 level atom */
169  cs = (realnum)MIN2(0.22,0.3622/(phycon.te05*phycon.te02*phycon.te003));
171 
172  /* 2-1 transitions, 2509.2A+2629.1A together */
173  cs = (realnum)MIN2(1.067,0.247*phycon.te10*phycon.te03*phycon.te005);
175 
176  /* 3-2 transition, 2261.5A */
177  cs = (realnum)MIN2(0.542,3.863/(phycon.te20*phycon.te03*
179  cs = (realnum)MAX2(0.3735,cs);
181 
183  /* atom_level3( t10,t21,t20)
184  *
185  * Mg VIII 3.03 micron, data from
186  * >>refer mg8 as Chandra, S. 1982, SoPh, 75, 133
187  * cs from
188  * >>refer mg8 cs Zhang, H.L., Graziani, M., Pradhan, A.K. 1994, A&A, 283, 319 */
189  PutCS(1.0,TauLines[ipxMg08303]);
191  /* fs303 = atom_pop2(0.26,2.,4.,0.324,4752.,xmg(8))*6.58E-13
192  * call CoolAdd( 'Mg 8' , 303 , FS303 )
193  *
194  * Mg IX 704.5, 1909-like, A from
195  * >>refer mg9 as Muhlethaler, H.P., & Nussbaumer, H. 1976, A&A 48, 109
196  * AtomSeqBeryllium line, cs data from
197  * >>refer mg9 cs Keenan, F.P. Berrington, K.A., Burke, P.G., Dufton, P.L.,
198  * >>refercon Kingston, A.E. 1986, PhyS 34, 216
199  * A's
200  * >>refer mg9 as Fleming, J., Bell, K.L, Hibbert, A., Vaeck, N., Godefroid, M.R.
201  * >>refercon 1996, MNRAS, 279, 1289 */
203  cs = (realnum)(0.98288 - 0.23766*phycon.alogte + 0.014334*POW2(phycon.alogte));
204  cs = (realnum)MAX2(0.01,cs);
205  PutCS(cs,TauLines[ipT705]);
207 
208  /* Mg X 610
209  * >>refer mg10 cs Cochrane, D.M., & McWhirter, R.W.P. 1983, PhyS, 28, 25 */
210  ligbar(12,TauLines[ipTMg610],TauLines[ipT58],&cs2s2p,&cs2s3p);
211  PutCS(cs2s2p,TauLines[ipTMg610]);
212  PutCS(cs2s2p*0.5,TauLines[ipTMg625]);
213  PutCS(1.0,*TauDummy);
215 
216  /* Mg X 58A */
217  PutCS(cs2s3p,TauLines[ipT58]);
219  return;
220 }
t_atoms::popmg2
realnum popmg2
Definition: atoms.h:262
atom_pop2
double atom_pop2(double omega, double g1, double g2, double a21, double bltz, double abund)
Definition: atom_pop2.cpp:9
dense
t_dense dense
Definition: dense.cpp:24
ipxMg52417
long ipxMg52417
Definition: atmdat_readin.cpp:60
atoms.h
MakeCS
void MakeCS(const TransitionProxy &t)
Definition: transition.cpp:613
t_phycon::te001
double te001
Definition: phycon.h:67
realnum
float realnum
Definition: cddefines.h:103
t_phycon::te07
double te07
Definition: phycon.h:56
ipT2804
long ipT2804
Definition: atmdat_readin.cpp:59
ipfsMg755
long ipfsMg755
Definition: atmdat_readin.cpp:64
atom_level3
void atom_level3(const TransitionProxy &t10, const TransitionProxy &t21, const TransitionProxy &t20)
Definition: atom_level3.cpp:15
ipMAGNESIUM
const int ipMAGNESIUM
Definition: cddefines.h:316
t_phycon::te03
double te03
Definition: phycon.h:59
phycon
t_phycon phycon
Definition: phycon.cpp:6
t_phycon::te005
double te005
Definition: phycon.h:63
lines_service.h
ipTMg6
long ipTMg6
Definition: atmdat_readin.cpp:63
CoolAdd
void CoolAdd(const char *chLabel, realnum lambda, double cool)
Definition: cool_etc.cpp:13
ipTMg14
long ipTMg14
Definition: atmdat_readin.cpp:63
ipT58
long ipT58
Definition: atmdat_readin.cpp:63
ipxMg72569
long ipxMg72569
Definition: atmdat_readin.cpp:62
POW2
#define POW2
Definition: cddefines.h:929
ligbar
void ligbar(long int ized, const TransitionProxy &t2s2p, const TransitionProxy &t2s3p, double *cs2s2p, double *cs2s3p)
Definition: atmdat_ligbar.cpp:11
MIN2
#define MIN2
Definition: cddefines.h:761
ipT4561
long ipT4561
Definition: atmdat_readin.cpp:60
ipMgI2853
long ipMgI2853
Definition: atmdat_readin.cpp:58
ipfsMg790
long ipfsMg790
Definition: atmdat_readin.cpp:64
dense.h
coolheavy.h
t_phycon::te01
double te01
Definition: phycon.h:61
cooling.h
ipxMg08303
long ipxMg08303
Definition: atmdat_readin.cpp:62
cddefines.h
atoms
t_atoms atoms
Definition: atoms.cpp:5
t_phycon::te0005
double te0005
Definition: phycon.h:73
TauDummy
TransitionProxy::iterator TauDummy
Definition: taulines.cpp:60
ipT705
long ipT705
Definition: atmdat_readin.cpp:60
t_phycon::te02
double te02
Definition: phycon.h:60
ipMgI2026
long ipMgI2026
Definition: atmdat_readin.cpp:59
PutCS
void PutCS(double cs, const TransitionProxy &t)
Definition: transition.cpp:317
ipxMg52855
long ipxMg52855
Definition: atmdat_readin.cpp:61
ipT2796
long ipT2796
Definition: atmdat_readin.cpp:59
MAX2
#define MAX2
Definition: cddefines.h:782
t_phycon::te30
double te30
Definition: phycon.h:53
ipTMg625
long ipTMg625
Definition: atmdat_readin.cpp:62
t_CoolHeavy::c1806
double c1806
Definition: coolheavy.h:53
t_dense::xIonDense
double xIonDense[LIMELM][LIMELM+1]
Definition: dense.h:125
TauLines
TransitionList TauLines("TauLines", &AnonStates)
CoolMagn
void CoolMagn(void)
Definition: cool_magn.cpp:14
t_phycon::te007
double te007
Definition: phycon.h:62
t_phycon::te003
double te003
Definition: phycon.h:65
t_phycon::te10
double te10
Definition: phycon.h:55
ipxMg72261
long ipxMg72261
Definition: atmdat_readin.cpp:61
t_phycon::te0001
double te0001
Definition: phycon.h:69
ligbar.h
atom_level2
void atom_level2(const TransitionProxy &t)
Definition: atom_level2.cpp:17
ipxMg71190
long ipxMg71190
Definition: atmdat_readin.cpp:61
t_phycon::te20
double te20
Definition: phycon.h:54
t_phycon::alogte
double alogte
Definition: phycon.h:82
taulines.h
CoolHeavy
t_CoolHeavy CoolHeavy
Definition: coolheavy.cpp:5
phycon.h
ipTMg610
long ipTMg610
Definition: atmdat_readin.cpp:62
t_phycon::sqrte
double sqrte
Definition: phycon.h:48
ipTMg4
long ipTMg4
Definition: atmdat_readin.cpp:63
t_atoms::PopLevels
double PopLevels[LIMLEVELN+1]
Definition: atoms.h:270
t_phycon::te05
double te05
Definition: phycon.h:57
t_phycon::te
double te
Definition: phycon.h:11
DEBUG_ENTRY
#define DEBUG_ENTRY(funcname)
Definition: cddefines.h:684
ipxMg51325
long ipxMg51325
Definition: atmdat_readin.cpp:60