<figure><img src="image_1.png" /></figure>

# An Investigation of the Formation and Line Properties of MgH in 3D Hydrodynamical Model Stellar Atmospheres

Anders O. Thygesen<fnref n="1" />, Evan N. Kirby<fnref n="1" />, Andrew J. Gallagher<fnref n="2" />,<fnref n="3" />, Hans-G. Ludwig<fnref n="4" />, Elisabetta Caffau<fnref n="3" />, Piercarlo Bonifacio<fnref n="3" />, and Luca Sbordone<fnref n="5" />

Received 2017 May 9; revised 2017 June 9; accepted 2017 June 12; published 2017 July 14

## Abstract

Studies of the isotopic composition of magnesium in cool stars have so far relied upon the use of 1D model atmospheres. Since the isotopic ratios derived are based on asymmetries of optical MgH lines, it is important to test the impact from other effects affecting line asymmetries, like stellar convection. Here, we present a theoretical investigation of the effects of including self-consistent modeling of convection. Using spectral syntheses based on 3D hydrodynamical CO⁵BOLD models of dwarfs (4000 K $\lesssim$ T<sub>eff</sub> $\lesssim$ 5160 K, 4.0 $\leq$ log g $\leq$ 4.5, -3.0 $\leq$ [Fe/H] $\leq$ -1.0) and giants (T<sub>eff</sub> ~ 4000 K, log g = 1.5, -3.0 $\leq$ [Fe/H] $\leq$ -1.0), we perform a detailed analysis comparing 3D and 1D syntheses. We describe the impact on the formation and behavior of MgH lines from using 3D models, and perform a qualitative assessment of the systematics introduced by the use of 1D syntheses. Using 3D model atmospheres significantly affect the strength of the MgH lines, especially in dwarfs, with 1D syntheses requiring an abundance correction of up to +0.69 dex, with the largest for our 5000 K models. The corrections are correlated with T<sub>eff</sub> and are also affected by the metallicity. The shape of the strong ²⁴MgH component in the 3D syntheses is poorly reproduced in 1D. This results in 1D syntheses underestimating ²⁵Mg by up to ~5 percentage points and overestimating ²⁴Mg by a similar amount for dwarfs. This discrepancy increases with decreasing metallicity. ²⁶Mg is recovered relatively well, with the largest difference being ~2 percentage points. The use of 3D for giants has less impact, due to smaller differences in the atmospheric structure and a better reproduction of the line shape in 1D.

**Key words:** hydrodynamics – line: formation – line: profiles – molecular processes – stars: atmospheres – techniques: spectroscopic

## 1. Introduction

The field of elemental abundance studies of stars in the Milky Way (MW) has seen an enormous renaissance over the past decade with the advent of several large-scale spectroscopic surveys like SEGUE (Yanny et al. 2009), RAVE (Steinmetz et al. 2006), the Gaia-ESO survey (Gilmore et al. 2012), GALAH (De Silva et al. 2015), and APOGEE (Majewski et al. 2015), with several future surveys seeing first light within the next decade (e.g., APOGEE-2, Sobeck et al. 2014; WEAVE, Dalton et al. 2012; PSF, Takada et al. 2014; and 4MOST, de Jong et al. 2016), promising an unprecedented amount of spectroscopic data.

While the measurements of bulk abundances provide a lot of information about the chemical enrichment history of the MW, deeper insight can be gained when one can also measure the isotopic composition of a given element. Most models of nucleosynthesis predict not only the bulk composition of various elements, but also the isotopic distribution. As such, measurements of the isotopic compositions provide more detailed information about the preceding nucleosynthesis. This is important if one is attempting to disentangle contributions from different sources of chemical enrichment, as different isotopes can be produced in different sites (see, e.g., Mashonkina & Zhao 2006 and Gallagher et al. 2010 regarding Ba odd/even ratios).

In the case of low-metallicity stars ([Fe/H] $\leq$ -1.0 dex), isotopes of magnesium are of particular interest. The most

abundant isotope, ²⁴Mg, is primarily produced in core-collapse supernovae, while the two heavier isotopes, ²⁵Mg and ²⁶Mg, are predominantly produced in asymptotic giant branch (AGB) stars at low metallicities. This makes magnesium isotopes well suited for studying the chemical enrichment timescales of old stellar populations like globular clusters (e.g., Yong et al. 2003a; Meléndez & Cohen 2009; Da Costa et al. 2013, and Thygesen et al. 2016), as well as of stars belonging to the MW halo (e.g., McWilliam & Lambert 1988; Yong et al. 2003b, and Meléndez & Cohen 2007).

Since the isotopic splittings of the atomic lines of most elements are significantly smaller than the thermal line broadening in the stellar atmospheres, one has to rely on spectral line asymmetries in isotopic studies, either in the atomic line themselves (e.g., Li, Ba) or in molecular features (e.g., CN, MgH, TiO). To accurately model the spectral line shapes, it is paramount to include other potential causes for line asymmetries aside from the effect of different isotopes.

Most isotopic studies have relied on the use of traditional 1D stellar atmospheres, which cannot model the convective motions of the gas in the stellar atmospheres. Convection, in itself, can lead to line asymmetries as discussed in, e.g., Dravins (1982), Dravins & Nordlund (1990), Asplund et al. (2000), Cayrel et al. (2007), and Klevas et al. (2013), which may mimic an isotopic signal. The use of full 3D model atmospheres resulted in a marked improvement for Ba odd/even ratios compared to 1D (Gallagher et al. 2015), as well as

<footnote n="1">¹ California Institute of Technology, 1200 E. California Boulevard, Pasadena, CA 91125, USA; thygesen@caltech.edu</footnote>

<footnote n="2">²Max-Planck Institute for Astronomy, Königstuhl 17, D-69117 Heidelberg, Germany</footnote>

<footnote n="3">³GEPI, Observatoire de Paris, PSL Research University, CNRS, Place Jules Janssen, F-92190 Meudon, France</footnote>

<footnote n="4">⁴Zentrum für Astronomie der Universität Heidelberg, Landessternwarte, Königstuhl 12, D-69117 Heidelberg, Germany</footnote>

<footnote n="5">⁵European Southern Observatory, Alonso de Cordova 3107, Vitacura, Santiago, Chile</footnote>
settling the debate about the existence of a ⁶Li plateau in metal-poor solar-type dwarf stars (Asplund et al. 2006; Asplund & Lind 2010; Steffen et al. 2012; Lind et al. 2013).

In addition, the temperature fluctuations in the 3D hydrodynamical models, as well as differences in the overall temperature structure can have a dramatic impact on the line formation of diatomic molecules as showed by, for instance, Asplund & García Pérez (2001), Collet et al. (2006), Bonifacio et al. (2013), Gallagher et al. (2016a), and Bessell et al. (2015) for NH, CN, CH, OH, and CO.

Recent improvements to the Linfor3D<fnref n="6" /> synthesis code (Gallagher et al. 2016b) have now made it more practical to compute 3D syntheses over larger spectral regions. In this paper, we present the first detailed investigation of the impact of using 3D hydrodynamical model atmospheres when modeling the optical features of MgH, typically used for the derivations of the distribution of Mg isotopes.

## 2. 3D Modeling of MgH Features

### 2.1. The 3D Model Atmosphere Grid

To compute 3D syntheses of the optical MgH transitions, we relied on a grid of models computed with the CO⁵BOLD hydrodynamical atmosphere code (Freytag et al. 2012). The models were computed under the assumption of local thermodynamic equilibrium (LTE). The code computes a small region of the star (the so-called box-in-a-star mode), represented as a Cartesian box covering the upper part of the convective envelope and the stellar photosphere, with a typical optical depth of $-6 < \log(\tau_{\text{ross}}) < 7$. The physical size of the box changes with temperature and gravity, and is scaled from the standard model of the Sun (5.6 × 5.6 × 2.3 Mm), according to the pressure scale height at the surface, $\log(\tau_{\text{ross}}) = 1$.

The dwarf models considered here are a subset of the models computed by the “Cosmological Impact of the First STars” (CIFIST) collaboration (Ludwig et al. 2009), while the giant models were computed for this project. Due to the substantial computational costs of constructing 3D hydrodynamical models, CO⁵BOLD utilizes precomputed opacity tables that have been grouped by wavelength (Nordlund 1982), with six opacity bins being the standard resolution. In the case of the giants, both standard and high-resolution models (12 opacity bins) were computed. The higher number of bins provides for a more accurate modeling of the outer layers of the stellar box, where the ranges in opacities can become very large. This may impact the spectral synthesis if the lines under investigation form predominantly in these layers. We compared the syntheses from 6 and 12 opacity bin models for the case of MgH, but did not find a noticeable difference. The 12 bin models were adopted for the remainder of the work presented in this paper.

