/home66/gary/public_html/cloudy/c08_branch/source/prt_lines_lv1_li_ne.cpp

Go to the documentation of this file.
00001 /* This file is part of Cloudy and is copyright (C)1978-2008 by Gary J. Ferland and
00002  * others.  For conditions of distribution and use see copyright notice in license.txt */
00003 /*lines_lv1_li_ne place lines of elements lithium through neon into lines storage stack */
00004 /*GetLineRec return recombination coefficient*hnu*eden*n_ion for C, N, or O recombination lines from Dima's list,
00005  * also zero's line in master stack so not entered second time in later dump of all rec lines */
00006 #include "cddefines.h"
00007 #include "carb.h"
00008 #include "nitro.h"
00009 #include "oxy.h"
00010 #include "coolheavy.h"
00011 #include "atmdat.h"
00012 #include "doppvel.h"
00013 #include "ionbal.h"
00014 #include "dense.h"
00015 #include "phycon.h"
00016 #include "physconst.h"
00017 #include "atoms.h"
00018 #include "mole.h"
00019 #include "embesq.h"
00020 #include "taulines.h"
00021 #include "trace.h"
00022 #include "lines_service.h"
00023 #include "lines.h"
00024 STATIC double GetLineRec(
00025         /* this is the number of the emission line in the stack of lines, on the C scale */
00026         long int ip, 
00027         /* the multiplet wavelength */
00028   long int lWl);
00029 
00030 void lines_lv1_li_ne(void)
00031 {
00032         long int ipnt;
00033         double 
00034           chem ,
00035           corr, 
00036           ct4363, 
00037           ctRate, 
00038           efac, 
00039           effec, 
00040           efficn2, 
00041           fac, 
00042           HBeta ,
00043           p386, 
00044           pump,
00045           r4363, 
00046           r6584, 
00047           raten3, 
00048           rb, 
00049           rec, 
00050           rn3mor, 
00051           rn3tot, 
00052           rnii, 
00053           rp300, 
00054           rp386, 
00055           r12 ,
00056           r13 ,
00057           sum,
00058                 rate_OH_dissoc;
00059         double rec7323 , rec7332, rec3730 , rec3726 , rec2471,
00060                 reco23tot , reco22tot;
00061 
00062         DEBUG_ENTRY( "lines_lv1_li_ne()" );
00063 
00064         if( trace.lgTrace )
00065         {
00066                 fprintf( ioQQQ, "   lines_lv1_li_ne called\n" );
00067         }
00068 
00069         /* level 1 ines */
00070         ipnt = StuffComment( "level 1 lines" );
00071         linadd( 0., (realnum)ipnt , "####", 'i',
00072                 " start level 1 ines" );
00073 
00074         linadd(CoolHeavy.colmet,0,"Mion",'c',
00075                 " cooling due to collisional ionization of heavy elements" );
00076 
00077         /* lithium */
00078 
00079         /* beryllium */
00080 
00081         /* boron*/
00082 
00083         /* carbon*/
00084 
00085         /* >>chng 97 may 02, added better rec coefficient
00086          * C I 1656 recombination, all agents */
00087         rec = GetLineRec(3,1657)*(1.-TauLines[ipT1656].Emis->ColOvTot);
00088         rec = GetLineRec(3,1657)*emit_frac(&TauLines[ipT1656]);
00089         PutExtra(rec);
00090 
00091         PutLine(&TauLines[ipT1656],
00092                 " C 1 1656, collision strength from van Regemoter");
00093 
00094         linadd(rec,1656,"REC ",'i',
00095                 " C 1 1656 recomb; n.b. coll deexcitation not in" );
00096 
00097         linadd(carb.c9850,9850,"C Ic",'c',
00098                 " C 1 9850, coll excit" );
00099 
00100         /* >>chng 97 may 02, added better rec coefficient
00101          * C 1 9850, recombination contribution rec coefficient from 
00102          * >>refer      C1      rec     Escalante, Vladimir, & Victor, G.A., 1990, ApJS 73, 513.
00103          * r9850 is correction for collisional deexcitation as in carb cool
00104          * >>chng 97 aug 2, had factor of rec, changed to r9850, this
00105          * was a big mistake */
00106         rec = (GetLineRec(1,9088) + GetLineRec(2,9658))*carb.r9850;
00107         linadd(rec,9850,"C Ir",'i',
00108                 " C I 9850 recombination contribution" );
00109 
00110         PntForLine(9850.,"C  1",&ipnt);
00111         lindst(rec+carb.c9850,9850,"TOTL",ipnt,'i',true ,
00112                 " total intensity, all processes, C I 9850");
00113 
00114 
00115         PntForLine(8727.,"C  1",&ipnt);
00116         lindst(carb.c8727,8727,"C  1",ipnt,'c',true,
00117                 "C 1 8727; equivalent to 4363" );
00118 
00119         linadd(carb.c8727*1.22e-6,4621,"C  1",'c',
00120                 " 1S - 3P" );
00121 
00122         PutLine(&TauLines[ipT610],
00123                 "  C 1 610 micron ");
00124 
00125         PutLine(&TauLines[ipT370],
00126                 "  C 1 370 micron ");
00127 
00128         PutLine(&TauLines[ipT157],
00129                 "  C 2 158 micron, both e- and H0, H2 in excitation ");
00130 
00131         linadd(
00132                 TauLines[ipC2_2325].Emis->xIntensity+
00133                 TauLines[ipC2_2324].Emis->xIntensity+
00134                 TauLines[ipC2_2329].Emis->xIntensity+
00135                 TauLines[ipC2_2328].Emis->xIntensity+
00136                 TauLines[ipC2_2327].Emis->xIntensity+carb.p2326*8.6e-12,
00137                 2326,"TOTL",'i',
00138                 " total intensity of C II] 2326, all lines in the multiplet " );
00139         PutLine(&TauLines[ipC2_2325],
00140                 " ");
00141         PutLine(&TauLines[ipC2_2324],
00142                 " ");
00143         PutLine(&TauLines[ipC2_2329],
00144                 " ");
00145         PutLine(&TauLines[ipC2_2328],
00146                 " ");
00147         PutLine(&TauLines[ipC2_2327],
00148                 " ");
00149 
00150         linadd(carb.p2326*8.6e-12,2326,"Phot",'i' ,
00151                 " photoproduction, Helfand and Trefftz");
00152 
00153         /* >>chng 97 may 02, better rec coef */
00154         /*rec = GetLineRec(11,1335)*(1.-TauLines[ipT1335].ColOvTot);*/
00155         /* >>chng 02 jul 01, add function to return emission probability */
00156         rec = GetLineRec(11,1335)*emit_frac(&TauLines[ipT1335]);
00157 
00158         /* total intensity of C 2 1335 */
00159         PutExtra(MAX2(0.,rec));
00160         PutLine(&TauLines[ipT1335],
00161                 " total intensity of C 2 1335");
00162 
00163         linadd(rec,1335,"REC ",'i',
00164                 " C 2 1335 recombination," );
00165 
00166         /* the CII 3918.98/3920.68 and 6578.05/6582.88 multiplets,
00167          * contributions by both continuum pumping through XUV line
00168          * and recombination */
00169         /* this is the driving line, pump is photons cm^-3 s^-1 */
00170         if( nWindLine > 0 )
00171         {
00172                 pump = TauLine2[186].Emis->pump*TauLine2[186].Emis->PopOpc;
00173         }
00174         else
00175         {
00176                 pump = 0.;
00177         }
00178 
00179 
00180         PntForLine(3920.,"C  2",&ipnt);
00181         lindst(pump*0.387 * 5.08e-12/(1.+dense.eden/1e12) ,3920,"pump",ipnt,'i',true ,
00182                 "  CII 3918.98/3920.68 is only pumped, no recombination part");
00183 
00184         /* recombination and specific pump for CII 5684 */
00185         rec = GetLineRec(8, 6580 );
00186         /* convert UV pump rate to intensity with branching ratio and hnu */
00187         pump *= 0.305 * 0.387 * 3.02e-12;
00188         linadd(rec/(1.+dense.eden/1e12),6580,"C 2r",'i',
00189                 " recombination part of C II 6580 line " );
00190         linadd(pump/(1.+dense.eden/1e12),6580,"C 2p",'i',
00191                 " pumped part of line C II 6580" );
00192 
00193         PntForLine(6580.,"C  2",&ipnt);
00194         lindst((rec+pump)/(1.+dense.eden/1e12),6580,"TOTL",ipnt,'i',true ,
00195                 " total intensity, all processes, C II 6580");
00196 
00197         /* C 3 977
00198          * recombination contribution from nussbaumer and story 84 */
00199         /*rec = GetLineRec(179,977)*(1.-TauLines[ipT977].ColOvTot);*/
00200         /* >>chng 02 jul 01, add function to compute emission fraction */
00201         rec = GetLineRec(179,977)*emit_frac(&TauLines[ipT977]);
00202 
00203         /* continuum pumped C 3 977 by continuum near 386A */
00204         rp386 = TauLines[ipT386].Emis->pump*TauLines[ipT386].Emis->PopOpc;
00205 
00206         /* higher lines, same process */
00207         rp300 = TauLines[ipT310].Emis->pump*TauLines[ipT310].Emis->PopOpc + 
00208                 TauLines[ipT291].Emis->pump*TauLines[ipT291].Emis->PopOpc + 
00209                 TauLines[ipT280].Emis->pump*TauLines[ipT280].Emis->PopOpc + 
00210                 TauLines[ipT274].Emis->pump*TauLines[ipT274].Emis->PopOpc + 
00211                 TauLines[ipT270].Emis->pump*TauLines[ipT270].Emis->PopOpc;
00212 
00213         /* total line intensity due to pumping */
00214         /*p386 = (rp386 + rp300)*2.03e-11*(1.-TauLines[ipT977].ColOvTot);*/
00215         /* >>chng 02 jul 01, add function to compute emission fraction */
00216         p386 = (rp386 + rp300)*2.03e-11*emit_frac(&TauLines[ipT977]);
00217 
00218         /* total C 3 977 including recombination and pumping */
00219         PutExtra(p386+MAX2(0.,rec));
00220 
00221         PutLine(&TauLines[ipT977],
00222                 "  total C 3] 977, recombination + collisional + pumped excitation ");
00223 
00224         linadd(rec,977,"C3 R",'i',
00225                 " dielectronic recombination contribution to C 3 977 " );
00226 
00227         linadd(p386,977,"P386",'r',
00228                 " C 3 977 pumped by continuum near 386A" );
00229 
00230         /* C 3  1909 collision, both lines together */
00231         fac = embesq.em1908 + TauLines[ipT1909].Emis->xIntensity;
00232         lindst(fac,1909,"TOTL",TauLines[ipT1909].ipCont,'i',false,
00233                 "C 3  1909 collision, both lines together");
00234 
00235         PutLine(&TauLines[ipT1909],
00236                 "C III 19091");
00237 
00238         PntForLine(1907.,"C  3",&ipnt);
00239         lindst(embesq.em1908,1907,"C  3",ipnt,'i',true,
00240                 " C 3 1908 j-2 to ground" );
00241 
00242         lindst(embesq.em13C1910,1910,"13C3",ipnt,'i',true,
00243                 " the 13C forbidden line of C III " );
00244 
00245         /*corr = 1.-TauLines[ipT1909].ColOvTot;*/
00246         /* >>chng 02 jul 01, add function to compute emission fraction */
00247         corr = emit_frac(&TauLines[ipT1909]);
00248         fac = dense.eden*dense.xIonDense[ipCARBON][3]/(phycon.te/phycon.te10)*
00249           ionbal.DielSupprs[1][2];
00250 
00251         linadd(3.1e-19*fac*corr,1909,"C3 R",'i',
00252                 " C 3 1909 recombination from Storey" );
00253 
00254         linadd(carb.p1909*corr*1.05e-11,1909,"Phot",'i',
00255                 " C 3 1909 following relax following inner shell photoionization" );
00256 
00257         /* >>chng 97 may 02, better rec ocef */
00258         /*rec = GetLineRec(178,1176)*(1.-TauLines[ipc31175].ColOvTot);*/
00259         /* >>chng 02 jul 01, add function to compute emission fraction */
00260         rec = GetLineRec(178,1176)*emit_frac(&TauLines[ipc31175]);
00261         PutExtra(MAX2(0.,rec));
00262 
00263         PutLine(&TauLines[ipc31175],
00264                 "  C 3* 1175, excited state line, above 1909 ");
00265 
00266         linadd(MAX2(0.,rec),1175,"Rec ",'i',
00267                 " dielectronic recombination contribution to C 3 1175 " );
00268 
00269         /* recombination C 4 1549 from C 5
00270          * >>chng 97 may 02, better rec coef */
00271         /*rec = GetLineRec(25,1549)*(1.-TauLines[ipT1550].ColOvTot);*/
00272         /* >>chng 02 jul 01, add function to compute emission fraction */
00273         rec = GetLineRec(25,1549)*emit_frac(&TauLines[ipT1550]);
00274 
00275         linadd(
00276                 TauLines[ipT1550].Emis->xIntensity+
00277                 TauLines[ipT1548].Emis->xIntensity+
00278                 rec,1549,"TOTL",'i',"total intensity of C 4 1549, all processes " );
00279 
00280         sum = 
00281                 TauLines[ipT1550].Emis->xIntensity*TauLines[ipT1550].Emis->FracInwd + 
00282                 TauLines[ipT1548].Emis->xIntensity*TauLines[ipT1548].Emis->FracInwd;
00283 
00284         linadd(sum+rec*TauLines[ipT1550].Emis->FracInwd,1549,"Inwd",'i',
00285                 "inward part of C 4 " );
00286 
00287         PutExtra(rec*.3333);
00288         PutLine(&TauLines[ipT1550],
00289                 " ");
00290 
00291         PutExtra(rec*.6666);
00292         PutLine(&TauLines[ipT1548],
00293                 " ");
00294 
00295         linadd((TauLines[ipT1550].Emis->ots+
00296                 TauLines[ipT1548].Emis->ots)*TauLines[ipT1548].EnergyErg,
00297           1549,"DEST",'i',
00298           " part of line destroyed by photoionization of Balmer continuum " );
00299 
00300         linadd(rec,1549,"C4 r",'i',
00301                 " recombination C 4 1549 from CV" );
00302 
00303         PutLine(&TauLines[ipT312],
00304                 "  Li seq 2s 3p Li seq transition");
00305 
00306         /* nitrogen */
00307 
00308         /* 5200 rec, both rad+di, 1/3 of total to doublets 
00309         colfac = COLL_CONST/phycon.sqrte*dense.eden;
00310         cs5200 = 7.28e-5*phycon.te/phycon.te10;*/
00311         /* ratio of radiative to total deexcitations 
00312         quench = 1.24e-5/(1.24e-5 + colfac * cs5200);
00313         quench = nitro.quench_5200;*/
00314 
00315         {
00316                 /*double recrate = GetLineRec(32,1200);*/
00317                 /*>>chng 06 jul 10, activate - this is rate coefficient cm3 s-1 from
00318                  *>>refer       NI      rec     Pequignot, D., Petijean, P. & Boisson, C. 1991, A&A, 251, 680 */
00319                 double recrate_new = 1.108e-13 * pow( (phycon.te*1e-4) , -0.6085) /
00320                         (1. - 0.0041 * pow( (phycon.te*1e-4) , -0.3975 ) ) * 
00321                         /* this is electron and ion density */
00322                         dense.eden * dense.xIonDense[ipNITROGEN][1] * 
00323                         /* ergs per 5199 photon */
00324                         3.83e-12;
00325 #               if 0
00326 #               endif
00327                 /* this is recombination with quenching 
00328                  * rec has units erg cm-3 s-1 */
00329                 rec = recrate_new * nitro.quench_5200;
00330         }
00331 
00332         /**** Terry's addition **************/
00333         linadd(rec,5199,"TOTr",'i',
00334                 " recombination Nitrogen I 5200 + 5198 together " );
00335 
00336         /* this is upper limit to production of 5200 by chemistry - assume every photo dissociation
00337          * populates upper level 
00338          * co.nitro_dissoc_rate is the total N photo dissociation rate, cm-3 s-1 */
00339         chem = co.nitro_dissoc_rate * 3.83e-12 * nitro.quench_5200;
00340         linadd(chem,5200,"chem",'i',
00341                 " upper limit to [N I] 5200 produced by chemistry" );
00342 
00343         pump = nitro.pump_rate_N1 * nitro.quench_5200 * 3.83e-12 * 
00344                 dense.xIonDense[ipNITROGEN][0];
00345         linadd(pump,5199,"pump",'i',
00346                 "  guess of contribution from pumping by FUV lines, evaluated in CoolNitr assumes 100% of triplet pumps goes to singlets - this is surely a large overestimate so will only print intensity, do not add to total line " );
00347 
00348         /* this is upper limit to production of 5200 by charge transfer -  
00349          * atmdat.HCharExcRecTo_N0_2D is the rate coefficient (cm3 s-1) for N+(3P) + H0 -> H+ + N0(2D) */
00350         ctRate = atmdat.HCharExcRecTo_N0_2D*dense.xIonDense[ipHYDROGEN][0]*dense.xIonDense[ipNITROGEN][1] * 
00351                 3.83e-12 * nitro.quench_5200;
00352         /*  */
00353         linadd(ctRate,5200,"H CT",'i',
00354                 " upper limit to [N I] 5200 produced by charge transfer" );
00355 
00356         linadd(nitro.xN5200,5200,"N 1c",'c',
00357                 " [N I] 5200 - just collisions" );
00358 
00359         linadd(nitro.xN5198,5198,"N 1c",'c',
00360                 "  [N I] 5198 - just collisions" );
00361 
00362         /*  >>chng 06 jul 08, add chem process to total assuming in proportional to stat weight  */
00363         linadd(nitro.xN5200 + (ctRate+chem+rec)*0.6 , 5200 ,"N  1",'i',
00364                 "[N I] 5200 - all processes - stat weight is 6 - total in term is 10" );
00365 
00366         linadd(nitro.xN5198 + (ctRate+chem+rec)*0.4 , 5198 ,"N  1",'i',
00367                 "[N I] 5198 - all processes - stat weight is 4 - total in term is 10 " );
00368 
00369         PntForLine(5200.,"N1 o",&ipnt);
00370         lindst(nitro.xN5200+nitro.xN5198 + (ctRate+chem+rec) , 5199 , "TOTL",ipnt , 'i',true,
00371                 " [N I] 5200 + 5198 together "  );
00372 
00373         linadd(nitro.xN3466,3466,"N  1",'c',
00374                 "[N I] 3466 together " );
00375 
00376         linadd(nitro.xN3467,3468,"N  1",'c',
00377                 " [N I] 3467 together " );
00378 
00379         linadd(nitro.xN3467+nitro.xN3466,3467,"TOTL",'i',
00380                 " [N I] 3467, 3466 together " );
00381 
00382         linadd(nitro.xN10408, 10408, "N  1",'c',
00383                 " " );
00384 
00385         linadd(nitro.xN10397+nitro.xN10398+nitro.xN10407, 10404,"N  1", 'c',
00386                 " Nitrogen I 10397, 10408, 10407 together");
00387 
00388         linadd(nitro.xN10398+nitro.xN10397+nitro.xN10408+nitro.xN10407, 10403,"TOTL", 'i',
00389                 " Nitrogen I 10398, 10397, 10408, 10407 together");
00390 
00391         /*************************/
00392 
00394         linadd(nitro.c5200+rec,5200,"N1 o",'i',
00395                 " N 1 5200, both 5198, 5200, collisions and recombination ");
00396 
00397         linadd(nitro.c5200,5200,"Colo",'c',
00398                 " N 1 5200, both 5198, 5200, collisions and recombination " );
00399 
00400         linadd(rec,5200,"REC ",'i',
00401                 " recombination contribution to [NI] 5200" );
00402 
00403         PntForLine(3466.,"N  1",&ipnt);
00404         lindst(nitro.c3466,3466,"N1 o",ipnt,'c',true,
00405                 " [N 1] 3466, 3 - 1 transition, whole multiplet" );
00406 
00407         PntForLine(10400.,"N  1",&ipnt);
00408         lindst(nitro.c10400,10400,"N1 o",ipnt,'c',true ,
00409                 " [N 1] 10400 3 - 2 transition, whole multiplet");
00410 
00411         PutLine(&TauLines[ipT1200],
00412                 "  collisionally excited part ");
00413 
00414         PutLine(&TauLines[ipT671],
00415                 "  6 lines with fake collision strengths" );
00416         PutLine(&TauLines[ipT315],
00417                 " " );
00418         PutLine(&TauLines[ipT333],
00419                 " " );
00420         PutLine(&TauLines[ipT324],
00421                 " " );
00422         PutLine(&TauLines[ipT374g],
00423                 " " );
00424         PutLine(&TauLines[ipT374x],
00425                 " " );
00426 
00427         PntForLine(6584.,"N  2",&ipnt);
00428         lindst(nitro.c6584/(1.+1./2.951),6584,"N  2",ipnt,'c',true ,
00429                 "  N 2 6584 alone " );
00430 
00431         PntForLine(6548.,"N  2",&ipnt);
00432         lindst(nitro.c6584/(1.+2.951),6548,"N  2",ipnt,'c',true,
00433                 "  N 2 6548 alone "  );
00434 
00435         efficn2 = 4e-3/(4e-3 + 5.18e-6*dense.eden/phycon.sqrte);
00436         r6584 = 8e-22/(phycon.te70/phycon.te03/phycon.te03)*efficn2;
00437         linadd(r6584*dense.xIonDense[ipNITROGEN][2]*dense.eden,6584,"REC ",  'i',
00438                 "  N 2 6584 alone, recombination contribution"  );
00439 
00440         /* helium charge transfer from 
00441         >>refer n2      CT      Sun Sadeghpour, Kirby Dalgarno and Lafyatis, CfA preprint 4208 */
00442         ctRate = 1.8e-11*dense.xIonDense[ipHELIUM][0]*dense.xIonDense[ipNITROGEN][2]*1.146/(1.146 + 
00443           0.87*dense.cdsqte)*3.46e-12;
00444 
00445         /* >>chng 01 jul 09, add recombination contribution to 5755 */
00446         /* >>refer      n2      rec     Liu, X.W., Storey, P.J., Barlow, M.J., Danziger, I.J., Cohen, M.,
00447          * >>refercon   & Bryce, M., 2000, MNRAS, 312, 585 */
00448         /* they give intensity in terms of hbeta intensity as their equation 1 */
00449         if( dense.xIonDense[ipHYDROGEN][1] > SMALLFLOAT )
00450         {
00451                 /* this test on >0 is necessary because for sims with no H-ionizing radiation
00452                  * the H+ density is initially zero */
00453                 /* H beta recombination, assuming old case B, needed since HS tables have
00454                  * only a narrow temperature range - at this point units are ergs cm^3 s-1 */
00455                 HBeta = (pow(10.,-20.89 - 0.10612*POW2(phycon.alogte - 4.4)))/phycon.te;
00456 
00457                 /* now convert to ergs cm-3 s-1 
00458                  * >>chng 05 mar 17, this step was missing, so recombination intensity off by density squared,
00459                  * bug reported by Marcelo Castellanos */
00460                 HBeta *= dense.eden * dense.xIonDense[ipHYDROGEN][1];
00461 
00462                 /* CoolHeavy.xN2_A3_tot is fraction of excitations that produce a photon 
00463                  * and represents the correction for collisional deexcitation */
00464                 /*>>chng 05 dec 16, Liu et al. (2000) eqn 1 uses t = Te/10^4 K, not Te so phycon.te30 
00465                  * is too large: (10^4)^0.3 = 16 - div by 15.8489 - bug caught by Kevin Blagrave */
00466                 rec = nitro.xN2_A3_tot * HBeta *
00467                         3.19 * phycon.te30 / 15.84893 * dense.xIonDense[ipNITROGEN][2]/dense.xIonDense[ipHYDROGEN][1];
00468         }
00469         else
00470         {
00471                 HBeta = 0.;
00472                 rec = 0.;
00473         }
00474 
00475         PntForLine(5755.,"N  2",&ipnt);
00476         lindst(nitro.c5755+ctRate+rec ,5755,"N  2",ipnt,'i',true,
00477                 " N 2 5755  total, collisions plus charge transfer plus recombination"  );
00478 
00479         linadd(nitro.c5755,5755,"Coll",'c',
00480                 " N 2 5755  collisional contribution" );
00481 
00482         linadd(ctRate,5755,"C T ",'i',
00483                 " N 2 5755  charge transfer contribution " );
00484 
00485         linadd( rec ,5755,"N 2r",'i',
00486                 " N 2 5755  recombination contribution" );
00487 
00488         PutLine(&TauLines[ipT122],
00489                 "  N 2 fine structure line ");
00490 
00491         PutLine(&TauLines[ipT205],
00492                 "  N 2 fine structure line " );
00493 
00494         PutLine(&TauLines[ipT2140],
00495                 "  N 2 2140 intercombination line " );
00496 
00497         /* >>chng 97 may 02, better rec contribution */
00498         /*rec = GetLineRec(201,1085)*(1.-TauLines[ipT1085].ColOvTot);*/
00499         /* >>chng 02 jul 01, add function to compute emission fraction */
00500         rec = GetLineRec(201,1085)*emit_frac(&TauLines[ipT1085]);
00501         PutExtra(MAX2(0.,rec));
00502 
00503         PutLine(&TauLines[ipT1085],
00504                 "  N 2 1084, CS guess from g-bar " );
00505 
00506         linadd(MAX2(0.,rec),1085,"Rec ",'i',
00507                 " dielectronic recombination contribution to N 2 1085" );
00508 
00509         /* continuum pumping of N 2 intersystem transition */
00510         rnii = TauLines[ipT671].Emis->pump*TauLines[ipT671].Emis->PopOpc;
00511 
00512         linadd(rnii*0.377*0.75*3.02e-12*efficn2,6584,"N2cn",'i',
00513                 " continuum pumped N 2 6584 " );
00514 
00515         efficn2 = 1./(1. + COLL_CONST*dense.eden/phycon.sqrte);
00516         linadd(rnii*0.0117*3.46e-12*efficn2,5755,"N2cn",'i',
00517                 " continuum pumped N 2 5755" );
00518 
00519         /* pumping of the NII 509A line excites 2p4s ^3P^o,
00520          * which decays through the 3328, 5679, and 671 multiplets
00521          * the NII 3311 (6 lines), 3840 (6 lines), and 3600 (3 lines) multiplets,
00522          * contributions by both continuum pumping through XUV line
00523          * and recombination */
00524         /* this is the driving line, pump is photons cm^-3 s^-1 */
00525         if( nWindLine > 0 )
00526         {
00527                 pump = TauLine2[265].Emis->pump*TauLine2[265].Emis->PopOpc;
00528         }
00529         else
00530         {
00531                 pump = 0.;
00532         }
00533 
00534         PntForLine(3311.,"N  2",&ipnt);
00535         lindst(pump*0.236 * 6.01e-12/(1.+dense.eden/1e12) ,3311,"pump",ipnt,'i',true,
00536                 " NII 3311.42 - 3331.31 (6 lines) are only pumped, no recombination part" );
00537 
00538         PntForLine(3840.,"N  2",&ipnt);
00539         lindst(pump*0.186 * 5.18e-12/(1.+dense.eden/1e12) ,3840,"pump",ipnt,'i',true,
00540                 " NII 3829.8-3856.06 (6 lines) are only pumped, no recombination part" );
00541 
00542         PntForLine(3609.,"N  2",&ipnt);
00543         lindst(pump*0.025 * 5.52e-12/(1.+dense.eden/1e12) ,3609,"pump",ipnt,'i',true,
00544                 " NII 3593.60/3609.1/3615.86 (3 lines) are only pumped, no recombination part" );
00545 
00546 
00547         PntForLine(4640.,"N  2",&ipnt);
00548         lindst(pump*0.186*0.595 * 4.31e-12/(1.+dense.eden/1e12) ,4640,"pump",ipnt,'i',true ,
00549                 " NII 4601.5-4643.1 (6 lines) are only pumped, no recombination part");
00550 
00551         PntForLine(5010.,"N  2",&ipnt);
00552         lindst(pump*0.025*0.442 * 3.97e-12/(1.+dense.eden/1e12) ,5010,"pump",ipnt,'i',true,
00553                 " NII 5002.7/5010.6/5045.1 (3 lines) are only pumped, no recombination part " );
00554 
00555         /* recombination and specific pump for NII 5679 */
00556         rec = GetLineRec(44, 5679 );
00557         /* convert UV pump rate to intensity with branching ratio and hnu */
00558         pump *= 0.236 * 0.626 * 3.50e-12;
00559 
00560         linadd(rec/(1.+dense.eden/1e12),5679,"N 2r",'i',
00561                 " recombination part of N II 5679 line" );
00562 
00563         linadd(pump/(1.+dense.eden/1e12),5679,"N 2p",'i',
00564                 " pumped part of line N II 5679 " );
00565 
00566         PntForLine(5679.,"N  2",&ipnt);
00567         lindst((rec+pump)/(1.+dense.eden/1e12),5679,"TOTL",ipnt,'i',true,
00568                 " total intensity, all processes, N II 5679 " );
00569 
00570         PutLine(&TauLines[ipT57],
00571                 " [N 3] 57 micron fine structure line");
00572 
00573         linadd(
00574                 TauLines[ipN3_1749].Emis->xIntensity+
00575                 TauLines[ipN3_1747].Emis->xIntensity+
00576                 TauLines[ipN3_1754].Emis->xIntensity+
00577                 TauLines[ipN3_1752].Emis->xIntensity+
00578                 TauLines[ipN3_1751].Emis->xIntensity,
00579                 1750,"TOTL",'i',
00580                 " total intensity of N III] 1750, all lines in the multiplet " );
00581         PutLine(&TauLines[ipN3_1749],
00582                 " ");
00583         PutLine(&TauLines[ipN3_1747],
00584                 " ");
00585         PutLine(&TauLines[ipN3_1754],
00586                 " ");
00587         PutLine(&TauLines[ipN3_1752],
00588                 " ");
00589         PutLine(&TauLines[ipN3_1751],
00590                 " ");
00591 
00592         /* continuum pumped "Bowen" N 3
00593          * rate system a is populated  */
00594         raten3 = TauLines[ipT374x].Emis->PopOpc*TauLines[ipT374x].Emis->pump;
00595 
00596         /* rate system b is populated */
00597         if( DoppVel.TurbVel < 200. )
00598         {
00599                 rb = TauLines[ipT374x].Emis->PopOpc*TauLines[ipT374x].Emis->pump + 
00600                         TauLines[ipT374g].Emis->PopOpc*TauLines[ipT374g].Emis->pump;
00601         }
00602         else
00603         {
00604                 /* only one line if both fully overlap due to large turb */
00605                 rb = TauLines[ipT374g].Emis->PopOpc*TauLines[ipT374g].Emis->pump;
00606         }
00607 
00608         rn3mor = 
00609                 TauLines[ipT315].Emis->PopOpc*TauLines[ipT315].Emis->pump*0.448 + 
00610                 TauLines[ipT324].Emis->PopOpc*TauLines[ipT324].Emis->pump*0.78 + 
00611                 TauLines[ipT333].Emis->PopOpc*TauLines[ipT333].Emis->pump*0.434;
00612 
00613         /* pumping of optical N 3 bowen lines */
00614         rn3tot = (rb + raten3)*0.439 + rn3mor;
00615 
00616         sum = raten3*4.29e-12;
00617         PntForLine(4640.,"N3cn",&ipnt);
00618         lindst(sum,4640,"N3cn",ipnt,'i',true ,
00619                 " continuum pumped \"Bowen\" N 3, optically thin excited line ");
00620 
00621         /*  */
00622         sum = rb*4.29e-12*0.834;
00623         PntForLine(4634.,"N3cn",&ipnt);
00624         lindst(sum,4634,"N3cn",ipnt,'i',true ,
00625                 " continuum pumped \"Bowen\" N 3, optically thin excited line");
00626 
00627         sum = rb*4.29e-12*(1. - 0.834);
00628         PntForLine(4642.,"N3cn",&ipnt);
00629         lindst(sum,4642,"N3cn",ipnt,'i',true,
00630                 " continuum pumped \"Bowen\" N 3, optically thin excited line" );
00631 
00632         /* total rate for N 3 990
00633          * correction factor for collisional deexcitation */
00634         /*fac = 1.-TauLines[ipT990].ColOvTot;*/
00635         /* >>chng 02 jul 01, add function to compute emission fraction */
00636         fac = 1.-emit_frac(&TauLines[ipT990]);
00637 
00638         /* >>chng 97 may 02, better rec coef */
00639         /*rec = GetLineRec(216,991)*(1.-TauLines[ipT990].ColOvTot);*/
00640         /* >>chng 02 jul 01, add function to compute emission fraction */
00641         rec = GetLineRec(216,991)*emit_frac(&TauLines[ipT990] );
00642         PutExtra(MAX2(0.,rec)+rn3tot*2.01e-11*fac);
00643 
00644         PutLine(&TauLines[ipT990],
00645                 "  N 3 990, all processes ");
00646 
00647         linadd(rec+rn3tot*2.01e-11*fac,990,"extr",'i',
00648                 " total N 3 990, both electron excitation and continuum pumping" );
00649 
00650         linadd(rec,990,"rec ",'i',
00651                 " part of N 3 990 due to recombination " );
00652 
00653         linadd(rn3tot*2.01e-11,990,"N 3p",'r',
00654                 " N 3 989.8, continuum pumped" );
00655 
00656         linadd(embesq.em1486+TauLines[ipT1486].Emis->xIntensity,1486,"TOTL",'i',
00657                 " N 4] 1486, total intensity of both lines" );
00658 
00659         PutLine(&TauLines[ipT1486],
00660                 " ");
00661 
00662         PntForLine(1485.,"N  4",&ipnt);
00663         lindst(embesq.em1486,1485,"N  4",ipnt,'c',true ,
00664                 " the N IV] slow transition by itself " );
00665 
00666         /* >>chng 97 may 02, better expression for dielectronic recombination */
00667         /*rec = GetLineRec(287,765)*(1.-TauLines[ipT765].ColOvTot);*/
00668         /* >>chng 02 jul 01, add function to get emission fraction */
00669         rec = GetLineRec(287,765)*emit_frac(&TauLines[ipT765] );
00670 
00671         /* dielectronic recombination contribution from Nussbaumer and Storey 1984 */
00672         PutExtra(rec);
00673 
00674         PutLine(&TauLines[ipT765],
00675                 " N 4 765, collisionally excited");
00676 
00677         linadd(MAX2(0.,rec),765,"rec ",'i',
00678                 " N 4 765 recombination," );
00679 
00680         linadd(TauLines[ipT1243].Emis->xIntensity+TauLines[ipT1239].Emis->xIntensity,1240,"TOTL",'i',
00681                 " continuum pumping of NV 1240, N 5 1240, total emission, collisions plus pumping " );
00682         sum = TauLines[ipT1243].Emis->xIntensity*TauLines[ipT1243].Emis->FracInwd + TauLines[ipT1239].Emis->xIntensity*
00683           TauLines[ipT1239].Emis->FracInwd;
00684 
00685         linadd(sum,1240,"Inwd",'i',
00686                 " inward part of N 5 " );
00687         PutLine(&TauLines[ipT1243],
00688                 " ");
00689         PutLine(&TauLines[ipT1239],
00690                 " ");
00691 
00692         PutLine(&TauLines[ipT209],
00693                 "  N 5 209, 2s-3p Li seq ");
00694 
00695         PntForLine(6300.,"O  1",&ipnt);
00696         lindst(CoolHeavy.c6300,6300,"O  1",ipnt,'c',true ,
00697                 "  oxygen total Oxygen I  6300, including continuum optical depth ");
00698 
00699         /* the intensity of [OI] 6300 line due to OH photodistruction */
00700         /* last term is fraction that emit rather than collisionally deexcited,
00701          * factor of 0.55 is branching ratio from chemistry for producing
00702          * OI in correct excited state 
00703          * this is used to get OH photo formation of [OI] 6300
00704          *>>refer       OI      photoexcitation Storzer, H., & Hollenbach, D. 2000, ApJ, 539, 751-759 
00705          * discussion on bottom left side of page 752 */
00706         /* rate_OH_dissoc is number of OH destruction events, OH -> O + H, cm-3 s-1,
00707          * 0.55 is fraction of OH dissociation that lead to pop of upper level of 6300
00708          * r12 is energy emitted per unit vol, erg cm-3 s-1, in 6300, due to OH dest */
00709         rate_OH_dissoc = CO_findrate("PHOTON,OH=>O,H");
00710         r12 = rate_OH_dissoc * 0.55 * 3.16e-12 * CoolHeavy.c6300_frac_emit;
00711 
00712         lindst( r12*TauLines[ipT6300].Emis->Aul/(TauLines[ipT6300].Emis->Aul+TauLines[ipT6363].Emis->Aul) , 
00713                 6300., "OH p",ipnt , 'i' , false,
00714                 " the intensity of [OI] 6300 line due to OH photodistruction");
00715 
00716         lindst( r12*TauLines[ipT6363].Emis->Aul/(TauLines[ipT6300].Emis->Aul+TauLines[ipT6363].Emis->Aul) , 
00717                 6363., "OH p",ipnt , 'i' , false,
00718                 " the intensity of [OI] 6363 line due to OH photodistruction ");
00719 
00720         PntForLine(6363.,"O  1",&ipnt);
00721         lindst(CoolHeavy.c6363,6363,"O  1",ipnt,'c',true,
00722                 " total Oxygen I  6363, including continuum optical depth " );
00723 
00724         PntForLine(5577.,"O  1",&ipnt);
00725         lindst(CoolHeavy.c5577,5577,"O  1",ipnt,'c',true,
00726                 " auroral OI " );
00727 
00728         r13 = rate_OH_dissoc * 0.05 * 3.57e-12 * 0.94*CoolHeavy.c5577_frac_emit;
00729         lindst( r13 , 5577., "OH p",ipnt , 'i', false,
00730                 " 94% of excitations to highest level decay via 5577" );
00731 
00732         PutLine(&TauLines[ipT63],
00733                 "  O I fine structure line ");
00734 
00735         PutLine(&TauLines[ipT146],
00736                 "  O I fine structure line ");
00737 
00738         linadd(MAX2(0.,CoolHeavy.coolOi),0,"TOIc",'c',
00739                 " total collisional cooling due to 6-level OI atom" );
00740 
00741         linadd(MAX2(0.,-CoolHeavy.coolOi),0,"TOIh",'h',
00742                 " total collisional heating due to 6-level OI atom " );
00743 
00744         /* OI 8446 from six level atom */
00745         /* >>chng 04 nov 15, upper level for 8446 was incorrect - was 4 should have been 2
00746          * bug caught by Yoshiki Matsuoka *
00747          *sum = atoms.popoi[4]*TauLines[ipT8446].Pesc*TauLines[ipT8446].Aul*2.36e-12;*/
00748         sum = atoms.popoi[2]*TauLines[ipT8446].Emis->Pesc*TauLines[ipT8446].Emis->Aul*2.36e-12;
00749         PntForLine(8446.,"O  1",&ipnt);
00750 
00751         lindst(sum,8446,"6lev",ipnt,'i',false,
00752                 " * \todo       2        these are actually in the optical depth arrays, should be moved to call PutLine - but some needed vars are not defined in structure " );
00753 
00754         PntForLine(1304.,"O  1",&ipnt);
00755         sum = atoms.popoi[1]*TauLines[ipT1304].Emis->Pesc*TauLines[ipT1304].Emis->Aul*1.53e-11;
00756         lindst(sum,1304,"6lev",ipnt,'i',false,
00757                 " OI 1304 from six level atom " );
00758 
00759         PntForLine(1039.,"O  1",&ipnt);
00760         sum = atoms.popoi[3]*TauLines[ipT1039].Emis->Pesc*TauLines[ipT1039].Emis->Aul*1.92e-11;
00761         lindst(sum,1039,"6lev",ipnt,'i',false ,
00762                 " OI 1039 from six level atom");
00763 
00764         PntForLine(4368.,"O  1",&ipnt);
00765         sum = atoms.popoi[5]*TauLines[ipT4368].Emis->Pesc*TauLines[ipT4368].Emis->Aul*4.55e-12;
00766         lindst(sum,4368,"6lev",ipnt,'i',false,
00767                 " OI 4368 from six level atom" );
00768 
00769         PntForLine(13100.,"O  1",&ipnt);
00770         sum = atoms.popoi[3]*TauLines[ipTOI13].Emis->Pesc*TauLines[ipTOI13].Emis->Aul*1.52e-12;
00771         lindst(sum,13100,"6lev",ipnt,'i',false ,
00772                 "OI 1.3 micron from six level atom");
00773 
00774         PntForLine(11300.,"O  1",&ipnt);
00775         sum = atoms.popoi[4]*TauLines[ipTOI11].Emis->Pesc*TauLines[ipTOI11].Emis->Aul*1.76e-12;
00776         lindst(sum,11300,"6lev",ipnt,'i',false ,
00777                 " OI 1.1 micron from six level atom");
00778 
00779         PntForLine(29000.,"O  1",&ipnt);
00780         sum = atoms.popoi[5]*TauLines[ipTOI29].Emis->Pesc*TauLines[ipTOI29].Emis->Aul*6.86e-13;
00781         lindst(sum,29000,"6lev",ipnt,'i',false ,
00782                 " OI 2.9 micron from six level atom");
00783 
00784         PntForLine(46000.,"O  1",&ipnt);
00785         sum = atoms.popoi[5]*TauLines[ipTOI46].Emis->Pesc*TauLines[ipTOI46].Emis->Aul*4.32e-13;
00786         lindst(sum,46000,"6lev",ipnt,'i',false ,
00787                 " OI 4.6 micron from six level atom");
00788 
00789         /*double rec7323 , rec7332, rec3730 , rec3726 , rec2471 
00790          * reco23tot , reco22tot;*/
00791 
00792         /* total recombination to 2P^o, the highest two levels of the 5-level atom,
00793          * which produces the 7325 multiplet, last factor accounts for coll deexcitation  
00794          * this implements equation 2 of 
00795          * refer        o2      rec     Liu, X-W., Storey, P.J., Barlow, M.J., Danziger, I.J.,
00796          * refercon     Cohen, M., & Bryce, M., 2000, MNRAS, 312, 585 */
00797         /* >>chng 05 dec 29, from first eqn, or unknown origin, to second, from indicated
00798          * reference.  They agreed within 20% */
00799         /*reco23tot = 3.484e-11 / ( phycon.sqrte / phycon.te05 * phycon.te003 ) * 
00800                 dense.eden * dense.xIonDense[ipOXYGEN][2] * CoolHeavy.O2_A3_tot *2.72e-12;*/
00801         if( dense.xIonDense[ipHYDROGEN][1]  > SMALLFLOAT )
00802         {
00803                 /* this test is necessary because for sims with no H-ionizing radiation
00804                  * the H+ density is initially zero */
00805                 reco23tot = CoolHeavy.O2_A3_tot * HBeta *
00806                         9.36 * phycon.te40*phycon.te04 / 57.544 * dense.xIonDense[ipOXYGEN][2]/dense.xIonDense[ipHYDROGEN][1];
00807         }
00808         else
00809         {
00810                 reco23tot = 0.;
00811         }
00812 
00813         sum = CoolHeavy.O2471*2471./7325. + CoolHeavy.O7323 + CoolHeavy.O7332;
00814         if( sum > SMALLFLOAT )
00815         {
00816                 /* assume effective branching ratio according to predicted intensities from 5-lev atom*/
00817                 reco23tot /= sum;
00818         }
00819         else
00820         {
00821                 reco23tot = 0.;
00822         }
00823         /* these are now ergs per sec unit vol for each transition */
00824         rec7323 = reco23tot * CoolHeavy.O7323;
00825         rec7332 = reco23tot * CoolHeavy.O7332;
00826         rec2471 = reco23tot * CoolHeavy.O2471*2471./7325. * 8.05e-12/2.72e-12;
00827 
00828         /* total recombination to 2D^o, the middle two levels of the 5-level atom,
00829          * which produces the 3727 multiplet, last factor accounts for coll deexcit */
00830         reco22tot = 1.660e-10 / ( phycon.sqrte * phycon.te03 * phycon.te005 ) * 
00831                 dense.eden * dense.xIonDense[ipOXYGEN][2] * CoolHeavy.O2_A2_tot;
00832         /* assume effective branching ratio according to predicted intensities from 5-lev atom*/
00833         sum = CoolHeavy.O3726 + CoolHeavy.O3730;
00834         if( sum > SMALLFLOAT )
00835         {
00836                 reco22tot /= sum;
00837         }
00838         else
00839         {
00840                 reco22tot = 0.;
00841         }
00842         /* these are now ergs per sec unit vol for each transition */
00843         rec3726 = reco22tot * CoolHeavy.O3726 * 5.34e-12;
00844         rec3730 = reco22tot * CoolHeavy.O3730 * 5.34e-12;
00845 
00846         /* O II 3727 produced by photoionization OF O0 */
00847         oxy.s3727 = (realnum)((oxy.s3727 + oxy.s7325*0.5)*5.34e-12*
00848           9.7e-5/(9.7e-5 + dense.eden*1.15e-6/phycon.sqrte));
00849 
00850         PntForLine(3727.,"O  2",&ipnt);
00851         fac = CoolHeavy.c3727+oxy.s3727+rec3726+rec3730;
00852         lindst(fac ,3727,"TOTL",ipnt,'c',true,
00853                 " O II 3727, all lines of multiplet together " );
00854 
00855         PntForLine(7325.,"O  2",&ipnt);
00856         fac = CoolHeavy.c7325+rec7323+rec7332;
00857         lindst( fac ,7325,"TOTL",ipnt,'c',true ,
00858                 " O II 7325, all lines of multiplet together");
00859 
00860         linadd(oxy.s3727,3727,"IONZ",'i',
00861                 " line produced by photoionization of Oo; already in TOTL" );
00862         oxy.s7325 = (realnum)(oxy.s7325*2.72e-12*0.34/(0.34 + dense.eden*
00863           6.04e-6/phycon.sqrte));
00864 
00865         linadd(oxy.s7325,7325,"IONZ",'i',
00866                 " line produced by photoionization of Oo; already in TOTL" );
00867 
00868         linadd(CoolHeavy.c7325,7325,"Coll",'i',
00869                 " collisional contribution to line " );
00870 
00871         linadd(CoolHeavy.c3727,3727,"Coll",'i',
00872         " collisional contribution to line " );
00873 
00874         linadd(CoolHeavy.O3730,3729,"O II",'i',
00875                 " five level atom calculations; D5/2 - S3/2" );
00876 
00877         linadd(CoolHeavy.O3726,3726,"O II",'i',
00878                 " D3/2 - S3/2 transition" );
00879 
00880         linadd(CoolHeavy.O2471,2471,"O II",'c',
00881                 " both 2P 1/2 and 3/2 to ground " );
00882 
00883         linadd(CoolHeavy.O7323,7323,"O II",'i',
00884                 " P1/2-D5/2 and P3/2-D5/2 together" );
00885 
00886         linadd(CoolHeavy.O7332,7332,"O II",'i',
00887                 " P1/2-D3/2 and P3/2-D3/2 together " );
00888 
00889     linadd( rec3730 ,3729,"O 2r",'i',
00890                 " chng 01 jul 08, add recombination contribution  refer o2      rec     Liu, X-W., Storey, P.J., Barlow, M.J., Danziger, I.J.,refercon  Cohen, M., & Bryce, M., 2000, MNRAS, 312, 585  recombination contributions five level atom calculations; D5/2 - S3/2 " );
00891 
00892         linadd( rec3726 ,3726,"O 2r",'i',
00893                 " D3/2 - S3/2 transition" );
00894 
00895         linadd(rec2471,2471,"O 2r",'i',
00896                 " both 2P 1/2 and 3/2 to ground " );
00897         linadd(rec7323,7323,"O 2r",'i',
00898                 " P1/2-D5/2 and P3/2-D5/2 together " );
00899 
00900         linadd(rec7332,7332,"O 2r",'i',
00901                 " P1/2-D3/2 and P3/2-D3/2 together " );
00902 
00903         PutLine(&TauLines[ipT834],
00904                 "  O II 833.8 coll excit ");
00905 
00906         /* the OII multiplets,
00907          * contributions by both continuum pumping through XUV line
00908          * and recombination */
00909         /* this is the driving line, pump is photons cm^-3 s^-1 */
00910         if( nWindLine > 0 )
00911         {
00912                 pump = TauLine2[387].Emis->pump*TauLine2[387].Emis->PopOpc;
00913         }
00914         else
00915         {
00916                 pump = 0.;
00917         }
00918 
00919         PntForLine(3120.,"O  2",&ipnt);
00920         lindst(pump*0.336 * 6.37e-12/(1.+dense.eden/1e12) ,3120,"pump",ipnt,'i',true,
00921                 " OII 3113.62 - 3139.68 (8 lines) are only pumped, no recombination part" );
00922 
00923         PntForLine(3300.,"O  2",&ipnt);
00924         lindst(pump*0.147 * 6.03e-12/(1.+dense.eden/1e12) ,3300,"pump",ipnt,'i',true,
00925                 " OII 3277.56 - 3306.45 (6 lines) are only pumped, no recombination part" );
00926 
00927         PntForLine(3762.,"O  2",&ipnt);
00928         lindst(pump*0.087 * 5.29e-12/(1.+dense.eden/1e12) ,3762,"pump",ipnt,'i',true,
00929                 " OII 3739.76/3762.47/3777.42 (3 lines) are only pumped, no recombination part" );
00930 
00931         /* recombination and specific pump for OII 4638.86-4696.35 (8 lines) */
00932         rec = GetLineRec(82, 4651 );
00933         PntForLine(4651.,"O  2",&ipnt);
00934         lindst(rec,4651,"O 2r",ipnt,'i',true,
00935                 " O II 4651 total recombination, 4638.86-4696.35 (8 lines)  " );
00936 
00937         /* convert UV pump rate to intensity with branching ratio and hnu recombination 
00938          * part of O II 4651 line */
00939         linadd(pump* 0.336 * 0.933 * 4.27e-12/(1.+dense.eden/1e12),4651,"O 2p",'i',
00940                 " pumped part of line O II 4651 " );
00941 
00942         /* recombination and specific pump for OII 4317.14-4366.89 (6 lines) */
00943         rec = GetLineRec(83, 4341 );
00944 
00945         linadd(rec/(1.+dense.eden/1e12),4341,"O 2r",'i',
00946                 " recombination contribution to O II 4341 line " );
00947 
00948         linadd(pump* 0.147 * 0.661 * 4.58e-12/(1.+dense.eden/1e12),4341,"O 2p",'i',
00949                 " pumped part of line O II 4341 " );
00950 
00951         PntForLine(4341.,"O  2",&ipnt);
00952         lindst(rec+pump* 0.147 * 0.661 * 4.58e-12/(1.+dense.eden/1e12),4341,"TOTL",ipnt,'i',true,
00953                 " total intensity, all processes, O II 4341" );
00954 
00955         /* recombination and specific pump for OII 3712.74/3727.32/3749.48 (3 lines) */
00956         rec = GetLineRec(84, 3736 );
00957         /* convert UV pump rate to intensity with branching ratio and hnu */
00958 
00959         linadd(rec/(1.+dense.eden/1e12),3736,"O 2r",'i',"\n recombination part of O II 3736 line " );
00960         linadd(pump* 0.087 * 0.763 * 5.33e-12/(1.+dense.eden/1e12),3736,"O 2p",'i',
00961                 " pumped part of line O II 3736" );
00962 
00963         PntForLine(3736.,"O  2",&ipnt);
00964         lindst((rec+pump* 0.087 * 0.763 * 5.33e-12)/(1.+dense.eden/1e12),3736,"TOTL",ipnt,'i',true,
00965                 " total intensity, all processes, O II 3736" );
00966 
00967         /* O III 1661+1666 */
00968         /*efac = ((1.-TauLines[ipT1666].ColOvTot) + (1.-TauLines[ipT1661].ColOvTot))*0.5;*/
00969         efac = (emit_frac(&TauLines[ipT1666]) + emit_frac(&TauLines[ipT1661]))*0.5;
00970 
00971         linadd(TauLines[ipT1666].Emis->xIntensity+TauLines[ipT1661].Emis->xIntensity,1665,"TOTL",'i',
00972                 "total intensity of OIII] 1665, all processes " );
00973         PutLine(&TauLines[ipT1661]," ");
00974 
00975         PutLine(&TauLines[ipT1666]," ");
00976 
00977         linadd(oxy.p1666*1.20e-11*efac,1665,"Phot",'i',
00978                 " contribution to OIII 1665 due to inner shell (2s^2) ionization " );
00979 
00980         linadd(oxy.AugerO3*1.20e-11*efac*0.27,1665,"Augr",'i',
00981                 " contribution to OIII 1665 due to K-shell ionization " );
00982 
00983         PntForLine(5007.,"O  3",&ipnt);
00984         lindst(CoolHeavy.c5007/(1.+1./3.01),5007,"O  3",ipnt,'c',true ,
00985                 "  O III  5007 alone, collisions, tot OIII is this times 1.333  fac = c5007/(1.+1./2.887) >>chng 01 may 04, branching ratio had been 2.887, revised to 3 as per refer   o3      as      Storey, P.J., & Zeippen, C.J., 2000, 312, 813-816 ");
00986 
00987         PntForLine(4959.,"O  3",&ipnt);
00988         lindst(CoolHeavy.c5007/(1.+3.01),4959,"O  3",ipnt,'c',true,
00989                 " O III  4959 alone, collisions, tot OIII is this times 4" );
00990 
00991         PntForLine(4931.,"O  3",&ipnt);
00992         lindst(CoolHeavy.c5007/(1.+3.01)*4.09e-4 ,4931,"O  3",ipnt,'c',true ,
00993                 "  O III  4931 alone, collisions  >>chng 01 jul 11, added this line  >>refer    o3      as      Nussbaumer, H., & Storey, P., 1981, A&A, 99, 177  >>refer       o3      as      Mathis, J.S., & Liu, X.-W., 1999, ApJ, 521, 212-216 ");
00994 
00995         linadd(oxy.d5007t/1.25,5007,"LOST",'i',
00996                 " O III 5007 lost through excited state photo" );
00997 
00998         /* collisional quenching ratio */
00999         effec = 1.6/(1.6 + 0.9*dense.cdsqte);
01000 
01001         /* O III 4363 recombination, coefficient from Burgess and Seaton */
01002         r4363 = 6.3e-21/(phycon.te70*phycon.te10)*dense.eden*dense.xIonDense[ipOXYGEN][3]*
01003           effec;
01004 
01005         /* charge exchange, 
01006          * >>refer      O3      CT      Dalgarno+Sternberg ApJ Let 257, L87.
01007          * scaled to agree with 
01008          * >>refer      O3      CT      Gargaud et al AA 208, 251, (1989) */
01009         ct4363 = phycon.sqrte*1.3e-12*4.561e-12*dense.xIonDense[ipHYDROGEN][0]*dense.xIonDense[ipOXYGEN][3]*
01010           effec;
01011 
01012         fac = CoolHeavy.c4363 + r4363 + ct4363;
01013         PntForLine(4363.,"O  3",&ipnt);
01014         lindst(fac,4363,"TOTL",ipnt,'i',true,
01015                 " O III 4363, sum of rec, coll, ct excitation" );
01016 
01017         linadd(CoolHeavy.c4363,4363,"Coll",'c',
01018                 " O III 4363,collisions from five level atom " );
01019 
01020         linadd(r4363,4363,"Rec ",'i',
01021                 " O III 4363 recombination, coefficient from Burgess and Seaton " );
01022 
01023         PntForLine(2321.,"O  3",&ipnt);
01024         lindst(CoolHeavy.c4363*0.236,2321,"O  3",ipnt,'c',true ,
01025                 " collisional excitation of 2321, 5-level atom");
01026         linadd(ct4363,4363,"C EX",'i' ,
01027                 " call linadd( c4363*0.236 , 2321 , 'O  3','c') charge exchange, Dalgarno+Sternberg ApJ Let 257, L87. ");
01028 
01029         linadd(dense.xIonDense[ipHYDROGEN][0]*dense.xIonDense[ipOXYGEN][3]*0.225*3.56e-12*1.34e-11*phycon.sqrte,
01030           5592,"C EX",'i'," charge exchange rate, D+S " );
01031 
01032         PutLine(&TauLines[ipTO88],
01033                 " O III 88 micron, collisionally excited");
01034 
01035         PutLine(&TauLines[ipT52],
01036                 " O III 52 micron, collisionally excited ");
01037 
01038         /* >>chng 97 may 02, better rec contribution */
01039         /*rec = GetLineRec(331,835)*(1.-TauLines[ipT835].ColOvTot);*/
01040         rec = GetLineRec(331,835)*emit_frac(&TauLines[ipT835]);
01041         PutExtra(MAX2(0.,rec));
01042 
01043         PutLine(&TauLines[ipT835],
01044                 "  O III 834A, collisions and dielectronic recombination ");
01045 
01046         linadd(MAX2(0.,rec),835,"rec ",'i',
01047                 " O III 834A, dielectronic recombination only" );
01048 
01049         PutLine(&TauLines[ipT26],
01050                 "  O IV 26 micron ");
01051 
01052         linadd(
01053                 TauLines[ipO4_1400].Emis->xIntensity+
01054                 TauLines[ipO4_1397].Emis->xIntensity+
01055                 TauLines[ipO4_1407].Emis->xIntensity+
01056                 TauLines[ipO4_1405].Emis->xIntensity+
01057                 TauLines[ipO4_1401].Emis->xIntensity,
01058                 1402,"TOTL",'i',
01059                 " total intensity of O IV] 1402, all lines in the multiplet " );
01060 
01061         PutLine(&TauLines[ipO4_1400],
01062                 " ");
01063         PutLine(&TauLines[ipO4_1397],
01064                 " ");
01065         PutLine(&TauLines[ipO4_1407],
01066                 " ");
01067         PutLine(&TauLines[ipO4_1405],
01068                 " ");
01069         PutLine(&TauLines[ipO4_1401],
01070                 " ");
01071 
01072         linadd(oxy.p1401*1.42e-11,1401,"InSh",'i',
01073                 " inner shell photoionization, relaxation " );
01074 
01075         /* >>chng 97 may 02, better rec contribution */
01076         rec = GetLineRec(378,789)*(1.-TauLines[ipT789].Emis->ColOvTot);
01077         rec = GetLineRec(378,789)*emit_frac(&TauLines[ipT789]);
01078         PutExtra(MAX2(0.,rec));
01079 
01080         PutLine(&TauLines[ipT789]," O IV 789A");
01081 
01082         linadd(MAX2(0.,rec),789,"rec ",'i',
01083                 " O IV 789A, dielectronic recombination only" );
01084 
01085         /* >>chng 97 may 02, better rec contribution */
01086         rec = GetLineRec(466,630);
01087         PutExtra(MAX2(0.,rec));
01088 
01089         PutLine(&TauLines[ipT630],"O V 630, collisional excitation and dielectronic recombination");
01090 
01091         linadd(MAX2(0.,rec),630,"rec ",'i',
01092                 " O V 630A, dielectronic recombination only" );
01093 
01094         linadd(embesq.em1218+TauLines[ipT1214].Emis->xIntensity,1218,"TOTL",'i',
01095                 " O V 1218], total intensity of both lines " );
01096         PutLine(&TauLines[ipT1214], " ");
01097 
01098         linadd(embesq.em1218,1211,"O  5",'i',
01099                 " the slow transition by itself" );
01100 
01101         linadd(1.4e-21/phycon.te70*dense.eden*dense.xIonDense[ipOXYGEN][5]*
01102           /*(1.-TauLines[ipT1214].ColOvTot),5112,"O  5",'i' );*/
01103           emit_frac(&TauLines[ipT1214]),5112,"O  5",'i',
01104           " BS O V 5112, recombination " );
01105 
01106         linadd(TauLines[ipT1032].Emis->xIntensity+TauLines[ipT1037].Emis->xIntensity,1035,"TOTL",'i',
01107                 " O VI 1035, total of pumping and collisional excitation " );
01108         sum = TauLines[ipT1032].Emis->xIntensity*TauLines[ipT1032].Emis->FracInwd + 
01109                 TauLines[ipT1037].Emis->xIntensity* TauLines[ipT1037].Emis->FracInwd;
01110 
01111         linadd(sum,1035,"Inwd",'i',
01112                 "  inward part of OVI line" );
01113         PutLine(&TauLines[ipT1032],
01114                 " ");
01115         PutLine(&TauLines[ipT1037],
01116                 " ");
01117 
01118         PutLine(&TauLines[ipT150],
01119                 "O VI 150, Li seq 2s 3p ");
01120 
01121         PutLine(&TauLines[ipF0229],
01122                 " fluorine       * [F II] 29.33 microns");
01123 
01124         PutLine(&TauLines[ipF0267],
01125                 "  [F II] 67.2 microns ");
01126 
01127         PutLine(&TauLines[ipF444],
01128                 "  F IV 44.07 micron ");
01129 
01130         PutLine(&TauLines[ipF425],
01131                 "  F IV 25.83 micron");
01132 
01133         PutLine(&TauLines[ipTNe13],
01134                 "  neon Neon II 12.8 micron ");
01135 
01136         PutLine(&TauLines[ipTNe16],
01137                 "  Ne III fine structure line ");
01138 
01139         PutLine(&TauLines[ipTNe36],
01140                 "  Ne III fine structure line ");
01141 
01142         PntForLine(3869.,"Ne 3",&ipnt);
01143         lindst(CoolHeavy.c3869/(1.+1./3.318),3869,"Ne 3",ipnt,'c',true,
01144                 "  Ne III  3869, of 3968+3869 doublet" );
01145 
01146         PntForLine(3968.,"Ne 3",&ipnt);
01147         lindst(CoolHeavy.c3869/(1.+3.318),3968,"Ne 3",ipnt,'c',true,
01148                 " Ne III  3968, of 3968+3869 doublet" );
01149 
01150         PntForLine(3343.,"Ne 3",&ipnt);
01151         lindst(CoolHeavy.c3343,3343,"Ne 3",ipnt,'c',true,
01152                 " NeIII auroral line " );
01153 
01154         PntForLine(1815.,"Ne 3",&ipnt);
01155         lindst(CoolHeavy.c3343*1.38,1815,"Ne 3",ipnt,'c',true ,
01156                 "  NeIII auroral line");
01157 
01158         PntForLine(2424.,"Ne 4",&ipnt);
01159         lindst(CoolHeavy.c2424,2424,"Ne 4",ipnt,'c',true,
01160                 " Ne IV 2424, collisional excitation" );
01161 
01162         PntForLine(4720.,"Ne 4",&ipnt);
01163         lindst(CoolHeavy.c4720,4720,"Ne 4",ipnt,'c',true,
01164                 "  Ne IV N=3-2 lines, three level atom approx, this is the sum of the 4714.5, 4724.2, 4725.5 lines" );
01165 
01166         PntForLine(1602.,"Ne 4",&ipnt);
01167         lindst(CoolHeavy.c4720*4.34,1602,"Ne 4",ipnt,'c',true ,
01168                 "  Ne IV N=3 lines, three level atom approx");
01169 
01170         PntForLine(3426.,"Ne 5",&ipnt);
01171         lindst(CoolHeavy.c3426/(1.+1./2.738),3426,"Ne 5",ipnt,'c',true,
01172                 " Ne V 3426 of 3426, 3346 doublet" );
01173 
01174         PntForLine(3346.,"Ne 5",&ipnt);
01175         lindst(CoolHeavy.c3426/(1.+2.738),3346,"Ne 5",ipnt,'c',true,
01176                 " Ne V 3346 of 3426, 3346 doublet " );
01177 
01178         PntForLine(2976.,"Ne 5",&ipnt);
01179         lindst(CoolHeavy.c2975,2976,"Ne 5",ipnt,'c',true,
01180                 " auroral line " );
01181 
01182         PntForLine(1575.,"Ne 5",&ipnt);
01183         lindst(CoolHeavy.c1565,1575,"Ne 5",ipnt,'c',true,
01184                    " collisionally excited" );
01185 
01186         PutLine(&TauLines[ipTNe24],"\n  Ne V 24.2, 14.3 micron ");
01187 
01188         PutLine(&TauLines[ipTNe14],"\n  Ne V 24.2, 14.3 micron ");
01189 
01190         PntForLine(1141.,"Ne 5",&ipnt);
01191         lindst(CoolHeavy.c1134,1141,"Ne 5",ipnt,'c',true," both components of 5S-3P 1146.1, 1137.0 doublet " );
01192 
01193         PutLine(&TauLines[ipxNe0676],"\n  [Ne VI] 7.6 microns ");
01194 
01195         linadd(embesq.em895+TauLines[ipT895].Emis->xIntensity,895,"TOTL",'i',
01196                 " Ne VII 895, collisionally excited, both lines " );
01197 
01198         PutLine(&TauLines[ipT895],
01199                 "  Ne VII 895, only fast transition ");
01200 
01201         linadd(embesq.em895,890,"Ne 7",'i',
01202                 " Ne VII 890, single line " );
01203 
01204         linadd(TauLines[ipT770].Emis->xIntensity+TauLines[ipT780].Emis->xIntensity,774,"TOTL",'i',
01205                 " Ne VIII 774, collisionally excited " );
01206 
01207         sum = TauLines[ipT770].Emis->xIntensity*TauLines[ipT770].Emis->FracInwd + 
01208                 TauLines[ipT780].Emis->xIntensity*TauLines[ipT780].Emis->FracInwd;
01209         linadd(sum,774,"Inwd",'i',
01210                 " inward part of NeVIII 774 line" );
01211 
01212         PutLine(&TauLines[ipT770],
01213                 " the NeVIII 770 780 doublet ");
01214         PutLine(&TauLines[ipT780],
01215                 " ");
01216 
01217         PutLine(&TauLines[ipT88],
01218                 "  Ne VIII 88 2s 3p, collisionally excited ");
01219 
01220         if( trace.lgTrace )
01221         {
01222                 fprintf( ioQQQ, "   lines_lv1_li_ne returns\n" );
01223         }
01224         return;
01225 }
01226 
01227 /*GetLineRec return rec coef*hnu*eden*n_ion for C, N, or O recombination lines from Dima's list,
01228  * also zero's line in master stack so not entered second time in later dump of all rec lines */
01229 STATIC double GetLineRec(
01230         /* this is the number of the emission line in the stack of lines, on the C scale */
01231         long int ip, 
01232         /* the multiplet wavelength */
01233   long int lWl)
01234 {
01235         double GetLineRec_v;
01236 
01237         DEBUG_ENTRY( "GetLineRec()" );
01238 
01239         if( (long)(LineSave.RecCoefCNO[2][ip]+0.5) != lWl )
01240         {
01241                 fprintf( ioQQQ, " GetLineRec called with incorrect wavelength.\n" );
01242                 fprintf( ioQQQ, " index, call and get wl are %5ld%5ld%5ld\n", 
01243                   ip, lWl, (long)(LineSave.RecCoefCNO[2][ip]+0.5) );
01244                 cdEXIT(EXIT_FAILURE);
01245         }
01246 
01247         /* final product is vol emissivity in line */
01248         GetLineRec_v = LineSave.RecCoefCNO[3][ip]*dense.eden*
01249                 dense.xIonDense[(long)(LineSave.RecCoefCNO[0][ip])-1][(long)(LineSave.RecCoefCNO[0][ip]-LineSave.RecCoefCNO[1][ip]+2)-1]*
01250           1.99e-8/LineSave.RecCoefCNO[2][ip];
01251 
01252         /* zero out rec coefficient so that not used again in master dump
01253          * this routine cannot be called twice on same line */
01254         LineSave.RecCoefCNO[3][ip] = 0.;
01255         return( GetLineRec_v );
01256 }

Generated on Mon Feb 16 12:01:26 2009 for cloudy by  doxygen 1.4.7