# A new algorithm for optimizing the wavelength coverage for spectroscopic studies: Spectral Wavelength Optimization Code (swoc)

G. Ruchti, S. Feltzing, K. Lind, E. Caffau, A. Korn, O. Schnurr, C. Hansen, A. Koch, L. Sbordone, R. De jong

► To cite this version:

G. Ruchti, S. Feltzing, K. Lind, E. Caffau, A. Korn, et al. A new algorithm for optimizing the wavelength coverage for spectroscopic studies: Spectral Wavelength Optimization Code (swoc). Monthly Notices of the Royal Astronomical Society, 2016, 461 (2), pp.2174-2191. 10.1093/mnras/stw1351. hal-02316096

HAL Id: hal-02316096

https://hal.science/hal-02316096

Submitted on 9 Sep 2021

HAL is a multi-disciplinary open access
archive for the deposit and dissemination of sci-
entific research documents, whether they are pub-
lished or not. The documents may come from
teaching and research institutions in France or
abroad, or from public or private research centers.

L'archive ouverte pluridisciplinaire HAL, est
destinée au dépôt et à la diffusion de documents
scientifiques de niveau recherche, publiés ou non,
émanant des établissements d'enseignement et de
recherche français ou étrangers, des laboratoires
publics ou privés.

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

Distributed under a Creative Commons Attribution 4.0 International License
<figure><img src="image_2.png" /></figure>

# A new algorithm for optimizing the wavelength coverage for spectroscopic studies: Spectral Wavelength Optimization Code (SWOC)

G. R. Ruchti,<fnref n="1" />* S. Feltzing,<fnref n="1" />* K. Lind,<fnref n="2" />,<fnref n="3" /> E. Caffau,<fnref n="4" /> A. J. Korn,<fnref n="3" /> O. Schnurr,<fnref n="5" /> C. J. Hansen,<fnref n="6" /> A. Koch,<fnref n="7" /> L. Sbordone<fnref n="8" />,<fnref n="9" /> and R. S. de Jong<fnref n="5" />

Accepted 2016 June 1. Received 2016 June 1; in original form 2016 May 10

## ABSTRACT

The past decade and a half has seen the design and execution of several ground-based spectroscopic surveys, both Galactic and Extragalactic. Additionally, new surveys are being designed that extend the boundaries of current surveys. In this context, many important considerations must be done when designing a spectrograph for the future. Among these is the determination of the optimum wavelength coverage. In this work, we present a new code for determining the wavelength ranges that provide the optimal amount of information to achieve the required science goals for a given survey. In its first mode, it utilizes a user-defined list of spectral features to compute a figure-of-merit for different spectral configurations. The second mode utilizes a set of flux-calibrated spectra, determining the spectral regions that show the largest differences among the spectra. Our algorithm is easily adaptable for any set of science requirements and any spectrograph design. We apply the algorithm to several examples, including 4MOST, showing the method yields important design constraints to the wavelength regions.

**Key words:** instrumentation: spectrographs – techniques: spectroscopic – surveys – stars: abundances – stars: fundamental parameters.

## 1 INTRODUCTION

Observational astronomy has entered an era of large-scale surveys, probing ever deeper into the Milky Way and the Universe. Several imaging surveys are already ongoing or completed, such as SDSS (Eisenstein et al. 2011), 2MASS (Skrutskie et al. 2006), WISE (Wright et al. 2010), and Skymapper (Keller et al. 2007), with future surveys soon starting (e.g. LSST; Ivezic et al. 2008). Further, at the end of 2013, the astronomical community celebrated the European Space Agency’s launch of the Gaia astrometric space mission. Gaia will deliver unparalleled high-precision positions and transverse velocities for a billion stars in the Milky Way (Perryman et al. 2001; Lindegren et al. 2008; Lindegren 2010). The imaging surveys and Gaia have led to the design and execution of ground-based, large-scale spectroscopic surveys (e.g. RAVE; Steinmetz et al. 2006, SEGUE; Yanny et al. 2009, LAMOST; Cui

et al. 2012, GALAH/HERMES; Barden et al. 2010, APOGEE; Eisenstein et al. 2011, the Gaia-ESO Survey; Gilmore et al. 2012). The spectroscopic surveys deliver complementary data that, when combined with the astrometric data from Gaia, allow us to comprehensively map all of the major stellar components of the Milky Way.

Future European large-scale surveys, such as the 4-metre Multi-Object Spectroscopic Telescope (4MOST; de Jong et al. 2014), WEAVE (Balcells et al. 2010), and surveys conducted with the third-generation VLT instrument MOONS (Cirasuolo et al. 2011) are also being planned, and are designed to provide the desired ground-based spectroscopic follow-up for Gaia. These new data will provide an extraordinary resource and will enable transformative science by providing many of the critical observational inputs needed to dissect the formation history of the Milky Way and other galaxies in great detail. However, these new surveys will come with limitations (e.g. in wavelength coverage and resolution) mainly due to constraints needed to be able to observe large numbers of targets. Thus, it is important to perform a detailed investigation of the required performance of future spectrographs and also test the power of

<footnote n="1">¹Lund Observatory, Department of Astronomy and Theoretical Physics, Box 43, SE-22100 Lund, Sweden</footnote>

<footnote n="2">²Max-Planck Institut für Astronomie, Königstuhl 17, D-69117 Heidelberg, Germany</footnote>

<footnote n="3">³Department of Physics and Astronomy, Uppsala University, Box 516, SE-75120 Uppsala, Sweden</footnote>

<footnote n="4">⁴GEPI, Observatoire de Paris, CNRS, Université Paris Diderot, 5 Place Jules Janssen, F-92190 Meudon, France</footnote>

<footnote n="5">⁵Astrophysikalisches Institut Potsdam, An der Sternwarte 16, D-14482 Potsdam, Germany</footnote>

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

<footnote n="7">⁷Physics Department, Lancaster University, Lancaster LA1 4YB, UK</footnote>

<footnote n="8">⁸Millennium Institute of Astrophysics, Av. Vicuña Mackenna 4860, 782-0436 Macul, Santiago, Chile</footnote>

<footnote n="9">⁹Pontificia Universidad Católica de Chile, Av. Vicuña Mackenna 4860, 782-0436 Macul, Santiago, Chile</footnote>

<footnote>*E-mail: gruchti@gmail.com (GRR); sofia@astro.lu.se (SF)</footnote>
existing instruments. Similar considerations can also be applied in other science areas where a spectrograph must be optimized.

There are many considerations that must be taken into account when designing a spectrograph for a given spectroscopic survey, e.g. design limitations such as the spectral resolution and sampling, the wavelength coverage, variation in fibre throughput for different wavelength regions, as well as the location in wavelength of the flux maximum for the typical target that will be observed by a given survey. In this paper, we concentrate on determining the spectral coverage (for a given range in resolution) best suited for a given science case within a spectroscopic survey.

Descriptions and arguments for how to determine the optimal placement of the wavelength bands are quite limited in the literature. A recent example is Caffau et al. (2013), who discussed the optimal wavelength coverage, resolution, and sampling of an earlier two-arm design for 4MOST. More recently, Hansen et al. (2015) performed a similar investigation for the preliminary design of the blue wavelength region ($\lambda < 4500$ Å) of the high-resolution spectrograph on 4MOST.

In this paper, we present a simple and effective algorithm (Spectral Wavelength Optimization Code – *swoc*), which utilizes information contained within the spectra of different objects and/or the science requirements for a given survey to weigh among different combinations of short wavelength bands. This program was originally conceived to optimize the wavelength coverage of the 4MOST spectrograph. However, it was written so that any spectrograph design can be evaluated. It can also be used to decide on which settings to use for an existing instrument for a specific project. Thus, the program can be applied to any spectroscopic study, both stellar and extragalactic, on any spectrograph, at any resolution.

The paper is organized as follows. In Section 2, we present an overview of the program. In Section 3, we describe the two different modes that can be used to evaluate the wavelength coverage. We then present in Section 4 several example analyses for the *feature mode*, while and additional example of the *spectral mode* is given in Section 5. Finally, in Section 6, we present our conclusions.

## 2 THE SWOC PROGRAM

The main goal of our methodology is to compute a figure-of-merit (FoM) for every possible combination of wavelength bands, which is based on the science goals intended to be achieved with a given spectrograph. This FoM can then be used to:

(i) determine the optimal combination of wavelength bands, which give the maximum possible information from the spectrum.

(ii) assess the amount of information lost if a different combination of bands is used.

(iii) assess the ability of an existing spectrograph or spectrograph design to achieve the desired science goals.

To this end, we have developed a new *swoc*, which evaluates all possible combinations of wavelength bands to determine those that maximize the FoM.

*swoc* was written as a package for the statistical software environment R.<fnref n="1" /> R is available as free software, thus allowing anyone to use *swoc* without any software licenses. The *swoc* package can be obtained through a website<fnref n="2" /> or upon request.

## 3 THE TWO MODES OF SWOC

*swoc* operates in two separate modes, *feature* and *spectral* modes. Input details for each mode are described in Appendix A, while common input definitions are listed in Table A1. Additional help files can also be accessed within the package in R.

Here, we describe the methodology behind each mode.

### 3.1 Feature mode

The main philosophy behind this mode is to make use of specific spectral features defined by the user to assess combinations of wavelength bands with a given scientific problem in mind. The spectral features can, e.g. be atomic or molecular absorption/emission lines. In order to find the best set of wavelength bands that optimizes the science, we define an FoM based on the number of spectral features present within each set of wavelength configurations. Different spectral features are typically not distributed evenly across a spectrum and can have varying degrees of quality. The strengths of the spectral features can also depend on the variety of objects being studied.

The *feature mode* of *swoc* was set up to take all of this into account when evaluating the FoM for different combinations of wavelength bands. This mode needs the following input:

(i) a set of line list files for those objects under consideration

(ii) a list of regions in the spectrum that must be included

(iii) a list of groups of spectral features that must be included

(iv) a list of groups of ‘conditional’ spectral features that would be useful/interesting to include.

The spectral line list file contains all needed information about the spectral lines and features of interest, including their location, designated name, strengths, and weights depending on their quality. It is important to generate a line list file for each type of object to be studied. The program will then iterate through each list, determining the optimal wavelength coverage for each object, and finally, combining all information to ascertain the optimal wavelength coverage for all objects together.

The point of the required wavelength regions and the groups of required spectral features is to set the bottom-line requirements for a given scientific study. The required wavelength regions consist of any spectral regions that must be included within the combination of wavelength bands in order to carry out the science of a given spectroscopic study. For example, such regions could include broad absorption features, such as the Hα Balmer line (that can be used to measure the effective temperature in cool stars) or diffuse interstellar bands (that trace dust in the interstellar medium – ISM), that cover several öms.

The groups of required spectral features are those for which at least one instance of each group must be contained within the final combination of wavelength bands. The program organizes the spectral features provided in the line list file according to each feature’s designated name (see Appendix A1). Groups of spectral features can thus include one or more type of ion or molecule, or some other categorization devised by the user. For example, a systematic study of lithium in stars would require lithium lines to be covered by the final combination of wavelength bands. Thus, the element lithium would be included as one group of required spectral features. Any combination of wavelength bands that do not satisfy all requirements are immediately discarded as ‘failures’ in the FoM analysis.

<footnote n="1">¹ https://www.r-project.org</footnote>

<footnote n="2">² http://www.astro.lu.se/~greg/swoc.html</footnote>
Finally, the list of conditional spectral features consists of those groups that will improve the science outcomes, but the loss of which would not inhibit the science goals of a given spectroscopic study. For some science cases, there might be zero conditional features. The final FoM is quantified as the number of spectral features in all groups of conditional features present within a given combination of wavelength bands divided by the total number of features across the entire spectral region under study.

swoc computes the FoM using the following steps.

(i) The program first computes a weighted sum of the number of spectral features associated with each groups of conditional features for the spectral range defined by the user:

$$N_{\text{tot},j} = \sum_{i}^{n} \frac{1}{w_{i,j}^2}, \qquad (1)$$

where $N_{\text{tot},j}$ is the weighted sum of the spectral features in the jth group of conditional spectral features, and $w_{i,j}$ represents a quality weight for the ith spectral feature in the jth group of conditional spectral features.

(ii) For each wavelength segment, a vector of bands is created. Each band has a starting wavelength (band head) inside the spectral range defined by the user. The step-size between subsequent band heads should be chosen according to the required precision needed.