We selected models in regions of the parameter space where one would expect to be able to detect Mg isotopes in MW halo stars. The full set of models are presented in Table 1. Note that unlike in traditional 1D models, it is not possible to enforce a $T_{\text{eff}}$ for a 3D hydro model, as this depends on the exact realization of the temperature fluctuations at a given instant in time. Hence, the average model $T_{\text{eff}}$ will deviate somewhat from the formally desired $T_{\text{eff}}$.

In addition to the full 3D hydrodynamical models, two additional models are provided. For each 3D model instance, a so-called “average 3D” or $\langle 3D \rangle$ model is constructed by temporally and spatially averaging the temperature structure of the full 3D box over surfaces of equal Rosseland optical depth. The result is a 1D model with the same average thermal structure as the full 3D computational box. For details of the averaging procedure, see, e.g., Ludwig & Kučinskas (2012). Furthermore, a traditional 1D model was computed using the Lagrangian hydrodynamical (LHD) code (Caffau & Ludwig 2007), which relies on the same input microphysics as CO⁵BOLD. Specifically, it uses the same equation-of-state and opacity binning scheme. Having these two sets of 1D models available allows us to directly investigate the impact of convection/temperature fluctuations (3D versus $\langle 3D \rangle$) and effects arising from changes to the overall temperature structure of the atmosphere ($\langle 3D \rangle$ versus 1D LHD). We will refer to the LHD syntheses and models as “1D” for the remainder of the paper.

For the computation of the 3D syntheses, a temporal sequence of computational boxes were selected from the full model sequence. We refer to these selections as snapshots. The snapshots were selected after the model had reached a statistically steady state. We used the 3D LTE synthesis code Linfor3D v.6.2.2 (Gallagher et al. 2016b) for the computation of the 3D, $\langle 3D \rangle$, and 1D syntheses. The syntheses for each 3D snapshot were subsequently averaged to yield the final 3D spectrum. Since only a small fraction of the stellar surface was simulated, we assumed that averaging over snapshots taken at different times was equivalent to averaging over the full stellar disk, as would be the case when dealing with spectra of real stars.

The temperature structure of 3D models can be markedly different from that of traditional 1D models, especially at lower metallicities (Nordlund & Dravins 1990; Asplund 2005; Freytag et al. 2012). In Figure 1, we present examples of the $T(\tau)$ structures of the full 3D computations of our 12 opacity bin giant models, as well as six dwarf models. The $T(\tau)$ structure of the remaining models is presented in Appendix A, Figures 12 and 13. In the case of the giants, relatively large temperature variations are observed in the line-forming regions in the 3D case, especially in the two low-metallicity cases. This is in line with the more vigorous convection in these models, compared to a dwarf model. The $\langle 3D \rangle$ and 1D models, on the other hand, look very similar in terms of the overall structure in the line-forming region, with the 1D giant model being slightly hotter in the $[\text{Fe}/\text{H}] = -3.0$ case.

The dwarf models, on the other hand, show very different model structures when the metallicity decreases. The 3D and $\langle 3D \rangle$ models have a notably cooler atmosphere than their 1D counterparts. This is the well-known extra cooling from the low amount of radiative line heating at the metallicities considered here, combined with the adiabatic expansion of the convective cells, which is not adequately modeled in 1D. This effect has been observed in most 3D models of low-metallicity dwarfs (see, e.g., Asplund et al. 1999 and Ludwig et al. 2008). Also, the temperature fluctuations in the low-metallicity models are much less pronounced than in the high-metallicity case. This behavior is different than what has been observed in higher temperature dwarfs, where the temperature fluctuations tend to increase with decreasing metallicity (Magic et al. 2013; Gallagher et al. 2016a). However, there is evidence that this behavior reverses for the coolest dwarf models ($\lesssim 5000$ K),

<footnote n="6">⁶ http://www.aip.de/Members/msteffen/linfor3d</footnote>
<table><caption>**Table 1**
The CO<sup>5</sup>BOLD Model Atmosphere Grid Used for Our 3D Syntheses</caption><thead><tr><th rowspan="2">Model</th><th rowspan="2">T<sub>eff</sub> (K)</th><th rowspan="2">log g (dex)</th><th rowspan="2">[Fe/H] (dex)</th><th colspan="2">1D only</th></tr><tr><th>ξ<sub>micro</sub> (km s<sup>-1</sup>)</th><th>v<sub>macro</sub> (km s<sup>-1</sup>)</th></tr></thead><tbody><tr><td>d3t4000g150m10 × 140z150k12</td><td>4051</td><td>1.5</td><td>-1.0</td><td>0.91</td><td>4.88</td></tr><tr><td>d3t4000g150m20 × 140z150k12</td><td>4003</td><td>1.5</td><td>-2.0</td><td>0.90</td><td>3.77</td></tr><tr><td>d3t4000g150m30 × 140z150k12</td><td>4002</td><td>1.5</td><td>-3.0</td><td>1.14</td><td>3.22</td></tr><tr><td>d3t40g15mm10n01</td><td>4040</td><td>1.5</td><td>-1.0</td><td>0.87</td><td>4.77</td></tr><tr><td>d3t40g15mm20n01</td><td>4001</td><td>1.5</td><td>-2.0</td><td>0.90</td><td>3.83</td></tr><tr><td>d3t40g15mm30n01</td><td>3990</td><td>1.5</td><td>-3.0</td><td>1.01</td><td>2.68</td></tr><tr><td>d3t40g45mm10n01</td><td>4001</td><td>4.5</td><td>-1.0</td><td>0.50</td><td>0.21</td></tr><tr><td>d3t40g45mm20n01</td><td>4000</td><td>4.5</td><td>-2.0</td><td>0.00</td><td>0.00</td></tr><tr><td>d3t45g40mm10n01</td><td>4525</td><td>4.0</td><td>-1.0</td><td>0.97</td><td>0.00</td></tr><tr><td>d3t45g40mm20n01</td><td>4504</td><td>4.0</td><td>-2.0</td><td>1.01</td><td>0.02</td></tr><tr><td>d3t45g40mm30n02</td><td>4494</td><td>4.0</td><td>-3.0</td><td>0.93</td><td>0.00</td></tr><tr><td>d3t45g45mm10n01</td><td>4499</td><td>4.5</td><td>-1.0</td><td>0.21</td><td>0.34</td></tr><tr><td>d3t45g45mm20n01</td><td>4539</td><td>4.5</td><td>-2.0</td><td>0.40</td><td>0.17</td></tr><tr><td>d3t45g45mm30n01</td><td>4522</td><td>4.5</td><td>-3.0</td><td>0.77</td><td>0.00</td></tr><tr><td>d3t50g40mm10n01</td><td>4986</td><td>4.0</td><td>-1.0</td><td>0.72</td><td>1.91</td></tr><tr><td>d3t50g40mm20n01</td><td>4955</td><td>4.0</td><td>-2.0</td><td>1.33</td><td>0.23</td></tr><tr><td>d3t50g40mm30n02</td><td>5160</td><td>4.0</td><td>-3.0</td><td>1.68</td><td>0.72</td></tr><tr><td>d3t50g45mm10n03</td><td>5061</td><td>4.5</td><td>-1.0</td><td>0.69</td><td>0.88</td></tr><tr><td>d3t50g45mm20n03</td><td>5013</td><td>4.5</td><td>-2.0</td><td>1.30</td><td>0.00</td></tr><tr><td>d3t50g45mm30n03</td><td>4992</td><td>4.5</td><td>-3.0</td><td>1.40</td><td>0.00</td></tr></tbody></table>

Note. The models with “k12” appended to their name indicate models computed with 12 opacity bins. For details on the derivation of the 1D model ξ<sub>micro</sub> and v<sub>macro</sub>, see Section 4. The model names for the dwarfs and the low-resolution giants follow the nomenclature used by the CIFIST collaboration. They indicate the “desired” model T<sub>eff</sub> (t), log g (g), metallicity (“m,” the second “m” indicates that the metallicity is negative), and the model version (“n”). The names for the giant models with a high number of opacity bins follow largely the same naming scheme with model T<sub>eff</sub> (t), log g (g), and metallicity (“m,” would be “p” for positive metallicity), but are expanded to include the number of grid cells in the horizontal directions (x, y) and vertical direction (z), and the number of opacity bins (k).

