root/trunk/tsuite/slow/h2_orion_hii_pdr.in

Revision 2539, 13.5 kB (checked in by peter, 4 weeks ago)

Merge the newsolvers branch.

This is the first merge from this branch implementing the new electron temperature and
density solvers, as well as a new method for tracking the convergence of the line optical
depths through different iterations.

In iter_track.h and iter_track.cpp the new classes iter_track and iter_track_basic are
implemented. The iter_track class iterates for the zero-point of a function based on the
van Wijngaarden-Dekker-Brent method, and is used for heavy-duty tracking of convergence
towards the root, complete with a full history of function evaluations. The
iter_track_basic class is a light-weight version that is based on a bisection search for
the zero-point and it does not keep track of the function evaluations.

The new electron density and temperature solvers are based on the iter_track class and as
a result now always bracket the solution before converging onto the solution. This should
improve the quality of the solution. The temperature solver now checks the accuracy of the
electron temperature in addition to the quality of the heating-cooling match. The old
solvers have been removed.

This merge also implements a new method based on the iter_track_basic class to track
convergence of the line optical depths through different iterations. This should improve
convergence when oscillations in the optical depth occur.

In cddefines.h new versions of the safe_div function are added that do not crash on 0/0,
but return a user-supplied argument instead.

The command PUNCH TEGRID has been removed since it is largely redundant. Use the command
PUNCH TEMPERATURE HISTORY instead. The commands SET TEMP/EDEN SOLVER have been removed
since they no longer serve any purpose (only one solver remains).

  • Property svn:eol-style set to native