(iii) The program then proceeds to define a matrix of all combinations of bands. Combinations with bands that overlap in wavelength coverage are discarded in order to avoid counting the same spectral feature multiple times. The program also allows for gaps between the bands. This leaves k distinct combinations of bands.

(iv) The program then determines which of the required spectral regions and groups of required spectral features have been satisfied for each combination of bands. Any combination of bands that does not meet the requirements are automatically discarded.

(v) For those combinations of bands that meet the requirements, the program computes a weighted sum of the number of spectral features associated with each group of conditional features, according to:

$$N_{j,k} = \sum_{i}^{n} \frac{1}{w_{i,j,k}^2}, \qquad (2)$$

where $N_{j,k}$ is the weighted sum of the spectral features in the jth group of conditional spectral features for the kth combination of bands, and $w_{i,j,k}$ represents the quality weight for the ith spectral feature in the jth group of conditional spectral features. Individual figures-of-merit (fom$_{j,k}$) for each group of conditional spectral features are computed by normalizing each $N_{j,k}$ by the maximum value over the entire spectral range considered, $N_{\text{tot},j}$ (see equation 1):

$$\text{fom}_{j,k} = \frac{N_{j,k}}{N_{\text{tot},j}}. \qquad (3)$$

(vi) A final FoM$_k$ for each combination of bands is computed by summing over all j groups of conditional spectral features and normalizing by the total number of groups, given as:

$$\text{FoM}_k = \frac{\sum_{i}^{j} \text{fom}_{j,k}}{N (\text{groups of conditional features})}. \qquad (4)$$

(vii) Those combinations of bands in which FoM$_k$ is maximized are selected as the most optimal combinations.

The above steps can be completed for a list of objects, each with their own line list file. Finally, the program determines an overall optimal combination of bands. This is done by first summing each

FoM$_k$ across all objects and normalizing by the total number of object line list files to compute an FoM-total. The combinations of bands for which FoM-total is maximized are considered to provide the optimal spectral coverage for all objects tested.

## 3.2 Spectral mode

In some studies, we may not want to use (or may not have) a set of spectral features with which to analyse a set of objects. Instead, we could classify objects according to their overall spectrum. In this case, we might want to determine in which parts of a spectrum we see the largest variation amongst a group of objects. This is the idea behind the spectral mode in swoc. This mode determines the wavelength regions, which show the largest differences among several flux calibrated spectra of objects of interest. In contrast to the feature mode, this mode requires very little input from the user. Thus, the spectral mode is considered more objective in nature than the feature mode.

The spectral mode can be very useful when (1) spectral template fitting is required to categorize objects or to determine some overall parameter of an object, or (2) a specific object must be selected among several different types of objects. In both cases, it is important to determine the spectral regions that show the greatest variation amongst the spectra for the typical objects that will be observed and identified. This is exactly what the spectral mode achieves.

In this mode, swoc performs the desired difference analysis using the following steps.

(i) All spectra are first reduced to the spectral range to be tested, as defined by the user.

(ii) The square of the difference between the fluxes of each pair of spectra are computed for all wavelength points in the spectra. For example, if three spectra are listed, then three resultant square difference arrays are computed:

$$\begin{align*} D_{1,2} &= \left\{ \frac{(f_{1,i} - f_{2,i})^2}{\sigma_{1,i}^2 + \sigma_{2,i}^2}, \dots \right\} \\ D_{1,3} &= \left\{ \frac{(f_{1,i} - f_{3,i})^2}{\sigma_{1,i}^2 + \sigma_{3,i}^2}, \dots \right\} \\ D_{2,3} &= \left\{ \frac{(f_{2,i} - f_{3,i})^2}{\sigma_{2,i}^2 + \sigma_{3,i}^2}, \dots \right\}, \end{align*} \qquad (5)$$

where $f_i$ is the flux and $\sigma_i$ is the uncertainty at the ith wavelength point. If, rather, the user wants to compare to a reference spectrum, then the square difference arrays will instead be given by

$$\begin{align*} D_{\text{ref},1} &= \left\{ \frac{(f_{1,i} - f_{\text{ref},i})^2}{\sigma_{\text{ref},i}^2 + \sigma_{1,i}^2}, \dots \right\} \\ D_{\text{ref},2} &= \left\{ \frac{(f_{2,i} - f_{\text{ref},i})^2}{\sigma_{\text{ref},i}^2 + \sigma_{2,i}^2}, \dots \right\} \\ D_{\text{ref},3} &= \left\{ \frac{(f_{3,i} - f_{\text{ref},i})^2}{\sigma_{\text{ref},i}^2 + \sigma_{3,i}^2}, \dots \right\}. \end{align*} \qquad (6)$$

The total square difference array is then computed by vector summing the individual square difference arrays:

$$\begin{align*} D_{\text{TOT}} &= D_{1,2} + D_{1,3} + D_{2,3}; \\ D_{\text{TOT}} &= D_{\text{ref},1} + D_{\text{ref},2} + D_{\text{ref},3}. \end{align*} \qquad (7)$$
(iii) The program next computes the total difference across the entire spectral range:

$$D_{\text{spec}} = \sum_{i} D_{\text{TOT},i}, \qquad (8)$$

where $D_{\text{TOT},i}$ is the value of $D_{\text{TOT}}$ at the $i$th wavelength point.

(iv) Similarly to the feature mode, a vector of bands is created for each wavelength segment, and a matrix of all combinations of bands is defined (also accounting for any defined gaps between the bands). This leaves $k$ distinct combinations of bands.

(v) The program then computes a total FoM by summing those elements of $D_{\text{TOT}}$, which correspond to wavelengths contained within the combination of bands, given as

$$\text{FoM}_k = \frac{\sum_i D_{\text{TOT},i}^k}{D_{\text{spec}}}, \qquad (9)$$

where $D_{\text{TOT},i}^k$ is the value of $D_{\text{TOT}}$ at the $i$th wavelength point inside the wavelength ranges of the $k$th combination of bands, and $D_{\text{spec}}$ is the total difference within the entire spectral range tested (see equation 8).

(vi) Those combinations of bands in which $\text{FoM}_k$ is maximized are selected as the most optimal combinations.

The resultant combination of bands that maximize $\text{FoM}_k$, as well as $D_{\text{TOT}}$ versus wavelength, are output by *swoc*. Further, the user can request that these be plotted together as an additional output figure.

## 4 FEATURE MODE EXAMPLE: FGK STARS IN THE GALACTIC DISC AND BULGE

In the following sections, we give several examples to illustrate how *swoc* works and how to use its two modes. For more details on the input to *swoc*, given in the following examples, see Appendix A and Table A1.

Our first example consists of a survey to study stars in the bulge and disc of the Milky Way. We assume that our spectrograph will have a resolving power of $R \sim 20\,000$, which is similar to that of the FLAMES/GIRAFFE spectrograph for the Gaia-ESO Survey, as well as the planned high-resolution spectrographs for WEAVE and 4MOST. Since the disc and bulge consist of predominantly metal-rich ($[\text{Fe/H}] > -1$) stars, we will limit our analysis to spectral features between 4500 and 7000 Å. Below 4500 Å, line blending tends to be an issue in metal-rich stars (Hansen et al. 2015).

We first compiled a line list, which contains spectroscopic lines to determine elemental abundances and features that provide diagnostics for the stellar parameters. A description of the major nucleosynthesis channels included and our chosen line list is given in Appendix B. This list is not necessarily exhaustive, and depending on the science goals for a different survey, one may add or exclude features, and extend the line list to bluer and redder wavelengths.

### 4.1 Determining line strengths

The strengths of different spectral features depend on the variety of stars being studied. Thus, it is necessary to include an estimate of the strength of all spectral features. For example, in the case of a stellar spectroscopic study, synthetic spectra could be computed for the types of stars that will be analysed. Using these spectra, theoretical equivalent widths (EWs) can be measured to determine the strengths of the lines in the spectral feature line list. Another option is to use the VALD data base (Kupka et al. 1999, 2000) to

<table><caption>**Table 1.** Synthetic spectra used for measuring EWs.</caption><thead><tr><th>Star type</th><th><i>T</i><sub>eff</sub><br>(K)</th><th>log <i>g</i></th><th>[Fe/H]</th><th><i>v</i><sub>mic</sub><sup>a</sup><br>(km s<sup>-1</sup>)</th></tr></thead><tbody><tr><td>MS</td><td>5250</td><td>4.5</td><td>(-2, -1, 0)</td><td>1.0</td></tr><tr><td>TO</td><td>6250</td><td>4.0</td><td>(-2, -1, 0)</td><td>1.0</td></tr><tr><td>RC</td><td>4500</td><td>3.0</td><td>(-2, -1, 0)</td><td>2.0</td></tr></tbody></table>

<sup>a</sup>Denotes microturbulence.

extract line depths for a given stellar type. Both EWs and line depths are suitable measures of line strength.

In order to measure the strength of the lines, we calculated theoretical EWs for the lines in our list. To measure the line strengths, we used synthetic spectra for typical effective temperatures ($T_{\text{eff}}$) and surface gravities (log g) for a main-sequence (MS), turn-off (TO), and red clump (RC) star, with metallicities of 0.0, -1.0, and -2.0 dex. The nine different sets of stellar parameters are listed in Table 1. We set $\text{feat.min} = 20.0 \, \text{m}\AA$. This means that for a given star/list, all lines weaker than 20 mÅ are considered unmeasurable. This somewhat emulates the capability of an $R \sim 20\,000$ spectrograph, which has been used to obtain spectra with signal-to-noise equal to 30–50 per pixel in the line free continuum.

### 4.2 Defining the requirements and groups of conditional features

We have compiled a set of requirements and groups of conditional spectral features, which are listed in Table 2. We have based our selection of the required and conditional features on a careful investigation of which groups of spectral features provide the best diagnostics for stellar parameters and that cover many of the major nucleosynthesis channels that can be used for Galactic archaeology (Freeman & Bland-Hawthorn 2002) and the understanding of the chemical enrichment of the disc and bulge of the Milky Way (see Appendix B). Depending on the science of a given survey, it is quite possible that these would differ from those listed in Table 2.

Including more than one indicator for $T_{\text{eff}}$ and log g is necessary to be able to determine stellar parameters for all stellar types (see Section B1). For our required spectral regions, we thus include the wavelength range that surrounds the Hα Balmer line, which is an indicator for $T_{\text{eff}}$. We further added ranges which cover either the Mg b triplet lines or the Ca I line at 6162 Å to estimate log g. See Appendix B1 for more details.

It is necessary to include a weaker Mg I or Ca I line from which to estimate the abundance of each respective element in order to achieve a good estimate of log g from the broad lines included in the list of required spectral regions (see Section B1). Thus, we include these in our list of groups of required spectral features. In addition, an Mn I line and an Al I or Na I line are required since they are extremely important for constraining proton capture and the metallicity-dependent nucleosynthesis of progenitor stars, respectively. Finally we require at least one neutron capture element indicator, such as a Ba II or Eu II line, to constrain heavy element production. With Mg, Mn, Al or Na, and Ba or Eu we have powerful tracers of the chemical evolution of the Milky Way (see Section B2). We further impose that only the best-quality lines (those with $w = 1$), which can potentially give the best results, are used for the majority of the requirements. However, due to paucity of lines, all lines in the line list can be considered for the Mn I requirement. The final requirements are listed in Table 2.