<figure><img src="image_2.png" /></figure>

**Figure 1.** Examples of the T(τ) structure of a subset of 3D CO<sup>5</sup>BOLD models (density map) together with their (3D) (red dashed line) and 1D (cyan dotted-dashed) counterparts. The darker areas indicate more frequently sampled temperature points. Shown for giants (top row), log(g) = 4.0 dwarfs (middle), and log(g) = 4.5 dwarfs (bottom). The model parameters are given in the captions. Note that each row defines a metallicity sequence. The formation regions of MgH in 3D (light red) and 1D (light blue) are indicated as horizontal bars.
<figure><img src="image_3.png" /><figcaption>**Figure 2.** Equivalent width contribution functions (MgH only) for the three MgH features under study. Shown for models d3t45g45mm10n01, d3t45g45mm20n01, and d3t45g45mm30n01 for the 3D (black solid), ⟨3D⟩ (red dashed), and 1D (blue dotted–dashed) syntheses.</figcaption></figure>

with fluctuations increasing with increasing metallicity
(Allende Prieto et al. 2013; Magic et al. 2013).

## 2.2. The Input Line List

All of the MgH features contain blends from both atomic and molecular species. We constructed a line list for use in the synthesis using input from a number of sources. MgH transitions were taken from Hinkle et al. (2013) and Shayesteh & Bernath (2011), with blending C₂, CN, and CH lines from Brooke et al. (2013, 2014) and Masseron et al. (2014) respectively. In addition, we incorporated atomic blends from the Gaia-ESO line list (Heiter et al. 2015), which is supplied with atomic blends from VALD (Kupka et al. 2000). After having constructed an initial line list, we made a careful calibration by comparing spectral syntheses based on the standard CO<sup>5</sup>BOLD model of the Sun to a high-resolution spectrum of the Sun, taken from BASS2000<sup>7</sup> (Delbouille & Roland 1995). Based on the comparison with the Sun, we performed an astrophysical correction of the oscillator strength of the MgH lines at 5135.5 Å and 5140.2 Å to reproduce the solar spectrum.

We used two different line lists, one for the MgH feature at 5135.1 Å (188 transitions) and one for the two features at 5138.7 Å and 5140.2 Å, (409 transitions) since the two latter lines suffered from blends from the wings of two strong Fe I lines at 5139.25 Å and 5139.47 Å, which needed accounting for in both cases. We attempted to minimize the number of lines in each line list, but note that the majority of the transitions for each region were from either C₂ or CN, which may not leave a visible signature at the temperature of the Sun.

Due to the significantly cooler temperatures of dwarfs targeted for MgH studies, molecular formation would be expected to be more efficient. For these reasons we decided to keep these transitions in our line list.

## 3. Formation of MgH Features

We computed a number of syntheses using a standard solar-scaled abundance pattern with [α/Fe] = +0.4 dex and three isotopic compositions of magnesium (100:0:0, 94:3:3, and 88:6:6, expressed as the ratio $^{24}$Mg:$^{25}$Mg:$^{26}$Mg). This is roughly the range that is expected for metal-poor stars in the MW halo (Yong et al. 2003b).

The differences in the temperature structure between 1D and 3D models (Figure 1) have a marked influence on the formation of the lines of MgH. In Figure 2, we show the contribution functions of syntheses including only MgH for three representative dwarf models. The contribution functions have been computed with identical [Mg/Fe] = +0.4 and an isotopic mixture of 88:6:6 in all cases shown here. They provide the fractional contribution to the line equivalent width (EW) as a function of optical depth, so that the integral gives the total line strength. The EW contribution functions were computed from the line depth contribution functions (Magain 1986). The formal definition of the EW contribution function, as implemented here, can be found in Equation (59) in the Linfor3D user manual.<fnref n="8" />

It is evident that when the metallicity decreases, the difference between using 3D models and 1D models becomes more substantial. In the 3D case, the region of line formation extends over a larger optical depth than is the case for the 1D models, with the contribution functions becoming shallower

<footnote n="7">⁷ http://bass2000.obspm.fr/solarspect.php</footnote>

<footnote n="8">⁸ http://www.aip.de/Members/msteffen/linfor3d</footnote>
<figure><img src="image_4.png" /><figcaption>Figure 3. As Figure 2, but for the giant case.</figcaption></figure>

and broader. Furthermore, in 3D, the line formation peaks in shallower layers than when using traditional atmospheres. These layers will have more efficient molecular formation as they are generally cooler in 3D, resulting in stronger features that become more pronounced as the metallicity decreases.

The effects of temperature fluctuations, on the other hand, seem to have a negligible impact on the MgH line formation in the cases shown here. This is clear from comparing the contribution functions for the 3D and ⟨3D⟩ cases, which are nearly identical. Only in the −1.0 metallicity case is there a marginal difference between the full 3D and ⟨3D⟩ contribution functions. This is also the model where the *T*(*τ*) structure (Figure 1, bottom row) exhibits the largest temperature fluctuations. It follows that the dominant reason for the differences in the line-forming regions arises from the differences in the overall structure of the atmospheres, as is evident by comparing 1D and ⟨3D⟩, rather than from *T* fluctuations.

In the case of giant stars (Figure 3), some obvious differences are observed compared to the dwarf case. While the shift in the main formation depth was evident at all metallicities in the dwarfs, this is negligible for the giants at [Fe/H] = −1.0, and is only becoming comparable to the dwarf case at the lowest metallicity. For the giants, the contribution functions are also notably shallower at high metallicity, indicating that the 3D MgH lines will tend to be weaker than their 1D counterpart. The influence of temperature fluctuations is more pronounced for giants than for the dwarfs investigated above. This is particularly true at the lowest metallicity, as suggested by the behavior of the *T* fluctuations in the models. But as in the dwarf case, overall changes to the *T* structure appear to be the dominant effect, becoming more important as the metallicity decreases. Although the *T*(*τ*) structures of the giants are very similar even at a metallicity of −3.0, it can be seen from Figure 1 that there still is

a difference of a few hundred K between the 3D and 1D models at [Fe/H] = −3.0, which explains part of the differences seen in the contribution functions.

In reality, none of the MgH features modeled here are free from blends. Although many of the lines from the blending species are weak, they may react differently to 3D effects, resulting in differences in line shape and strength that can affect the interpretation of observed spectra. In Figure 4, we present the contribution functions of the two regions computed for the purpose of the isotopic analysis for a typical dwarf (top) and a typical giant (bottom), including all blending lines. Also shown is the MgH-only contribution functions for the 5135 Å feature and for the entire region including the 5138.7 Å and 5140.2 Å features. The inclusion of blending lines clearly has a significant impact on the overall shape of the contribution functions, especially in the giant case.

Comparing the top rows of the dwarf and giant contribution functions in Figure 4 to the bottom rows in the same figure, the 5135 Å region shows similar behavior when all blends are included in both cases. The same holds for the region with the 5138.7 Å and 5140.7 Å MgH transitions for the dwarf.

The giant model in Figure 4, on the other hand, shows more pronounced differences when all blends are included. Here, the ⟨3D⟩ synthesis shows a larger deviation from the full 3D case than when looking only at MgH transitions. This indicates that the temperature fluctuations are becoming more important for the line formation of the blends than was the case in the dwarf model. This can be understood as a consequence of the larger *T* fluctuations observed in giants, relative to the dwarfs, which will impact especially molecular lines (Gallagher et al. 2016a). The reason that the region including the 5138.7 Å and 5140.2 Å MgH features exhibits larger 3D–1D differences is a consequence of the
<figure><img src="image_5.png" /><figcaption>**Figure 4.** Contribution functions for the region including the 5135 Å MgH feature and the region including the 5138 Å and 5140 Å features, for MgH only (top row for each model) and including all molecular and atomic blends (bottom row for each model). Top: the dwarf model d3t45g45mm10n01. Bottom: the giant model d3t4000g150m10 × 140z150k12.</figcaption></figure>

broader wavelength range computed here, as this includes a larger number of blending species, compared to the 5135 Å region.

### 3.1. Molecular Number Densities

