4. Numerical results
In this section, the Monte Carlo technique and the temperature-correction procedure described in Sect. 3 are used to derive the radiative equilibrium solution for the density stratification given by Castor's (1974) code.
The basic parameters for the extended, spherical atmosphere are , , and a composition of pure hydrogen. With these parameters, The luminosity is therefore close to the Eddington limit, and so the atmosphere is distended by the greatly reduced effective gravity.
As Castor (1974) himself pointed out, such high values of are not achieved by stars in their hydrogen-burning phases, and so this mechanism is certainly not relevant for the extended continuum-forming layers of Of stars. The interest here is that the resulting stratification makes sphericity important. Moreover, the Schuster mechanism in such extended, scattering-dominated atmospheres results in the Lyman continuum being in emission. Together, these aspects of Castor's (1974) work provide a challenging test for the Monte Carlo approach.
For the Monte Carlo calculation, the lower boundary is taken to be at , corresponding to Rosseland mean optical depth according to Castor's code. The constant ratio is set = 1.053 as in Castor's calculation, a choice that eliminates the need for interpolation when comparing temperature distributions. With these choices, the number of shells is , and the outer radius is .
In sampling black body emission at the lower boundary and the emissivity in each shell, equal probability bins are used.
4.2. Temperature corrections
With the above parameters, Castor's code computes , and the emergent spectrum. For the Monte Carlo calculation, this is taken as given and an initial guess made for the temperature distribution. With two state variables thus known, the degree of ionization of hydrogen and the scattering and absorption coefficients can be calculated for all shells. Together with an initial guess for the boundary temperature, these coefficients then allow a Monte Carlo step to be made. At the completion of this step, a divergence-free model of the ambient radiation field is available, from which an improved temperature distribution and an improved boundary temperature are computed as described in Sect. 3.5. This procedure is then repeated until "convergence" is achieved.
In Fig. 1, the results of 13 such iterations are shown in a Monte Carlo experiment for which is the number of packets emitted at the lower boundary. Since Castor's code provides an essentially exact , the plotted quantity is rather than , the fractional change from the previous approximation.
From Fig. 1, we see that the iterations (with an overly cautious undercorrection factor = 0.5) converge rapidly until but thereafter exhibit apparently random fluctuations about a mean that agrees to better than 1% with Castor's solution. For most astrophysical purposes, both the amplitude of the fluctuations after "convergence" and the accuracy of recovering a known solution are entirely satisfactory. (A slight anomaly at the surface may be seen in Fig. 1, in the form of a slight uptick in the fractional errors of all iterates. This is due to the way the were derived from Castor's model, which results in his surface value being assigned to the mid-point of the outermost shell in the Monte Carlo calculation.)
Although of little consequence, the displacement from Castor's solution is systematic and therefore merits investigation. When the calculation is repeated with the lower boundary higher in the atmosphere - i.e., larger - this systematic displacement increases. This suggests that the problem is the approximation - Eq. (2) - used as the lower boundary condition, and which is valid only in the limit . Nevertheless, there may also be a contribution to the displacement from small differences in the two codes' treatments of the absorption coefficient as well as from the cruder discretizations used in the Monte Carlo calculation.
4.3. Grey atmospheres
As a further check on systematic error, the Monte Carlo code has been applied to the essentially trivial problem of computing grey atmospheres in radiative equilibrium.
In the plane-parallel case, the lower boundary is placed at , and the limb-darkening law obeyed by the emitted packets is linear with coefficient , which would be exact if for were the Milne-Eddington solution. In an experiment with packets, the derived temperature distribution matched that calculated with the Hopf function with root mean square error = 0.021% and maximum error = 0.045%. These are negligibly small compared to the offset in Fig. 1 from Castor's solution.
In this same Monte Carlo experiment, the mean intensity is also calculated as in Och et al. (1998) using reference surfaces at the mid-points of the slabs into which the plane-parallel atmosphere is discretized. The resulting temperature distribution obtained by setting has root mean square error = 0.031% and maximum error = 0.061%. These are moderately inferior to the results above and therefore support the preference for volume-based mean intensity estimators.
The Monte Carlo code has also been applied to spherical grey atmospheres, specifically to the calculations of Hummer & Rybicki (1971). In an experiment with , their temperature distribution for opacity index and outer radius is reproduced with root mean square error = 0.061% and maximum error = 0.20%.
These grey atmosphere successes confirm that high precision can be achieved with this Monte Carlo code and that the slight offset in the non-grey test case is not a consequence of the adopted technique.
4.4. Emergent spectrum
Having demonstrated in Sect. 4.2 that the iterative scheme reproduces Castor's temperature distribution with acceptable accuracy, we now compare emergent spectra. With the temperature distribution from the 13th iteration - an unnecessarily large number of iterations, in fact - a further Monte Carlo step is carried out with N increased by a factor of 5 to packets. Of these, escape to infinity and their distribution in frequency constitutes the Monte Carlo prediction for the emergent spectrum. This prediction (filled circles) is shown in Fig. 2, together with the spectrum predicted by Castor's conventional transfer calculation.
Comparison of the two theoretical spectra reveals excellent agreement in the Lyman and Balmer continua. In particular, the operation of the Schuster mechanism in inverting the Lyman discontinuity has evidently been accurately modelled. A significant fall-off in accuracy is, however, seen in the IR and EUV. This is of course a consequence of the small number of escaping packets in these frequency bins and illustrates the limited dynamical range of Monte Carlo calculations.
In 2- or 3-D problems, it will often be desirable to compute spectra as seen from different orientations after deriving the temperature stratification with a technique such as described here. This can be done via the formal integral for the emergent intensity - i.e., by computing the intensity observed along multiple lines-of-sight to the object when viewed at the required orientation and then summing to obtain the luminosity density . But to do this, the mean intensity is needed in order to evaluate the source function at points along these lines-of-sight. In fact, the necessary estimator is given by Eq. (12), which converts to physical units when is determined by forcing the Monte Carlo calculation to be consistent with the luminosity of the source(s) illuminating the domain of calculation.
A formal-integral calculation of the emergent spectrum using the source function thus extracted from the simulation has been carried out with the familiar cylindrical coordinates. The resulting spectrum is plotted in Fig. 2 as open circles and is seen to agree closely with the spectrum derived from escaping packets.
© European Southern Observatory (ESO) 1999
Online publication: March 10, 1999