-
PDF
- Split View
-
Views
-
Cite
Cite
Matthew R. Bate, Eric R. Keto, Combining radiative transfer and diffuse interstellar medium physics to model star formation, Monthly Notices of the Royal Astronomical Society, Volume 449, Issue 3, 21 May 2015, Pages 2643–2667, https://doi.org/10.1093/mnras/stv451
- Share Icon Share
Abstract
We present a method for modelling star-forming clouds that combines two different models of the thermal evolution of the interstellar medium (ISM). In the combined model, where the densities are low enough that at least some part of the spectrum is optically thin, a model of the thermodynamics of the diffuse ISM is more significant in setting the temperatures. Where the densities are high enough to be optically thick across the spectrum, a model of flux-limited diffusion is more appropriate. Previous methods either model the low-density ISM and ignore the thermal behaviour at high densities (e.g. inside collapsing molecular cloud cores), or model the thermal behaviour near protostars but assume a fixed background temperature (e.g. ≈10 K) on large scales. Our new method treats both regimes. It also captures the different thermal evolution of the gas, dust, and radiation separately. We compare our results with those from the literature, and investigate the dependence of the thermal behaviour of the gas on the various model parameters. This new method should allow us to model the ISM across a wide range of densities and, thus, develop a more complete and consistent understanding of the role of thermodynamics in the star formation process.
1 INTRODUCTION
The thermal behaviour of interstellar gas is of fundamental importance for star formation. To initiate star formation, the thermal pressure must be insufficient to support the gas against gravitational collapse (Jeans 1929). Further evolution also depends on the thermodynamics and density structure, with a variety of different outcomes being possible such as the formation of a single polytrope or fragmentation into many clouds (Hoyle 1953; Hunter 1962; Layzer 1963; Tohline 1980; Rozyczka 1983). Larson (1985, 2005) emphasized the importance of the relationship between temperature and density in the interstellar medium (ISM), and Whitworth, Boffin & Francis (1998) emphasized the importance of the transition from molecular cooling to dust cooling. The typical decrease in gas temperature from Tg ∼ 1000 K at number densities of hydrogen nuclei of nH ∼ 1 cm−3 to Tg ∼ 10 K at densities of nH ∼ 104 cm−3 promotes fragmentation, while the transition to an isothermal regime or temperature that increases with density above nH ∼ 104 cm−3 may help to produce a characteristic stellar mass (Larson 1985, 2005; Jappsen et al. 2005; Bonnell, Clarke & Bate 2006; Elmegreen, Klessen & Wilson 2008). Chemical reactions that control the abundances of gas phase coolants, and therefore radiative equilibrium, may affect this transition and the formation of molecular cloud cores. At even higher densities, deep within collapsing molecular cloud cores, different phases of collapse are believed to occur as the gas becomes optically thick and later as molecular hydrogen dissociates (Larson 1969). The treatment of radiative transfer can be crucial for determining whether the core fragments into multiple protostars or not (Boss et al. 2000; Krumholz 2006; Whitehouse & Bate 2006).
Previous radiation hydrodynamical simulations of star cluster formation demonstrate the importance of radiative feedback from protostars to correctly capture fragmentation and produce realistic numbers of brown dwarfs (Bate 2009; Offner et al. 2009). Whereas barotropic calculations of star cluster formation produce characteristic stellar masses that depend on the initial Jeans mass in the cloud (Bate & Bonnell 2005), Bate (2009) showed that radiative feedback reduces this dependence on the initial conditions. This may help to explain the apparent universality of the stellar initial mass function (IMF), at least in recent epochs (see also Krumholz 2011). Indeed, some recent radiation hydrodynamical simulations of star cluster formation have been quite successful in reproducing the observed IMF and other properties of stellar systems (Bate 2012, 2014; Krumholz, Klein & McKee 2012).
However, to date, radiation hydrodynamical simulations of star formation have been restricted to modelling dense molecular clouds and assuming that the only significant sources of radiation are the protostars themselves. In this case, the gas temperature at large distances from the protostars is assumed to be ≈10 K. However, this approximation is generally invalid at densities nH ≲ 104 cm−3 with solar metallicities, and is invalid at even higher densities at lower metallicities, if at all.
Informed by the vast literature on the physics, thermodynamics, and chemistry of the diffuse ISM (see the thorough review provided by Tielens 2005) and collapsing clouds with different metallicities (e.g. Omukai 2000; Omukai et al. 2005), interest has grown in studying the formation and evolution of molecular clouds using three-dimensional hydrodynamical calculations coupled with chemistry. Initial calculations treated only the formation of molecular hydrogen (Dobbs, Bonnell & Pringle 2006; Dobbs & Bonnell 2007; Glover & Mac Low 2007a,b; Micic et al. 2012). More recent work has included more complex chemistry, in particular that involving carbon and oxygen (Glover et al. 2010; Glover & Mac Low 2011; Clark et al. 2012b; Glover & Clark 2012a,b,c). Along with the formation mechanisms of molecular clouds and their chemical and temperature distributions, some of these calculations have begun to investigate star formation, using sink particles to replace collapsing regions of gas (in particular, the models of Glover & Clark). At the same time, there have been several studies of the chemical and thermal evolution of low-metallicity clouds and their star formation (e.g. Dopcke et al. 2011, 2013; Glover & Clark 2012c).
Therefore, at the present time, the star formation community has two different classes of hydrodynamical models for star formation. One class treats the low-density thermochemical evolution in some detail, but does not treat radiative feedback from protostars. The other ignores the complicated physics of the diffuse ISM, which is particularly important at low densities and low metallicities, but includes the radiative effects of protostars. The goal of this paper is to make an attempt to bridge this gap, by combining a model for the physics of the low-density ISM with a method for modelling radiative transfer. Our main purpose is to develop a model that does a reasonable job of modelling the thermodynamics at both low and high densities in star-forming clouds, with metallicities as low as 1/100 solar. The aim is not to produce a detailed chemical model. Rather, we wish to implement the simplest possible chemical model that will provide the abundances of the major coolants of the gas that are necessary to calculate realistic temperatures.
It turns out that a method very similar to that which we present here has recently been developed by Pavlyuchenkov & Zhilkin (2013) and Pavlyuchenkov et al. (2015). Although we developed our method independently, each of the methods is based on extending a method of radiative transfer that is valid at high densities to include effects that are important at low densities. Each of the methods treats gas and dust temperatures separately. Pavlyuchenkov & Zhilkin (2013) base their method on the diffusion approximation for radiative transfer and add heating and cooling terms relevant at lower densities to model the collapse of dense molecular cloud cores. Pavlyuchenkov et al. (2015) replace the diffusion approximation with flux-limited diffusion like we use in this paper. They do not include cooling processes relevant at very low densities that we include (e.g. electron recombination and fine-structure emission from atomic oxygen), and they only perform one-dimensional calculations, but the underlying methods are very similar.
This paper is primarily a method paper where we describe our implementation and demonstrate its performance in a wide variety of tests, comparing our results to those of others who have performed similar calculations (sometimes using much more complete and/or complex models). However, we also explore the effects of varying many of the parameters that go into the model in order to better understand which physical processes may be most important for affecting star formation. Large-scale star formation calculations are beyond the scope of this paper, but we hope to use this new method to perform such calculations in the future.
In Section 2, we provide the fundamental equations and assumptions that go into our model. The implementation of these equations into a smoothed particle hydrodynamics (SPH) code is described in Section 3. We present the results from our test calculations, and compare our results with those in the literature in Section 4. Finally, we draw our conclusions in Section 5.
2 METHOD
2.1 The flux-limited diffusion approximation
Taking an ideal equation of state for the gas pressure p = (γ − 1)uρ, where u = e/ρ is the specific energy of the gas, the temperature of the gas is |$T_{\rm g} = (\gamma -1) \mu u/{\cal {R}}$|, where μ is the mean molecular weight of the gas and |$\cal {R}$| is the gas constant. The frequency-integrated Planck function is given by |$B=(\sigma _{\rm B}/\pi )T_{\rm g}^4$|, where σB is the Stefan–Boltzmann constant. The radiation energy density also has an associated temperature Tr from the equation |$E=4 \sigma _{\rm B}T_{\rm r}^4/c$|.
There are a number of problems with using the flux-limited diffusion approximation to model radiative processes in star formation. Many of these are a direct result of the approximations made in deriving the method. The diffusion approximation is good at high optical depths, but the directional behaviour of anisotropic radiation at low optical depths is modelled poorly. This means, for example, that shadowing is not reproduced. The flux limiter gives the correct limiting behaviour for the propagation rate in the optically thin and thick regimes, but at intermediate optical depths is dependent on the arbitrary choice of the flux limiter. Finally, most implementations take the grey approach, ignoring the frequency dependence of the radiative transfer in favour of mean opacities (as discussed above). This is likely to be a good approximation when most of the energy is in long-wavelength radiation, but is a poor approximation near hot massive stars (Wolfire & Cassinelli 1987; Preibisch, Sonnhalter & Yorke 1995; Yorke & Sonnhalter 2002; Edgar & Clarke 2003).
Despite these drawbacks, flux-limited diffusion is expected to do a reasonable job of modelling radiative transfer in dense star-forming regions that produce low-mass stars (e.g. Bate 2009, 2012; Offner et al. 2009), and it is computationally efficient.
2.2 The diffuse ISM
However, other problems arise when modelling low-density environments. For a start, the above-mentioned equations treat radiation and matter, but do not distinguish between different types of matter which may have different temperatures. In particular, at solar metallicities, dust and gas temperatures are only well coupled (by collisions) at gas densities above 105 cm−3 (Burke & Hollenbach 1983; Goldsmith 2001; Glover & Clark 2012a). At lower densities, the gas and dust temperatures can be very different from one another with the gas temperature typically exceeding that of the dust. There are also sources of heating that affect the matter other than work done on the gas and the radiative interaction between the matter and the radiation field that are included in equation (4). Cosmic rays heat the gas by direct collision (Goldsmith, Habing & Field 1969; O'Donnell & Watson 1974; Black & Dalgarno 1977; Goldsmith & Langer 1978). Ultraviolet (UV) photons heat the gas indirectly through the photoelectric release of hot electrons from dust grains (Draine 1978; Bakes & Tielens 1994). Absorption and emission of radiation that is highly frequency dependent is also problematic in a grey treatment. In particular, gas cooling occurs by atomic and molecular line cooling which may be optically thin due to Doppler shifts even when static clouds would be optically thick. The external interstellar radiation (ISR) field (Habing 1968; Witt & Johnson 1973; Draine 1978; Black 1994), attenuated by dust extinction, also heats the dust.
2.3 Combining a diffuse ISM model with flux-limited diffusion
In this section, we present a method to combine a model of the radiative equilibrium of the diffuse ISM with flux-limited diffusion to determine the gas, dust, and radiation temperatures in both low-density and high-density regions of molecular clouds. We include treatments for all of the effects mentioned in the previous section. We also allow for heating due to H2 formation. We do not treat photoionization or heating from X-rays.
2.4 Equations for heating and cooling terms in the ISM
To calculate the extra heating and cooling terms appearing in equations (12)–(14), we make the same approximations as those made in the past by many others who have studied the thermal structure of molecular clouds.
2.4.1 Gas heating equations
2.4.2 Gas cooling equations
At the low densities of the WNM and CNM, the equations for cosmic ray and photoelectric heating and cooling due to electron recombination and oxygen and carbon cooling can be used to calculate the equilibrium temperature as a function of density. This equilibrium curve resulting from our chosen parametrizations is shown in Fig. 1 as the solid line and compared to the results obtained by Wolfire et al. (2003) for solar metallicities at a Galactic radius of 8.5 kpc using a dashed line. Given that our model is much simpler than that of Wolfire et al. (2003) and that our main interest is in the star formation occurring in higher density (nH ≳ 100 cm−3) molecular gas where other processes dominate, the level of agreement is satisfactory. Also plotted in the figure with a dotted line is the result obtained by Glover & Mac Low (2007a). We note that our model gives slightly lower temperatures than Wolfire et al. (2003) at densities nH ≳ 20 cm−3, while the model of Glover & Mac Low (2007a) gives somewhat higher temperatures.

The equilibrium temperature as a function of the number density of hydrogen nuclei, nH, in the warm and cold neutral mediums achieved by considering cosmic ray and photoelectric heating (without extinction) balanced by cooling due to electron recombination, and fine-structure emission from carbon and oxygen (solid line; equations 24, 26, 30, 32, and 33). The dashed line gives the result obtained by Wolfire et al. (2003) for solar metallicity gas at a Galactic radius of 8.5 kpc. The dotted line gives the result from the model of Glover & Mac Low (2007a).
To allow for depletion, we use table 4 of Goldsmith (2001) which gives cooling rates as functions of density over the range nH2 = 103–106 cm−3 and as functions of a depletion factor ranging from 1 to 100. When depletion is allowed, for nH2 < 102 cm−3 we use the standard cooling rates divided by the depletion factor, and for nH2 > 107 cm−3 we use the standard cooling rates (since the cooling rates become less dependent on the depletion factor at high densities, according to Goldsmith 2001). In the intermediate density range, we use bilinear interpolation in log-space of the values in table 4 that are given as functions of density and depletion. In the ranges nH2 = 102–103 cm−3 and nH2 = 106–107 cm−3, we further use linear interpolation in log-space to achieve smooth transitions between using the depleted cooling rates (from table 4) and the depleted standard cooling rates (nH2 = 102–103 cm−3) or the standard cooling rates (nH2 = 106–107 cm−3).
2.4.3 Dust heating and cooling equations
2.4.4 Metallicity
In all of the above-mentioned equations, we have assumed standard abundances and gas-to-dust mass ratios. To allow the modelling of molecular gas with different metallicities, we assume that Qν (and hence κd), Λgd, Λline, and Γpe all scale linearly with the metallicity. Thus, each of these quantities is multiplied by the factor Z/Z⊙. In doing so, we are also assuming that the grain properties are independent of the metallicity. Note that Γcr does not depend on the metallicity. Also, the gas opacities, κg, already explicitly include the metallicity dependence (see Section 3.3).
2.5 Chemistry
As mentioned in the Introduction, our aim with this method is to develop a relatively simple model that captures the most important thermodynamic behaviour of the low-density ISM, not to develop a full chemical model of molecular clouds. The equations in the previous section almost enable us to do this without modelling any chemistry at all. However, as we will see in Section 4.4, we do need to have some model to treat the transformation of C+ into CO. At low densities (nH ≈ 10–103 cm−3) C+ is the major coolant, while at higher densities CO is the primary coolant until dust takes over (e.g. Glover & Clark 2012b). Furthermore, particularly at low metallicities, extra heating of the gas can be provided by the formation of molecular hydrogen so we need to treat the evolution of atomic and molecular hydrogen.
2.5.1 Carbon chemistry
2.5.2 Hydrogen chemistry
For the hydrogen chemistry, we only consider H2 formation on grains and dissociation due to cosmic rays and photodissociation. Omukai (2000) finds that grain formation dominates over gas phase formation (i.e. via H− or H|$_2^+$| ions) for metallicities Z/Z⊙ ≳ 10−4. Glover (2003) compares gas-phase and grain-catalysed formation in detail and draws similar conclusions – for temperatures less than a few hundred kelvin, H2 formation on grains is expected to dominate for dust-to-gas ratios ≳ 10−3–10−4 of that found in the local ISM, over wide ranges of densities and levels of ionization. We neglect collisional dissociation of H2 as at the temperatures we are dealing with in the low-density ISM it is expected to be negligible compared to photodissociation and dissociation due to cosmic rays (cf. the rates in Lepp & Shull 1983).
In the previous sections, when we have used nH2, it has been in the context of fully molecular gas for which nH2 = nH/2. However, with the introduction of hydrogen chemistry, we need to distinguish between atomic and molecular hydrogen. We therefore introduce the fraction of molecular hydrogen, xH2, which is equal to nH2/nH = 1/2 when the gas is fully molecular, and is equal to zero when the gas is fully atomic.
In addition to heating due to molecular hydrogen formation, we investigated (using calculations similar to those presented in Section 4.4) the effect of including gas heating during H2 photodissociation and due to UV pumping of H2 (Glover & Mac Low 2007a). However, we found that it is usually insignificant. The extra heating only has a significant effect when the gas is initially highly molecular and has a low metallicity (Z ≲ 0.1 Z⊙). Such circumstances are highly unrealistic because the low extinction favours prior destruction of the H2. Even then, the heating only affects the outer, low-density (nH ≲ 103 cm−3) parts of the clouds (because of H2 self-shielding) which are even less likely to be molecular than the inner parts of the clouds. Since we find this heating to be insignificant in realistic situations, and for the sake of simplicity, we do not include this effect.
3 IMPLEMENTATION
The calculations presented in this paper were performed using a three-dimensional SPH code based on the original version of Benz (1990; Benz et al. 1990), but substantially modified as described in Bate, Bonnell & Price (1995), Whitehouse et al. (2005), Whitehouse & Bate (2006), Price & Bate (2007), and parallelized using both OpenMP and the message passing interface (MPI).
Gravitational forces between particles and a particle's nearest neighbours are calculated using a binary tree. The cubic spline kernel is used and the smoothing lengths of particles are variable in time and space, set iteratively such that the smoothing length of each particle h = 1.2(m/ρ)1/3, where m and ρ are the SPH particle's mass and density, respectively (see Price & Monaghan 2007, for further details). The SPH equations are integrated using a second-order Runge–Kutta–Fehlberg integrator (Fehlberg 1969) with individual time steps for each particle (Bate et al. 1995). To reduce numerical shear viscosity, we use the Morris & Monaghan (1997) artificial viscosity with αv varying between 0.1 and 1 while βv = 2αv (see also Price & Monaghan 2005).
3.1 Implementation of the new method
In this section, we describe the detailed implementation of the method described in Section 2. The two main new elements are the implicit integration of equations (12)–(14), and the calculation of the dust attenuation which is required to compute the local ISR that appears in equations (27), (35), and the extinction in equation (39).
3.1.1 Solving the energy equations
In solving the energy equations (12)–(14), we closely follow the implementation of the flux-limited diffusion method of Whitehouse et al. (2005) and Whitehouse & Bate (2006). The energy equations are very similar to those for the pure flux-limited diffusion method, except that the dust and gas now have different temperatures and there are some additional heating and cooling terms. Whitehouse et al. (2005) developed an implicit method for solving equations (3) and (4) based on writing the equations in terms of the specific radiation energy, ξ = E/ρ, and the specific internal energy of the gas, u. For each SPH particle i, implicit expressions were derived for these two quantities at time step n + 1. These two equations were combined so as to solve for |$\xi ^{n+1}_i$| and |$u^{n+1}_i$|. The values from the previous time step, |$\xi ^{n}_i$| and |$u^{n}_i$|, were used as the initial guesses for |$\xi ^{n+1}_i$| and |$u^{n+1}_i$|, and Gauss–Seidel iteration was performed over all particles that were being evolved until the quantities converged to a given tolerance. The same basic method is used here.
During each Gauss–Seidel iteration, the dust temperature must be solved for first. Equation (14) is solved directly for Td of each particle based on its quantities from the previous time step or iteration. This is a root finding problem, for which Newton–Raphson iteration converges very quickly. It involves computing the left-hand side of equation (14) and its derivative with respect to Td, which is straightforward except for the fact that κd is a function of Td. However, since κd is stored in a table as a function of Td (see Section 3.3), we simply use a numerical derivative to calculate d(κd)/d(Td).
Within each Gauss–Seidel iteration, for each particle i, equations (57) and (59) are solved simultaneously for |$u_i^{n+1}$| and then |$\xi _i^{n+1}$|. This could be done exactly for the equations used by Whitehouse et al. (2005). Note, however, that equation (59) includes the quantities |$T_{{\rm g},i}^{1/2}$| and |$(T_{{\rm g},i})^{\beta _i}$| in the collisional dust–gas term and the line cooling term, and the heating rate due to molecular hydrogen formation, ΓH2, g, also involves the gas temperature. For a purely implicit solution of |$u_i^{n+1}$|, the terms involving Tg, i should be written as |$T_{{\rm g},i}= u_i^{n+1}/c_{{\rm v},i}$|, but this would introduce fractional powers of |$u_i^{n+1}$|, making direct solution impractical. Instead, in equation (59) we take |$T_{{\rm g},i}= u_i^n/c_{{\rm v},i}$| and rely on the fact that |$u_i^n$| is updated in every Gauss–Seidel iteration so that if |$u_i^{n+1}$| converges, so too does |$u_i^n$|. Empirically, this seems to work well as long as large decreases in the gas temperature (which would result in a large decrease in the emission line cooling) are avoided from one iteration to the next – we limit |$u^{n+1}_i\ge 0.8 u^i_i$|.
Apart from these changes, the simultaneous solution for |$u_i^{n+1}$| and then |$\xi _i^{n+1}$| follows the method of Whitehouse et al. (2005) and will not be repeated here. Briefly, in general, equations (57) and (59) are combined to eliminate |$\xi _i^{n+1}$| and produce a quartic equation for |$u_i^{n+1}$| that can be solved analytically. When solving the implicit version of equation (54) we use Newton-Raphson iteration to obtain |$u_i^{n+1}$|. Once |$u_i^{n+1}$| is obtained, |$\xi _i^{n+1}$| is found simply by rearranging equation (57). This is done for all active particles for each iteration, and the iterations are repeated until a desired tolerance is reached.
3.1.2 Calculating the ISR attenuation
It is necessary to calculate the local intensity of the ISR (attenuated due to dust extinction) and the mean visual extinction in order to evaluate the ΛISR and Γpe terms and to model the chemistry (Section 2.5). This is potentially very difficult computationally because it involves integrating over all angles at each point in the simulation. To make this computationally tractable, we use a similar method to the TREECOL method of Clark, Glover & Klessen (2012a). They propose calculating the mass surrounding a particle in angular cones (and thereby calculating the column density and optical depths) using the same tree which is frequently used in SPH codes to calculate gravity and neighbouring particles. The algorithm essentially sums over the column densities of nearby particles and more distant tree nodes that intersect the angular cone being considered. To cover the full 4π steradians uniformly, they used angular cones defined using the healpix1 library functions (Górski et al. 2005).
It should be noted that even using the same tree that is used to calculate gravitational forces to estimate the extinction and other directional averages, obtaining the averages in many directions can still require a substantial amount of computation. Furthermore, when the code is run in parallel using MPI with domain decomposition, the contributions of each domain to the column densities along each ray must be added together in order to calculate the quantities in each direction. This would not be necessary if one simply wanted the average column density to a particle (since the column density adds linearly), but because calculating the extinction involves a non-linear function, exp (−τ), the column density in each direction must be computed separately. Thus, when running with MPI domain decomposition there is also a substantial memory overhead which depends on the chosen number of directions.
3.2 Equation of state and boundary conditions
As in Bate (2009, 2012), the calculations presented in this paper were performed using RHD with an ideal gas equation of state for the gas pressure |$p= \rho T_{\rm g} \cal {R}/\mu$|. The thermal evolution takes into account the translational, rotational, and vibrational degrees of freedom of molecular hydrogen (assuming a 3:1 mix of ortho- and para-hydrogen; see Boley et al. 2007). It also includes molecular hydrogen dissociation, and the ionizations of hydrogen and helium. The hydrogen and helium mass fractions are X = 0.70 and Y = 0.28, respectively. For this composition, the mean molecular weight of the gas is initially μ = 2.38. The contribution of metals to the equation of state is neglected.
In previous calculations using the flux-limited diffusion method of Whitehouse et al. (2005), it was necessary to set matter and radiation temperature boundary conditions. For calculations contained within a particular volume (e.g. the collapse of a molecular cloud core; Whitehouse & Bate 2006; Bate 2010, 2011; Bate, Tricco & Price 2014), the matter and radiation temperatures were fixed on ghost particles outside the boundary at the initial (low) temperature (e.g. 10 K). For calculations of clouds with free boundaries (e.g. Bate 2009, 2012, 2014), all particles with densities less than a particular value (typically 10−21 g cm−3) had their matter and radiation temperatures set to the initial values (again ≈10 K). This matter was two orders of magnitude less dense than that in the initial cloud and, thus, these boundary particles surrounded the region of interest in which the star cluster formed. In both cases, this essentially meant that the clouds were embedded in an external radiation field with this boundary temperature.
The new method presented here eliminates the need for these arbitrary temperature boundary conditions. Now the temperature of the gas, dust and radiation are all set consistently at both high and low densities.
3.3 Opacities and metallicity
Whitehouse & Bate (2006), Bate (2009, 2010, 2011, 2012), and Bate et al. (2014) assumed solar metallicity gas and used the Rosseland mean opacity tables of Pollack, McKay & Christofferson (1985) for interstellar dust and, at higher temperatures when the dust is destroyed, the gas opacity tables of Alexander (1975, the IVa King model); see Whitehouse & Bate (2006) for further details. Bate (2014) performed calculations with varying opacities. He used the same dust opacities, scaled linearly in proportion to the metallicity, but replaced the gas opacity tables with the metallicity-dependent tables of Ferguson et al. (2005) with X = 0.70. It is worth noting that one of the main conclusions of Bate (2014) was that the results of star formation calculations are very insensitive to the opacities that are used.
In this paper, because the equations treating dust heating and photoelectric heating of the gas require integrals over the dust opacity as a function of frequency, we cannot continue simply to use the Rosseland mean opacities of Pollack et al. (1985). At low-densities (i.e. when the optical depth is low and the dust is essentially in thermal equilibrium with the ISR field), the Planck mean is more appropriate than the Rosseland mean, and we desire consistency between the frequency-dependent dust opacity, Qν(ν) and the grey opacity, κd, appearing in equations (12) and (14). In other words, equation (15) should be satisfied. Therefore, we calculate Planck mean opacities directly from Qν(ν) before the code begins to evolve the SPH calculation and the values are stored in a table as a function of dust temperature. Any frequency dependent opacities can be used in principle, but for simplicity, we use the parametrization provided by Zucconi et al. (2001) of the opacities from Ossenkopf & Henning (1994). We use these values for κd whenever the dust temperature is less than 100 K. We assume that higher dust temperatures (Td > 100 K) will only be encountered at high densities (i.e. near protostars) when the gas and dust are optically thick and thermally well-coupled. In this case, Rosseland mean opacities are appropriate, and we use those of Pollack et al. (1985) as we have in our earlier calculations mentioned above.
For the gas, we continue to use the Rosseland mean opacities of Ferguson et al. (2005) for κg, since the gas opacity only becomes important in the highly optically-thick regions inside, or very near to, a star, for which the Rosseland mean is appropriate.
4 CALCULATIONS
4.1 Testing the method for calculating ISR attenuation
One of the tests that Clark et al. (2012a) used for the TREECOL method was to calculate the temperature structure of two uniform-density spherical clouds when subjected to a Black (1994) ISR field. They took densities of 10−19 g cm−3 for clouds with masses of 1 and 10 M⊙ and used 2.6 × 105 SPH particles. We perform the same tests here. For this test, we set the internal radiation to zero (i.e. E = Tr = 0) and we turn off the coupling between the gas and the dust (i.e. Λgd = 0) so that equation (14) is only solving for the equilibrium temperature of the dust subject to the attenuated external ISR. The ISR is as discussed in Section 2.4.1, except that we exclude the additional UV flux which is important for photoelectric heating. We have calculated the exact radial temperature distribution by analytically calculating the column density along 192 healpix directions (using 48 provides an almost identical result) and used these values to calculate the attenuated dust heating (equations 63 and 64) and the equilibrium dust temperature as functions of radius.
In Fig. 2, we give the distribution of the equilibrium dust temperature as a function of radius for each of the two clouds. One point is plotted for each SPH particle. Different colours give the results obtained when the code uses 12, 48, or 192 healpix directions to calculate the mean extinction. The number of healpix directions used has little impact on the results, except in the very outer part of the clouds when using only 12 directions. However, using more directions takes longer to compute, so from this point on we use 48 healpix directions. The equilibrium temperature of dust that is subject to the full ISR is 17.2 K for our chosen ISR. By considering equation (23), we expect a dust particle that is subject to one hemisphere of heating to have an equilibrium temperature that is a factor of 21/6 lower (i.e. 15.3 K) and, as expected, this is essentially equal to the temperature at the edge of each of the clouds. However, within the clouds we find that the dust temperatures are up to ≈1 K warmer than given by the exact solutions (solid black lines). We note that the central temperatures in our clouds are in good agreement with those found by Clark et al. (2012a), but they obtained substantially lower temperatures at the outer edges of their clouds (13–14 K). The reason for this is not clear since, as just mentioned, our edge temperatures are what we would expect. Their ISR may have been different to ours, although both are nominally based on that of Black (1994).

The dust temperature as a function of radius inside two uniform-density molecular cloud cores that are subject to an external ISR field. The clouds have the same densities, but different masses: 1 M⊙ (upper distributions) and 10 M⊙ (lower distributions). The exact solutions are plotted using the solid black lines. For the SPH calculations, a point is plotted for each SPH particle (2.6 × 105 for each cloud). The different colours give the results obtained when the code uses 12 (red), 48 (green), or 192 (blue) healpix directions to calculate the mean extinction. Dust within the clouds receives less of the external radiation due to extinction and, therefore, is colder. The number of healpix directions used has little impact on the results, except in the very outer part of the clouds. The equilibrium temperature of dust that is subject to the full ISR is 17.2 K (horizontal dashed line), and the equilibrium temperature of dust that received exactly half of this radiation would be 15.3 K, which is lower by a factor of 21/6 (horizontal dotted line). As expected, dust at the edges of the clouds is close to this temperature.
In Fig. 3, we plot the dust temperatures from five calculations of the 1-M⊙ cloud that each use 48 healpix directions, but that have different numbers of SPH particles: 280, 2608, 2.6 × 104, 2.6 × 105, and 2.6 million. It can be seen that the dust temperature tends to be overestimated when a smaller number of particles is used, but the dust temperature appears to be slowly converging towards the exact solution as the number of particles is increased. The error in the dust temperature is approximately halved each time the number of SPH particles is increased by an order of magnitude (i.e. the error decreases at about the same rate that the linear spatial resolution increases). Comparing the 2.6 × 104 particle calculation with the exact solution, the maximum difference between the mean temperatures at any radius is only 1 K. Clark et al. (2012a) did not discuss how their method behaves with different numbers of particles.

The dust temperature as a function of radius inside the 1 M⊙ uniform-density molecular cloud core that is subject to external ISR. The exact solution is plotted using the solid black line. The results from five SPH calculations are illustrated, and a point is plotted for each SPH particle. The calculations each use 48 healpix directions to calculate the mean extinction, but different numbers of SPH particles are used to model the cloud – from top to bottom: 280 (black), 2608 (red), 2.6 × 104 (green) 2.6 × 105 (blue), and 2.6 million (magenta). It can be seen that using fewer particles tends to result in warmer dust temperatures (i.e. an underestimate of the extinction), but the dust temperature appears to be slowly converging towards the exact solution as the number of particles is increased. As long as ≳3 × 104 particles are used the maximum error in the mean temperature at any radius is ≲ 1 K. The equilibrium temperature of dust that is subject to the full ISR is 17.2 K (horizontal dashed line), and the equilibrium temperature of dust that received exactly half of this radiation would be 15.3 K, which is lower by a factor of 21/6 (horizontal dotted line). As expected, with sufficient resolution, the dust at the edges of the clouds is close to this temperature.
We used a cubic lattice SPH particle distribution to generate the results presented in Figs 2 and 3. We have also tried a random particle distribution. Using 2.6 × 105 randomly-placed SPH particles to model the 1-M⊙ cloud, we obtained an almost identical mean radial temperature distribution to the case that used a cubic lattice, but with a temperature scatter of up to ±0.2 K. However, given that this error is similar to the systematic difference between the temperature distributions obtained from the 2.6 × 105 and 2.6 million particle cubic lattice calculations, we conclude that the accuracy of the solution depends more on the number of particles used than on the details of how they are distributed.
In Fig. 4, we investigate the effects on the calculation of the dust temperature of varying the tree-opening criterion and the effective radius of the tree nodes, the latter of which is parametrized by the factor f (see Section 3.1.2). During the walk through the tree to calculate gravity, nodes are opened if sn/rnp is larger than a critical value, usually taken to be 0.5. We perform calculations using a tree-opening parameter of 0.5 and 0.25 (the latter of which means more nodes are opened during the tree walk). For each case, we perform five SPH calculations of the 1-M⊙ cloud that each use 48 healpix directions and 2.6 × 105 SPH particles, but we vary the effective radius of the node that is used when calculating the column density. We take factors of f = 2.0, 1.0, 0.5, 0.1, and 0.01. It can be seen from Fig. 4 that using very large tree-opening angles and/or effective node radii results in warmer dust temperatures (i.e. an underestimate of the extinction). We also note that almost identical results are obtained when the product of the opening parameter and the factor f is a constant (e.g. using a tree-opening parameter of 0.5 and f = 1 gives almost identical results to using a tree-opening parameter of 0.25 and f = 2). The calculation of the extinction becomes very poor when the product of these two quantities exceeds ≈0.5. If the effective node size is too small, the calculations provide reasonable mean temperatures at a given radius, but the scatter increases (e.g. the black points in the left-hand panel that were produced using f = 0.01). With the typical tree-opening parameter of 0.5, setting the factor f = 0.5 gives the best trade-off between accurately computing the mean radial temperature distribution and minimizing the scatter.

The dust temperature as a function of radius inside the 1 M⊙ uniform-density molecular cloud core that is subject to external ISR. The exact solution is plotted using the solid black line. The results from 10 SPH calculations are illustrated, and a point is plotted for each SPH particle. The calculations each use 48 healpix directions to calculate the mean extinction and 2.6 × 105 SPH particles, but the tree-opening parameter and the effective sizes of the tree nodes are varied. In the left-hand panel, the tree-opening parameter is 0.5, while in the right-hand panel it is 0.25. In each panel, the effective size of the tree nodes decreases from top to bottom, using scaling factors of f = 2.0 (red), 1.0 (green), 0.5 (blue), 0.1 (magenta), and 0.01 (black). It can be seen that using very large tree-opening angles and/or effective node sizes results in warmer dust temperatures (i.e. an underestimate of the extinction). If the effective node size is too small, the scatter increases. With a tree-opening parameter of 0.5, an effective node size of half the actual node size (i.e. f = 0.5) gives the best trade-off between accurately computing the mean radial temperature distribution and minimizing the scatter. The equilibrium temperature of dust that is subject to the full ISR is 17.2 K (horizontal dashed line), and the equilibrium temperature of dust that received exactly half of this radiation would be 15.3 K, which is lower by a factor of 21/6 (horizontal dotted line). As expected the dust right at the edges of the clouds is close to this temperature.
The typical resolutions employed in SPH calculations of star cluster formation vary from ∼103 particles per solar mass (Bonnell, Bate & Vine 2003; Bonnell et al. 2011) to ∼105 particles per solar mass (Bate, Bonnell & Bromm 2003; Bate 2012). The results of this test suggest that the typical errors in the dust temperature due to finite numbers of SPH particles and healpix directions and variations of the tree parameters should be ≲1 K as long as ≳3 × 104 particles per solar mass are used and large effective node radii are avoided.
4.2 Equilibrium dust and gas temperatures
More realistic than using a uniform-density sphere is to use Bonner–Ebert spheres. To allow comparison with earlier work, we use the same 5-M⊙ Bonner–Ebert spheres that were used by Keto & Field (2005) – a (marginally) subcritical case with a central density of nH2 = 104 cm−3, and a supercritical case with a central density of nH2 = 106 cm−3. The former case has a ratio of the inner to outer density of 14, while the ratio of the latter is 3000. Their radii are 0.223 and 0.265 pc, respectively. In these tests, we assume the hydrogen is fully molecular. We model both clouds with 3 × 105 SPH particles.
The SPH particles were set up using a cubic lattice which was then deformed radially to obtain the required cumulative radial mass profile. In Fig. 5, we provide the SPH density as a function of radius for of each SPH particle for both cores. The small ‘spikes’ in the density in the supercritical case are due to the lattice structure affecting the density calculation of some particles in this case with a very strong density gradient. They do not appear in the subcritical case, which has a much shallower density profile. In both cases, there is also some ‘noise’ in the density near the outer boundary (which is made of reflected ghost particles).

Plots of the SPH molecular hydrogen number density, nH2, as functions of radius inside the subcritical (blue) and supercritical (red) 5-M⊙ Bonner–Ebert spheres. A point is plotted for each SPH particle. The ‘spikes’ in the density for the supercritical case are an artefact of the particles being set up on a radially-deformed cubic lattice.
In this section, we investigate the effects of each of the physical heating and cooling mechanisms on the temperatures of the gas and dust. We begin by including only cosmic ray heating and molecular line cooling for the gas, and the dust is taken to be in thermal equilibrium with the ISR. We then add in the effects of gas–dust collisions, photoelectric heating of the gas and cooling from C+. For the first two cases, we also investigate the effects of including and excluding the UV flux.
4.2.1 Cosmic ray heating, molecular line cooling, and dust radiative equilibrium
In Fig. 6, we plot the dust and gas temperatures as functions of radius inside the two Bonner–Ebert spheres. These calculations include only cosmic ray heating and undepleted molecular line cooling of the gas, and the dust is in thermal equilibrium with the external ISR. There is no gas–dust collisional coupling, photoelectric effect, or cooling due to C+, oxygen, or recombination lines. There are two calculations for each case – one that excludes the UV contribution to the ISR, and one that includes it.

The dust (upper) and gas (lower) temperatures as functions of radius inside the subcritical (left) and supercritical (right) 5-M⊙ Bonner–Ebert spheres. The ISM physics includes cosmic ray heating and molecular line cooling of the gas, and the dust is in thermal equilibrium with an external ISR that excludes (green) or includes (red) the UV contribution (see Section 2.4.1). The dust temperature drops as the extinction increases at smaller radii. The gas temperature rises because the line cooling becomes less effective at higher densities. The UV ISR only affects the dust temperature in the low-extinction outer parts of the cloud. The small ‘spikes’ in the gas temperature in the right plot at radii r ≈ 0.03–0.16 pc are due to the artefacts in the calculation of the SPH density due to the particles being set up on a radially-perturbed cubic lattice.
In the outer parts of the cores, the dust temperature exceeds the gas temperature as the local ISR is only weakly attenuated by the dust, and the cosmic ray flux and line cooling are such that the low-density equilibrium gas temperature is ≈10 K. Including the UV contribution to the ISR boosts the dust temperature by up to 2 K in the outer parts, but the total energy in the UV flux is small compared to the total ISR flux and the UV does not penetrate very far into the cores. In the inner parts of the cores, the gas temperature rises as the effectiveness of the line cooling decreases (Goldsmith 2001). On the other hand, the dust temperature decreases, particularly in the supercritical case, because the dust extinction attenuates the ISR.
4.2.2 The effects of gas–dust collisions
In Fig. 7, we include the same physical processes as in the previous section, but we now also turn on the transfer of thermal energy between the gas and the dust due to collisions. The strength of this interaction depends on the square of the density (equation 36), so we expect it to have little impact at low densities, but a significant impact as the density increases. Indeed, this can be clearly seen in Fig. 7, in which we plot the same calculations as in Fig. 6 for reference, but we now also include the case with gas–dust coupling in blue (without the UV ISR) and magenta (with the UV ISR). The gas–dust thermal coupling has no significant effect on the temperatures in the subcritical core because the densities are too low. In the supercritical case, the dust temperature is unaffected, but the gas temperature at r < 0.04 pc (densities nH2 ≳ 2 × 104) is ‘dragged down’ by the interaction with the cold dust so that at the centre the gas and dust temperatures are both ≈7.5 K.

The dust (upper) and gas (lower) temperatures as functions of radius inside the subcritical (left) and supercritical (right) 5-M⊙ Bonner–Ebert spheres. Red and green points (mostly obscured) are the same as in Fig. 6. For the blue (without the UV ISR) and magenta (with the UV ISR) points, the ISM physics is exactly the same, except that it includes thermal collisional coupling between the gas and the dust. The black solid lines give the results obtained by Keto & Field (2005) without including the UV ISR. The effect is that at high densities, the gas essentially adopts the dust temperature. The small ‘spikes’ in the gas temperature in the right-hand plot at radii r ≈ 0.03–0.16 pc are due to the artefacts in the calculation of the SPH density due to the particles being set up on a radially-perturbed cubic lattice.
Our numerical results are in reasonable agreement with those presented in figs 4 and 5 of Keto & Field (2005), who use the same models for the ISM physics as we use here, without the UV ISR (black solid lines in Fig. 7). The main difference is that the gas temperatures at low densities are slightly lower in Keto & Field (2005). The gas temperature at low density is set by the balance between cosmic ray heating and the line cooling rates. The latter is dependent on the method used to interpolate from the tables of Goldsmith (2001). Since the cosmic ray heating and line cooling rates are both simple functions of nH (equations 24 and 34), it is easy to solve for the central gas temperature of 12.4 K in the subcritical case (where the gas–dust coupling is negligible). The slightly lower gas temperature (≈11.5 K) obtained by Keto & Field (2005) was found to be due to less accurate interpolation used by Keto & Field of the line cooling functions of Goldsmith (2001). Thus, the different interpolation of the line cooling produces the different gas temperatures.
4.2.3 The effects of photoelectric heating and carbon chemistry
In Fig. 8 , in addition to the other physical processes, we turn on photoelectric heating of the gas due to UV ISR photons liberating electrons from dust grains (equation 26). The resulting gas and dust temperatures (green) are compared to those without the photoelectric heating (blue). The dust temperature is essentially unchanged, but the gas temperature in the outer parts of the cores, at densities such that the gas and dust are thermally decoupled (nH2 ≲ 104 cm−3), is much hotter than without photoelectric heating. In fact the photoelectric heating is so strong that the cosmic ray heating is irrelevant in the low-density gas.

The effect of photoelectric heating and C+ cooling of the gas on the dust and gas temperatures as functions of radius inside the subcritical (left) and supercritical (right) 5-M⊙ Bonner–Ebert spheres. The dust temperatures are essentially unaffected by the extra gas heating and cooling processes. The blue points are the same as in Fig. 7, where the gas is subject to cosmic ray heating, molecular line emission, and collisions with the dust, while the dust is subject to heating from the ISR (including the UV), thermal emission, and collisions with the gas. The green points include the same physical effects as the blue points, but with the addition of photoelectric gas heating (equation 26). The photoelectric heating has an enormous effect on the gas temperature in the outer, low-density parts of the clouds. However, when the C+ cooling is included (red points), the effect of the photoelectric heating on the gas temperature is greatly reduced.
Whereas Keto & Field (2005) did not consider photoelectric heating, as discussed in Section 2.5, Keto & Caselli (2008) included photoelectric heating and a simple carbon chemistry model which allowed them to include both cooling from C+ at low densities and treat the depletion of CO at high densities. Therefore, in Fig. 8, we keep the photoelectric heating on, but also add cooling from C+ (red). It can be seen that the C+ cooling dramatically lowers the temperatures in the outer parts of the cloud; the temperature is still somewhat higher than it was without either the photoelectric heating or the C+ cooling, but much less than if C+ cooling is omitted. We note that recombination and oxygen cooling are both insignificant at these densities and that the temperatures are essentially identical whether they are included or not.
Finally, in Fig. 9 we turn on the effects of CO depletion based on the equilibrium prescription of Keto & Caselli (2008). This results in only slightly higher gas temperatures at intermediate densities (nH2 = 104–105 cm−3) where the densities are still too low for dust cooling to dominate, but the densities are high enough that C+ is ineffective.

The effect of CO depletion on the gas on the dust and gas temperatures as functions of radius inside the subcritical (left) and supercritical (right) 5-M⊙ Bonner–Ebert spheres. The red points are the same as in Fig. 8, where the gas is subject to cosmic ray and photoelectric heating, molecular and C+ line emission, and collisions with the dust, while the dust is subject to heating from the ISR (including the UV), thermal emission, and collisions with the gas. The black points include the same physical processes as the red points, but also allow for CO depletion. This reduces the molecular line cooling at high densities which raises the gas temperature slightly at densities nH2 = 104–105 cm−3. At higher densities the depletion has little effect because the cooling is dominated by dust emission through collisions with the dust.
4.2.4 The effects of changing the ISM parameters
The previous sections used the diffuse ISM model parameters described in Sections 2.3 and 2.4. In this section, we investigate the dependence of the gas and dust temperatures on the strengths of the various external heating sources. We only use the supercritical Bonner–Ebert sphere in these tests because this has the larger range of densities. In the left-hand panel of Fig. 10, we explore the effects of changing the cosmic ray heating rate (equation 24) by an order of magnitude in each direction. In the right-hand panel of Fig. 10, we explore the effects of change the gas photoelectric heating rate (equation 26) by an order of magnitude in each direction. It can be seen that over particular density ranges, either of these changes the gas temperature by approximately half an order of magnitude in each direction because the gas line cooling scales roughly as the square of the gas temperature for the molecular lines (Goldsmith 2001). The gas temperatures in the outer parts of the cloud are much more strongly affected by photoelectric heating than cosmic ray heating. On the other hand, at number densities nH2 ≳ 105 cm−3 strong cosmic ray heating can raise the gas temperature significantly above the dust temperature whereas the photoelectric heating has no effect this deep within the core.

The effects of changing the strengths of the cosmic ray (left) and photoelectric (right) heating of the gas on the dust and gas temperatures as functions of radius inside the supercritical 5-M⊙ Bonner–Ebert sphere. In both panels, the red points are the same as in the black points in the right-hand panel of Fig. 9. The other points include the same physical effects as the red points, but with one order of magnitude less (green) or more (blue) cosmic ray (left) or photoelectric (right) heating. Changing the level of cosmic ray heating has a large effect on the gas temperature at intermediate densities, but not at high densities (where the gas and dust are well coupled) or low densities (where photoelectric heating dominates). Changing the levels of photoelectric heating has a large effect on the gas temperature only in the outer regions of the core. The dust temperatures are unaffected in either case.
In Fig. 11, we probe the effects of changing the ISR field (equation 25) by an order of magnitude in each direction, excluding the UV contribution which is held fixed. The calculations include photoelectric heating of the gas and C+ cooling. The increased ISR primarily affects the dust temperature, but because the dust emission scales as the sixth power of its temperature (equation 23), this only has a 50 per cent effect on the dust temperatures. Deep within the core where the gas becomes thermally coupled to the dust, the warmer or cooler dust also results in warmer or cooler gas, respectively.

The effects of changing the strength of the ISR field on the dust and gas temperatures as functions of radius inside the supercritical 5-M⊙ Bonner–Ebert sphere. The red points are the same as the black points in the right-hand panel of Fig. 9. The other points include the same physical effects as the red points, but with one order of magnitude less (green) or more (blue) ISR heating. Changing the level of ISR by an order of magnitude has a 50 per cent effect (101/6) on the dust temperatures. At high densities, the different dust temperature affects the gas temperature in a similar manner, but at low densities the gas temperature is unaffected as it is set by the photoelectric heating and C+ cooling.
In Fig. 12, we investigate the effects of changing the metallicity of the core, performing additional calculations with metallicities of 1 per cent, 10 per cent, and 3 times solar. It can be seen that the highest metallicity results in the coldest temperatures for both the gas and the dust due to the combination of several effects. The increased metallicity increases the ISR attenuation, decreasing the dust temperature inside the core. Similarly, the UV is prevented from penetrating as far into the core, reducing the effects of photoelectric heating of the gas, and the gas line emission is enhanced. Finally, there is an increase in the effectiveness of collisional thermal coupling between the gas and the dust. With the lowest metallicity, the dust almost becomes isothermal since there is almost no attenuation of the ISR, and the gas is warmer because the photoelectric heating is strong while emission line cooling is weak.

The effects of changing the metallicity on the dust and gas temperatures as functions of radius inside the supercritical 5-M⊙ Bonner–Ebert sphere. Photoelectric heating has been included. From top to bottom, the calculations have metallicities of 1/100 (magenta points, top curves), 1/10 (blue points), solar metallicity (red points), and 3 times solar metallicity (green points). The red points are the same as in the black points in the right-hand panel of Fig. 9. The dust temperatures are greater with lower metallicities because the ISR is less attenuated by extinction. The gas temperatures are greater with lower metallicities because the UV ISR is less attenuated by extinction (leading to stronger photoelectric heating) and also because the gas emission line cooling is reduced.
4.3 The evolution of a collapsing Bonner–Ebert sphere
In this section, as opposed to the static tests from the previous sections, we report the results from a hydrodynamical calculation of the collapse of a Bonner–Ebert sphere and compare them to the results obtained using the pure flux-limited diffusion method of Whitehouse et al. (2005) and Whitehouse & Bate (2006). We begin with a somewhat unstable Bonner–Ebert sphere, similar to those studied in the previous section. We choose a 5-M⊙ core with an inner to outer density contrast of 20 and a radius of 0.1 pc. We model the core with 3 × 105 SPH particles and use spherical reflective boundary conditions (modelled using ghost particles).
In Fig. 13, we plot the central temperatures as functions of the central (maximum) density for the two methods. All of the initial temperatures in the pure flux-limited diffusion calculations are arbitrary. As is standard practice in such calculations, we set the matter and radiation temperatures to be in thermal equilibrium initially. We perform two separate calculations and with two different initial temperatures of 10 and 14 K. For the calculation performed using the method described in this paper, the initial gas and dust temperatures are not arbitrary – they are set by our model of the diffuse ISM. The initial dust temperature increases from 8 K in the centre to 17 K at the outer edge of the molecular cloud core. The initial gas temperature is slightly warmer than the dust at the centre (10 K) and cooler at the outside (≈15 K). The initial central dust and gas temperatures are quite similar because the central density of the core is quite high (ρ = 6 × 10−19 g cm−3 or nH2 = 1.5 × 105 cm−3) so that there is significant thermal coupling between the dust and the gas (we use equation 36 in these calculations). As the collapse proceeds, the central dust and gas temperatures quickly converge, so we do not plot the central dust temperature in Fig. 13. The increases in extinction and density during the collapse mean that both the dust and gas temperatures drop to a minimum of 6.5 K when the central density is 10−16 g cm−3 before the compressional heating starts to increase the central temperature again. The initial radiation temperature should be set to a low value, because the heating of the initial conditions is via external radiation rather than internal radiation. As long as a small value is chosen the exact value is unimportant, but we wish to avoid setting it to zero so as to avoid numerical problems. We chose a value of 1 K.

The evolution of the central gas and radiation temperatures as functions of the maximum (central) density during a radiation hydrodynamical calculation of the collapse of an unstable spherical 5-M⊙ Bonner–Ebert sphere. The radiation temperature is always less than or equal to the gas temperature in this graph. After the central density exceeds 10−17 g cm−3, the central dust temperature is indistinguishable from that of the gas. The black solid lines give the results from a calculation using the method described in this paper, while the red dashed lines and blue long-dashed lines give the results using the pure FLD method of Whitehouse & Bate (2006). The diffuse ISM model used in the former calculation determines the initial gas and dust temperatures, which vary with radius, and the internal radiation temperature is arbitrarily set to a low initial value (1 K). In the FLD calculations, the initial temperatures of the matter (gas and dust) and internal radiation are arbitrary and we set them to 14 K (red dashed) and 10 K (blue long-dashed). As expected, it is mainly the low-density evolution that is affected by including the diffuse ISM model.
As may be expected, Fig. 13 shows that it is mainly the low-density phase of evolution of the clouds that differs between the two methods (densities ≲10−13 g cm−3). Once the central regions of the core become optically-thick to infrared radiation (the so-called opacity limit for fragmentation; Low & Lynden-Bell 1976; Rees 1976) all of the temperatures converge. The evolution obtained with the pure flux-limited diffusion calculation with the lower initial temperature (10 K) is closest to the evolution obtained using the method presented here, presumably because the central temperature in this model is closest to that given by the ISM initial conditions.
In Fig. 14, we plot temperature profiles as functions of radius (left-hand panel) and density (right-hand panel) at various points during the collapse. Gas is shown with solid lines, dust with dotted lines, and radiation with dashed lines. At either a given radius or density the temperatures tend to rise during the collapse as the protostar emits more radiation. The formation of the stellar core at late times (initial radius ≈0.01 au and temperature >104 K) is clearly visible in the left-hand panel. Except in the outer parts of the core, these profiles are very similar to those obtained using pure flux-limited diffusion. The main difference in the outer parts of the core (radii ≳103 au) is that the gas, dust, and radiation all have different temperatures with the new method, whereas with pure flux-limited diffusion all are very close to the initial arbitrary temperature (e.g. 10 K; see Whitehouse & Bate 2006).

The evolution of the gas (solid), dust (dotted), and radiation (dashed) temperatures as functions of radius (left-hand panel) and maximum density (right-hand panel) during a radiation hydrodynamical calculation of the collapse of an unstable spherical 5-M⊙ Bonner–Ebert sphere. Each colour gives the state of the calculation when the maximum density reaches a different value, with the initial conditions given in black. The radiation temperature is always less than or equal to the gas temperature in this graph. The thick black long-dashed lines in the right-hand panel give the evolution of the central gas and radiation temperatures with central density from Fig. 13 for reference (only for ρ > 10−15 g cm−3). It can be seen that for a given density the gas is usually hotter latter in the collapse than earlier due to radiation from the protostar heating the outer parts of the core. The formation of the stellar core is apparent in the upper-left of the left-hand panel (initial radius ≈0.01 au).
After stellar core formation as radiation works its way outwards from the centre the gas, dust, and radiation temperatures become inverted at intermediate radii in the core (radii 400–3000 au; Fig. 15). Before this point the gas temperature is the hottest and the radiation temperature the coldest at these radii. However, the radiation emitted by the protostar quickly dominates that from the external radiation field at these radii. The dust adopts a new thermodynamic equilibrium with the combined radiation field, being heated to temperatures of 15–40 K, but the gas which is poorly coupled to either the radiation or the dust at these low densities remains at temperatures of 8–12 K. Such effects are impossible to capture unless the thermal evolution of the gas and dust are treated separately.

The gas (solid), dust (dotted), and radiation (dashed) temperatures as functions of radius when the collapsing spherical 5-M⊙ Bonner–Ebert sphere has reached a maximum density of 0.01 g cm−3 (lower, red lines), and 1.76 years later at the end of the calculation when the maximum density is 0.06 g cm−3 (upper, blue lines). Near the end of the calculation, after the stellar core forms, the radiation and dust temperatures become hotter than the gas temperature at radii of 400–3000 au because of the radiation emitted by the protostar.
4.4 The evolution of an isolated turbulent molecular cloud
Glover & Clark (2012a,c) studied the thermodynamics of turbulent molecular clouds with different metallicities. In particular, they performed calculations of 104 M⊙ clouds, typically modelled using SPH with 2 million particles. Their initial conditions consisted of a uniform-density sphere of number density nH = 300 cm−3, giving a radius of approximately 6 pc. The cloud was given initial ‘turbulent’ motions with a power spectrum P(k) ∝ k−4, where k is the wavenumber. The energy in the turbulence was initially set equal to the magnitude of the gravitational potential energy of the cloud, giving an initial root-mean-square velocity of around 3 km s−1. The turbulence was allowed to decay freely. The calculations were performed using a confining pressure of pext = 1.2 × 104 K cm−3 which was implemented in the SPH equations by subtracting the external pressure from the pressure used in the momentum equation. We use the same set up as Glover & Clark, although of course we are unable to use exactly the same initial velocity field. We use our full diffuse ISM model to obtain the results below, but we begin by excluding the hydrogen chemistry and heating due to the formation of molecular hydrogen (Section 2.5.2). In the first set of results, we have also excluded molecular depletion (because Glover & Clark did not include depletion), but since we find that switching depletion on or off has little effect on the results it is included in most of the subsequent calculations. For the dust–gas thermal coupling, we switch to equation (37) because this is the equation Glover & Clark used.
4.4.1 Results excluding hydrogen chemistry
In Fig. 16, we plot the gas (upper panel) and dust (lower panel) temperatures as functions of the number density of hydrogen nuclei, nH, for a calculation performed at solar metallicity. The snapshot is taken just before the first sink particle is formed. The colours in the gas temperature plot indicate the average CO abundance of each point in temperature–density space. This is the equivalent of fig. 2 in Glover & Clark (2012a) or the upper-right panel of Fig. 4 in Glover & Clark (2012c). Since Glover & Clark did not include molecular depletion on to grains, we have turned this off in our calculation. The distribution of gas temperatures with density shows the same general features seen in the papers of Glover & Clark. At low densities (nH ≲ 103 cm−3), the gas temperature rises towards ∼100 K as the number density decreases towards nH ∼ 10 cm−3. The temperatures at densities nH ≲ 100 cm−3 are primarily determined by the models of photoelectric heating, and cooling due to electron recombination and emission from ionized oxygen and carbon (equations 26 to 33). The gas temperatures lie beneath the equilibrium curve (solid black line from Fig. 1) because the equilibrium curve assumes no extinction whereas in fact the photoelectric heating is generally attenuated by the dust extinction (depending on the location of the gas). Our maximum temperatures in this density regime are somewhat cooler than those obtained by Glover & Clark due to our slightly different models in this regime as already demonstrated in Fig. 1. At densities nH ≈ 100–104 cm−3, there is a large dispersion in the gas temperatures with a range of Tg ≈ 8–50 K obtained at densities nH ≈ 103–104 cm−3. In this region, although there is still significant photoelectric heating, the low-density coolants just mentioned become ineffective. Instead, the main cooling is from molecular lines, in particular CO (e.g. Goldsmith 2001; Glover & Clark 2012a), which depends strongly both on density and temperature. At the same time, work from the gas motions becomes important (either heating or cooling the gas, depending on whether the gas is being compressed or expanding, respectively), as does heating in shocks. Together these effects lead to the wide range in temperatures. Finally, at densities nH ≳ 105 cm−3 thermal coupling of the gas to the dust becomes important and the gas temperature converges towards that of the dust as the density increases.

Phase diagrams showing the gas (top panel) and dust (lower panel) temperatures as functions of the gas density. The colours in the gas temperature plot indicate the average CO abundance of each point in temperature–density space. The black solid line in the gas temperature plot is the equilibrium curve from Fig. 1.
As mentioned above, Glover & Clark (2012a) do not treat depletion of CO on to dust grains. Turning this on has little effect on the phase diagram (Fig. 17). As may be expected, the temperatures at densities of nH ≈ 103–105 cm−3 are slightly higher, but the effect is hardly noticeable. At lower densities the CO is not depleted and the dominant coolant is C+ rather than CO anyway. At higher densities where the CO does become depleted, the dominant coolant is dust.
We now explore the sensitivity of the results to several of the assumptions in our model. We examine the dependence on changes of the chemistry, in particular the abundance of C+ and the depletion of molecules like CO on to grains, as well as the effects of variations in the molecular line cooling rates and the strength of the coupling between the gas and the dust.
The main effect of the carbon chemistry model described in Section 2.5.1 is to provide the abundances of the coolants C+ at low-densities and CO at high densities. Typically, the transition between the dominance of the two coolants occurs at nH ∼ 103 cm−3 (e.g. Glover & Clark 2012a). The temperature of the gas is quite sensitive to this transition from C+ to CO. For example, in Fig. 18 we give the results obtained by assuming that the carbon remains as C+ at all densities and we turn off all molecular cooling. In this case, essentially all of the gas lies at temperatures below the equilibrium curve of Fig. 1 and there is little gas with temperatures greater than 20 K with densities nH ≈ 103–105 cm−3. This extreme case shows that it is important to have at least a simple model that switches the carbon from C+ to CO.
In Fig. 19, we return to our standard model including molecular depletion, but we increase the molecular line cooling rates by an arbitrary factor of 3. As expected, this decreases the temperatures of the gas with densities nH ≈ 103–105 cm−3. The lowest temperature (at densities nH ≈ 103 cm−3) decrease from Tg ≈ 8 to ≈5 K, but the highest temperatures (at densities nH ≈ 103 cm−4) are not significantly affected.

Phase diagram showing the gas temperature as a function of the gas density for a calculation that is identical to that portrayed in Fig. 17, except that the molecular line cooling rate has been increased by a factor of 3. The colours in the gas temperature plot indicate the CO abundance of each point in temperature–density space. The black solid line is the equilibrium curve from Fig. 1.
As mentioned in Section 2.4.3, equations (36) and (37) for the gas–dust thermal coupling coefficient differ by a factor of 15 (the latter, used by Glover & Clark, gives stronger coupling). Therefore, in Fig. 20 we examine the effect of using the weaker coupling provided by equation (36) instead. As expected, this only has an effect on the temperatures at high densities, nH ≳ 105 cm−3. The gas shows a somewhat increased spread of temperatures because the coupling with the dust is not strong enough to force the gas to adopt the dust temperature.

Phase diagram showing the gas temperature as a function of the gas density for a calculation that is identical to that portrayed in Fig. 17, except that the collisional thermal coupling between the dust and the gas is 15 times smaller (equation 36 has been used rather than 37). Note that there is a larger dispersion in the gas temperatures at densities nH ≳ 105 cm−3. The black solid line is the equilibrium curve from Fig. 1.
In summary, the gas temperatures in solar metallicity turbulent clouds are relatively independent of many of the parameters of our diffuse ISM model. The most important factors are the low-density equilibrium model (portrayed in Fig. 1) which essentially sets an upper limit to the temperatures at densities nH ≲ 103 cm−3, and the way in which the carbon transitions from C+ to CO. The exact molecular cooling rates, molecular depletion, and dust–gas thermal coupling parameters are less important.
4.4.2 The effects of metallicity and hydrogen chemistry
Following Glover & Clark (2012c), we examine the dependence on metallicity and on hydrogen chemistry. We perform full calculations (i.e. including the simple carbon chemical model and molecular depletion) for four different metallicities: 3, 1, 1/10, and 1/100 times the solar value. For each metallicity, we perform calculations that exclude hydrogen chemistry and its associated heating terms (results from the solar metallicity case have already been displayed in Fig. 17). We also perform calculations that include the evolution of hydrogen (i.e. its molecular fraction xH2) and heating due to H2 formation on dust grains. Two calculations are performed for each metallicity: one beginning with fully atomic hydrogen, and one beginning with fully molecular hydrogen.
In Fig. 21, we plot the evolution of the fractional abundance of molecular hydrogen in the eight calculations that include hydrogen chemistry up until the formation of the first sink particle in each calculation. This is the equivalent of fig. 3 in Glover & Clark (2012c). Beginning with fully molecular hydrogen, the decrease in H2 is primarily due to photodissociation in the outer parts of the clouds. The destruction is greater at lower metallicities because the UV radiation is less attenuated by dust. Beginning with fully atomic hydrogen, H2 is formed on dust grains and the total abundance monotonically increases in each calculation. However, the rate of increase strongly depends on the metallicity. The main reason for this is that there are more dust grains on which to produce H2 at higher metallicity (equation 40) so the rate of formation is higher. In addition, the extra dust attenuates the UV radiation that destroys H2 so the destruction rate is also lower. By the time stars begin to form, clouds with solar metallicity or higher are mostly molecular regardless of whether atomic or molecular initial conditions were adopted (particularly in the central regions where the stars actually form). However, at lower metallicities the initial conditions matter much more. When stars begin to form in the 1/10Z⊙ calculations, the H2 abundance is 65 per cent when beginning with molecular initial conditions, but only 15 per cent beginning with atomic initial conditions. For 1/100Z⊙, the disparity is even stronger, with the two abundances being 60 and 1.7 per cent, respectively.

We plot the evolution of the total fractional abundance of molecular hydrogen in calculations of turbulent clouds up until the time that stars begin to form. For each metallicity, we perform two calculations: one with fully molecular initial conditions (upper lines) and one with fully atomic initial conditions (lower lines). The metallicities are 3 times solar (black dotted lines), solar (red solid lines), 1/10 solar (green dashed lines), and 1/100 solar (blue dot–dashed lines). By the time stars begin to form, clouds with solar or supersolar metallicity are mostly molecular, regardless of their initial H2 abundance, but little molecular gas has formed in the low-metallicity clouds that consist of fully atomic hydrogen initially.
The behaviour of the molecular hydrogen evolution is qualitatively similar to that reported by Glover & Clark (2012c). In particular, the growth rate of molecular hydrogen in the atomic solar-metallicity calculation matches theirs to within 10 per cent, and the decay rates of the abundances in all of the molecular calculations are very similar. The clouds in Glover & Clark (2012c) take longer to begin forming stars (2.7–4.0 Myr rather than 1.7–2.6 Myr). This difference is most likely due to the different initial turbulent velocity field. With fully molecular initial conditions, because the stars take longer to form in the calculations of Glover & Clark (2012c), the H2 abundances when the star formation takes place are lower. This is most important in the lowest metallicity case, where the total abundance is only ≈20 per cent when the star formation begins in the Glover & Clark (2012c) calculation, whereas it is 60 per cent in our calculation. There are also differences in the abundances of molecular hydrogen in the lower metallicity calculations with atomic initial conditions. The total H2 abundances when beginning with fully atomic hydrogen remain low throughout both our calculations and those of Glover & Clark. However, at any particular time our abundance is twice that obtained by Glover & Clark (2012c) with 1/10Z⊙ and it is about an order of magnitude higher for the 1/100Z⊙ case until shortly before stars begin to form (when the abundances in both calculations are ≈1 per cent). No doubt some of this difference is due to the different velocity field and dust opacities used in the calculations, though it is not clear whether or not this explains all of the discrepancy.
Turning to the phase diagrams of gas temperature in Fig. 22, the general trends are again in agreement with those found by Glover & Clark (2012c). First, we consider the calculations that exclude hydrogen chemistry (they assume all hydrogen is in molecular form) and its associated heating (left-hand column of Fig 22). Increasing the metallicity above solar results in a reduction of the lower envelope of the gas temperatures at densities nH = 102–104 cm−3 because the additional molecular cooling and increased extinction produces lower gas temperatures. The upper temperature envelope is less affected. Lowering the metallicity to 1/10 of solar results in a smaller range of temperatures because extinction has less of an effect at low and intermediate densities so the temperatures tend to lie close to the equilibrium curve of Fig. 1 (which does not depend significantly on metallicity because the photoelectric heating and the cooling due to electron recombination and fine-structure emission are all assumed to be proportional to the metallicity). At higher densities, the main heating sources (compressional heating and cosmic ray heating) are independent of the metallicity and although the gas is less well coupled to the dust it is still coupled well enough that the gas temperatures are kept around 10 K. As the metallicity is reduced still further to 1/100 solar, the temperatures move above the solar metallicity equilibrium curve of Fig. 1. This is because the cosmic ray heating (which is taken to be independent of metallicity) becomes as important as the photoelectric heating at low metallicity. Furthermore, the magnitudes of the electron recombination and fine-structure cooling rates are proportional to metallicity, so regions that are heated by adiabatic and shock heating take longer to cool.

Phase diagrams of the gas temperature versus the gas density in turbulent clouds with metallicities of 3, 1, 1/10, and 1/100 times solar (top to bottom, respectively). The calculations in the left-hand column were performed without any H2 chemistry (assuming purely molecular hydrogen) and without heating from H2 formation. The other two columns included H2 chemistry and heating from H2 formation, but the calculations in the centre column began with fully atomic hydrogen, and the calculations in the right column began with fully molecular hydrogen. The colour bars indicate the average CO abundance of each point in temperature–density space (note that the scales differ from those in Figs 16, 17, 19, and 20). The black solid lines give the equilibrium curve from Fig. 1 for solar metallicity. Beginning with atomic gas results in significantly higher gas temperatures for densities nH ∼ 104–106 cm−3 (or even higher densities in the low-metallicity cases) due to heating from H2 formation on dust grains.
At high densities nH ≳ 105 cm−3 where the gas is thermally coupled to the dust in the solar metallicity case there is not much change in the supersolar metallicity case. The temperatures are slightly cooler (about 1–2 K) because the coupling is even stronger and the dust has slightly cooler temperatures due to the increased extinction. A larger effect is seen with reduced metallicities because the thermal coupling to the dust is substantially weaker. At 1/10 solar metallicity, the gas has a maximum in the temperature distribution of about 15 K at nH ≈ 3 × 105 cm−3 before the dust cooling takes over and reduces the temperatures at higher densities. At 1/100 solar metallicity, the gas temperature rises with increasing density until nH ≈ 2 × 107 cm−3 when it reaches a maximum of ≈20 K before it begins to drop again at higher densities.
We now consider the effects of hydrogen chemistry on the gas temperature due to heating of the gas when molecular hydrogen is formed on dust grains (equation 50). This has little effect in the calculations that began with fully molecular hydrogen (right-hand column of Fig. 22). There are two small differences. First, in the solar and supersolar calculations the upper envelope of gas temperatures is higher at densities nH ≈ 102–104 cm−3. This is because some molecular hydrogen is destroyed by photodissociation and when it reforms on dust grains this adds a source of heating. Second, in the low-metallicity calculations some regions of mostly atomic gas become molecular at densities nH ≈ 105–106 cm−3 and the extra heating makes this gas hotter than the molecular gas at the same densities. Thus, a bifurcation of the gas temperature is apparent at these densities.
Beginning with fully atomic gas has a much greater effect on the gas temperature (centre column of Fig. 22). In these cases, heating due to H2 formation on dust becomes significant at densities nH ≳ 103 cm−3, and the gas temperature is generally much greater than in the calculations without hydrogen chemistry or with fully molecular hydrogen initially. At solar and supersolar metallicities, the main effect is to raise the gas temperatures in the density range nH ≈ 103–106 cm−3. Above these densities the gas is mostly molecular and the gas is thermally well-coupled to the dust. At low metallicities, the gas is significantly hotter from densities of nH ≈ 103 cm−3 even up to nH ≈ 108 cm−3. This is primarily because of the reduced dust abundance which has two main effects: the atomic hydrogen persists to higher densities, and the gas does not become thermally coupled to the gas until much higher densities.
As mentioned above, the general temperature trends seen here are in agreement with those found by Glover & Clark (2012c). However, there are also some differences. At low densities, our temperatures tend to be lower because of the different equilibrium models that we have already mentioned (Fig. 1). But there are also differences at higher densities. In the solar metallicity cases, Glover & Clark (2012c) obtain slightly lower minimum temperatures at nH ∼ 103 cm−3. This may be because their molecular cooling is somewhat stronger (cf. the difference that increasing the molecular cooling makes in Figs 17 and 19). In the calculations at 1/10 Z⊙, the mean temperatures at each density are similar to those obtained by Glover & Clark (2012c) for both atomic and molecular initial conditions, but the scatter in the temperatures obtained by Glover & Clark (2012c) is greater at nH ≳ 105 cm−3. This may be largely due to the different density structure of the clouds (caused by the different initial velocity fields). In the lowest metallicity calculations (1/100 Z⊙), the temperatures obtained by Glover & Clark (2012c) are generally higher than ours at nH ≳ 104 cm−3 for the molecular initial conditions, and above nH ≳ 106 cm−3 for the atomic initial conditions. This may be related to the higher molecular hydrogen abundances that were commented on when we discussed Fig. 21. In our initially atomic calculation, the gas is mostly molecular for densities nH ≳ 106 cm−3 meaning that there will be little heating from H2 formation above these densities. If Glover & Clark (2012c) have more atomic gas remaining at high densities, this will provide additional heating. In our initially molecular calculation, because the stars begin to form at 2.0 Myr instead of 3.6 Myr, more of the initial molecular hydrogen remains. The total abundance is only 20 per cent in the calculation of Glover & Clark (2012c) when the temperature diagrams were plotted, whereas the total abundance in our calculation is 60 per cent and all of the high-density gas (nH ≳ 105 cm−3) is essentially fully molecular (i.e. there is little heating from H2 formation). On the other hand, the temperature–density behaviour we obtain for the low-metallicity fully atomic initial conditions is in very good agreement with the results given in fig. 1 of Omukai et al. (2005). For 1/10 Z⊙ calculations, the temperature at high densities has a peak at nH ∼ 105 cm−3 at similar temperatures in both our calculations and those of Omukai et al. At 1/100 Z⊙, both our results and those of Omukai et al. display high-density temperature maxima of Tg ≈ 60 K at nH ≈ 106 cm−3.
5 CONCLUSIONS
We have presented a new method for modelling the thermal evolution of star-forming molecular clouds. The method combines a model for the thermodynamics of the diffuse ISM with radiative transfer in the flux-limited diffusion approximation. The former is required to correctly model the thermal behaviour of molecular clouds at low densities and metallicities, while the latter allows us to model protostar formation. Unlike most previously published star formation calculations, our new model evolves the temperatures of the gas, dust, and radiation separately. The code can also follow the evolution of atomic and molecular hydrogen. We have compared our method with existing literature on the thermal behaviour of the ISM and molecular cloud cores and generally obtain good agreement.
We have also explored the sensitivity of the thermal structure of molecular cloud cores and turbulent clouds to many of the parameters that enter our diffuse ISM model. For the gas at solar metallicities, the most important thermal processes at low densities (nH ≲ 1–1000 cm−3) are photoelectric heating of electrons from dust grains and cooling due to electron recombination with small grains and PAHs and fine-structure emission from C+ and atomic oxygen. At high densities (nH ≳ 105 cm−3), cosmic ray heating and the work done by hydrodynamical flows dominate the heating, while the cooling is dominated by continuum dust emission so that the gas and dust adopt similar temperatures. At intermediate densities (nH ≲ 103–105 cm−3), most processes have a significant effect and there tends to be a large dispersion of temperatures in turbulent clouds. The abundance of C+ changes rapidly at these densities and because C+ is such an effective coolant it is important to have a model for the C+ abundance. However, the exact values of the molecular cooling rates, molecular depletion, and the strength of the thermal coupling between the dust and the gas are less important. When beginning with low-density molecular clouds (which may not be purely molecular), the thermal evolution also depends significantly on relative abundances of atomic and molecular hydrogen due to heating from the formation of molecular hydrogen on dust grains. This becomes more important at lower metallicities.
Our new method should allow more realistic radiation hydrodynamical calculations of star formation to be performed, particularly in molecular clouds that have low mean densities (nH ≲ 104 cm−3) and/or subsolar metallicities. However, we also emphasize that this model is far from complete. In particular, it relies on various parametrizations of the thermal effects of many physical processes, and it does not calculate these processes explicitly. Furthermore, it contains only extremely simple models of hydrogen and carbon chemistries and does not explicitly model the chemistry of other elements at all. However, the basic model developed in this paper could easily be extended to increase the complexity of the chemical modelling (at the cost of increased computational expense).
We thank Paul Clark for constructive criticism that helped improve the method, and the anonymous referee whose comments helped us improve the manuscript. This work was supported by the European Research Council under the European Community's Seventh Framework Programme (FP7/2007-2013 grant ggreement no. 339248). The calculations for this paper were performed on the University of Exeter Supercomputer, a DiRAC Facility jointly funded by STFC, the Large Facilities Capital Fund of BIS, and the University of Exeter, and on the Complexity DiRAC Facility jointly funded by STFC and the Large Facilities Capital Fund of BIS.