The changes in the temperature structure of the model atmospheres, as well as the temperature fluctuations, will impact the molecular number densities, $n_j$. Examples of this are

shown in Figure 5 for three giant (top) and three dwarf (bottom) models, and were computed using the partition functions from Sauval & Tatum (1984). It is evident that convection impacts the formation of MgH to a larger extent in the giant case, where fluctuations in the MgH number density are observed in the outer parts of the atmosphere. This is significantly less pronounced in the dwarf case. However, both for giants and dwarfs, the number densities do not fluctuate as
<figure><img src="image_6.png" /><figcaption>**Figure 5.** Number densities of MgH for the 3D case (density plot), 〈3D〉 case (white dash), and the 1D case (cyan dotted–dashed) for three giants (top) and three dwarfs (bottom) at different metallicities. Darker shaded regions indicate a higher sampling of points with this number density. See Table 1 for model details.</figcaption></figure>

much as in the case for other molecules investigated in 3D (see Gallagher et al. 2016a for the dwarf case and Collet et al. 2007 for giants), and in all cases the results from the 〈3D〉 models closely resemble the full 3D case.

One possible explanation for this behavior could be the very low dissociation energy of MgH ($D_0$ = 1.34 eV), compared to that of CH, CO, and OH investigated by Gallagher et al. (2016a; $D_0$ = 3.465, 11.092 and 4.392 eV, respectively). As such, one might expect the number densities of the carbon-bearing molecules to be more sensitive to *T* fluctuations than MgH. To test this, we computed $n_j$ for CO and CH for the model d3t45g45mm30n01. It was found that the number densities of these molecules closely resembled what we found for MgH, with a narrow, symmetric distribution, without strong fluctuations. Thus, the main reason for the difference between the molecular $n_j$ in the dwarf models investigated here, compared to Gallagher et al. (2016a), must be related to the lack of *T* fluctuations, and not to differences in $D_0$ between the molecules considered in the two cases. This was further confirmed by computing an experimental synthesis with the $D_0$ of MgH artificially increased to 11 eV, which only served to increase $n_j$ but did not alter the shape of the distribution.

There is very little difference between the full 3D and the 1D results in the giant case for all metallicities. The number densities are essentially the same, which is also supported by the MgH-only contribution functions, which show comparable strength and formation depth.

For the metal-poor dwarfs, this is no longer the case. While the temperature fluctuations due to convection only have a small impact, the significant changes to the overall temperature structure of the atmosphere between the 3D and 1D models become important. Indeed, as seen in Figure 1, the temperature

in parts of the line-forming region is significantly cooler in the 3D/〈3D〉 case, compared to the 1D models, resulting in a significantly more efficient formation of MgH by almost an order of magnitude in the main line-forming region. Number densities for the models not shown in Figure 5 are presented in Figures 14 and 15 in Appendix B.

# 4. Analysis of 3D MgH Features

## 4.1. Micro- and Macroturbulence

The self-consistent modeling of convection in 3D hydrodynamical model atmospheres has several advantages over 1D models. In particular, the models aim at a realistic modeling of the turbulent gas motion, so that it is no longer required to parametrize this using microturbulence, $\xi_{\text{micro}}$, and macroturbulence, $v_{\text{macro}}$. However, since the 3D gas motions are undoubtedly impacting the line shapes, this needs to be accounted for in the 1D syntheses before a meaningful comparison can be made between 1D and 3D. This is especially important when dealing with isotopic ratios, as the line broadening applied in 1D will have a significant impact on the line shapes and hence the derived abundance of the Mg isotopes.

To derive the $\xi_{\text{micro}}$ and $v_{\text{macro}}$ of the 3D models, we used four different lines: three Ca I lines at 5581 Å, 5590 Å, and 5601 Å, and one Ti I line at 5145 Å. These lines all have 1D contribution functions very similar to those of MgH, and have been used in previous studies of Mg isotopes to derive $v_{\text{macro}}$ in 1D syntheses (Yong et al. 2003b and Meléndez & Cohen 2007).

We utilized method 2a from Steffen et al. (2013) to derive $\xi_{\text{micro}}$. In brief, from each of the atomic transitions, we
<figure><img src="image_7.png" /><figcaption>**Figure 6.** Contribution functions for the lines used to determine $\xi_{\text{micro}}$ and $v_{\text{macro}}$ for model d3t50g40mm30n02.</figcaption></figure>

generated a set of nine artificial lines, changing the log (gf) value to get a variation in line strength, but kept all other line parameters intact. A full 3D synthesis was computed for these sets, constituting 36 lines in total. In addition, we computed a set of 1D syntheses for each line, varying $\xi_{\text{micro}}$, but also again changing the log (gf) for each line. This provided a set of 1D syntheses with different $\xi_{\text{micro}}$ and log (gf) for each of the 36 lines computed in full 3D. We changed the log (gf) values to account for possible differences in line strength between 1D and 3D. We assumed that changing the log (gf) value was equivalent to changing the abundance, log $\epsilon$. The advantage of changing log (gf) over changing the raw abundance of the lines in question is that we do not need to consider possible changes to the free electron budget. This could in principle impact the continuum opacity through $H^{-}$. By changing the log (gf) of the lines instead, we circumvented this.

For each 3D line equivalent width, $EW_{3D}$, we thus have a set of $EW_{1D}(\xi_{\text{micro}}, j)$, log $\epsilon_{1D, i}$. For each $\xi_{\text{micro}}$, we then computed the abundance correction, $\Delta \log \epsilon_{1D, i}(\xi_{\text{micro}})$, so that $EW_{3D} = EW_{1D}$. To finally derive the microturbulence in the 3D model, we performed linear fits to {$EW_{3D}$, $\Delta \log \epsilon_{1D}(\xi_{\text{micro}})$} and demanded that the relation had a slope of zero. We ensured that only lines with an EW less than 150mÅ were used for this exercise to avoid problems with strong saturation.

The three Ca I lines gave consistent values for $\xi_{\text{micro}}$ across all 3D models, while the $\xi_{\text{micro}}$ derived from the Ti I line showed some deviation. We attributed this to the fact that while the selected elements have comparable ionization energy (Ca I = 6.11 eV, Ti I = 6.83 eV; Kramida et al. 2015), the excitation potentials differ by ~1 eV. Since the line strength depends on both temperature and these two energies, the Ca and Ti lines will have different sensitivities to the temperature fluctuations and the different temperature structure in the 3D models. Indeed, for the low-metallicity dwarfs, the contribution functions for the Ca lines and Ti lines can be very different between 1D and 3D (Figure 6), with the 3D lines forming over a much larger range of optical depths than the 1D case. As such, it is not surprising that we cannot describe $\xi_{\text{micro}}$ with a single value for both the Ca and Ti lines. The contribution functions of the Ca lines were more similar to the MgH contribution functions than to those of the single Ti line, and we discarded the latter in the determination of $\xi_{\text{micro}}$ and $v_{\text{macro}}$. As our final value, we took the average of the individual Ca lines. We report these in Table 1.

While the $\xi_{\text{micro}}$ determination gives reasonable, albeit low, values in most cases, it is worth noting that there seems to be a correlation between $\xi_{\text{micro}}$ and metallicity, with the $\xi_{\text{micro}}$ increasing as the metallicity decreases. A similar effect was seen by Steffen et al. (2013), who attributed this not to the low-metallicity models having an abnormally high $\xi_{\text{micro}}$ but rather an effect of the changes in temperature structure between 3D and 1D models. The metal-poor 3D models are significantly cooler in the line-forming region than their 1D counterparts. Thus, strong, low excitation potential lines will require a higher abundance correction than weaker lines to match the 3D EW. Since we determine the $\xi_{\text{micro}}$ by requiring identical abundance corrections across all line strength, this will tend to increase $\xi_{\text{micro}}$ as a high value of $\xi_{\text{micro}}$ will compensate for a line-dependent abundance correction.

One model, d3t40g45mm20n01, stands out, giving a microturbulence of zero. While this might seem surprising, an inspection of the temperature structure revealed that the 3D model has very efficient convection, with essentially adiabatic stratification out to an optical depth of ~-2.0, also for the 1D model (Figure 12). The effective temperature of the model together with efficient convection implies small convective velocities and small temperature fluctuations, so that thermal motion will dominate the line broadening. Moreover, the T-distribution is very narrow and practically identical between 3D and 1D. As such, one would not expect weak lines forming in this region to require any significant $\xi_{\text{micro}}$ nor abundance corrections to compensate for line strength differences, as they would be nearly identical already.