With the requirements in place, we devised a list of groups of conditional spectral features, which are also listed in Table 2. First,
<table><caption>**Table 2.** The required and conditional groups of spectral features for the optimization of the wavelength coverage.</caption><thead><tr><th>Group</th><th>Ion/Feature</th><th>Comment</th></tr></thead><tbody><tr><td></td><td>Required spectral regions</td><td></td></tr><tr><td>wreq1<sup>a</sup></td><td>H<sub>α</sub></td><td>6470–6650 Å</td></tr><tr><td>wreq2<sup>b</sup></td><td>Mg b</td><td>5100–5250 Å</td></tr><tr><td></td><td>CaI</td><td>6152–6172 Å</td></tr><tr><td></td><td>Groups of required spectral features</td><td></td></tr><tr><td>freq1<sup>c</sup></td><td>MgI</td><td>w = 1</td></tr><tr><td>freq2</td><td>AlI, NaI</td><td>w = 1</td></tr><tr><td>freq3<sup>c</sup></td><td>CaI</td><td>w = 1</td></tr><tr><td>freq4</td><td>MnI</td><td>w ≤ 2</td></tr><tr><td>freq5</td><td>BaII, EuII</td><td>w = 1</td></tr><tr><td></td><td>Groups of conditional spectral features</td><td></td></tr><tr><td>con1</td><td>FeI with EP ≤ 2.5</td><td>w = 1</td></tr><tr><td>con2</td><td>FeI with EP > 2.5</td><td>w = 1</td></tr><tr><td>con3</td><td>FeII</td><td>w ≤ 2</td></tr><tr><td>con4</td><td>LiI</td><td>w ≤ 2</td></tr><tr><td>con5</td><td>CI</td><td>w ≤ 2</td></tr><tr><td>con6</td><td>OI</td><td>w ≤ 2</td></tr><tr><td>con7</td><td>NaI</td><td>w ≤ 2</td></tr><tr><td>con8</td><td>MgI</td><td>w ≤ 2</td></tr><tr><td>con9</td><td>AlI</td><td>w ≤ 2</td></tr><tr><td>con10</td><td>SiI, CaI</td><td>w ≤ 2</td></tr><tr><td>con11</td><td>TiI, TiII</td><td>w ≤ 2</td></tr><tr><td>con12</td><td>CrI, CrII, NiI</td><td>w ≤ 2</td></tr><tr><td>con13</td><td>CoI, ZnI</td><td>w ≤ 2</td></tr><tr><td>con14</td><td>CuI</td><td>w ≤ 2</td></tr><tr><td>con15</td><td>BaII</td><td>w ≤ 2</td></tr><tr><td>con16</td><td>EuII</td><td>w ≤ 2</td></tr></tbody></table>

we wish to have a statistically significant number of both high and low excitation potential (EP) FeI lines, as well as FeII lines to successfully determine *T*<sub>eff</sub> and log *g* through excitation and ionization equilibrium of iron (see Appendix B1 and; e.g. Lind, Bergemann & Asplund 2012). Since there are plenty of strong FeI lines across a large range of wavelengths, we want to consider only *w* = 1 lines. In practice, there will likely be many more lines that can be used. However, having a set of highly weighted lines is desirable.

The remaining groups of conditional features provide at least one indicator from each nucleosynthesis channel described in Section B2. Some of the lines for the ions listed can be very weak or suffer from blends or hyperfine splitting. However, since the program weighs each line according to $1/w^2$ (see equation 2), the best lines will dominate the FoM calculations for these ions.

The location in wavelength of the spectral lines and features, which are used for our requirements and groups of conditional features, is shown in Fig. 1. As can be seen, the lines are not evenly distributed for most elements. Now that the requirements and groups of conditional features have been selected, wavelength regions can be assessed to determine those that give optimal coverage.

## 4.3 Exploring a two-arm design

We now explore the optimal wavelength coverage for several two-arm spectrograph designs using *swoc*. For simplicity, we here re-

quire that both arms must have equal bandwidths. Although we have chosen this simple setup, our method is easily expanded to accommodate designs with different wavelength limits, a larger set of arms (Section 4.4), as well as one which has arms of varying wavelength ranges.

For our example two-arm spectrograph design, we evaluated bands inside 4500 and 8000 Å, which have bandwidths ranging from 550 down to 450 Å in steps of 25 Å. The band head of each consecutive band was taken in steps of *bstep* = 20 Å. We set *gap* = 0, as well as *rv.shift* = 10 Å to account for radial velocities of up to ~400 km s⁻¹. The FoM values were then computed with *swoc* for various combinations of two bands where the bands are always the same width.

The maximum FoM and the band heads of the two bands with that FoM are listed in Table 3 for each bandwidth. In Fig. 2, we show the results for the 525 Å bandwidth case, plotting the optimal band combinations for each individual star (listed in Table 1), as well as the final overall optimal combination of bands. This illustrates the range of possibilities for each stellar type, but when all information is considered together, a single set of bands provides the optimal coverage.

All combinations of bands with bandwidths of 450 Å and smaller failed to meet the requirements listed in Table 2. In the 475 Å bandwidth case, the optimal combinations contain either the Mg b triplet lines or the CaI 6162 Å line as the log *g* indicator, while the optimal combinations only contained the CaI 6162 Å line in the 500–550 Å bandwidth cases. In general, the maximum FoM increases with increasing bandwidth. Note, however, that due to normalization differences, direct comparisons can be misleading.

It is interesting to point out that in all cases, the dominant LiI line at 6708 Å is either not covered or is near the edge of the final bands. The reason for this is that the line is very weak in most stars. Thus, this line does not contribute to the FoM calculation. The lithium abundance, however, can provide valuable information about the evolution of stars. Thus, if the science goals of a survey require such a line, then it would be better handled if LiI was added as a groups of required spectral features instead of a group of conditional features.

## 4.4 Exploring a four-arm design

*swoc* was written to handle any number of bands. Thus, the analysis need not be limited to two arms. As an example, we evaluated the combinations of 200 Å wide bands for an example four-arm spectrograph. We assume this spectrograph has the same capabilities as that in the two-arm example.

Fig. 3 shows the plot that is created by *swoc* when it has finished running. Here, the required wavelength regions are shown as black segments, while the points represent the features which contribute to the groups of required and conditional spectral features listed in Table 2, colour-coded according to each feature's weight. The optimal combination of bands is shown as the grey regions to illustrate what information is available with this configuration.

## 4.5 Application to 4MOST

The *swoc* algorithm was originally devised to optimize the wavelength coverage for the green and red arms for the preliminary design of the high-resolution 4MOST spectrograph (de Jong et al. 2014). These regions would be primarily used to perform Galactic archaeology in the disc and bulge of the Milky Way. The 4MOST spectrograph will also include a blue arm to be used primarily for

<footnote><sup>a</sup>*T*<sub>eff</sub> indicator.</footnote>

<footnote><sup>b</sup>log *g* indicators. Only one is required, and so both would be listed together in the input file.</footnote>

<footnote><sup>c</sup>A weak line of the same element as the log *g* indicator is required in order to estimate the abundance of that element. However, we require a weak MgI line in either case.</footnote>
<figure><img src="image_3.png" /><figcaption>**Figure 1.** Location of spectral features and lines in wavelength. Elements and features have been grouped according to those listed in Table 2. The required spectral regions surrounding the strong Hα Balmer, Mg b triplet, and Ca I lines are shown as black segments. Lines with *w* = 1 are shown as black circles, while those with *w* = 2 are given by red triangles.</figcaption></figure>

<table><caption>**Table 3.** Final FoM results for combinations of two spectral regions of equal bandwidth.</caption><thead><tr><th>Bandwidth (Å)</th><th>Band1 (Å)</th><th>Band2 (Å)</th><th>Max FoM</th></tr></thead><tbody><tr><td rowspan="2">550</td><td>5280</td><td>6120</td><td>0.39</td></tr><tr><td>5360</td><td>6120</td><td>0.39</td></tr><tr><td>525</td><td>5280</td><td>6140</td><td>0.37</td></tr><tr><td>500</td><td>5680</td><td>6220</td><td>0.32</td></tr><tr><td rowspan="6">475</td><td>5080</td><td>6240</td><td>0.29</td></tr><tr><td>5080</td><td>6260</td><td>0.29</td></tr><tr><td>5080</td><td>6280</td><td>0.29</td></tr><tr><td>5700</td><td>6200</td><td>0.29</td></tr><tr><td>5700</td><td>6220</td><td>0.29</td></tr><tr><td>5700</td><td>6240</td><td>0.29</td></tr><tr><td>450</td><td>-</td><td>-</td><td>Failed requirements</td></tr></tbody></table>

metal-poor stars in the halo of the Milky Way. The methods to optimize this blue arm are described in detail in Hansen et al. (2015).

Initially, combinations of two arms restricted to wavelengths between 4500 and 8000 Å with varying bandwidths were evaluated with *swoc*. From this analysis, we found that the bandwidths of the two arms must be at least 450 Å wide in order to pass our requirements. Using this information, the instrument designers found that bandwidths in the green and red arms can be as large as 570 and 690 Å, respectively, for potential designs. These both met our initial recommendations. However, the designers also required an ~300 Å gap between the two arms due to the cross-over of the dichroic.

Given this information, we ran *swoc*, using our defined requirements and conditionals in Table 2, for two arms with bandwidths of 570 and 690 Å, respectively. We imposed a gap, with gap = 300 Å. Similarly to Section 4.3, we chose *bstep* = 20 Å, *rv.shift* = 10 Å, and *feat.min* = 20 mÅ. This resulted in two optimal combinations of wavelength bands: [5160–5730 Å, 6040–6730 Å] and [5240–5810 Å, 6120–6810 Å]. Both of these combinations resulted in an FoM = 0.41. Further assessment showed that the former combination of bands included a large chunk of the Mg b triplet (see Fig. 4). Since the Mg b triplet is an important feature that can be used to estimate the surface gravity of a star, this set of bands was selected as the final optimal combination. Note, however, that later analyses at higher precision in *bstep* showed some flexibility in the range for the red arm. Thus, the current design values for 4MOST are 5160–5730 Å and 6100–6790 Å.

## 5 SPECTRAL MODE EXAMPLE: CHOOSING A SPECTRAL SETUP

As described in Section 3.2, the *spectral* mode of *swoc* can be useful to determine where in a spectrum several objects show the largest spectral differences. This is especially useful when we want to provide an overall classification of objects.

In this example, we investigated several spectral settings for the FLAMES/GIRAFFE spectrograph (Pasquini et al. 2002) on the Very Large Telescope at the ESO La Silla Paranal Observatory in Chile. We utilized the nine stellar spectra listed in Table 1, representing MS, TO, and RC stars at three different metallicities (solar, −1 dex, and −2 dex). The spectra were all normalized since the *spectral*
<figure><img src="image_4.png" /><figcaption>**Figure 2.** Combinations of spectral bands that achieved a maximum FoM in the 525 Å bandwidth case for (a) the MS star, (b) the RC star, (c) the TO star, and (d) all stars together. The stellar parameters for each star are given in Table 1. The optimal combinations of bands are shown as red segments with error-bars at the ends for each metallicity. For some metallicities, one of the bands could be combined with several different other bands to achieve a maximum FoM. These are shown as black segments underneath the red segments.</figcaption></figure>

mode of *swoc* requires that all spectra are flux calibrated. We then ran *swoc* in its static spectral mode. That is, we investigated specific spectral regions instead of scanning across all possible regions (see Appendix A3 for more details). For this example, we investigated only those GIRAFFE settings with wavelengths between 4500 and 8000 Å. Table 4 lists the GIRAFFE settings and their respective wavelength coverage.

Since we want to compare all nine spectra with each other, we set *ref.spec* = 0 (as explained in Appendix A2). *swoc* will then compute the total difference among the spectra for each GIRAFFE setting and compare this to the total difference among the spectra for the entire spectral range between 4500 and 8000 Å, thus providing an FoM statistic that can be used to assess the distinguishing capability (in terms of overall classification) of each GIRAFFE setting.

The FoM values are also listed for each GIRAFFE setting in Table 4. The lowest wavelength settings tend to show the largest differences among the spectra. It appears that HR9A would provide the best spectral range in which we could identify differences and classify the nine spectra. This setting, as well as the other two settings with FoM ~ 0.2, contains the strong Mg b triplet lines. These lines vary greatly with the surface gravity of a star (see Section B1), and are thus very useful for classifying the stars.

It is important to remember that the spectral mode computes the FoM differently from the feature mode. In the spectral mode, only differences in the spectra are considered, while the feature mode takes into account specific user-defined features in the spectra. Thus, both modes can result in very different FoM values. To illustrate this, we computed the FoM in feature mode, which is also listed in Table 4. In this example, we computed the FoM using only the conditionals listed in Table 2. As shown in Table 4, the FoM values from the two modes can be quite different.

It is interesting to note that the primary GIRAFFE settings used for observations of Milky Way field stars in the Gaia-ESO Survey were HR10 and HR21. We do not assess HR21 in our analysis, since it lies outside of the spectral range for our tests. However, according to the spectral mode analysis, HR10 underperforms compared to other settings, such as HR9A and HR9B. On the other hand, it appears to have a comparable FoM to HR9A (and exceeds that of HR9B) in the feature mode analysis. This is an important distinction since a primary science goal of the Gaia-ESO Survey is to obtain accurate individual abundances. Thus, the feature mode FoM is more appropriate.