Line 
1title constant gas pressure orion into pdr
2// >>chng 00 oct 13, from 50 to 10
3stop temperature 10 linear
4c
5c print lots of faint CO lines
6print line faint -4
7// >>chng 02 dec 21, change to set thickness, with new hmole
8// co hits asymptote at 0.9 and so does not stop due to co
9// >>chng 03 sep 12, co network cleaned up, reset thickness to
10// 1 parsec, roughly the width of the cloud
11// stop thickness 1 linear parsec
12// >>chng 05 dec 19, stop at AV 10000 to prevent H2-> H0 in deep regions
13// due to low grain temperature - see further comments below
14stop AV 1000 point
15// >>chng 01 dec 30, make constant gas pressure to avoid Lya rad pressure
16constant gas pressure
17// >>chng 05 jan 06, rm the itertate since this sim is soooo slooooow
18// iterate
19// >>chng 03 sep 12, add this command
20double // mimic existance of unmodeled molecular gas
21sphere
22c
23c the incident continuum is two parts
24c star and flux of photons striking it
25// >>chng 03 sep 12, now go deep into omc1 and cannot assume plane par geometry
26table read "star_kurucz_39600.dat"
27c
28Q(H) 49
29radius 17.4507
30//
31c plus hot brems
32brems 6
33phi(h) 10
34c
35// >>chng 03 apr 30, add cosmic rays to model
36c add cosmic rays, which are important at depth
37cosmic rays, background
38c
39c we have a spherical geometry but want to simulate observing
40c through a spectrometer's slit.  use the aperture
41c command for this
42aperture beam
43c
44c the observed microturbulence
45turbulence 8 km/sec no pressure
46c
47c density and abundances
48hden 4
49init file="ism.ini"
50abundances hii region no grains
51grains orion
52// turn on PAHs with default abundance, depending on physical conditions
53grains pah
54atom h2 
55c
56set nend 2000
57c
58punch overview last "h2_orion_hii_pdr.ovr"
59punch hydrogen 21 cm last "h2_orion_hii_pdr.21cm"
60punch heating "h2_orion_hii_pdr.het"
61punch cooling "h2_orion_hii_pdr.col"
62punch dr last "h2_orion_hii_pdr.dr"
63punch results last "h2_orion_hii_pdr.rlt"
64punch continuum last "h2_orion_hii_pdr.con" units microns
65punch hydrogen lya last "h2_orion_hii_pdr.lya"
66punch grain charge last "h2_orion_hii_pdr.grnchr"
67punch grain potential last "h2_orion_hii_pdr.grnpot"
68punch H2 lines last "h2_orion_hii_pdr.h2lin"
69punch H2 column density last "h2_orion_hii_pdr.h2col"
70punch H2 destruction "h2_orion_hii_pdr.H2d"
71punch H2 creation "h2_orion_hii_pdr.H2c"
72punch molecules "h2_orion_hii_pdr.mol"
73c
74//
75// >>chng 04 mar 26, add large H2
76// all lines changed, so removed history
77//
78// >>chng 07 dec 05, from 0.656 to 0.676, RP iso updates
79assert line luminosity "h  1" 4861 0.676
80//
81assert line luminositry "o  3" 5007 1.236
82//
83// >>chng 06 nov 29, from -1.115 to -1.126, Badnell DR
84assert line luminosity "totl" 4363 -1.126
85//
86// >>chng 06 nov 29, from 0.013 to 0.0462, Badnell DR
87assert line luminosity "o  3" 51.80m 0.0462
88//
89// >>chng 06 aub 06, update O+2 & N+2 CT, from 0.752 to 0.777
90// >>chng 06 nov 29, from 0.777 to 0.736, Badnell DR
91assert line luminosity "totl" 3727 0.736
92//
93// >>chng 06 aub 06, update O+2 & N+2 CT, from -0.020 to -0.034
94// >>chng 06 aug 17, from -0.034 to 0.0328, update [OII] cs
95// >>chng 06 nov 29, from 0.0328 to -0.009, Badnell DR
96assert line luminosity "totl" 7325 -0.009
97//
98// >>chng 06 oct 02, from -1.678 to -1.579 HM update OI cs to Barklem '06
99assert line luminosity "o  1" 6300 -1.579
100//
101// >>chng 05 jul 17, from 0.219 to 0.28 first run in 6 mo
102assert line luminosity "o  1" 63.17m  0.28 error 0.1
103//
104// >>chng 05 jul 17, from -1.10 to -1.05 first run in 6 mo
105// >>chng 06 jun 02, from -1.05 to -1.09, NA refactor chem, bug fix
106assert line luminosity "c  2" 157.6m -1.09 error 0.1
107//
108// >>chng 05 jul 17, from -0.74 to -0.67 first run in 6 mo
109assert line luminosity "si 2" 34.81m -0.67 error 0.1
110//
111// >>chng 05 dec 19, from 3.630 to 3.514, stop AV 1000
112assert line luminosity "GraT" 0 3.514
113//
114// >>chng 05 sep 08, from 25.49 to 25.45, first run in two months
115// >>chng 05 dec 19, from 25.45 to 23.95, stop AV 1000
116assert H2 column density 23.95 error 0.1
117//
118// >>chng 05 jul 17, from 22.26 to 21.89 first run in 6 mo
119// >>chng 05 dec 19, from 21.89 to 20.73, stop AV 1000
120assert CO column density 20.73 error 0.15
121//
122// >>chng 05 sep 08, from -2.96 to -2.93, first run in two months
123// >>chng 05 dec 19, from -2.93 to -2.99, stop AV 1000
124// >>chng 06 mar 02, from -2.99 to -2.94, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
125// also energy barrier for H + (CH and CH2) reactions
126// >>chng 06 jun 02, from -2.94 to -2.84, NA refactor chem, bug fix
127assert line luminosity "12CO" 647.2m  -2.84 error 0.1
128//
129// >>chng 05 jul 17, from -2.70 to -2.67 first run in 6 mo
130// >>chng 05 dec 19, from -2.67 to -2.71, stop AV 1000
131// >>chng 06 mar 02, from -2.71 to -2.66, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
132// also energy barrier for H + (CH and CH2) reactions
133// >>chng 06 jun 02, from -2.66 to -2.56, NA refactor chem, bug fix
134assert line luminosity "12CO" 517.8m  -2.56 error 0.1
135//
136// >>chng 05 jul 17, from -2.50 to -2.46 first run in 6 mo
137// >>chng 06 jun 02, from -2.46 to -2.35, NA refactor chem, bug fix
138assert line luminosity "12CO" 431.5m  -2.35 error 0.1
139//
140// >>chng 05 jul 17, from -2.33 to -2.29 first run in 6 mo
141// >>chng 06 jun 02, from -2.29 to -2.21, NA refactor chem, bug fix
142assert line luminosity "12CO" 369.8m  -2.21 error 0.1
143//
144// >>chng 05 jul 17, from -2.18 to -2.15 first run in 6 mo
145// >>chng 06 jun 02, from -2.15 to -2.10, NA refactor chem, bug fix
146assert line luminosity "12CO" 323.6m  -2.10 error 0.1
147//
148// >>chng 05 jul 17, from -2.06 to -2.03 first run in 6 mo
149// >>chng 05 dec 19, from -2.02 to -2.07, stop AV 1000
150// >>chng 06 jun 02, from -2.07 to -2.02, NA refactor chem, bug fix
151assert line luminosity "12CO" 287.7m  -2.02 error 0.1
152//
153// >>chng 05 jul 17, from -1.99 to -1.96 first run in 6 mo
154// >>chng 05 dec 19, from -1.96 to -2.00, stop AV 1000
155assert line luminosity "12CO" 258.9m  -2.00 error 0.1
156//
157// >>chng 05 jul 17, from -2.00 to -1.96 first run in 6 mo
158// >>chng 05 sep 08, from -1.96 to -1.92, first run in two months
159// >>chng 05 dec 19, from -1.92 to -1.99, stop AV 1000
160assert line luminosity "12CO" 235.4m  -1.99 error 0.1
161//
162// >>chng 05 jul 17, from -2.19 to -2.06 first run in 6 mo
163// >>chng 05 sep 08, from -2.06 to -1.98, first run in two months
164// >>chng 05 dec 19, from -1.98 to -2.12, stop AV 1000
165// >>chng 07 feb 06, bugfix in r828, from -2.12 to -2.09 (9.03)
166assert line luminosity "12CO" 215.7m  -2.09 error 0.1
167//
168// >>chng 05 dec 19, from 1600 to 1400, stop AV 1000
169// >>chng 08 dec 08, from 1400 to 1266, upper limit -> equals (r2515)
170assert nzone 1266 error 0.01
171//
172// >>chng 04 dec 08, from 13 to 19 co-ion feedback, check converg
173// >>chng 05 jul 17, from 19 to 25 first run in 6 mo
174// >>chng 08 dec 08, from 25 to 20.36, upper limit -> equals (r2515)
175// >>chng 08 dec 13, from 20.36 to 34.55, merging newsolvers branch
176assert itrzn 34.55 error 0.02
177//
178// these added 05 jan 23
179// >>chng 05 sep 08, from 25.49 to 25.45, first run in two months
180// >>chng 05 dec 19, from 25.45 to 23.91, stop AV 1000
181assert H2 column density level 0  0  23.91 error 0.1
182//
183// >>chng 05 jul 17, from 23.34 to 23.49 first run in 6 mo
184// >>chng 05 sep 08, from 23.49 to 23.55, first run in two months
185// >>chng 05 dec 19, from 23.55 to 22.96, stop AV 1000
186// >>chng 08 feb 10, from 22.96 to 23.03, chng CR heat efficiency
187assert H2 column density level 0  1  23.03 error 0.1
188//
189// >>chng 05 jul 17, from 18.74 to 19.76 first run in 6 mo
190// >>chng 05 sep 08, from 19.76 to 19.81, first run in two months
191// >>chng 05 dec 19, from 19.81 to 19.67, stop AV 1000
192// >>chng 06 jun 02, from 19.67 to 19.50, NA refactor chem, bug fix
193// >>chng 07 dec 05, from 19.50 to 19.57 H-H2 coll update
194// >>chng 08 mar 17, from 19.57 to 19.52 line overlap??, not run recently
195// >>chng 08 sep 25, from 19.52 to 19.56, remove damper on line pump (r2367)
196assert H2 column density level 0  2  19.56 error 0.1
197//
198// >>chng 05 jul 17, from 18.41 to 18.83 first run in 6 mo
199// >>chng 05 sep 08, from 18.83 to 18.75, first run in two months
200// >>chng 05 sep 17, from 18.75 to 18.71, update H- rate
201// >>chng 06 mar 02, from 18.71 to 18.88, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
202// also energy barrier for H + (CH and CH2) reactions
203// >>chng 06 jun 02, from 18.88 to 18.50, NA refactor chem, bug fix
204// >>chng 07 feb 06, bugfix in r828, from 18.50 to 18.53 (9.03)
205// >>chng 07 dec 05, from 18.53 to 18.83 H-H2 coll update
206// >>chng 08 mar 17, from 18.83 to 18.73 line overlap??, not run recently
207// >>chng 08 sep 25, from 18.73 to 18.79, remove damper on line pump (r2367)
208assert H2 column density level 0  3  18.79 error 0.1
209//
210// >>chng 05 feb 12, from 15.54 to 15.58, better H2 conv
211// >>chng 05 jul 17, from 15.58 to 16.44 first run in 6 mo
212// >>chng 05 sep 08, from 16.44 to 16.37, first run in two months
213// >>chng 05 sep 17, from 16.37 to 16.32, update H- rate
214// >>chng 06 mar 02, from 16.32 to 16.40, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
215// also energy barrier for H + (CH and CH2) reactions
216// >>chng 06 jun 02, from 16.40 to 16.23, NA refactor chem, bug fix
217// >>chng 07 dec 05, from 16.23 to 16.43 H-H2 coll update
218// >>chng 07 dec 31, from 16.43 to 16.52 additional vJ H-H2 rates
219// >>chng 08 mar 17, from 16.52 to 16.35 line overlap??, not run recently
220// >>chng 08 sep 25, from 16.35 to 16.4, remove damper on line pump (r2367)
221assert H2 column density level 0  4  16.4 error 0.1
222//
223// >>chng 05 jul 17, from 17.29 to 17.18 first run in 6 mo
224// >>chng 05 sep 08, from 17.18 to 17.14, first run in two months
225// >>chng 06 nov 29, from 17.14 to 17.09, Badnell DR
226// >>chng 07 dec 05, from 17.09 to 16.88 H-H2 coll update
227// >>chng 07 dec 31, from 16.88 to 17.11 additional vJ H-H2 rates
228assert H2 column density level 0  5  17.11 error 0.1
229//
230// >>chng 05 feb 12, from 16.01 to 16.06, better H2 conv
231// >>chng 05 jul 17, from 16.06 to 16.72 first run in 6 mo
232// >>chng 05 sep 17, from 16.72 to 16.68, update H- rate
233// >>chng 05 dec 19, from 16.68 to 16.55, stop AV 1000
234// >>chng 06 mar 02, from 16.55 to 16.59, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
235// also energy barrier for H + (CH and CH2) reactions
236// >>chng 06 jun 02, from 16.59 to 16.53, NA refactor chem, bug fix
237// >>chng 07 apr 10, from 16.53 to 16.48, ORNL H2-He collisions
238// >>chng 07 dec 05, from 16.48 to 16.40 H-H2 coll update
239// >>chng 08 sep 25, from 16.4 to 16.35, remove damper on line pump (r2367)
240assert H2 column density level 0  6  16.35 error 0.1
241//
242// >>chng 05 feb 12, from 17.29 to 17.24, better H2 conv
243// >>chng 05 jul 17, from 17.24 to 17.12 first run in 6 mo
244// >>chng 05 dec 19, from 17.12 to 17.03, stop AV 1000
245// >>chng 07 dec 05, from 17.03 to 16.35 H-H2 coll update
246// >>chng 07 dec 31, from 16.35 to 16.86 additional vJ H-H2 rates
247assert H2 column density level 0  7  16.86 error 0.15
248//
249// >>chng 05 feb 12, from 15.52 to 15.55, better H2 conv
250// >>chng 05 jul 17, from 15.55 to 16.13 first run in 6 mo
251// >>chng 05 dec 19, from 16.13 to 15.94, stop AV 1000
252// >>chng 07 feb 03, from 15.94 to 15.90, drift down
253// >>chng 07 feb 06, bugfix in r828, from 15.99 to 15.90 (9.03)
254// >>chng 07 dec 05, from 15.90 to 15.61 H-H2 coll update
255// >>chng 07 dec 31, from 15.61 to 15.79 additional vJ H-H2 rates
256// >>chng 08 may 16, from 15.79 to 15.785, increase error, sensitive to computational detail
257assert H2 column density level 0  8  15.785 error 0.15
258//
259// >>chng 05 jul 17, from 16.74 to 16.62 first run in 6 mo
260// >>chng 05 dec 19, from 16.62 to 16.53, stop AV 1000
261// >>chng 07 dec 05, from 16.53 to 15.50 H-H2 coll update
262// >>chng 07 dec 31, from 15.50 to 16.33 additional vJ H-H2 rates
263assert H2 column density level 0  9  16.33 error 0.15
264//
265// >>chng 05 feb 12, from 14.54 to 14.57, better H2 conv
266// >>chng 05 jul 17, from 14.57 to 15.15 first run in 6 mo
267// >>chng 05 sep 08, from 15.15 to 15.07, first run in two months
268// >>chng 05 dec 19, from 15.07 to 14.93, stop AV 1000
269// >>chng 07 feb 06, bugfix in r828, from 14.93 to 14.89 (9.03)
270// >>chng 07 dec 31, from 14.89 to 14.94 additional vJ H-H2 rates
271// >>chng 08 feb 10, from 14.94 to 14.99, chng CR heat efficiency
272// >>chng 08 mar 17, from 14.99 to 14.92 line overlap??, not run recently
273assert H2 column density level 1  0  14.92 error 0.1
274//
275// >>chng 05 jul 17, from 15.97 to 15.86 first run in 6 mo
276// >>chng 05 sep 08, from 15.86 to 15.78, first run in two months
277// >>chng 05 dec 19, from 15.78 to 15.74, stop AV 1000
278// >>chng 06 mar 02, from 15.74 to 15.78, NA Fe0, Mg0, <-> Si+, S+, C+ ct,
279// also energy barrier for H + (CH and CH2) reactions
280// >>chng 06 jun 02, from 15.78 to 15.71, NA refactor chem, bug fix
281// >>chng 07 apr 10, from 15.71 to 15.76, ORNL H2-He collisions
282// >>chng 07 dec 05, from 15.76 to 15.94 H-H2 coll update
283// >>chng 07 dec 31, from 15.94 to 15.70 additional vJ H-H2 rates
284assert H2 column density level 1  1  15.70 error 0.1
285//
286// >>chng 05 feb 12, from 14.85 to 14.87, better H2 conv
287// >>chng 05 jul 17, from 14.87 to 15.34 first run in 6 mo
288// >>chng 05 sep 08, from 15.34 to 15.23, first run in two months
289// >>chng 05 dec 19, from 15.23 to 15.19, stop AV 1000
290// >>chng 07 dec 05, from 15.19 to 15.11 H-H2 coll update
291// >>chng 07 dec 31, from 15.11 to 15.15 additional vJ H-H2 rates
292// >>chng 08 mar 17, from 15.15 to 15.11 line overlap??, not run recently
293assert H2 column density level 1  2  15.11 error 0.1
294//
295// >>chng 05 jul 17, from 15.69 to 15.62 first run in 6 mo
296// >>chng 05 sep 08, from 15.62 to 15.55, first run in two months
297// >>chng 07 apr 10, from 15.55 to 15.49, ORNL H2-He collisions
298// >>chng 07 dec 05, from 15.49 to 15.59 H-H2 coll update
299// >>chng 07 dec 31, from 15.59 to 15.44 additional vJ H-H2 rates
300assert H2 column density level 1  3  15.44 error 0.1
301//
302c h2_orion_hii_pdr.in
303
30405 dec 19,  had stopped at 1 pc, gas/dust got very cold and H2 stopped
305forming, H2 went to H0 - this below the CO network out of the water.
306stop at AV of 1000 instead.  Is this loss of H2 at low grain temperature
307physical?  Is it ever seen?
308
Note: See TracBrowser for help on using the browser.