Before performing any additional analysis of the 3D spectra, we convolved all spectra with a Gaussian with an FWHM corresponding to $R = 110,000$, which is the typical resolving power of a UVES-like spectrograph used for observing stars for the purpose of studying MgH isotopes.

With the 3D model $\xi_{\text{micro}}$ determined, we derived the $v_{\text{macro}}$ by fitting the same 3D spectral lines with 1D syntheses computed with the $\xi_{\text{micro}}$ and $\Delta \log \epsilon_{1D}$ just determined, but with a range of broadenings. We assumed that $v_{\text{macro}}$ was isotropic and described by a Gaussian, and took the best-fitting value as determined by a $\chi^2$ minimum to represent the macroscopic turbulence in our 1D syntheses. The value of $v_{\text{macro}}$ reported in Table 1 corresponds to the straight average of the values from the individual lines. Before fitting the 1D
<figure><img src="image_8.png" /><figcaption>**Figure 7.** Syntheses of the three MgH features in the dwarf model d3t40g45mm20n01. 3D (solid black) and 1D (solid red) syntheses are shown. The best-fitting values of the Mg abundance and $^{24}$Mg:$^{25}$Mg:$^{26}$Mg 1D fit are shown in the legend. This synthesis included only $^{24}$MgH. We indicate the central wavelength of the $^{24}$MgH features with vertical blue and magenta dashed lines, scaled relative to the strength of the strongest component of the 3D syntheses in each panel.</figcaption></figure>

syntheses, we performed a wavelength shift to account for the convective line shift present in the 3D syntheses.

As can be seen from Table 1, we found that the giant models have larger $v_{\text{macro}}$ than the dwarfs. It is also worth noting that the determined $v_{\text{macro}}$ decreases with decreasing metallicity, for both dwarfs and giants. This can be attributed to the increased $\xi_{\text{micro}}$, which will already introduce additional line broadening as discussed above. In effect, that results in a small (or no) subsequent macroturbulent broadening needed in the 1D syntheses to provide the best match to the 3D syntheses, effectively creating an anti-correlation between $\xi_{\text{micro}}$ and $v_{\text{macro}}$.

## 4.2. 3D–1D Corrections

In Figure 7, we show $^{24}$MgH-only syntheses for all three features for our coolest dwarf model for $[\alpha/\text{Fe}] = +0.4$. Both the original 3D and best-fitting 1D syntheses are shown, and we indicate the central wavelength of the $^{24}$MgH isotopic component for each feature. The best fits were determined through $\chi^2$ minimization, varying the abundance of Mg, as well as the fraction of $^{25}$Mg and $^{26}$Mg, under the constraint that the total amount $^{24}$Mg + $^{25}$Mg + $^{26}$Mg = 100. In addition, a small wavelength shift was permitted in order to account for possible convective velocity shifts. Even with $\xi_{\text{micro}}$ and $v_{\text{macro}}$ values of 0 km s$^{-1}$ and a reduced [Mg/Fe], the 1D syntheses are still broader than the full 3D syntheses, which are particularly evident for the 5138 Å feature. In addition, the 1D syntheses are not able to simultaneously reproduce the 3D line shape and the core strength.

To investigate whether the 1D dwarf syntheses were systematically broader than the 3D counterparts, we analyzed the $^{24}$MgH-only syntheses for all our dwarf models. The 1D

and $\langle 3D \rangle$ syntheses were computed with identical values of $\xi_{\text{micro}}$. We performed Gaussian fits to the 1D, $\langle 3D \rangle$, and 3D syntheses for each model and computed the FWHM, which we used to quantify the total line broadening. In essentially all cases it was found that $\text{FWHM}_{\text{1D}} > \text{FWHM}_{\text{3D}} \ge \text{FWHM}_{\langle 3D \rangle}$. Only for the two hottest models at [Fe/H] = -1.0 were the 3D syntheses broader than both the $\langle 3D \rangle$ and 1D syntheses. This is consistent with these models also having the largest T fluctuations among the dwarfs (Figure 13). That the 1D syntheses are broader than the $\langle 3D \rangle$ models suggests that the main reason for the discrepancy is the difference in the overall temperature structure between 3D and 1D. The line-forming regions in 1D are significantly hotter, so the thermal broadening of the lines will be larger. This is true even for the coolest dwarfs which show significant differences in their structure between 3D and 1D, already for a metallicity of -1.0 (Figure 12). We note that these syntheses were computed without applying any macroturbulent/instrumental broadening, although that would not have changed the result.

Two things can be learned from this:

First, the difference in line strength means that any 1D fit will tend to overestimate the abundance of Mg, as this will need to be artificially increased to match the full line strength. This was already observed by Ramirez (2008) in the case of the solar metallicity dwarf, HIP 86400 ($T_{\text{eff}}$ = 4830 K, $\log g$ = 4.62, [Fe/H] = -0.05). They found a significantly better match between observations and the spectral synthesis from a 3D model, compared to that from a traditional 1D model, when computed with identical Mg abundance.

Second, the broader lines found in the 1D case will tend to result in an underestimation of the amount of the heavy isotopes, when fitting spectra with syntheses based on 1D model atmospheres.
<figure><img src="image_9.png" /><figcaption>**Figure 8.** 1D fit (red) to the d3t45g45mm20 3D syntheses for each of the three features. Original composition (3D) and best-fit values (1D) are provided in the captions. The central wavelength of the MgH features is shown as the vertical solid blue and dotted-dashed magenta lines. The lengths of the lines are scaled relative to the strongest component in each panel, and to isotopic fraction of the 3D syntheses.</figcaption></figure>

To investigate this in more detail, we performed fits with 1D syntheses to a number of 3D syntheses, using the *Fitprofile* software described in Thygesen et al. (2016). We simultaneously fit the abundance of magnesium, as well as the fraction of $^{25}$Mg and $^{26}$Mg. The fraction of $^{24}$Mg was subsequently computed as 100 $^{-25}$Mg $^{-26}$Mg. *Fitprofile* also allows for small velocity shifts when performing the $\chi^2$ minimization to account for convective line shifts not present in the 1D models.

For each 3D model, we analyzed three different syntheses, with isotopic compositions 100:0:0, 94:3:3, and 88:6:6, percent-age $^{24}$Mg:$^{25}$Mg:$^{26}$Mg. This covers the expected range of isotopic compositions in stars at these metallicities (Yong et al. 2003b). All syntheses were computed with [α/Fe] = +0.4.

Figure 8 shows the best-fitting 1D syntheses for each of the MgH features for a typical dwarf model, with the 3D syntheses computed for an 88:6:6 isotope composition. The 1D syntheses are reproducing the line shapes well for the 5135 Å and 5140 Å features in this case, although the tendency of the 1D syntheses to be slightly too broad is still visible. The situation is markedly different for the 5138 Å feature, where neither the line shape nor the line strength is well reproduced in 1D, even considering the substantial enhancement in Mg. The fraction of the heavy isotopes is also overestimated for all three features. This confirms the expectations from Figure 7 that the 1D syntheses would tend to yield lower amounts of the heavy isotopes, even if we are able to reproduce the shape of the MgH wings well. The problems with reproducing the MgH feature at 5138 Å are persistent across most dwarfs models for the three isotopic mixtures considered here, although we note that the agreement improves for the 5000 K models.

In the case of a giant model, the 1D syntheses were also able to fit the 3D spectra well (Figure 9). Both the line strengths and

the overall line shapes were reproduced remarkably well in the 1D case for this particular model, with the $^{25}$Mg fraction being slightly overestimated. The best-fitting Mg abundances were essentially identical to the input abundance. The good reproduction of the 3D line profile remains for the giant models at [Fe/H] = -1.0 and -3.0, but in these cases the disagreement between the input Mg abundance and the best-fitting value increased. Nevertheless the agreement between 1D and 3D for the Mg abundance was still significantly better than for the dwarfs, at most differing by 0.16 dex. The isotopic fractions, on the other hand, stay essentially unchanged, differing at most by 1.4 percentage points for $^{24}$Mg in the case of the 88:6:6 mixture for the [Fe/H] = -3.0 metallicity giant. The differences for the heavy isotopes across all remaining features and giant models were typically ≤1 percentage point.