In addition, other considerations must be made beyond just wavelength considerations. For example, the resolving power of HR10 is R ~ 21 500, while it is lower for HR9A, at R ~ 18 000. Further, the throughput of the HR9A setting is much lower than that of HR10 for the typical objects observed by the Gaia-ESO Survey. This means that the exposure times must be longer when using the HR9A setting to achieve the same signal-to-noise values as HR10. This will lower the survey efficiency. All of these points together suggest that the HR10 setting is more optimal for the survey science goals.

## 6 CONCLUSIONS

In this work, we have presented a new algorithm *swoc*, which provides a thorough analysis of the science goals and spectral information to establish the best spectral coverage for a potential spectrograph design or to decide which wavelength settings to use for an existing spectrograph, such as FLAMES (Pasquini et al. 2002), HIRES (Vogt et al. 1994), or UVES (Dekker et al. 2000). We have described the two modes, feature and spectral, in which the code operates to evaluate different wavelength configurations and the required input needed for each mode. The most important features of this analysis are careful investigations of the useful spectral lines and features (feature mode) or the regions of largest variation in a spectrum (spectral mode) that are essential for the science requirements for a given spectroscopic study or survey. With its two modes, the code has been developed so that it can be used for any spectrograph design and survey science goals.

We illustrated the workings of the feature mode of *swoc* by constructing a line list, which bears relevance for Galactic archaeology with FGK stars in the bulge and disc of the Milky Way (see Appendix B). We then ran the program for two example spectrograph designs, showing that it efficiently and effectively determines the best possible combinations of wavelength bands for a set of science requirements. We also applied our analysis to the preliminary design for the 4MOST spectrograph. The wavelength range covered by the two redder arms of the high-resolution spectrograph are well defined through our FoM calculations, which include the ability to not only measure elemental abundances but also derive stellar parameters from the spectra themselves. As discussed in Appendix B1, this has numerous advantages, including being able to extend the surveys with 4MOST beyond the range of good Gaia
<figure><img src="image_5.png" /><figcaption>**Figure 3.** Output plot from swoc showing the optimal combination of four 200 Å wide bands for the example four-arm spectrograph. The final optimal bands are plotted as grey regions. The required wavelength regions are shown as black, bracketed line segments. The spectral features that make up the different groups of required and conditional features (listed in Table 2) are plotted as points, with the symbols and colours corresponding to the weight given to each feature. The final bands are: 4540–4740 Å, 5280–5480 Å, 6080–6280 Å, and 6460–6660 Å.</figcaption></figure>

<figure><img src="image_6.png" /><figcaption>**Figure 4.** Output plot from swoc showing the optimal combination of 570 and 690 Å wide bands for the preliminary design for the 4MOST spectrograph. The final optimal bands are plotted as grey regions, while symbols and colours are the same as defined in Fig. 3. The final bands chosen are: 5160–5730 and 6040–6730 Å. While this is what came out of swoc, this is not what is currently implemented in 4MOST because more flexibility was later indicated for the red arm (see Section 4.5). Current design values are 5160–5730 and 6100–6790 Å.</figcaption></figure>
<table><caption>**Table 4.** The spectral and feature mode FoM results for the FLAMES/GIRAFFE Settings.</caption><thead><tr><th>Setting</th><th>λ Start (nm)</th><th>λ End (nm)</th><th>spectral FoM</th><th>feature FoM</th></tr></thead><tbody><tr><td>HR6</td><td>453.8</td><td>475.9</td><td>0.19</td><td>0.08</td></tr><tr><td>HR7A</td><td>470.0</td><td>497.4</td><td>0.17</td><td>0.05</td></tr><tr><td>HR7B</td><td>474.2</td><td>493.2</td><td>0.11</td><td>0.03</td></tr><tr><td>HR8</td><td>491.7</td><td>516.3</td><td>0.21</td><td>0.06</td></tr><tr><td>HR9A</td><td>509.5</td><td>540.4</td><td>0.26</td><td>0.12</td></tr><tr><td>HR9B</td><td>514.3</td><td>535.6</td><td>0.20</td><td>0.06</td></tr><tr><td>HR10</td><td>533.9</td><td>561.9</td><td>0.10</td><td>0.10</td></tr><tr><td>HR11</td><td>559.7</td><td>584.0</td><td>0.04</td><td>0.07</td></tr><tr><td>HR12</td><td>582.1</td><td>614.6</td><td>0.04</td><td>0.09</td></tr><tr><td>HR13</td><td>612.0</td><td>640.5</td><td>0.04</td><td>0.11</td></tr><tr><td>HR14A</td><td>630.8</td><td>670.1</td><td>0.04</td><td>0.09</td></tr><tr><td>HR14B</td><td>638.3</td><td>662.6</td><td>0.03</td><td>0.06</td></tr><tr><td>HR15N</td><td>647.0</td><td>679.0</td><td>0.02</td><td>0.06</td></tr><tr><td>HR15</td><td>660.7</td><td>696.5</td><td>0.01</td><td>0.02</td></tr><tr><td>HR16</td><td>693.7</td><td>725.0</td><td>0.02</td><td>0.00</td></tr><tr><td>HR17A</td><td>712.9</td><td>758.7</td><td>0.03</td><td>0.01</td></tr><tr><td>HR17B</td><td>722.5</td><td>749.0</td><td>0.02</td><td>0.00</td></tr><tr><td>HR18</td><td>746.8</td><td>788.9</td><td>0.01</td><td>0.00</td></tr></tbody></table>

parallaxes and being independent of reddening complications and extinction determinations. This demonstrates the importance of having well-defined science requirements, in combination with an appraised line list, when determining the wavelength coverage for a given spectrograph.

We also provided an example of the spectral mode, which can be used to assess the parts of a spectrum that provide the most distinguishing features among a set of objects. The spectral mode is useful, because it relies on the spectra alone, with very little input by the user. It can thus provide a relatively objective analysis of how best to classify several objects given a set of spectral settings, as we showed in our example.

swoc has numerous applications across all spectral studies, from stellar spectroscopy to the investigation of high-redshift galaxies. With the number of spectroscopic surveys coming online over the next decade, and the availability of many instruments at facilities throughout the world, swoc provides a robust and efficient way to assess the spectral coverage that is best suitable to use on such instruments to achieve the desired science goals.

## ACKNOWLEDGEMENTS