In Table 2, we provide the 3D corrections to the derived Mg abundances, in the sense $\Delta\text{Mg}_{3\text{D}-1\text{D}} = A(\text{Mg})_{3\text{D}} - A(\text{Mg})_{1\text{D}}$. We averaged the results from the fits of the individual features, and note that the feature-to-feature agreement is typically good, differing only by a few hundredths of a dex in the vast majority of the cases.

In Figure 10, we plot the $\Delta\text{Mg}_{3\text{D}-1\text{D}}$ value for all models in our sample, including error bars given as the standard deviation. It is evident that there is a correlation with $T_{\text{eff}}$ with hotter models showing a larger deviation in Mg abundance, peaking at [Fe/H] = -2.0 for the 5000 K, $\log g = 4.0$ model. It is clear that the metallicity also has an impact, both for giants and dwarfs, where the correction changes signs for the giants as the metallicity decreases. The hottest models also exhibit larger corrections as the metallicity drops below [Fe/H] = -1.0. The 4500 K dwarfs, on the other hand, appears to have a nearly constant abundance offset across all metallicities. Yong et al.
<figure><img src="image_10.png" /><figcaption>**Figure 9.** 1D fit (red) to the d3t4000g150m20 × 140z150k14 3D syntheses for each of the three features. The original composition (3D) and best-fit values (1D) are provided in the captions. The central wavelength of the MgH features are shown as vertical solid blue and dotted-dashed magenta lines. The length of the lines are scaled relative to the strongest component in each panel and to isotopic fraction of the 3D syntheses.</figcaption></figure>

<table><caption>**Table 2**
The 3D–1D Corrections for the Mg Abundance, Derived from $\chi^2$ Fits to the 3D Syntheses of the Three MgH Features</caption><thead><tr><th>Model</th><th>ΔMg<sub>3D-1D</sub></th></tr></thead><tbody><tr><td>d3t4000g150m10 × 140z150k14</td><td>+0.15</td></tr><tr><td>d3t4000g150m20 × 140z150k14</td><td>-0.03</td></tr><tr><td>d3t4000g150m30 × 140z150k14</td><td>-0.13</td></tr><tr><td>d3t40g45mm10n01</td><td>+0.13</td></tr><tr><td>d3t40g45mm20n01</td><td>+0.02</td></tr><tr><td>d3t45g40mm10n01</td><td>-0.18</td></tr><tr><td>d3t45g40mm20n01</td><td>-0.19</td></tr><tr><td>d3t45g40mm30n02</td><td>-0.19</td></tr><tr><td>d3t45g45mm10n01</td><td>-0.27</td></tr><tr><td>d3t45g45mm20n01</td><td>-0.24</td></tr><tr><td>d3t45g45mm30n01</td><td>-0.16</td></tr><tr><td>d3t50g40mm10n01</td><td>-0.30</td></tr><tr><td>d3t50g40mm20n01</td><td>-0.69</td></tr><tr><td>d3t50g40mm30n02</td><td>-0.65</td></tr><tr><td>d3t50g45mm10n03</td><td>-0.32</td></tr><tr><td>d3t50g45mm20n03</td><td>-0.60</td></tr><tr><td>d3t50g45mm30n03</td><td>-0.39</td></tr></tbody></table>

(2004) studied Mg isotopes in a large sample of Hyades dwarfs and also found a correlation between the Mg abundance derived from the MgH features and the stellar $T_{eff}$, with stars at 5000 K having ~0.2 dex higher Mg values than their counterparts at 4000K. They did, however, find that the Mg abundance derived from the MgH features were smaller than the equivalent derived from atomic lines. This, together with the smaller range found by these authors, is likely a consequence of the metallicity of the Hyades being slightly above solar. This is supported by our model comparisons, which suggest that the

total range of Mg corrections decrease and that $\Delta Mg_{3D-1D}$ may change signs as the metallicity increases, as indicated by the correction for the 4000 K dwarf at $[Fe/H] = -1.0$.

The contribution functions shown in Figures 2 and 4 suggest that the MgH line equivalent widths are relatively similar between 1D and 3D, especially for the most metal-rich dwarf shown. That we still found a need for abundance corrections when fitting our 3D syntheses with 1D syntheses is a consequence of the $^{24}$MgH component already dominating the spectrum. For the heavy isotope fractions considered here, any decrease (increase) in the amount of $^{25}$Mg and $^{26}$Mg will also decrease (increase) the total line EW, as the $^{24}$MgH component barely changes strength, since the vast majority of the available Mg is already in this form. To match the line asymmetries it was found that a decrease in the heavy isotopes was required in the 1D syntheses (see below). This, in turn, allowed for a better match to the 3D core line strength by increasing the Mg abundance. As such, not only the core strength but also the line shape affects the derived 3D–1D Mg abundance corrections.

Deriving 3D–1D corrections for the isotopic fractions of Mg was more subtle, as this required an accurate reproduction of the full line shape, which was not possible for the 5138 Å feature in the dwarf models. Nevertheless, it is instructive to inspect also the differences between 1D and 3D for the isotopes, to assess qualitatively, whether any systematic effects are present. In Figure 11, we plot $\Delta^{24,25,26}\text{Mg}_{3\text{D}-1\text{D}}$ fractions for all our models, based on the syntheses with the 88:6:6 isotopic composition. While these differences should not be considered as absolute corrections to be applied to 1D analyses of real stellar spectra, some systematic behavior is still evident.

The magnitude of the differences between 3D and 1D increases for the dwarf models as the metallicity decreases. We
<figure><img src="image_11.png" /><figcaption>**Figure 10.** $\Delta\text{Mg}_{3\text{D}-1\text{D}}$ for all models, against $T_{\text{eff}}$. Model gravities are $\log g = 1.5$ (green squares), $\log g = 4.0$ (blue triangles), and $\log g = 4.5$ (red circles). Each panel is for a fixed metallicity. The error bars give the standard deviation of the mean and are smaller than the size of the plotting symbols in most cases.</figcaption></figure>

<figure><img src="image_12.png" /><figcaption>**Figure 11.** $\Delta^{24,25,26}\text{Mg}_{3\text{D}-1\text{D}}$ fractions for all models, against $T_{\text{eff}}$. Symbol shapes have the same meaning as in Figure 10, but here are color coded according to the specific isotope ($^{24}\text{Mg}$, open symbols; $^{25}\text{Mg}$, light shaded symbols; $^{26}\text{Mg}$, dark shaded symbols). The error bars give the standard deviation of the mean.</figcaption></figure>

attribute this to the changes in the overall temperature structure of the model atmospheres, which increases when the metallicity decreases as discussed in Section 2. As a result, lines of MgH, as well as blending species will form in layers of the atmosphere with significantly different temperatures, which impacts the line formation. It also appears that the 1D models tend to underestimate the $^{25}\text{Mg}$ fraction and overestimate the amount of $^{24}\text{Mg}$ relative to the input composition in the 3D syntheses. The fraction of $^{26}\text{Mg}$, on the other hand, is recovered well in most cases. This is a consequence of the different shape of the $^{24}\text{MgH}$ feature in 3D and 1D, which will have a significantly stronger impact on the neighboring $^{25}\text{MgH}$ feature than on the $^{26}\text{MgH}$ feature. This effect is also seen for the two 5000 K models at $[\text{Fe/H}] = 1.0$, but in the opposite direction, where $^{24}\text{Mg}$ is underestimated and $^{25}\text{Mg}$ is overestimated, consistent with our finding that for these two models, the 3D syntheses were broader than their 1D equivalents.

It is also clear that the disagreement between dwarfs in 3D and 1D is correlated with the stellar $T_{\text{eff}}$ for the $\log g = 4.5$ models, for a fixed metallicity, when the metallicity is below −1.0. Albeit small, the differences more than double when increasing the model $T_{\text{eff}}$ from 4000 K to 5000 K for $[\text{Fe/H}] = -2.0$.

The correlation between metallicity and 3D–1D differences for the dwarfs may also be related to the high value of $\xi_{\text{micro}}$ found for the low-metallicity models. If this is overbroadening

the 1D syntheses, the best fit will tend to yield a lower fraction of the heavier isotopes. However, inspecting Figure 7, it is clear that even for a model where we derived both a $\xi_{\text{micro}}$ and $v_{\text{macro}}$ of zero km s$^{-1}$ from fitting the Ca lines, the 1D syntheses are still slightly broader than the 3D equivalent. Keeping in mind the impact of the thermal broadening discussed above, we consider it unlikely that the high value of $\xi_{\text{micro}}$ for the lowest metallicity is the explanation for the disagreement. Rather, the differences in *T* structure between 3D and 1D models create the observed effect.

The giants, on the other hand, show a somewhat different behavior. Here, the disagreement between 3D and 1D is small for all metallicities, with a tendency to slightly overestimate the amount of $^{25}\text{Mg}$ and $^{26}\text{Mg}$ in 1D, which naturally leads to an underestimation of $^{24}\text{Mg}$. Since we only have giant models at a single temperature and $\log g$, we cannot comment on the possible systematic behavior of the isotopes with these two parameters.

We note that the same behavior was also observed in the case where the fractions of heavy isotopes of Mg were halved, compared to the case discussed here, i.e., a 94:3:3 mixture. For the case of the pure $^{24}\text{Mg}$ mixture, the majority of the best fitting dwarf 1D syntheses agree with the input isotopic values. The only exception being the two 5000 K models at $[\text{Fe/H}] = -1.0$, where a slight overestimation of $^{25}\text{Mg}$ was found (at most 2.4 percentage points for the 5140 Å feature).
We note that the good agreement with the <sup>24</sup>Mg-only mixture should be taken with some caution, since the 1D syntheses are broader than their 3D counterparts. Our fitting routines do not allow for negative isotopic fractions, which undoubtedly would provide a better agreement in a χ<sup>2</sup> sense. For the giants, on the other hand, the best fit to the pure <sup>24</sup>Mg syntheses resulted in a marginal overestimation (<1 percentage point) of the heavy isotopes, consistent with our findings from the two isotopic mixtures discussed above.

**5. Discussion**

From the investigation performed here, it is evident that effects from using 3D hydrodynamical atmospheres in place of traditional 1D atmospheric models impacts the lines from MgH in a non-negligible fashion. This is particularly true for dwarf stars, where the differences in the *T*(*τ*) structure between 1D and 3D are more dramatic than for the giants. The core strength of the MgH lines especially changes significantly between 1D and 3D, a fact that was already noted by Ramirez (2008), with the 3D synthesis providing a significantly better fit to the observed stellar spectra. The magnitude of the ΔMg<sub>3D-1D</sub> corrections increases with increasing model *T*<sub>eff</sub>, but metallicity changes also have an impact. The sensitivity to metallicity changes can be attributed to changes in the overall *T*(*τ*) structure, where the 1D models will tend to be significantly hotter than their 3D counterparts in the line-forming region. The cooler 3D atmospheres will enhance the molecular formation, allowing the lines to form over a more extended part of the model atmosphere. In 1D, on the other hand, the hotter atmospheres means that the lines form in deeper layers, where the pressure is high enough for MgH to form in significant amounts. The increased temperature results in increased thermal broadening, as well as stronger molecular dissociation. The combination of these effects results in a need for Mg enhancement in the 1D syntheses when simultaneously fitting the line shape and line strength of the 3D synthesis.

In fitting the MgH lines in observed spectra, the Mg
abundance is normally included as a fitting parameter in order
to match the line strength of the MgH features (e.g. Yong
et al. 2003b and Meléndez & Cohen 2007). In most cases,
this results in a disagreement between the Mg abundance
found from the atomic lines in the stellar spectra and that
needed to fit the MgH features. The results from Section 4.2
suggest that 1D dwarf syntheses will tend to overestimate the
Mg abundance at low metallicity, compared to the 3D case.
Yong et al. (2004) already reported correlations between
stellar parameters and [Mg/Fe] from the MgH features for
the Hyades. The behavior of the Mg abundance derived from
the molecular features at low-metallicity dwarfs is currently
under investigation.

Since an accurate determination of the Mg isotopes in stars
must necessarily demand a good reproduction of the entire line
profile, and not merely the wings, any analysis using 3D
atmospheres will impact the observed isotopic ratios. The
results from Section 4.2 suggest that in the case of low-
metallicity dwarfs, previous analyses relying on 1D models are
likely to have underestimated the fraction of <sup>25</sup>Mg observed in
stellar spectra by a few percentage points, while the fraction of
<sup>26</sup>Mg appears to be largely unchanged. From an observational
point of view, this is fortunate, as the <sup>26</sup>Mg isotope is the
easiest to measure and is considered more reliable than the

<sup>25</sup>Mg measurements, due to the larger wavelength separation from the strong <sup>24</sup>MgH lines that dominate the MgH features in all cases.

The potential increase in <sup>25</sup>Mg at the lowest metallicities may bring observations at odds with current chemical evolution models for the Milky Way halo (e.g. Kobayashi et al. 2011), which predicts a very low <sup>25</sup>Mg/<sup>24</sup>Mg ratio at metallicities below −1.5. This in turn may require modifications of the chemical evolution models for the halo, but before the impact can be determined, a large sample of halo stars needs to be analyzed using syntheses based on 3D model atmospheres. Such a project is currently underway for a substantial sample of metal-poor halo stars.

**6. Conclusion**

In this paper, we have presented the first ever detailed
analysis of the formation and shape of optical MgH lines, using
3D hydrodynamical CO<sup>5</sup>BOLD stellar atmospheres in the
context of isotopic ratios. Based on the comparison between 3D
and 1D syntheses, we found that the Mg abundance required to
fit the 3D features in most cases needed to be enhanced beyond
the nominal input value of [α/Fe] = +0.40. This was
especially true for dwarf stars, where an additional enhance-
ment of up to +0.69 dex was required for the 5000 K, 4.0 log g
model at [Fe/H] = −2.0, clearly outside any reasonable value.
The disagreement between 1D and 3D Mg abundances was
found to increase with increasing temperature, but the
metallicity also plays a role, likely as an effect of changes to
the overall *T*(*τ*) structure being significantly different in 1D
and 3D.

The influence of 3D atmospheres on the isotopic fractions is less dramatic than the overall line strength. For giants, the 1D models reproduce the full line shape well, and the isotopic fractions are well recovered, with the largest differences being approximately one percentage point, for the heavy isotopes, which is comparable to the best-case fitting precision when dealing with high-quality observed spectra. For dwarfs, the disagreement is more substantial. We were able to simultaneously fit the core strength and the wings of the MgH lines at 5135 Å and 5140 Å, but the 1D syntheses could not reproduce the 5138 Å feature well in 1D. In addition, in most cases the 1D syntheses were broader than the equivalent 3D syntheses. As a result, the 1D fits will tend to underestimate the true value of the heavy isotopes, particularly for <sup>25</sup>Mg, by up to five percentage points in the most severe case. In effect, <sup>24</sup>Mg is traded for <sup>25</sup>Mg when moving from 1D to 3D. The fraction of <sup>26</sup>Mg on the other hand appears to be relatively robust and the true value is essentially recovered for the cases treated here. The magnitude of the differences is increasing with decreasing metallicity.

We strongly encourage the use of 3D model atmospheres for
detailed isotope studies in metal-poor dwarfs, as we find
differences that are comparable to, or larger than, the typical
fitting precision when dealing with real stellar spectra. An
increase in the <sup>25</sup>Mg fraction in metal-poor stars would result in
an increase in both the <sup>25</sup>Mg/<sup>24</sup>Mg and <sup>26</sup>Mg/<sup>24</sup>Mg ratios,
which will impact the interpretation of, for instance, the
chemical enrichment timescale of the Milky Way halo and the
metallicity at which AGB stars become an important
contributor to the halo chemistry.
<figure><img src="image_13.png" /><figcaption>**Figure 12.** *T*(τ) structure of the 4000 K CO<sup>5</sup>BOLD models used in this work. Model parameters are given in each panel. The formation regions of MgH in 3D and 1D are indicated as horizontal bars.</figcaption></figure>

<figure><img src="image_14.png" /><figcaption>**Figure 13.** *T*(τ) structure of the 5000 K CO<sup>5</sup>BOLD models used in this work. Model parameters are given in each panel. The formation regions of MgH in 3D and 1D are indicated as horizontal bars.</figcaption></figure>

H.G.L. acknowledges financial support by the Sonderforschungsbereich SFB 881 “The Milky Way System” (subproject A4) of the German Research Foundation (DFG). A.J.G. acknowledges the support of the FONDATION MERAC, the matching fund granted by the Scientific Council of Observatoire de Paris, and the Collaborative Research Centre SFB 881 (Heidelberg University) of the Deutsche Forschungsgemeinschaft (DFG, German Research Foundation).