GRR and SF acknowledge support from the project grant ‘The New Milky Way’ from the Knut and Alice Wallenberg Foundation. AJK acknowledges support from the Swedish National Space Board. CJH was supported by a research grant (VKR023371) from the VILLUM Foundation. The authors have used ‘Robert L. Kurucz online database of observed and predicted atomic transitions’ for the observations given in this paper (http://kurucz.harvard.edu/atoms/).

## REFERENCES

* Adibekyan V. Z., Sousa S. G., Santos N. C., Delgado Mena E., González Hernández J. I., Israelian G., Mayor M., Khachatryan G., 2012, A&A, 545, A32

* Aldenius M., Tanner J. D., Johansson S., Lundberg H., Ryan S. G., 2007, A&A, 461, 767

* Anders F. et al., 2014, A&A, 564, A115

* Anstee S. D., O'Mara B. J., 1991, MNRAS, 253, 549

* Anstee S. D., O'Mara B. J., 1995, MNRAS, 276, 859

* Balcells M. et al., 2010, Proc. SPIE, 7735, 77357G

* Bard A., Kock M., 1994, A&A, 282, 1014

* Bard A., Kock A., Kock M., 1991, A&A, 248, 315

* Barden S. C. et al., 2010, Proc. SPIE, 7735, 773509

* Barklem P. S., O'Mara B. J., 1997, MNRAS, 290, 102

* Barklem P. S., O'Mara B. J., Ross J. E., 1998, MNRAS, 296, 1057

* Beers T. C., Christlieb N., 2005, ARA&A, 43, 531

* Bensby T., Feltzing S., Oey M. S., 2014, A&A, 562, A71

* Bergemann M., Lind K., Collet R., Magic Z., Asplund M., 2012, MNRAS, 427, 27

* Biemont E., Godefroid M., 1980, A&A, 84, 361

* Blackwell D. E., Ibbetson P. A., Petford A. D., Shallis M. J., 1979a, MNRAS, 186, 633

* Blackwell D. E., Petford A. D., Shallis M. J., 1979b, MNRAS, 186, 657

* Blackwell D. E., Petford A. D., Shallis M. J., Leggett S., 1982a, MNRAS, 199, 21

* Blackwell D. E., Petford A. D., Shallis M. J., Simmons G. J., 1982b, MNRAS, 199, 43

* Blackwell D. E., Petford A. D., Simmons G. J., 1982c, MNRAS, 201, 595

* Blackwell D. E., Menon S. L. R., Petford A. D., 1983, MNRAS, 204, 883

* Blackwell D. E., Booth A. J., Menon S. L. R., Petford A. D., 1986a, MNRAS, 220, 289

* Blackwell D. E., Booth A. J., Haddock D. J., Petford A. D., Leggett S. K., 1986b, MNRAS, 220, 549

* Bonifacio P. et al., 2007, A&A, 462, 851

* Bonifacio P., Caffau E., Ludwig H.-G., 2010, A&A, 524, A96

* Booth A. J., Blackwell D. E., Petford A. D., Shallis M. J., 1984, MNRAS, 208, 147

* Bridges J. M., Kornblith R. L., 1974, ApJ, 192, 793

* Busso M., Gallino R., Wasserburg G. J., 1999, ARA&A, 37, 239

* Butler K., Mendoza C., Zeippen C. J., 1993, J. Phys. B At. Mol. Phys., 26, 4409

* Caffau E. et al., 2013, Astron. Nachr., 334, 197

* Cardon B. L., Smith P. L., Scalo J. M., Testerman L., Whaling W., 1982, ApJ, 260, 395

* Carlsson J., Sturesson L., Svanberg S., 1989, Z. Phys. D Atoms Mol. Clusters, 11, 287

* Carretta E., Gratton R. G., Bragaglia A., D'Orazi V., Lucatello S., 2013a, A&A, 550, A34

* Carretta E., Gratton R. G., Bragaglia A., D'Orazi V., Lucatello S., Sollima A., Sneden C., 2013b, ApJ, 769, 40

* Castro M., Do Nascimento J. D., Jr, Biazzo K., Meléndez J., de Medeiros J. R., 2011, A&A, 526, A17

* Chang T. N., Tang X., 1990, J. Quant. Spectrosc. Radiat. Transfer, 43, 207

* Chiappini C., Matteucci F., Meynet G., 2003, A&A, 410, 257

* Cirasuolo M., Afonso J., Bender R., Bonifacio P., Evans C., Kaper L., Oliva E., Vanzi L., 2011, The Messenger, 145, 11

* Cohen J. G. et al., 2005, ApJ, 633, L109

* Cui X.-Q. et al., 2012, Res. Astron. Astrophys., 12, 1197

* Davidson M. D., Snoek L. C., Volten H., Doenszelmann A., 1992, A&A, 255, 457

* de Jong R. S. et al., 2014, Proc. SPIE, 9147, 91470M

* Dekker H., D'Odorico S., Kaufer A., Delabre B., Kotzlowski H., 2000, in Iye M., Moorwood A. F., eds, Proc. SPIE Conf. Ser. Vol. 4008, Optical and IR Telescope Instrumentation and Detectors. SPIE, Bellingham, p. 534

* Den Hartog E. A., Lawler J. E., Sobeck J. S., Sneden C., Cowan J. J., 2011, ApJS, 194, 35

* Do Nascimento J. D., Castro M., Jr, Meléndez J., Bazot M., Théado S., Porto de Mello G. F., de Medeiros J. R., 2009, A&A, 501, 687

* Doerr A., Kock M., 1985, J. Quant. Spectrosc. Radiat. Transfer, 33, 307

* Edvardsson B., 1988, A&A, 190, 148

* Eisenstein D. J. et al., 2011, AJ, 142, 72

* Feltzing S., Gustafsson B., 1998, A&AS, 129, 237
Feltzing S., Primas F., Johnson R. A., 2009, A&A, 493, 913

Fields B. D., 2011, Annu. Rev. Nucl. Part. Sci., 61, 47

François P., Matteucci F., Cayrel R., Spite M., Spite F., Chiappini C., 2004, A&A, 421, 613

François P. et al., 2007, A&A, 476, 935

Freeman K., Bland-Hawthorn J., 2002, ARA&A, 40, 487

Froese Fischer C., Tachiev G., 2012, Multiconfiguration Hartree-Fock and Multiconfiguration Dirac-Hartree-Fock Collection, Version 2.

Fuhr J. R., Wiese W. L., 2006, J. Phys. Chem. Ref. Data, 35, 1669

Fuhr J. R., Martin G. A., Wiese W. L., 1988, J. Phys. Chem. Ref. Data, 17, 4

Fuhrmann K., 1998, A&A, 338, 161

Fulbright J. P., 2000, AJ, 120, 1841

Fulbright J. P., 2002, AJ, 123, 404

Gallagher A. J., Ryan S. G., Hosford A., García Pérez A. E., Aoki W., Honda S., 2012, A&A, 538, A118

Garz T., 1973, A&A, 26, 471

Garz T., Kock M., 1969, A&A, 2, 274

Gilmore G. et al., 2012, The Messenger, 147, 25

Gratton R. G., Carretta E., Bragaglia A., 2012, A&AR, 20, 50

Gustafsson B., 1989, ARA&A, 27, 701

Hannaford P., Lowe R. M., Grevesse N., Biemont E., Whaling W., 1982, ApJ, 261, 736

Hansen C. J. et al., 2015, Astron. Nachr., 336, 665

Heil M., Juseviciute A., Käppeler F., Gallino R., Pignatari M., Uberseder E., 2009, Publ. Astron. Soc. Aust., 26, 243

Hibbert A., Biemont E., Godefroid M., Vaeck N., 1991, J. Phys. B: At. Mol. Opt. Phys., 24, 3943

Hibbert A., Biemont E., Godefroid M., Vaeck N., 1993, A&AS, 99, 179

Ivezic Z. et al., 2008, Serb. Astron. J., 176, 1

Johnson J. A., 2002, ApJS, 139, 219

Käppeler F., Gallino R., Bisterzo S., Aoki W., 2011, Rev. Mod. Phys., 83, 157

Karakas A. I., Lattanzio J. C., 2014, Publ. Astron. Soc. Aust., 31, e030

Keller S. C. et al., 2007, Publ. Astron. Soc. Aust., 24, 1

Kobayashi C., Nomoto K., 2009, ApJ, 707, 1466

Kobayashi C., Umeda H., Nomoto K., Tominaga N., Ohkubo T., 2006, ApJ, 653, 1145

Kock M., Richter J., 1968, Z. Phys., 69, 180

Korn A. J., Grundahl F., Richard O., Barklem P. S., Mashonkina L., Collet R., Piskunov N., Gustafsson B., 2006, Nature, 442, 657

Kupka F., Piskunov N., Ryabchikova T. A., Stempels H. C., Weiss W. W., 1999, A&AS, 138, 119

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

Lawler J. E., Dakin J. T., 1989, Journal of the Optical Society of America B Optical Physics, 6, 1457

Lawler J. E., Wickliffe M. E., den Hartog E. A., Sneden C., 2001, ApJ, 563, 1075

Lawler J. E., Guzman A., Wood M. P., Sneden C., Cowan J. J., 2013, ApJS, 205, 11

Lennard W. N., Whaling W., Scalo J. M., Testerman L., 1975, ApJ, 197, 517

Lind K., Primas F., Charbonnel C., Grundahl F., Asplund M., 2009, A&A, 503, 545

Lind K., Charbonnel C., Decressin T., Primas F., Grundahl F., Asplund M., 2011, A&A, 527, A148

Lind K., Bergemann M., Asplund M., 2012, MNRAS, 427, 50

Lindegren L., 2010, in Klioner S. A., Seidelmann P. K., Soffel M. H., eds, Proc. IAU Symp. 261, Relativity in Fundamental Astronomy: Dynamics, Reference Frames, and Data Analysis. Cambridge Univ. Press, Cambridge, p. 210

Lindegren L. et al., 2008, in Jin W. J., Platais I., Perryman M. A. C., eds, Proc. IAU Symp. 248, A Giant Step: from Milli- to Micro-Arcsecond Astrometry. Cambridge Univ. Press, Cambridge, p. 529

Lucatello S., Beers T. C., Christlieb N., Barklem P. S., Rossi S., Marsteller B., Sivarani T., Lee Y. S., 2006, ApJ, 652, L37

Ludwig H.-G., Behara N. T., Steffen M., Bonifacio P., 2009, A&A, 502, L1

McWilliam A., Preston G. W., Sneden C., Shectman S., 1995, AJ, 109, 2736

McWilliam A., Rich R. M., Smecker-Hane T. A., 2003, ApJ, 592, L21

Maeda K., Nomoto K., 2003, ApJ, 598, 1163

Magic Z., Collet R., Asplund M., Trampedach R., Hayek W., Chiavassa A., Stein R. F., Nordlund Å., 2013, A&A, 557, A26

Martin G., Fuhr J., Wiese W., 1988, J. Phys. Chem. Ref. Data Suppl. 3, 17

Mashonkina L., 2014, in Feltzing S., Zhao G., Walton N. A., Whitelock P., eds, Proc. IAU Symp. 298, Setting the Scene for Gaia and LAMOST. Cambridge Univ. Press, Cambridge, p. 355

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

Mashonkina L., Korn A. J., Przybilla N., 2007, A&A, 461, 261

Matteucci F., Brocato E., 1990, ApJ, 365, 539

Matteucci F., Raiteri C. M., Busson M., Gallino R., Gratton R., 1993, A&A, 272, 421

May M., Richter J., Wichelmann J., 1974, A&AS, 18, 405

Meléndez J., Barbuy B., 2009, A&A, 497, 611

Munari U., Zwitter T., 1997, A&A, 318, 269

Nahar S. N., 1993, Phys. Scr., 48, 297

Nissen P. E., 2013, A&A, 552, A73

Nissen P. E., Schuster W. J., 2010, A&A, 511, L10

Nissen P. E., Chen Y. Q., Carigi L., Schuster W. J., Zhao G., 2014, A&A, 568, A25

Nitz D. E., Wickliffe M. E., Lawler J. E., 1998, ApJS, 117, 313

Nitz D. E., Kunau A. E., Wilson K. L., Lentz L. R., 1999, ApJS, 122, 557

Nomoto K., Kobayashi C., Tominaga N., 2013, ARA&A, 51, 457

O'Brian T. R., Lawler J. E., 1991, Phys. Rev. A, 44, 7134

O'Brian T. R., Wickliffe M. E., Lawler J. E., Whaling W., Brault J. W., 1991, J. Opt. Soc. Am. B, 8, 1185

Ohkubo T., Umeda H., Maeda K., Nomoto K., Suzuki T., Tsuruta S., Rees M. J., 2006, ApJ, 645, 1352

Parkinson W. H., Reeves E. M., Tomkins F. S., 1976, Phil. Trans. R. Soc. A, 351, 569

Pasquini L. et al., 2002, The Messenger, 110, 1

Perryman M. A. C. et al., 2001, A&A, 369, 339

Pignatari M., Gallino R., Heil M., Wiescher M., Käppeler F., Herwig F., Bisterzo S., 2010, ApJ, 710, 1557

Pinnington E. H., Ji Q., Guo B., Berends R. W., van Hunen J., Biemont E., 1993, Can. J. Phys., 71, 470

Pompéia L., Barbuy B., Grenon M., 2003, ApJ, 592, 1173

Raassen A. J. J., Uylings P. H. M., 1998, A&A, 340, 300

Reddy B. E., Lambert D. L., Allende Prieto C., 2006, MNRAS, 367, 1329

Richter J., Wulff P., 1970, A&A, 9, 37

Ruchti G. R. et al., 2011, ApJ, 743, 107

Ruchti G. R., Bergemann M., Serenelli A., Casagrande L., Lind K., 2013, MNRAS, 429, 126

Ruffoni M. P., Den Hartog E. A., Lawler J. E., Brewer N. R., Lind K., Nave G., Pickering J. C., 2014, MNRAS, 441, 3127

Ryabchikova T. A., Hill G. M., Landstreet J. D., Piskunov N., Sigut T. A. A., 1994, MNRAS, 267, 697

Sbordone L. et al., 2010, A&A, 522, A26

Seitenzahl I. R., Cescutti G., Röpke F. K., Ruiter A. J., Pakmor R., 2013, A&A, 559, L5

Simmerer J., Sneden C., Ivans I. I., Kraft R. P., Shetrone M. D., Smith V. V., 2003, AJ, 125, 2018

Skrutskie M. F. et al., 2006, AJ, 131, 1163

Smith G., 1981, A&A, 103, 351

Smith G., 1988, J. Phys. B: At. Mol. Opt. Phys., 21, 2827

Smith G., O'Neill J. A., 1975, A&A, 38, 1

Smith G., Raggett D. S. J., 1981, J. Phys. B: At. Mol. Opt. Phys., 14, 4015

Sobeck J. S., Lawler J. E., Sneden C., 2007, Astrophys. J., 667, 1267

Spite F., Spite M., 1982, A&A, 115, 357

Steinmetz M. et al., 2006, AJ, 132, 1645

Storey P. J., Zeippen C. J., 2000, MNRAS, 312, 813

Suda T., Aikawa M., Machida M. N., Fujimoto M. Y., Iben I., Jr, 2004, ApJ, 611, 476

Tolstoy E., Hill V., Tosi M., 2009, ARA&A, 47, 371

Travaglio C., Röpke F. K., Gallino R., Hillebrandt W., 2011, ApJ, 739, 93
Vogt S. S. et al., 1994, in Crawford D. L., Craine E. R., eds, Proc. SPIE Conf. Ser. Vol. 2198, Instrumentation in Astronomy VIII. SPIE, Bellingham, p. 362

Volz U., Majerus M., Liebel H., Schmitt A., Schmoranzer H., 1996, Phys. Rev. Lett., 76, 2862

Wallerstein G., Conti P. S., 1969, ARA&A, 7, 99

Whaling W., Hannaford P., Lowe R. M., Biemont E., Grevesse N., 1985, A&A, 153, 109

Wickliffe M. E., Lawler J. E., 1997, ApJS, 110, 163

Wolnik S. J., Berthel R. O., Wares G. W., 1970, ApJ, 162, 1037

Wolnik S. J., Berthel R. O., Wares G. W., 1971, ApJ, 166, L31

Wood M. P., Lawler J. E., Sneden C., Cowan J. J., 2013, ApJS, 208, 27

Wright E. L. et al., 2010, AJ, 140, 1868

Yan Z.-C., Tambasco M., Drake G. W. F., 1998, Phys. Rev. A, 57, 1652

Yanny B. et al., 2009, AJ, 137, 4377

## SUPPORTING INFORMATION

Additional Supporting Information may be found in the online version of this article:

**Table B2.** Final compiled line list for the analysis of FGK stars in the Milky Way (http://www.mnras.oxfordjournals.org/lookup/suppl/ doi:10.1093/mnras/stw1351/-/DC1).

Please note: Oxford University Press is not responsible for the content or functionality of any supporting materials supplied by the authors. Any queries (other than missing material) should be directed to the corresponding author for this paper.

## APPENDIX A: SWOC INPUT DEFINITIONS

All input parameters are read into `swoc` using an input file, a template for which is provided as part of the program package. In the following sections, we describe many of the input parameters and their uses. Many of the input parameters are also defined in Table A1. Further details and formatting instructions can be found in the program help files.

### A1 feature mode input parameters

The full range of wavelengths (`band_range`) over which the FoM analysis will take place should be first determined, as well as the units (`wunits`) of the wavelengths given, which will be used throughout the analysis. This is purely for aesthetic purposes in the

output files and plots. The number of wavelength segments (`nband`) and their respective bandwidths (`band_width`, e.g. 300, 400, or 500 Å) can then be defined. If required, a minimum wavelength gap (`gap`) that must reside between each band of a combination can also be defined. Finally, the step-size (`bstep`) between band heads is needed to create the vector of bands (see also Section 3.1).

Each spectral feature list should be saved as a text file and listed under `inFILE`. Each file should include four columns: the spectral feature wavelength centre, a designated name for the feature, an estimate of the strength for each feature, and a weight. The weight parameter must be greater than zero, where the smallest weight is best. This is used during the FoM analysis either as an exclusion parameter or a weight parameter (see Section 3.1). Spectral features that are given the same designated name, will be associated with the same required or conditional spectral feature group during the FoM analysis in `swoc`.

A minimum line strength (`feat_min`) can be set in the input file to `swoc`, below which lines are considered immeasurable. Further, each spectral feature listed can be given a wavelength tolerance (`rv_shift`) to account for possible shifts due to the radial velocity of a given object.

Next, the required spectral regions should be listed under `wreq`, while the groups of required and conditional spectral features should be listed under `freq` and `con`, respectively. For each group of spectral features listed in `freq` or `con`, a maximum quality weight should be provided. Any features associated with that group and that have a quality weight greater than this value will be disregarded in the FoM analysis.

Below is a template for the input file for the example given in Section 4.3.

```ini
#INPUT FILE FOR SWOC: FEATURE MODE
```

```ini
########## WAVELENGTH SEGMENT SETUP ##########
```

```ini
########## WAVELENGTH SEGMENT SETUP ##########
```

```ini
########## WAVELENGTH SEGMENT SETUP ##########
```

```ini
#Wavelength Units
```

```ini
#e.g. nm (nanometer) or Å (Ångstrom)
```

```ini
wunits <- 'Å'
```

```ini
#Wavelength Range
```

```ini
#Define full range of lambda in which the
```

<table><caption>**Table A1.** SWOC input definitions.</caption><thead><tr><th>Input</th><th>Definition</th></tr></thead><tbody><tr><td>band_range</td><td>Full range of wavelengths over which the FoM analysis will take place</td></tr><tr><td>band_static</td><td>List of specific band combinations to be analysed using the static modulation</td></tr><tr><td>band_width</td><td>List of the respective bandwidths for each wavelength segment</td></tr><tr><td>bstep</td><td>Step size between band heads, needed to create the vector of bands</td></tr><tr><td>con</td><td>List of groups of conditional spectral features, consisting of those spectral features used to compute the FoM</td></tr><tr><td>feat_min</td><td>Minimum line strength, below which lines are considered immeasurable</td></tr><tr><td>freq</td><td>List of groups of spectral features required to be present in the final combination of wavelength bands</td></tr><tr><td>gap</td><td>Minimum gap that must reside between each band of a combination</td></tr><tr><td>inFILE</td><td>List of spectral feature line lists (feature mode) or list of spectra (spectral mode) used for the FoM analysis</td></tr><tr><td>nband</td><td>Number of wavelength segments</td></tr><tr><td>refspec</td><td>Reference spectrum with which each spectrum in inFILE will be compared in spectral mode</td></tr><tr><td>rv_shift</td><td>Wavelength tolerance to account for possible shifts due to the radial velocity of a given object</td></tr><tr><td>spec sig</td><td>Global uncertainty for each spectrum if no variance spectrum is given in the input spectra</td></tr><tr><td>wreq</td><td>List of spectral regions required to be present in the final combination of wavelength bands</td></tr><tr><td>wunits</td><td>Wavelength units, e.g. Å or nm</td></tr></tbody></table>
FoMs will be computed
band_range <- c(4500.0,8000.0)

#FOR SCANNING MODULATION (swoc.mode=1)
#Number of Bands
#Define the number of wavelength segments
to be considered
nband <- 2

#Bandwidths
#Define the size of each wavelength segment
band.width <- c(500.0,500.0)

#Band gap
#Define the size of the wavelength gap
between each wavelength segment
gap <- 0

#Step Size
#Define the step size to determine the bands
bstep <- 20

#FOR STATIC MODULATION (swoc.mode=2)
#List bands / band combinations
for which an FoM will be computed.
#Only used if swoc.mode=2 in main swoc
program
#band static[[1]] <- rbind(c(5160,5730),
c(6040,6730))
#band static[[2]] <- rbind(c(5200,6300))

##########
#LOAD FEATURE FILES AND INITIALIZE SETUP
##########

#Directory containing line list files
#e.g. FILE.dir <- ''swoc/spec/''
FILE.dir <- paste(.libPaths(), ''/swoc/
extdata/'', sep='''') #Path to run example
files that come with the SWOC package

#List line list files to be considered
#Files should contain the following:
Lambda, feature name, strength (e.g.,
EW, line depth, etc.), flag
#Files can be zipped or unzipped.
inFILE <- c(

''MSp0.0.xy_47K_full.4m.ldat.gz'',
''MSm1.0.xy_47K_full.4m.ldat.gz'',
''MSm2.0.xy_47K_full.4m.ldat.gz'',
''RCp0.0.xy_47K_full.4m.ldat.gz'',
''RCm1.0.xy_47K_full.4m.ldat.gz'',
''RCm2.0.xy_47K_full.4m.ldat.gz'',
''TOp0.0.xy_47K_full.4m.ldat.gz'',
''TOm1.0.xy_47K_full.4m.ldat.gz'',
''TOm2.0.xy_47K_full.4m.ldat.gz''
)

#Line wavelength shifts
#Wavelength shift added and subtracted
from line centers to account for RV shifts
rv.shift <- 10.0

#Minimum feature strength
#Define the minimum feature
strength, which sets what features
are strong enough to ''measure''.
feat.min <- 20.0

##########
#FIGURE-OF-MERIT SETUP
##########

#Required Spectral Regions
#Useful for broad features, or groups
of features that are required no matter what
#Denote in Å
#wreq <- NULL #Set if no wavelength
requirements
wreq[[1]] <- rbind(c(6470.0,6650.0))
wreq[[2]] <- rbind(c(5100.0,5250.0),
c(6152.0,6172.0))

#Groups of required spectral features
#List spectral features or groups of
spectral features required
regardless of strength
#freq <- NULL #Set if no element
requirements
freq[[1]] <- rbind(c(12.0,1))
freq[[2]] <- rbind(c(11.0,1),c(13.0,1))
freq[[3]] <- rbind(c(20.0,1))
freq[[4]] <- rbind(c(25.0,2))
freq[[5]] <- rbind(c(56.1,1),c(63.1,1))
freq[[7]] <- rbind(c(6.0,1))

#Groups of conditional features
#A Figure-of-Merit is
computed based on spectral feature
strengths (e.g., equivalent widths, depth)
#List spectral features or groups of
spectral features desired according
to name and the maximum weight.
#each feature given as c(name,weight), e.g.
for Mg lines with weight <= 2: c(12.0,2)
con[[1]] <- rbind(c(26.0,1)) #FeI, EP <
2.5
con[[2]] <- rbind(c(26.25,1)) #FeI, EP >=
2.5
con[[3]] <- rbind(c(26.1,2)) #FeII
con[[4]] <- rbind(c(3.0,2)) #LiI
con[[5]] <- rbind(c(6.0,2)) #CI
con[[6]] <- rbind(c(8.0,2)) #OI
con[[7]] <- rbind(c(11.0,2)) #NaI
con[[8]] <- rbind(c(12.0,2)) #MgI
con[[9]] <- rbind(c(13.0,2)) #AlI
con[[10]] <- rbind(c(14.0,2),c(20.0,2)) #
SiI, CaI
con[[11]] <- rbind(c(22.0,2),c(22.1,2)) #
TiI, TiII
con[[12]] <- rbind(c(24.0,2),c(24.1,2),c
(28.0,2)) #CrI, CrII, NiI
con[[13]] <- rbind(c(27.0,2),c(30.0,2)) #
CoI, ZnI
con[[14]] <- rbind(c(29.0,2)) #CuI
con[[15]] <- rbind(c(56.1,2)) #BaII
con[[16]] <- rbind(c(63.1,2)) #EuII

##########
#OUTPUT FILES
##########

#Where do you want results to be output?
outdata <- 'out_test.txt'

#Would you like the results plotted?
TRUE/FALSE
#If TRUE, resultant plots will be saved as
a post-script file
plot results <- TRUE
#Where would you like the plots saved?
outplot <- 'out_test.ps'

## A2 spectral mode input parameters

The input parameters for the spectral mode in swoc very much resemble those defined in feature mode. All wavelength segment parameters should be defined as described in Section A1. In this mode, the spectra that will be analysed should be listed in inFILE. The spectra should be in text format with two or three columns, the first being the wavelength and the second, flux. The third column is optional. If included, it should be the variance in the flux for each point in the spectrum. If no variance spectrum is included, then a global uncertainty value should be supplied under spec.sig for each spectrum listed in inFILE. If only a single value is given, this uncertainty is assumed for all spectra. If the user wishes to ignore uncertainties (highly unadvised if actual observations are being used), then set spec.sig = 0.

In addition, the user can supply a reference spectrum under ref.spec. In this case, the spectra listed in inFILE will be compared with this spectrum only and not each other. This is useful if the user is trying to determine the wavelength regions that could be best used to select an object with a typical spectrum like that in ref.spec amongst objects that will have typical spectra like those listed in inFILE. If the user wishes to not use a reference spectrum, and instead compute the differences among all spectra in inFILE, then just set ref.spec = 0.

swoc computes direct differences between each spectrum. It is therefore important that the spectra are already flux and continuum normalized (if not synthetic spectra), and also have the same sampling (i.e. the wavelength points are consistent among all spectra). No additional input is needed from the user.

Below, we provide an example input file for the test described in Section 5.

#INPUT FILE FOR SWOC: SPECTRAL MODE

##########
#WAVELENGTH SEGMENT SETUP
##########

#Wavelength Units
#e.g. nm (nanometer) or Å (Ångstrom)
wunits <- 'nm'

#Wavelength range
#Define full range of lambda in which the
FoMs will be computed

band range <- c(450.0,800.0)

#FOR SCANNING MODULATION (swoc.mode=3)

#Number of bands

#Define the number of wavelength segments
to be considered

nband <- 1

#Bandwidths

#Define the size of each wavelength segment

band.width <- c(45.0,45.0)

#Band gap

#Define the size of the wavelength gap
between each wavelength segment

gap <- 10.0

#Step size

#Define the step size to determine the bands
bstep <- 2

#FOR STATIC MODULATION (swoc.mode=4)

#List bands / band combinations for which
an FoM will be computed.

#Only used if swoc.mode=2 in main swoc
program

band static[[1]] <- rbind(c(453.8,475.9))

#HR6

band static[[2]] <- rbind(c(470.0,497.4))

#HR7A

band static[[3]] <- rbind(c(474.2,493.2))

#HR7B

band static[[4]] <- rbind(c(491.7,516.3))

#HR8

band static[[5]] <- rbind(c(509.5,540.4))

#HR9A

band static[[6]] <- rbind(c(514.3,535.6))

#HR9B

band static[[7]] <- rbind(c(533.9,561.9))

#HR10

band static[[8]] <- rbind(c(559.7,584.0))

#HR11

band static[[9]] <- rbind(c(582.1,614.6))

#HR12

band static[[10]] <- rbind(c(612.0,640.5))

#HR13

band static[[11]] <- rbind(c(630.8,670.1))

#HR14A

band static[[12]] <- rbind(c(638.3,662.6))

#HR14B

band static[[13]] <- rbind(c(647.0,679.0))

#HR15N

band static[[14]] <- rbind(c(660.7,696.5))

#HR15

band static[[15]] <- rbind(c(693.7,725.0))

#HR16

band static[[16]] <- rbind(c(712.9,758.7))

#HR17A

band static[[17]] <- rbind(c(722.5,749.0))

#HR17B

band static[[18]] <- rbind(c(746.8,788.9))

#HR18
##########

#LOAD SPECTRAL FILES

##########

#Directory containing line list files

#e.g. FILE.dir <- 'swoc/spec/'
FILE.dir <- paste(.libPaths(), '/swoc/ /extdata/', sep="") #Path to run example files that come with the SWOC package

#List spectral files to be considered

#Files should contain the following:
Lambda, flux, variance (optional)

#All input spectral data should already be flux normalized to the same scale.

#Files can be zipped or unzipped.

inFILE <- c(

'MSp0.0.xy_20K_full.dat.gz',
'MSm1.0.xy_20K_full.dat.gz',
'MSm2.0.xy_20K_full.dat.gz',
'RCp0.0.xy_20K_full.dat.gz',
'RCm1.0.xy_20K_full.dat.gz',
'RCm2.0.xy_20K_full.dat.gz',
'TOp0.0.xy_20K_full.dat.gz',
'TOm1.0.xy_20K_full.dat.gz',
'TOm2.0.xy_20K_full.dat.gz'

#If variance not provided, global
uncertainty should be given.

#Can be single value, or vector with
length equal to inFILE.

#Set spec.sig <- 0 to ignore uncertainty.

spec.sig <- 0

#List reference spectrum to which spectra
in inFILE will be compared.

#File should contain the following:

Lambda, flux, variance (optional)
#Set ref.spec <- 0 if no reference spectrum.

#ref.spec <- 'RCm1.0.xy_20K_full.dat.gz'
ref.spec <- 0

#If variance not provided, global
uncertainty should be given.

#Set ref.sig <- 0 to ignore uncertainty.

ref.sig <- 0

##########

#OUTPUT FILES

##########

#Where do you want results to be output?

outdata <- 'outspec_test.txt'

#Would you like the results plotted?

#If TRUE, resultant plots will be saved as
a post-script file

plot results <- TRUE

#Where would you like the plots saved?

outplot <- 'outspec_test.ps'

### A3 The static modulation

Instead of scanning through a range of possible wavelength bands, *swoc* can also be used to assess the form for specific wavelength bands and combinations. This is known as the 'static' modulation and can be performed in both *feature* and *spectral* modes. Both modes run similarly to their scanning modulations, but in this case, the user lists the specific bands and combination of bands under *band static* in the input file. The final output will consist of the defined wavelength bands or combination of bands and their respective computed form. These can then be compared to assess the performance of different setups.

## APPENDIX B: A LINE LIST FOR FGK STARS

Here, we describe the elements and spectral features (between 4500 and 7000 Å) that are useful when conducting a survey of FGK stars in the bulge and disc of the Milky Way. The final line list (described in Section B4) contains many spectroscopic lines and features that provide diagnostics for the stellar parameters, and that cover many of the major nucleosynthetic channels. This list is not meant to be exhaustive, and depending on the science goals for a given survey and the resolution of the spectrograph, one may add or exclude elements, and extend the line list to bluer and redder wavelengths.

### B1 Determination of stellar parameters

Stars in the disc and the bulge will be moderately affected by reddening. This means that we cannot exclusively rely on photometric colours for the derivation of effective temperatures ($T_{eff}$). Also surface gravities (log g) need independent confirmation by spectroscopy since the astrometric inference of log g may suffer from considerable uncertainties stemming from uncertainties in mass, when studying populations with a wide age range. The inclusion of a measure of log g will also allow us to extend a survey to distances where the parallaxes are poor (even if such an approach might need calibration, see the discussion in Bensby, Feltzing & Oey 2014 and notes in Nissen et al. 2014) or non-existent. From these points of view, it is highly desirable to include spectroscopic measures of both $T_{eff}$ and log g directly in the selected wavelength regions.

Often spectroscopic analyses make use of ionization equilibrium for the determination of log g and excitation balance for $T_{eff}$ (e.g. Fulbright 2000; Adibekyan et al. 2012; Bensby et al. 2014). Ionization equilibrium from neutral and singly ionized Fe (Fe I and Fe II) is often used to derive the surface gravity but also Ca I and Ca II lines (e.g. in the Gaia-ESO Survey) and Ti I and Ti II lines (e.g. GALAH) can be used.

The main stumbling block with this technique for a survey with limited wavelength coverage is usually the paucity of unblended and strong lines from the singly ionized ions (e.g. Fe II). However, also high-resolution studies with wide coverage have reported problems with ionization balance as a measure of surface gravity (see, e.g. Bensby et al. 2014 and references therein and the plots in Anders et al. 2014 for APOGEE). In particular, the MS just below the TO and further down suffer from increasingly underestimated log g with lower $T_{eff}$, resulting in an unphysical morphology for the MS. The red giant branch is similarly affected, but since the direction of the stellar sequence here aligns with the direction in which the parameters are skewed, the effect is less obvious, but still present.
<table><caption>**Table B1.** List of lines and spectral features that are of high relevance for the determination of $T_{\text{eff}}$ and log g.</caption><thead><tr><th>λ (Å)</th><th>Line/Feature</th><th>w</th><th>star flag</th></tr></thead><tbody><tr><td colspan="4">Effective temperature (T<sub>eff</sub>)</td></tr><tr><td>4861.35</td><td>H<sub>β</sub></td><td>2</td><td>D, RC</td></tr><tr><td>6562.83</td><td>H<sub>α</sub></td><td>1</td><td>D, RC</td></tr><tr><td colspan="4">Surface gravity (log g)</td></tr><tr><td>5167.32</td><td>Mg b</td><td>1</td><td>D</td></tr><tr><td>5172.68</td><td>Mg b</td><td>1</td><td>D</td></tr><tr><td>5183.60</td><td>Mg b</td><td>1</td><td>D</td></tr><tr><td>6162.17</td><td>Ca I</td><td>1</td><td>D, RC</td></tr><tr><td colspan="4">Interstellar reddening<sup>a</sup></td></tr><tr><td>5889.95</td><td>Na D</td><td>2</td><td>D, RC</td></tr><tr><td>5895.92</td><td>Na D</td><td>2</td><td>D, RC</td></tr></tbody></table>

Studies have shown that 1D model atmospheres in combination with the assumption of local thermodynamic equilibrium (LTE) are likely the cause of these problems (e.g. Mashonkina, Korn & Przybilla 2007; Bergemann et al. 2012). Indeed, Ruchti et al. (2013) illustrated how, at low metallicities, inclusion of non-LTE (NLTE) corrections for Fe I (from Lind et al. 2012) can strongly mediate the problem with underestimated log g from ionization balance on the red giant branch. It is thus likely that inclusion of NLTE effects, possibly in combination with 3D atmospheric models (e.g. Ludwig et al. 2009; Magic et al. 2013), in the analysis will help, however, it remains to be shown that this can fully solve the problem with traditional spectroscopic parameters at all metallicities.

A robust complement to excitation and ionization balance is the inclusion of broad features whose shape, in particular their extending wings, serve as sensitive diagnostics of stellar parameters. Suitable examples for FGK stars are the Ca II near-infrared triplet at 8500 Å, the optical Mg b lines at 5170 Å and the Ca I line at 6162 Å. The Mg b lines and the Ca I line at 6162 Å are all strong except at very low metallicities ([Fe/H] < −2.5) and their wings are affected by pressure broadening and can thus be used to determine log g (e.g. Edvardsson 1988; Feltzing & Gustafsson 1998; Fuhrmann 1998; Caffau et al. 2013). Similarly, the wings of the H$_{α}$ and H$_{β}$ lines are mostly sensitive to effective temperature ($T_{\text{eff}}$) in cool stars, via the excitation properties of neutral hydrogen. We have therefore included broad hydrogen and metal lines in our list (see Table B1).

A few remarks are in order. First, the two Balmer lines have different advantages and disadvantages connected to their different sensitivities to stellar parameters and convection treatment. We prefer H$_{α}$ mainly because it is situated in a region that is much less crowded with blending metal lines. Hence, it is easier to recognize and model the shape of the line (i.e. it will work well also at moderate resolution). Secondly, we note that both Balmer lines lose sensitivity to effective temperature in cooler stars, and are therefore not useful below ~4500 K. Thus, they cannot serve exclusively as spectroscopic indicators of $T_{\text{eff}}$. Thirdly, it is important to realize that the usefulness of broad lines of Mg and Ca for surface gravity determination is dependent on the knowledge of their respective abundances. Other, weaker lines of the same element must simultaneously provide information about these. This requirement will be important when we define wavelength regions (see Section 4).

We have compiled a list (see Table B1) that includes the most important features for determination of stellar parameters from the

spectra. These should be considered when discussing the wavelength coverage. Note, that this list does not take ionization balance into account. This is instead included in the full line list (see also discussion in Section 4 and Table 2).

## B2 Nucleosynthesis channels

In the following sections, we highlight some of the most important elements that probe different nucleosynthesis paths. This list is not meant to be complete, but offers a concise description of those elements which have been shown to be useful for chemical evolution models, as well as the feasibility of observing such elements.

For some of the most important elements that probe the different nucleosynthetic paths there is only one or a few lines available in the optical and near-infrared spectrum. These lines are hence of high importance when choosing the wavelength range(s). Finally, for those elements with many lines available we wish to have as many lines as feasible and also ensure that we include lines that are strong and unblended enough to be analysed in a wide range of stars, e.g. metal-rich dwarf and RC stars as well as stars at low metallicities ([Fe/H] ~ −2).

### B2.1 Lithium

Lithium has many unique properties and a mixed origin, including big bang, stellar, and ISM nucleosynthesis. The low stellar abundances of Li are disproportionate to the immense interest in this light element. It is an important diagnostic tool for cosmology (e.g. Fields 2011, and references therein). In particular, the connection to big bang nucleosynthesis has prompted many studies of Li in metal-poor stars (e.g. Spite & Spite 1982; Bonifacio et al. 2007; Sbordone et al. 2010). Further, Li can also serve as an indicator of age (e.g. Do Nascimento et al. 2009; Castro et al. 2011) and the internal physics of stars (e.g. Wallerstein & Conti 1969; Gustafsson 1989; Korn et al. 2006; Ruchti et al. 2011) of all metallicities, because the fragile nuclei are destroyed in the hot stellar interiors. Lithium is also important for constraining cluster formation (e.g. Lind et al. 2009). In medium-resolution surveys, the element can only be studied from a single line at 6708 Å.

### B2.2 Carbon and nitrogen

Carbon and nitrogen are primarily produced in AGB stars. Thus, the abundances of these elements are important for constraining stellar evolutionary models of low-mass stars (e.g. Chiappini, Matteucci & Meynet 2003). Further, the abundances of these elements can be used to probe the nucleosynthesis and internal mixing processes that take place between the interior and surface of low-mass giant stars (e.g. Karakas & Lattanzio 2014, and references therein).

Many stars, especially at low metallicity ([Fe/H] ≤ −2), have been observed to have large enhancements in [C/Fe] (e.g. Beers & Christlieb 2005; Cohen et al. 2005; Lucatello et al. 2006). Studies of these carbon enhanced metal-poor (CEMP) stars have primarily focused on determining their frequency and understanding the enrichment processes that took place to cause these stars to have such large C abundances. For example, one possibility is mass transfer from a binary companion (e.g. Suda et al. 2004).

The [C/O] ratio in the Galactic discs has also been under debate and is highly relevant, for example, for understanding planet formation and the possible existence of terrestrial planets (e.g. Nissen 2013).

<footnote><sup>a</sup>See Section B2.5.</footnote>
There are only two useful atomic CⅠ lines between 4500 and 8000 Å, at 5380.3 and 6587.6 Å. These lines, however, are quite weak. On the other hand, there are no useful atomic NⅠ lines between these wavelengths. Several molecular features exist that can be used to constrain the abundances of C and N. For example, there is the C₂ Swan band at 5135.6 Å, as well as a weak CN feature at 6332.2 Å. We have not included these features in the line list used to illustrate our method. However, they could readily be included if the science so demands, e.g. when studying CEMP stars. There are other, stronger, features at wavelengths bluer and redder than our set range, such as the CH G-band, which can further provide diagnostics (e.g. Hansen et al. 2015). Again, it is easy to extend our methodology to bluer and redder wavelengths as needed.

## B2.3 The α-elements: O, Mg, Si, Ca

The α-elements all share a similar behaviour with metallicity, characterized by an enhanced plateau up to [Fe/H] ~ -0.5 dex where a gradual decrease sets in (e.g. Fuhrmann 1998; Fulbright 2002; Adibekyan et al. 2012; Bensby et al. 2014). This is traditionally explained by the dominance of core-collapse supernovae, such as Type II supernovae (SNe II) and hypernovae (HNe), in the early universe and the delayed onset of Type Ia supernovae (SNe Ia). Thus, the α-elements can serve as tracers of the star formation rate and star formation efficiency within a stellar population (e.g. Matteucci & Brocato 1990). The α-elements are also among the best elements with which we can recognize accreted stars in the Milky Way (e.g. Tolstoy, Hill & Tosi 2009; Nissen & Schuster 2010).

Observationally, O, Mg, and Si have been found to show a clear separation between the 'canonical' thin and thick discs, while the separation is less clear for Ca (e.g. Bensby et al. 2014). However, Si is overproduced with respect to O and Mg in pair-instability supernovae (PISN), and thus the ratio of these α-elements with respect to each other can serve to trace PISN progenitors. Along with the other light elements ($Z \le 13$), O and Mg also display anomalies in globular clusters and can be used to study the globular cluster/halo field connection (e.g. Gratton, Carretta & Bragaglia 2012).

There are several good Si and Ca lines above ~5500 Å. However, Si lines become very weak for metal-poor stars. On the other hand, there are only a handful of good weak Mg lines. O can only be constrained using the oxygen triplet near 7770 Å and the forbidden line at 6300 Å. However, the forbidden line is often very weak and can be contaminated by telluric lines.

## B2.4 Titanium

Titanium displays an α-element like behaviour with metallicity and is one of the clearest separators of the thin and thick disc (e.g. Bensby et al. 2014). However, models of Galactic chemical evolution currently fall short of explaining the [Ti/Fe] enhancement at low metallicities. This may be resolved with multidimensional nucleosynthesis calculations of SNe yields (Maeda & Nomoto 2003; Nomoto, Kobayashi & Tominaga 2013).

Spectra of cool stars have several excellent lines from the neutral atom. However, they span a short range in EP. Lines of the singly ionized ion are considerably fewer and often weak.

## B2.5 Light odd-Z elements: Na, Al, K

Contrary to the α-elements, Na and Al ratios with respect to Fe in field stars increase up to [Fe/H] ~ -1.0, because their nucleosynthesis yields strongly depend on the metallicity of the

progenitor stars (Kobayashi et al. 2006). [Na/Fe] and [Al/Fe] thereafter turn over and decrease down to solar metallicity as SNe Ia contribute Fe but no Na and Al. As with O and Mg, Na and Al both show anomalies in globular clusters (e.g. Lind et al. 2011; Gratton et al. 2012; Carretta et al. 2013a). On the other hand, the chemical evolution of potassium is poorly studied as it is only accessible through one line (e.g. Carretta et al. 2013b).

There are several good Al and Na lines within our wavelength range, however, they are all of weak to moderate strength at solar metallicity. Thus, they are quite weak in metal-poor stars. In addition, the strong NaⅤ lines, listed in Table B1, can be used for measurements of interstellar reddening (e.g. Munari & Zwitter 1997). Further, in regions with low extinction and for stars with sufficiently large radial velocities, they can be used as abundance indicators for metal-poor stars.

## B2.6 Iron-peak elements: Sc, V, Cr, Mn, Co, Ni, Cu, Zn

Observationally, Sc and V approximately behave like α-elements in the disc (e.g. Adibekyan et al. 2012) but are underproduced by chemical evolution models (e.g. Kobayashi et al. 2006). Mn is extremely important for characterizing SNe Ia enrichment (e.g. Seitenzahl et al. 2013). Contrary to many elements, SNe Ia raise the [Mn/Fe] ratio (e.g. François et al. 2004). In addition, the yields from SNe Ia may be metallicity dependent (e.g. McWilliam, Rich & Smecker-Hane 2003; Kobayashi & Nomoto 2009; Travaglio et al. 2011). Cr and Ni constrain the mixing efficiency and fall-back times of SN ejecta at early times, while they later follow Fe (e.g. McWilliam et al. 1995; Bensby et al. 2014). Ni shows an interesting upturn at supersolar metallicities (e.g. Pompéia, Barbuy & Grenon 2003; Bensby, Feltzing & Oey 2014) and an interesting split between the low- and high-α component of the local halo (Nissen & Schuster 2010), which most likely comes from the fact that low-α stars are likely born in satellite galaxies and accreted into the halo (e.g. Tolstoy et al. 2009).

Zn and Co, on the other hand, constrain the explosion energy of core-collapse SNe (e.g. Kobayashi et al. 2006; Ohkubo et al. 2006), with Zn providing the strongest constraints. Finally, Cu reacts to both metallicity (like Na) and energy (like Zn). The [Cu/Fe] ratio shows an increasing trend with metallicity that does not turn-over at [Fe/H] ~ -1.0, because SNe Ia yield more Cu than Fe (e.g. Matteucci et al. 1993; Reddy, Lambert & Allende Prieto 2006).

Both Sc and V have several lines throughout the optical/near-infrared spectrum, but only ScⅡ lines are visible in metal-poor stars. Many lines of neutral Cr, Ni, and Mn are available. However, not all lines perform equally, and there are unidentified blends in some Mn lines. Zn has only a handful of lines in a limited wavelength region, which are also affected by continuum issues. There are plenty of Co lines in the optical range, however, they are mostly weak. Unfortunately, there are few useful Cu lines and these tend to be contaminated by molecular lines, which are hard to model (e.g. Simmerer et al. 2003; Bonifacio, Caffau & Ludwig 2010).

## B2.7 Neutron-capture elements: Sr, Y, Ba, Eu

The neutron-capture elements are important for furthering our understanding of the formation of heavy elements, e.g. understanding the slow (s-) and rapid (r-) neutron capture processes, putting constraints on yields from AGB stars, SN, and neutron-star mergers, as well as improving our understanding of the overall chemical evolution of our Galaxy (cf. Karakas & Lattanzio 2014, and references therein). To make progress information on more than one heavy
element is needed. It is important to study the distribution and behaviour around both the first as well as the second rapid and slow neutron-capture process peaks.

Sr and Y are excellent tracers for the weak s-process (e.g. Heil et al. 2009; Pignatari et al. 2010), while Ba primarily traces the main s-process at solar metallicity (e.g. Busso, Gallino & Wasserburg 1999; Käppeler et al. 2011). However, at low metallicity, these elements can be produced via the main r-process. The ratio [Sr/Ba] is especially important since a large spread in this ratio has been observed in metal-poor stars in the halo, which has yet to be fully explained (e.g. François et al. 2007).

The lines for Sr and Y are quite weak, and Y lines are typically very blended (especially for $R < 20\,000$). Ba, on the other hand, includes several strong lines. Several lines, however, are affected by isotopic splitting, which can be difficult to constrain (e.g. Mashonkina & Zhao 2006; Gallagher et al. 2012). Eu is produced via the r-process, but only has a single good (and weak) line in the optical, at 6645 Å. The remaining heavy elements have lines that are too weak to measure.

## B3 An aside: non-LTE effects

As with Fe, the lines of many elements can suffer from significant 3D and NLTE effects. NLTE effects in FGK stars have already been studied in detail for many elements (see, e.g. Mashonkina 2014, and references therein). It is beyond the scope and purpose of this paper to list the details of these effects, and how they can affect the interpretation of trends in Galactic chemical evolution models, for each individual element. However, it is important to keep these issues in mind when developing the line list.

## B4 The final line list

To source lines, we used the following material as a starting point: working material from Caffau et al. (2013), Bensby et al. (2014), Fulbright (2000), Johnson (2002), and two line lists for short regions

of horizontal branch stars in metal-rich globular clusters (Feltzing, Primas & Johnson 2009, Simmerer, private communication). All of these lists include well-behaved lines used for successful analysis in the quoted studies (at their given *R* and SNR). In addition, we also included lines from the Gaia-ESO Survey (Heiter et al. in preparation) and the line list used for the optimization for HERMES (Freeman, private communication). A first list was compiled by simply merging these different line lists. The lines in this list were then critically evaluated, very weak lines were culled and each line was given a weight.

The lines were first visually inspected in synthetic spectra convolved to a resolution of $R \sim 20\,000$ (i.e. lower than in some of the studies used to source the list) for a TO star ($T_{\text{eff}} \sim 6500$ K), an MS star ($T_{\text{eff}} \sim 5800$ K), and an RC star ($T_{\text{eff}} \sim 5000$ K), each covering three different metallicities (solar, -0.5 dex, -1.0 dex, respectively). The lines were appraised according to three main criteria (strength, general appearance of the wavelength region and blends) and then given a weight based on this information. The strength was judged on how deep the decrement was at solar metallicity. In general, lines with a decrement of 0.8 (where the continuum is at 1.0) were kept. Potential blends were inspected and in particular we looked for a broadening or skewness of the line. If a line was both deemed suitable for all three metallicities and types of stars then the weight was set to $w = 1$. If only suitable for one stellar type, the weight was set to $w = 2$. If the region is complex, due e.g. to telluric contamination or auto-ionizing bands, this was flagged. Thereafter, the lines were synthesized with and without blends at the same resolution and compared to very high quality spectra of the Sun and Arcturus, to thoroughly assess their blending properties and astrophysical performance. The weights of the lines were adjusted during this process.

The final line list comprises all lines that were appraised between 4500 Å and about 8000 Å, and is shown in Table B2. Note that this line list does not include all lines that can give some abundance information. It includes only those lines that have been used in previous well-established studies and passed our inspection. Obviously, this list can be augmented for specific purposes, for other

<table><caption>Table B2. Final compiled line list for the analysis of FGK stars in the Milky Way.</caption><thead><tr><th>Species</th><th>λ (Å)</th><th>EP</th><th>log(gf)</th><th>w</th><th>f<sub>gf</sub></th><th>f<sub>b</sub></th><th>f<sub>s</sub></th><th>Reference</th></tr></thead><tbody><tr><td>Mg I</td><td>5167.3216</td><td>2.709</td><td>-0.931</td><td>2</td><td>1</td><td>1</td><td>3</td><td>Aldenius et al. (2007) <sup>c</sup></td></tr><tr><td>Mg I</td><td>5172.6843</td><td>2.712</td><td>-0.450</td><td>1</td><td>1</td><td>1</td><td>3</td><td>Aldenius et al. (2007) <sup>i</sup></td></tr><tr><td>Mg I</td><td>5183.6042</td><td>2.717</td><td>-0.239</td><td>1</td><td>1</td><td>1</td><td>3</td><td>Aldenius et al. (2007) <sup>i</sup></td></tr><tr><td>Ca I</td><td>6162.1730</td><td>1.899</td><td>-0.090</td><td>1</td><td>1</td><td>1</td><td>3</td><td>Smith & O'Neill (1975)</td></tr><tr><td>Li I</td><td>6707.7635</td><td>0.000</td><td>-0.002</td><td>1</td><td>1</td><td>1</td><td>3</td><td>Yan, Tambasco & Drake (1998)</td></tr><tr><td>Li I</td><td>6707.9145</td><td>0.000</td><td>-0.303</td><td>1</td><td>1</td><td>1</td><td>3</td><td>Yan et al. (1998)</td></tr><tr><td>C I</td><td>5380.3252</td><td>7.685</td><td>-1.615</td><td>1</td><td>1</td><td>1</td><td>1</td><td>Hibbert et al. (1993)</td></tr><tr><td>C I</td><td>6587.6100</td><td>8.537</td><td>-1.021</td><td>1</td><td>1</td><td>1</td><td>1</td><td>Hibbert et al. (1993)</td></tr><tr><td>O I</td><td>6300.3038</td><td>0.000</td><td>-9.715</td><td>2</td><td>1</td><td>0</td><td>2</td><td>Storey & Zeippen (2000); Froese Fischer & Tachiev (2012) <sup>a</sup></td></tr></tbody></table>

This table is published in its entirety in the electronic edition of the MNRAS. A portion is shown here for guidance regarding its form and content.

<sup>a</sup>Tellurics.

<sup>b</sup>Weak.

<sup>c</sup>Blended.

<sup>d</sup>Two blended lines of same species.

<sup>e</sup>Partly or weakly blended.

<sup>f</sup>Wing of a strong line.

<sup>g</sup>Overestimated theoretical blend.

<sup>h</sup>Unidentified blend.

<sup>i</sup>Continuum issue.

<sup>j</sup>Blended with Fe I.

<sup>k</sup>Possible bad log(gf).

<sup>l</sup>Ca autoionization.
types of objects and other science goals. It can also be extended to bluer and redder wavelengths.

The first column gives the element species and ion, while the following three columns give the central wavelength (λ) in Å, the EP, and oscillator strength (log(gf)), respectively. The atomic data were compiled as part of the Gaia-ESO Survey (Heiter et al., in preparation), and the references for these values are given in the final column of the table.

The final weight (*w*) prescribed to each line is listed in the fifth column, which is followed by several flags that contributed to this final weight. The first flag ($f_{gf} = 1, 2, 3$) reflects the quality on the log(gf) value, where $f_{gf} = 1$ implies the highest quality. The availability of Anstee, Barklem and O'Mara (ABO; Anstee & O'Mara

1991, 1995; Barklem & O'Mara 1997; Barklem, O'Mara & Ross 1998) cross-section data for collisional broadening by hydrogen for each line is given by the second flag, $f_b = (0, 1)$. A value of 1 equals 'yes', while a value of 0 means 'no'. The last flag, $f_s = (1, 2, 3)$, indicates the stellar type for which each line is measurable. A value of 1 means the line can be measured in a dwarf-like star, while a value of 2 means the line can be measured in a giant. If the line is measurable in both types of stars, $f_s = 3$. Further comments to some of the lines are given as footnotes to the table.

This paper has been typeset from a TeX/Latex file prepared by the author.