*Software:* CO<sup>5</sup>BOLD (Freytag et al. 2012), Linfor3D (Steffen et al. 2015), Matplotlib (Hunter 2007), Fitprofile (Thygesen et al. 2016).

## Appendix A
### Temperature Structure of 3D Models

Figures 12 and 13 show the structure of the 4000 K and 5000 K CO<sup>5</sup>BOLD models used in this work, respectively.

## Appendix B
### Number Densities of MgH

Figure 14 shows the molecular number density, $n_j$, of MgH for the 4000 K and 4500 K CO<sup>5</sup>BOLD models not presented in Figure 5. Figure 15 shows the molecular number density, $n_j$, of MgH for the 5000 K CO<sup>5</sup>BOLD models.
<figure><img src="image_15.png" /><figcaption>**Figure 14.** Molecular number density, $n_p$, of MgH for the 4000 K and 4500 K CO$^5$BOLD models not presented in Figure 5. Model parameters are given in each panel. Darker shaded area indicates a higher sampling of points with this number density.</figcaption></figure>

<figure><img src="image_16.png" /><figcaption>**Figure 15.** Molecular number density, $n_p$, of MgH for the 5000 K CO$^5$BOLD models used in this work. Model parameters are given in each panel. The darker shaded area indicates a higher sampling of points with this number density.</figcaption></figure>
References

Allende Prieto, C., Koesterke, L., Ludwig, H.-G., Freytag, B., & Caffau, E. 2013, A&A, 550, A103

Asplund, M. 2005, ARA&A, 43, 481

Asplund, M., & García Pérez, A. E. 2001, A&A, 372, 601

Asplund, M., Lambert, D. L., Nissen, P. E., Primas, F., & Smith, V. V. 2006, ApJ, 644, 229

Asplund, M., & Lind, K. 2010, in IAU Symp. 268, Light Elements in the Universe, ed. C. Charbonnel et al. (Cambridge: Cambridge Univ. Press), 191

Asplund, M., Nordlund, Å., Trampedach, R., Allende Prieto, C., & Stein, R. F. 2000, A&A, 359, 729

Asplund, M., Nordlund, Å., Trampedach, R., & Stein, R. F. 1999, A&A, 346, L17

Bessell, M. S., Collet, R., Keller, S. C., et al. 2015, ApJL, 806, L16

Bonifacio, P., Caffau, E., Ludwig, H.-G., et al. 2013, MSAIS, 24, 138

Brooke, J. S. A., Bernath, P. F., Schmidt, T. W., & Bacskay, G. B. 2013, JQSRT, 124, 11

Brooke, J. S. A., Ram, R. S., Western, C. M., et al. 2014, ApJS, 210, 23

Caffau, E., & Ludwig, H.-G. 2007, A&A, 467, L11

Cayrel, R., Steffen, M., Chand, H., et al. 2007, A&A, 473, L37

Collet, R., Asplund, M., & Trampedach, R. 2006, ApJL, 644, L121

Collet, R., Asplund, M., & Trampedach, R. 2007, A&A, 469, 687

Da Costa, G. S., Norris, J. E., & Yong, D. 2013, ApJ, 769, 8

Dalton, G., Trager, S. C., Abrams, D. C., et al. 2012, Proc. SPIE, 8446, 84460P de Jong, R. S., Barden, S. C., Bellido-Tirado, O., et al. 2016, Proc. SPIE, 9908, 99081O

De Silva, G. M., Freeman, K. C., Bland-Hawthorn, J., et al. 2015, MNRAS, 449, 2604

Delbouille, L., & Roland, G. 1995, Opt. Eng., 34, 2736

Dravins, D. 1982, ARA&A, 20, 61

Dravins, D., & Nordlund, A. 1990, A&A, 228, 184

Freytag, B., Steffen, M., Ludwig, H.-G., et al. 2012, JCoPh, 231, 919

Gallagher, A. J., Caffau, E., Bonifacio, P., et al. 2016a, A&A, 593, A48

Gallagher, A. J., Ludwig, H.-G., Ryan, S. G., & Aoki, W. 2015, A&A, 579, A94

Gallagher, A. J., Ryan, S. G., García Pérez, A. E., & Aoki, W. 2010, A&A, 523, A24

Gallagher, A. J., Steffen, M., Caffau, E., et al. 2016b, arXiv:1610.04427

Gilmore, G., Randich, S., Asplund, M., et al. 2012, Msngr, 147, 25

Heiter, U., Lind, K., Asplund, M., et al. 2015, PhyS, 90, 054010

Hinkle, K. H., Wallace, L., Ram, R. S., et al. 2013, ApJS, 207, 26

Hunter, J. D. 2007, CSE, 9, 90

Klevas, J., Ludwig, A. K. H.-G., Bonifacio, P., & Steffen, M. 2013, MSAIS, 24, 78

Kobayashi, C., Karakas, A. I., & Umeda, H. 2011, MNRAS, 414, 3231

Kramida, A., Ralchenko, Yu., Reader, J. & NIST ASD Team 2015, NIST Atomic Spectra Database (ver. 5.3) (Gaithersburg, MD: National Institute of Standards and Technology) http://physics.nist.gov/asd

Kupka, F. G., Ryabchikova, T. A., Piskunov, N. E., Stempels, H. C., & Weiss, W. W. 2000, BaltA, 9, 590

Lind, K., Melendez, J., Asplund, M., Collet, R., & Magic, Z. 2013, A&A, 554, A96

Ludwig, H.-G., Caffau, E., Steffen, M., et al. 2009, MmSAI, 80, 711

Ludwig, H.-G., González Hernández, J. I., Behara, N., Caffau, E., & Steffen, M. 2008, in AIP Conf. Ser. 990, First Stars III, ed. B. W. O'Shea & A. Heger (Melville, NY: AIP), 268

Ludwig, H.-G., & Kučinskas, A. 2012, A&A, 547, A118

Magain, P. 1986, A&A, 163, 135

Magic, Z., Collet, R., Hayek, W., & Asplund, M. 2013, A&A, 560, A8

Majewski, S. R., Schiavon, R. P., Frinchaboy, P. M., et al. 2015, arXiv:1509.05420

Mashonkina, L., & Zhao, G. 2006, A&A, 456, 313

Masseron, T., Plez, B., Van Eck, S., et al. 2014, A&A, 571, A47

McWilliam, A., & Lambert, D. L. 1988, MNRAS, 230, 573

Meléndez, J., & Cohen, J. G. 2007, ApJL, 659, L25

Meléndez, J., & Cohen, J. G. 2009, ApJ, 699, 2017

Nordlund, A. 1982, A&A, 107, 1

Nordlund, A., & Dravins, D. 1990, A&A, 228, 155

Ramirez, I. 2008, PhD thesis, Univ. Texas

Sauval, A. J., & Tatum, J. B. 1984, ApJS, 56, 193

Shayesteh, A., & Bernath, P. F. 2011, JChPh, 135, 094308

Sobeck, J., Majewski, S., Hearty, F., et al. 2014, in American Astronomical Society Meeting 223, Abstract, 440.06

Steffen, M., Caffau, E., & Ludwig, H.-G. 2013, MSAIS, 24, 37

Steffen, M., Cayrel, R., Caffau, E., et al. 2012, MSAIS, 22, 152

Steffen, M., Ludwig, H.-G., Wedemeyer-Böhm, S., & Gallagher, A. J. 2015, Linfor3D User Manual, http://www.aip.de/Members/msteffen/linfor3d

Steinmetz, M., Zwitter, T., Siebert, A., et al. 2006, AJ, 132, 1645

Takada, M., Ellis, R. S., Chiba, M., et al. 2014, PASJ, 66, R1

Thygesen, A. O., Sbordone, L., Ludwig, H.-G., et al. 2016, A&A, 588, A66

Yanny, B., Rockosi, C., Newberg, H. J., et al. 2009, AJ, 137, 4377

Yong, D., Grundahl, F., Lambert, D. L., Nissen, P. E., & Shetrone, M. D. 2003a, A&A, 402, 985

Yong, D., Lambert, D. L., Allende Prieto, C., & Paulson, D. B. 2004, ApJ, 603, 697

Yong, D., Lambert, D. L., & Ivans, I. I. 2003b, ApJ, 599, 1357