Stars play a decisive role in our Universe from its beginning throughout its complete evolution. For a thorough understanding of their properties evolution and physics of their outer envelopes stellar spectra need to be analyzed by comparison with numerical models of their atmospheres. We discuss the foundations of how to calculate such models in particular density and temperature stratification affected by convective energy transport in lowmass stars which requires a parallel treatment of hydrodynamics thermodynamics and radiative transfer. We stress the impact of emissivities opacities and particularly their ratio source function and summarize how these quantities are calculated either adopting or relaxing the assumption of LTE local thermodynamic equilibrium. Subsequently we discuss the influence and physics of stellar winds and their various driving mechanisms as a function of stellar type rotation magnetic fields inhomogeneities and multiplicity. Finally we outline the basics of quantitative spectroscopy namely how to analyze observed spectra in practice.
['Astrophysics - Solar and Stellar Astrophysics', 'Astrophysics - Instrumentation and Methods for Astrophysics']
Stellar Atmospheres
{'Joachim Puls ,a , Artemio Herrero b,c and Carlos Allende Prieto c,b': "a LMU Munich, University Observatory, Scheinerstr. 1, D-81679 Munchen, Germany  \nUniversidad de La Laguna, Departamento de Astrof'ısica, Avda. Astr. Francisco S'anchez, E-38206 La Laguna, Spain  \nb c Instituto de Astrof'ısica de Canarias, C/ Via L'actea s/n, E-38206 La Laguna, Spain  \n© 20xx Elsevier Ltd. All rights reserved.  \nChapter Article tagline: update of previous edition,, reprint..", 'Glossary': 'corona outermost, extended region of a (low-mass) star such as the Sun, with very high temperatures (millions of Kelvin) and low densities. chromosphere transition zone between photosphere and corona.  \nphotosphere outer region of a star where most of the optical light (and from other wavelengths) originates from. Geometrically thin compared to the stellar radius, with temperatures on the order of the e ff ective one.  \nquantitative spectroscopy derivation of stellar atmospheric parameters, incl. chemical surface abundances, by means of comparing observed and synthetic spectra.  \nspecific intensity basic quantity in radiative transfer, proportional to transported energy, direction-dependent.  \nspectral lines narrow absorption or emission features in a spectrum, resulting from electronic transitions between two bound levels. stellar atmosphere outer region of a star where all emitted light is produced. Comprises photosphere, and, if present, chromosphere, corona, and wind.  \nstellar wind mass outflow from a star.', 'Nomenclature': 'CMF  \ncomoving frame  \nLTE  \nlocal thermodynamic equilibrium  \nNLTE  \nnon-LTE, or kinetic equilibrium  \nRE  \nradiative equilibrium  \nRT  \nradiative transfer  \nRMHD  \nradiation magneto-hydrodynamics  \nSED  \nspectral energy distribution  \nSN, SNe  \nsupernova(e)  \nTE  \nthermodynamic equilibrium  \nUV  \nultraviolet  \nStars play a decisive role in our Universe, from its beginning throughout its complete evolution. For a thorough understanding of their properties, evolution, and physics of their outer envelopes, stellar spectra need to be analyzed by comparison with numerical models of their atmospheres. We discuss the foundations of how to calculate such models (in particular, density and temperature stratification, affected by convective energy transport in low-mass stars), which requires a parallel treatment of hydrodynamics, thermodynamics and radiative transfer. We stress the impact of emissivities, opacities, and particularly their ratio (source function), and summarize how these quantities are calculated, either adopting or relaxing the assumption of LTE (local thermodynamic equilibrium). Subsequently, we discuss the influence and physics of stellar winds (and their various driving mechanisms as a function of stellar type), rotation, magnetic fields, inhomogeneities, and multiplicity. Finally, we outline the basics of quantitative spectroscopy, namely how to analyze observed spectra in practice.', 'Key Points': '- · The theory of stellar atmospheres provides us with physical models for the outermost stellar envelopes, and quantifies, in dependence of atmospheric parameters, the run of, e.g., density, velocity, temperature, radiation field, ionization / excitation of atoms, ions, molecules.\n- · Such models base on a radiation (magneto-)hydrodynamic and thermodynamic description, either simplified (one-dimensional, static, steady-state), or, if required, accounting for convection, outflows, rotation, magnetic fields, and inhomogeneities (partly multi-D).\n- · Atmospheric models are utilized to synthesize the emergent SEDs, that will be compared with observations to infer the stellar (and, if present, wind) parameters, as well as the chemical surface composition.\n- · The ionization / excition balance of the atmospheric atoms, ions, and molecules is calculated either under the assumption of LTE, or, if the impact of the radiation field dominates over collisional processes, accounting for deviations from LTE ( = non-LTE).\n- · Stellar outflows ( = winds) modify the outermost atmospheres and the emergent SEDs. The majority of stellar winds are accelerated either by gas pressure forces (when a hot corona is present), or by radiation pressure forces (for luminous and / or hot stars).', '1 Introduction': 'Most of the information we collect from objects and regions beyond the Solar System is carried by photons, and most of these photons are generated in stellar interiors and transported throughout the stars. In their journey to the outer stellar layers (atmospheres), they change their properties and finally escape, after a last interaction with the atmospheric atoms and molecules. Leaving the star behind, photons travel to us, sometimes su ff ering additional interactions in the nearly void interstellar medium, until they reach our instruments.  \nThis information has to be interpreted with models describing the physical processes that photons have been subject to. With this formulation, we can recover the physical conditions that generated the observed photons, and gather required knowledge about the conditions inside stellar envelopes (temperatures, densities, pressures, chemical composition, etc.) and also about the properties of stellar interiors.  \nEvery photon counts for the analysis, but it is their spectral energy distribution (SED) that contains the record of the physical processes involved. Thus, the better this distribution is known, the better we can describe those physical processes. A condensed description of this distribution (usually called photometric information) provides the basic information about the star, but describing its detailed distribution (the spectroscopic information) requires an accurate formulation of the physical laws governing stellar atmospheres. The process of extracting the physical quantities and magnitudes present in the system by analyzing the observed detailed distribution of photons is what we call quantitative spectroscopy .  \nThe theories of radiative transfer and stellar structure are continously tested and challenged through quantitative spectral analyses of stellar atmospheres, both in individual systems and in increasingly larger stellar samples. Joint studies of stars in the same cluster or association, or of similar nature (like Blue or Red Supergiants, high-mass X-ray binaries or extremely metal poor stars, to mention only few) test and extend our knowledge of the theory of stellar formation, structure and evolution, and inform us about the fate of the di ff erent stars and stellar systems. This way they provide us with quantitative information about the mechanical and radiative energy injected into their environments and host galaxies, including ionizing fluxes and newly synthesized elements. Combining this information with observations of distant galaxies and very old stars, we can build a scenario of cosmic evolution, also via exploiting the information contained in the observation of extreme events, like supernovae (SNe), gamma-ray bursts and black hole mergers.  \nAll this knowledge relies on the accuracy of analyses of the light emitted by stellar atmospheres: hot plasmas with strong physical gradients kept bound by the action of gravity, but subject to rotation, magnetic fields, radiation pressure, and (radiation-magneto)hydrodynamic instabilities giving rise to spatial inhomogeneities. Within this framework, we have to describe the interaction of photons and matter at atomic and molecular level.  \nThis is the subject of the theory of stellar atmospheres, and has to invoke a variety of building blocks from our physical theories. Many authors have contributed to its development and current status (see the introductory chapters in classical (text)books 1 like Payne (1925), Unsold (1955), Aller (1963), Mihalas (1978), Gray (2021), and Hubeny and Mihalas (2015, H&M), rendering the Theory of Stellar Atmospheres a corner stone for our knowledge of the Universe. A brief exposure of the foundations of this theory is the purpose of the present chapter.', '2 Basic Considerations': 'In this section, we will introduce the major assumptions, definitions, and techniques required to model stellar atmospheres. Since these will strongly depend on the considered stellar type (cool vs. hot, compact vs. extended) and the absence or presence of a mass outflow (wind), a variety of concepts needs to be discussed. A particular di ffi culty arises since in almost all cases the coupling of matter with the radiation field must be accounted for, which requires accounting for radiative transfer (RT), and increases significantly the computational e ff ort.', '2.1 Hydrostatic and Hydrodynamic Structure': "We begin with a description of the density structure. Under typical conditions (except for coronae), atmospheric plasmas behave as ideal gases, and (kinematic) viscosity terms are small (e.g., Cowley 1990) and mostly negligible. In this case, the hydrodynamic equations of continuity (i) and momentum (ii, 'Euler equation') read (with boldface indicating vectors)  \n(i) ∂ρ ∂ t + ∇ · ( ρ u ) = 0 , (ii) ∂ρ u ∂ t + ∇ · ( ρ u ⊗ u ) = -∇ p + ρ g ext , (1)  \nwith density ρ , velocity u , gas pressure p and external accelerations g ext , and ⊗ the dyadic (or outer) product. In many cases, atmospheres are adopted as stationary (steady-state, time-independent), and a 1-D approximation is applied (but see below), either with plane-parallel symmetry and height coordinate z (if the extent of the atmosphere is small compared to the stellar radius, R ∗ ), or with spherical symmetry and radial coordinate r (if the extension is large, often because of the presence of a wind or very low gravity). Furthermore, if velocity fields can be neglected, the Euler equation collapses to the equation of hydrostatic equilibrium , d p / d z = ρg ext , stating that the pressure force needs to be balanced by external forces. Under simplifying assumptions (neglect of radiative acceleration, T ( r ) ≈ T phot with T phot a representative value), this equation can be solved analytically 2 by means of the ideal gas equation of state, P = Nk B T with particle density N , Boltzmann  \nFig. 1 Density stratification as a function of column density ( d m = -ρ d z or d m = -ρ d r ), for an O-star with T e ff = 35,000 K and log g = 4.0 (cgs-units). Solid: hydrostatic stratification from TLUSTY (see Sect. 4.2), dashed: hydrodynamic stratification with a wind of intermediate strength from FASTWIND. When plotted as a function of m (or optical depth τ ), the outer densities (low column densities) for a wind-model are lower than for a hydrostatic one. Since the cores of strong lines form already at m > 0 . 01 , in this case the wind would need to be considered in an analysis (see Sect. 3.1).  \n<!-- image -->  \nconstant k B and temperature T . The solution is the well-known barometric formula ,  \nP ( z ) = P ( z 0) exp GLYPH<16> -( z -z 0) H GLYPH<17> or ρ ( z ) = ρ ( z 0) exp GLYPH<16> -( z -z 0) H GLYPH<17> with H = k B T phot µ m H g ∗ = 2 v 2 s v 2 esc R ∗ , g ∗ = GM ∗ R 2 ∗ (2)  \nwhere H is the (photospheric) scale height , µ the mean molecular weight in units of hydrogen atomic mass m H, v s = p k B T / ( µ m H) the isothermal speed of sound, v esc = p 2 g ∗ R ∗ the photospheric escape velocity, and g ∗ the photospheric gravitational acceleration, with gravitational constant G . For the sun, the scale height is roughly 150 km, for a typical O-dwarf with a surface temperature of 35,000 K it is 4500 km, while for a Red Supergiant it easily exceeds 10 6 km.  \nIf we now include the presence of an outwards directed velocity field ( v ( r ) > 0), and still require stationarity, a spherically symmetric 1-D description predicts the presence of a mass-flux, a stellar wind 3 ,  \n(i) r 2 ρv ( r ) = const = ˙ M 4 π , (ii) ρv ( r ) d v d r = -d p d r + ρg ext ( r ) , (3)  \nwith ˙ M the stellar mass-loss rate. The left-hand side (lhs) of the equation of motion , Eq. 3(ii), is the advection term, resulting from inertia. A detailed comparison of the hydrostatic and hydrodynamic description reveals that both formulations become similar for low velocities v ( r ) ≪ v s, i.e., that also in case of a stellar wind the deep photosphere becomes quasi-hydrostatic, though with a non-zero velocity controlled by Eq. 3 (i).  \nStationary 1-D atmospheric models including both photosphere and wind can be constructed in two ways. One possibility consists of integrating the equation of motion by accounting for all relevant external accelerations 4 , detailed in Sect. 3.1. Approximate models (see Fig. 1), on the other hand, smoothly connect a (quasi-)hydrostatic subsonic solution with a prescribed wind-velocity law and an input mass-loss rate, such that the innermost velocities are calculated from ˙ M and ρ ( r ), whereas the wind densities result from ˙ M and v ( r ).  \nBecause of increasing computational power, a variety of multi-dimensional (multi-D) atmospheric models have been considered. For cooler type stars, this is mostly to investigate the e ff ects of convection and pulsations, and for hotter type stars to investigate the role of inhomogeneities and rotation in their winds, while the impact of magnetic fields has to be considered in both cases.", '2.2 Radiative Transfer (RT)': "As already mentioned, various radiation field related quantities need to be known to calculate model atmospheres and corresponding synthetic spectra. The fundamental quantity is the specific intensity I ( r , n , ν, t ) being the radiation energy with frequencies within ( ν, ν + d ν ), which is transported through a projected area element d σ cos θ into direction n (with θ the angle between the surface normal and the  \npropagation direction), per time interval d t and solid angle d Ω , such that the transported energy is given by  \nd  \nE  \n=  \nI  \n(  \nr  \n,  \nn  \n, ν,  \nt  \n) cos  \nθ  \nd  \nσ  \nd  \nν  \nd  \nt  \nd  \nΩ  \n.  \n(4)  \nBy definition, the specific intensity remains constant between an emitting and receiving area (e.g., a telescope), as long as there is no absorption and emission in between. Otherwise, and in the absence of general relativistic e ff ects 5 (i.e., photons move on straight lines at constant frequency), the equation of radiative transport (RT) reads  \nGLYPH<16> 1 c ∂ ∂ t + n · ∇ GLYPH<17> I ν = ην -χν I ν, (5)  \nwhere the arguments ( r , n , t ) have been omitted. ην is the macroscopic emissivity, and ην d s is the specific intensity added by emission along a path-length d s (with n · ∇ = d / d s ). χν is the macroscopic opacity, such that χν I ν d s is the specific intensity removed by absorption or scattering. Further details will be discussed in Sect. 2.4.  \nBecause of the directional derivative and without any specific symmetry, two directional angles have to be accounted for. If non-Cartesian coordinates were used (e.g., spherical ones), these angles change with location, and the above equation becomes a partial di ff erential equation with six(!) independent variables, to be solved for each frequency ν . This immediately reveals that any radiation-hydrodynamics problem su ff ers from a bottleneck established by RT, and approximate methods are required for reasonable turnaround times.  \nAfter solving the RT equation for I ν (in most cases, numerically), one can integrate the specific intensity over d Ω / (4 π ), over n d Ω , and over nn d Ω to obtain the mean intensity, J ν , the radiative flux, F ν and the radiation stress tensor, P ν , respectively, which are inevitable quantities when considering, e.g., scattering and photoionization, radiative acceleration, and radiative pressure.  \nAssuming stationarity and either (i) plane-parallel or (ii) spherical geometry, the number of independent variables becomes significantly reduced, and the corresponding equations read  \n(i) µ d d z I ν ( z , µ ) = ην -χν I ν, (ii) GLYPH<16> µ ∂ ∂ r + 1 -µ 2 r ∂ ∂µ GLYPH<17> I ν ( r , µ ) = ην -χν I ν. (6)  \nwhere µ = cos θ . A clever way to get rid of the ∂/∂µ derivative in Eq. 6 (ii) is to use a so-called p-z geometry (Hummer and Rybicki 1971, see also Crivellari et al. 2019, Chapter 5), where the RT equation is solved along impact parameters p for 'height' coordinates z , and the directional derivative from Eq. 5 collapses to d / d z | p along p = const. Often, the dimensionless optical depth (here for (i) Cartesian and (ii) spherical coordinates)  \n(i) d τν = -χν d z , τν ( z ) = Z ∞ z χν ( z )d z , (ii) d τν = -χν d r , τν ( r ) = Z ∞ r χν ( r )d r , (7)  \nis introduced, where τν ( ∞ ) = 0 at the outer boundary. In both cases, τν is better suited to act as a spatial 'coordinate' than z or r . Dividing Eq. 6 (i) by ( -χν ), we obtain (in plane-parallel symmetry)  \nµ d I ν ( z , µ ) d τν = I ν -S ν, S ν = ην χν , S TE ν = B ν ( T ) = 2 h ν 3 c 2 1 e h ν k B T -1 , (8)  \nwith source function S ν . The Kirchho ff -Planck law states that in thermodynamic equilibrium (TE) the source function is given by the Planck function ( h is the Planck constant), i.e., that under TE conditions the emissivity can be simply calculated from the opacity and temperature. Eq. 8 (left) can be easily integrated, and for a 'semi-infinite' atmosphere (with τν = (0 , ∞ ) at the surface and bottom of the atmosphere, respectively, and I ν ( τν ) exp( -τν ) → 0 for τν →∞ ), the specific intensity at the outer boundary and µ > 0 (the so-called emergent intensity ) results as  \nI em ν ( µ ) = I ν ( τν = 0 , µ > 0) = Z ∞ 0 S ν ( t )e -( t /µ ) d t µ . (9)  \nThis solution - the emergent intensity is just the Laplace-transform of the source function - shows clearly the major role of the latter in atmospheric calculations where the lower atmosphere is typically located at large optically depths (high densities, τν ≫ 1). It is thus su ffi cient to know S ν as function of optical depth to solve for the emergent intensity. The importance of S ν becomes also evident when solving Eq. 9 by approximating the source function to be linear in τν , which results in the so-called Eddington-Barbier relation ,  \nI em ( µ ) ≈ S ν ( τν = µ ) . (10)  \nν  \nThis relation states that, e.g., for vertical rays ( µ = 1) 'we see' just the source-function at τν = 1. In particular, it explains stellar limbdarkening of photospheres: for decreasing µ (center to limb), the specific intensity decreases, since the source function (evaluated at τν = µ ) usually decreases outwards with height (e.g., in the simple case that S ν ≈ B ν ( T ) with outwards decreasing T , see Fig. 2). As well, the above relation explains the absorption seen in spectral lines, since their opacity is larger than in the neighbouring continuum, i.e., τν = 1 is reached further out in the photosphere, implying a lower source-function and thus lower intensities in the lines.  \nOne major problem might appear when including velocity fields into the RT equation, In principle, all opacities and emissivities need to be evaluated at the comoving ( = atomic) frame frequency (CMF), i.e., accounting for Doppler-shifts between the inertial, observer's restframe and the comoving material, ν CMF ≈ ν obs(1 -n · u / c ) in the non-relativistic approximation (note the projection!). For comparatively  \nFig. 2 Sketch of limb darkening. Because of an outwards decreasing source-function (see text), the emergent intensity decreases from the center to the stellar limb (cf. Eq. 10).  \n<!-- image -->  \nlow velocities (e.g., winds from Red Supergiants) this is usually not a problem. For superthermal speeds ( v > v th, typical for winds from hot massive stars), however, a very high radial and often also angular grid resolution would be required, to resolve the transfer in the most relevant line-cores, which are Doppler-broadened with a width corresponding to the thermal velocity (see Sect. 2.4.1). In e ff ect, a solution in the observer's frame becomes very time-consuming. There are various possibilities to circumvent this problem. Often, the RT equation is solved in the CMF, which however is only advantegeous when the velocity field is monotonic. For details regarding the spherical symmetric 6 and the general case (multi-D, relativistic), we refer to H&M and references therein.  \nAn alternative approach is given by the so-called Sobolev theory (Sobolev, 1960), which aims at an analytical solution of the linetransfer problem in rapidly expanding atmospheres. This approximation makes advantage of the fact that because of the low thermal speed compared to the bulk velocities, the geometrical extent of a zone where stellar radiation can interact with a line-transition from a moving ion (the so-called resonance zone) is quite narrow, of order L Sob( r ) = v th / (d v/ d r ). In the original approach, all quantities except for the velocity gradient are then approximated as being constant within such a resonance zone. The line-profile weighted and frequency integrated specific intensity, ¯ I , which is central to many applications (line source function and radiative line acceleration) then becomes a purely local quantity, and can be easily calculated. An excellent presentation of the complete approach has been given by Rybicki and Hummer (1978), and for a summary of how to include additional e ff ects we refer to Crivellari et al. (2019, Chap. 5).", '2.3 Energy Transport': 'In order to derive the atmospheric hydrodynamic structure, and the opacities and emissivites controlling the radiation field ( → radiatitive acceleration g rad), we need to know the temperature stratification (under TE conditions, this would provide us with the source function). The temperature stratification results from the total (matter + radiation) energy equation, which in stationary and static ( u = 0) atmospheres (for time-dependent and / or hydrodynamic conditions, see H&M) collapses to  \n∇ · [ F + F c + F conv + . . . ] = 0 , i.e., either X F = const (plane-parallel sym.) or r 2 X F = const (spherical sym.) . (11)  \nF c and F conv are the conductive and convective fluxes, and the dots leave room for any other energy transport, e.g., by waves and pulsations. The above equation clearly shows that the sum of all transported energies remains constant, since there are no energy sources.', 'Radiative Atmospheres': "In most stellar atmospheres, the conductive fluxes can be neglected compared to the others, with the notable exception of specific environments where the conductivity is large, e.g., coronae and White Dwarfs (degenerate material). Moreover, velocity fields do not play a decisive role for the energy equation, as long as v/ c ≪ 1. We first concentrate on those atmospheres where the energy is transported, to the largest part, by radiation, i.e., on stars roughly more massive than 1.3 M ⊙ . When integrating the RT equation (Eq. 5) over solid angle and frequency, one obtains the energy equation for the radiation field (again adopting v ≪ c ), which for stationary conditions relates the radiative flux with the radiative cooling and heating rates, Λ and H (first equation below). For the considered case of purely radiative energy transport, flux conservation (Eq. 11) then implies  \n∇ · F = Z ∞ 0 d ν I d Ω ( ην -χν I ν ) = Λ - H ! = 0 → L = 4 π r 2 F ( r ) = 4 π R 2 ∗ F ( R ∗ ) = 4 π R 2 ∗ σ B T 4 e ff = const . (12)  \n<!-- image -->  \nFig. 3 Temperature stratifications as a function of τ R , for an A-type dwarf model (left) at T e ff = 8000 K and log g = 4.0, and for a solar-type model ( T e ff = 5780 K and log g = 4.44), right. The approximate stratification Eq. 14 (right) for radiative envelopes is displayed in red, and the 'exact' stratification from a plane-parallel, hydrostatic MARCS atmosphere (see Sect. 4.2) in black. Whilst the appproximate radiative stratification matches the exact one quite well for the A-star model, large differences at high optical depths are visible for the solar-type model, because of a convective stratification in the lower photosphere (and below).  \n<!-- image -->  \nHere we have defined the stellar luminosity, L (with units Js -1 ) and the e ff ective temperature, T e ff , the latter as that temperature where the frequency integrated Planck-function (times π , to account for the corresponding flux) equals the photospheric flux F ( R ∗ ) (with σ B the Stefan-Boltzmann constant). Both the first ( ∇ · F ) and the alternative formulation ( Λ - H ) in Eq. 12 can be used to derive the atmospheric temperature structure in an iterative way, until the required condition ( = 0) is fulfilled. Flux conservation is usually utilized at large optical depths, whereas the second formulation, 'radiative equilibrium' (considered at low optical depths), states that the absorbed energy must equal the emitted one. For first estimates and a basic understanding, one might assume opacities and emissivities to be frequency independent ('grey'), and couple the frequency-integrated equation of RT, of its first moment (see textbooks), and of radiative equilibrium together with some minor approximations to obtain  \nT 4 ( τ grey) ≈ 3 4 T 4 e ff ( τ grey + 2 3 ) with τ grey = Z ∞ z χ greyd z . (13)  \nBy introducing the widely used Rosseland mean opacity , defined in such a way as to replace the above grey approximation by a more physical one based on the di ff usive character of the radiation field at large optical depths (for details, see any textbook)  \n1 ¯ χ R = h Z ∞ 0 1 χν ∂ B ν ∂ T d ν i / h 4 σ B π T 3 i → T 4 ( τ R) ≈ 3 4 T 4 e ff ( τ R + 2 3 ) , (14)  \nthe temperature structure is now expressed in terms of a meaningful optical-depth scale. By construction, the Rosseland mean can be calculated without any radiative transfer, and the harmonic weighting of the individual contributions accounts for the fact that the maximum flux is transported in those frequency regions where χν is small.  \nThe above temperature stratification is close to being exact at large optical depth ( τ R > ∼ 3 . . . 5), but predicts all major trends also at lower values (see Fig. 3, left panel) 7 . In particular, the temperature becomes equal to T e ff at τ R = 2 / 3, which is sometimes used, via Eq. 12, to define the stellar radius, namely R ∗ = r ( τ R = 2 / 3). A generalization of these results towards spherically extended atmospheres has been given by Lucy (1971).", 'Convective Envelopes': "Under conditions typically valid for low-mass star envelopes, convection becomes the dominant type of energy transport. When radiative energy transport is the only competing process, we find (adopting stationary, static and plane-parallel conditions)  \n∇ · [ F rad + F conv ] = 0 ⇒ d F conv d z = -F rad d z = -Z ∞ 0 d ν I d Ω ( ην -χν I ν ) = -4 π Z ∞ 0 d νχν ( S ν -J ν ) = H Λ , (15)  \nFig. 4 Temperature stratifications as a function of τ 500nm for the Sun as given by a 1D theoretical model from Kurucz (M'esz'aros et al., 2012, blue), the semi-empirical Holweger-Muller model (Holweger and Mueller, 1974, black-dashed), spatially resolved profiles from a snapshot of a 3D hydrodynamical simulation (Caffau et al., 2011, grey) and their spatial average (red).  \n<!-- image -->  \ni.e., an imbalance between radiative heating and cooling. In a simple picture, the heat content of lower regions is transported by 'bubbles' towards outer regions, where these bubbles dissolve and release their excess energy. The driving force for the outward propagation of these bubbles is buoyancy, as long as the bubble has a lower density than the ambient medium. Under the assumption of pressure equilibrium (requiring slow - compared to the speed of sound - convective velocities) and no energy exchange with the ambient medium (adiabatic change of state inside the bubbles), one can formulate a (simplified) criterion for convection to take place, the so-called Schwarzschild criterion 8  \n∇ a = d ln T a d ln p > 1 -1 Γ ad = ∇ ad . (16)  \nHere, the Nablas are the conventional thermodynamic derivatives, 'a' means ambient, 'ad' means adiabatic (for the bubbles), and Γ ad is the adiabatic exponent. If this condition is not fulfilled, the stratification becomes radiative, and ∇ a →∇ rad, where the latter can be estimated from the pressure scale height H (Eq. 2) and the temperature stratification (approximated in Eq. 14). For massive and other hot stars, hydrogen (as the major constituent) is completely ionized, and ∇ ad ≈ 0 . 4 turns out to be larger than ∇ rad throughout the complete atmosphere. Consequently, hot star atmospheres are convectively stable, at least under typical conditions (but see Sect. 3.3). On the other hand, in the outer photospheres of cool stars, hydrogen is neutral, but becomes ionized at larger depths. In this case, ∇ ad decreases, with a minimum of 0.07 when 50% of hydrogen is ionized. For the Sun, this occurs around 9,000 K, and ∇ ad < ∇ rad, indicating convection is active. Ionization changes of elements other than hydrogen may also contribute to the appearance of convective zones.  \nIf an atmosphere turns out to be convectively unstable, convective transport needs to be included in the modeling. This can be done either in an approximate way, or by expensive 3-D radiation-hydrodynamic simulations. The first possibility (still applied in many numerical codes, both for atmospheric and for stellar structure / evolution models) bases on the so-called mixing length theory (MLT), first suggested by Prandtl (1925). Within this approximation, the various gradients are calculated in an iterative way (e.g., H&M), from the condition of total flux (radiative + convective) conservation, accounting for radiative losses during the lifetime of a mass element. For low radiative losses, ∇ a →∇ ad ('e ffi cient convection'), and for (very) large losses, ∇ a →∇ rad ('ine ffi cient convection'). Fig. 3 (right panel) shows a comparison between the temperature structure for a solar-type atmosphere with (black) and without (red) convection.  \nMulti-D radiation-hydrodynamic simulations allow for a (much more) precise treatment, but can be performed for only few, representative frequency bins, due to the extremely time consuming multi-D RT to calculate the radiative heating and cooling terms ( H Λ , 0 for convection). These approaches were pioneered in the late 1980's (Stein and Nordlund, 1989; Ste ff en and Freytag, 1991), and a prominent application is the comparison with observational data from the Sun (limb-darkening, line-profile shifts / variations, granulation patterns), and the re-determination of the solar abundance pattern (Asplund et al., 2009; Ca ff au et al., 2011).  \nFigure 4 illustrates the thermal stratification of a plane-parallel 1D model atmosphere for the Sun, a semi-empirical 1D model, and the average thermal structure from a snapshot of a hydrodynamical solar simulation. The grey curves correspond to spatially-resolved stratifications across the 3D snapshot, and illustrate the horizontal inhomogeneities of the simulation. Hydrodynamical models of cool atmospheres remove the need for parameters such as micro and macro-turbulence (see Sect. 3.3), and predict line profiles that are usually  \nblueshifted and asymmetric, much like the observed ones. As for the Sun, thermal inhomogeneities lead also in many other cases to changes in the inferred elemental abundances and isotopic ratios. Various grids of hydrodynamical model atmospheres for cool stars covering typical parameter ranges with di ff erent metallicities are available (see, e.g., Ludwig et al. 2009; Magic et al. 2013; Rodr'ıguez D'ıaz et al. 2024).", 'Cromospheres and Coronae': 'The outermost layers of a low-mass star, sometimes called the upper atmosphere , can be split into the chromosphere and the corona , with an area in between known as the transition region . In these layers the pattern of decreasing temperature seen in the underlying photosphere is reversed and, for example, in a star like the Sun, the average temperature increases from a few thousand Kelvin at the top of the photosphere to millions of Kelvin in the corona, accompanied by a continuosly decreasing density. In this tenous environment, photons can travel far from where they have been emitted before they are absorbed, greatly enhancing departures from local thermodynamical equilibrium (Sect. 2.5), and magnetic fields play a prominent role. The optical and near-infrared spectra of cool stars are mostly formed in the photosphere, and hints of the existence of the upper atmosphere are typically only apparent in the cores of the strongest lines, such as H α or the Ca ii H and K lines. On the contrary, the upper atmosphere starts to manifest itself in the near UV, and dominates the solar spectrum in the vacuum UV, whereas the corona shows emission lines of extremely ionized metals (e.g., Fe xvii ). The detailed heating mechanism (likely related to the dissipation of acoustic and magneto-hydrodynamic waves) is still subject of current research, but we note here that because of the low densities, the corona does not need to be included into a photospheric modeling (though there is a certain impact from the cromosphere).', '2.4 Opacities and Emissivities': 'The most important quantities required to perform radiative transfer are opacities and emissivities. Basically, these are the sums of all individual contributions at a given frequency, and can be calculated from the cross-sections (atomic / molecular physics) times the occupation numbers (number densities of atoms and molecules populating each of the absorbing and emitting levels). For the line case, (normalized) profile functions are required as well, providing the probabilities for an absorption / emission event at frequencies away from the line center. In addition, scattering processes need to be accounted for.', '2.4.1 Line Processes': "For transitions between bound levels, the individual line opacities and emissivities can be calculated from  \nχ line ν = h ν ul 4 π ϕ ( ν ) h n l B lu -n u B ul ψ ( ν ) ϕ ( ν i , η line ν = h ν ul 4 π ψ ( ν ) n u A ul , (17)  \nwhere ν ul is the frequency at line center, ϕ and ψ are the absorption and emission profile functions, n the occupation number densities for the lower ('l') and upper ('u') levels of the considered transition, and B lu , B ul , A ul the Einstein coe ffi cients (atomic properties closely related to the transition probability, and independent of the thermodynamic state) for absorption, induced and spontaneous emission, respectively. Induced emission is included here as negative absorption. Under typical conditions in stellar atmospheres (no correlation between absorbed and emitted frequencies, so-called complete redistribution , see textbooks), ψ → ϕ . From simple arguments, it is easy to show that there are two relations connecting the three Einstein coe ffi cients, and only one needs to be known for the line opacity / emissivity; the line source function does not depend on any of those at all. B lu can be also expressed in terms of the classical cross-section from electrodynamics and the quantum-mechanical oscillator-strength, f . The profile function, ϕ ( ν ), is a convolution of di ff erent broadening functions, in particular natural line broadening (basically, a quantum electrodynamic e ff ect, heuristically resulting from the finite life-time of the emitting state and Heisenberg's uncertainty principle) and various kinds of collisional broadening (perturbation of radiating particles by other plasma components, e.g., Stark, resonance and van der Vaals broadening). Except for linear Stark-broadening, all of these can be described by a Lorentzian (Cauchy) distribution. Most important for the line cores is Doppler-broadening, which accounts for the Doppler e ff ect due to the thermal (Maxwellian) velocities of the absorbing and emitting particles. The convolution of the latter Gaussian with the Lorentzian from a above is called a Hjerting or Voigt profile .  \nWhen the gas reaches temperatures cool enough (typically about 4000 K), molecules become progressively important. Molecular electronic transitions split in a myriad of vibrational and rotational components that form absorption bands that can span a broad spectral range, impacting significantly the emerging SED of the atmosphere and the energy balance. The chemical equilibrium among all the relevant molecular species, which are many, needs to be computed in detail, and the outcome a ff ects atomic absorption lines, since atoms trapped in molecules no longer contribute to atomic transitions. Fortunately, quantum mechanical calculations have improved their accuracy in recent years, and are now providing detailed line lists for the most important molecular species (see,e. g., Tennyson and Yurchenko 2018).", '2.4.2 Continuum Processes and Scattering': 'Bound-free and free-free opacities / emissivities can be calculated from the Einstein-Milne relations, and also involve products of occupation numbers and quantum-mechanical cross-sections. Bound-free cross-sections are typically di ff erent from zero for frequencies larger than the corresponding ionization threshold (but can extend also to lower frequencies, because of so-called resonances), and free-free processes increase quadratically with density and wavelength, dominating the IR and radio domains. In cool stars, the free-free and bound-free opacities from the H -ion, with one bound state at 0.75 eV, have to be accounted for (essential for solar-type stars in the optical and near IR).  \nA variety of potential scattering processes additionally contribute to the total opacity and emissivity. Most important is the scattering by free electrons, which in the range roughly below 12.4 keV becomes coherent and is called Thomson scattering. The corresponding  \nscattering opacity, σν , only depends on cross-section and electron density (low in cool star atmospheres), and the emissivity can be fairly well approximated in terms of the mean intensity,  \nχ Th ν = σ Th n e with σ Th = 8 π 3 r 2 0 ≈ 6 . 65 · 10 -29 m 2 , η Th ν ≈ χ Th ν J ν (18)  \n( r 0 is the classical electron radius). Other scattering processes are the high-energy generalizations of Thomson-scattering (Compton- and Klein-Nishina scattering), Rayleigh scattering (basically atomic / molecular line absorption / emission far from their central frequency), and sometimes also Raman-scattering (inelastic scattering by molecules). After summing up the individual contributions from lines, continuua and scattering processes, the total source function does not only depend on atomic quantities and occupation numbers, but also on the mean intensity (because of the scattering terms), which immediately shows the necessity of an iterative procedure.', '2.5 Occupation Numbers': 'As long as a plasma is dominated by collisions at a given point, i.e., if there are (in each transition!) much more collisional than radiative processes, the plasma will be in local thermodynamic equilibrium (LTE). In this case, all occupation numbers (ionization and excitation) can be calculated from the well-known Saha-Boltzmann equation, in dependence of local electron density and temperature. If the above condition is no longer fulfilled for all transitions, either part or even all atomic / molecular levels require a so-called non-LTE (NLTE) or kinetic equilibrium treatment. As a rule of thumb, atmospheric LTE conditions (high densities and low temperatures) are mostly met in dwarfs and partly giants of spectral type late B and cooler (for Galactic metallicities). For the rest, NLTE is required. We note that even for relatively cool stars such as the Sun, detailed calculations including 3-D modeling show a better reproduction of specific lines (e.g., strong Fe i , Ca i and Ca ii lines) when calculated in NLTE (e.g., Bergemann et al. 2012). We also note that in the deepest part of stellar atmospheres (lower boundary), LTE prevails, since the density increases more rapidly than temperature.  \nUnder NLTE conditions, the calculation of occupation numbers and radiation field has to proceed (iteratively) in parallel (together with temperature and density stratification): Saha-Boltzmann is no longer valid, and the occupation numbers have to be derived from the socalled rate equations . Under stationary conditions, i.e., as long as kinematic time-scales are much larger than atomic ones 9 , these are given by  \nX j , i n i P ij = X j , i n j P ji ∀ levels i . (19)  \nHere, the indices (i,j) refer to all levels considered in the model atom (a theoretical description of levels and potential transitions, see Sect. 3.5), n i are the corresponding occupation number densities, and P ij the transition rates from level i to level j, for radiative and collisional bound-bound and bound-free processes. Eq. 19 states that the number of all possible transitions from level i to other levels j needs to be balanced by the number of transitions from all other levels j into level i. In mathematical terms, this is a linear equation system, which needs to be closed with an equation of particle (or charge) conservation  \nThere are at least three major challenges when solving Eq. 19: (i) For each(!) transition (and usually 10 5 . . . 10 6 transitions need to be considered), corresponding atomic data (radiative and collisional cross sections) need to be present. (ii) All radiative rates depend on the mean intensity, and the RT needs to be solved for a large frequency range, with high resolution to resolve all line cores and ionization edges (computational time!). (iii) Since the occupation numbers depend on the transition rates and thus the radiation field, and the radiation field depends on the opacities and thus occupation numbers, a clever iteration scheme 10 needs to be established. NLTE calculations for molecular species were traditionally considered as out of reach due to the vast numbers of levels and transitions involved. However, there are brave e ff orts on this front giving promising results (Schweitzer et al., 2003; Ogibalov and Shved, 2016; Popa et al., 2023).', '3.1 Stellar Winds': "Stellar winds ( = mass outflows) are ubiquitious throughout the Hertzsprung-Russel diagram, and indeed it is di ffi cult (if not impossible) to find a star that has no wind at all. Such winds can have vastly di ff erent mass-loss rates and terminal velocities, but if the wind-strength is not very low, they have to be included (at least in principle) into atmospheric calculations. Using the 1-D equation of motion together with the equation of continuity (Eqs. 3ii / 3i) and the equation of state, p = ρv 2 s , an alternative formulation reads  \nGLYPH<16> 1 -v 2 s v 2 GLYPH<17> ρv ( r ) d v d r = -GM r 2 + g o ( r ) + 2 v 2 s r -d v 2 s d r (20)  \nwhere we have split the external accelerations into gravity and other accelerations ( g o ), and rewritten the gas pressure gradient. Basically, four di ff erent solutions are possible, but when concentrating here on a potential mass outflow, we see that in order to switch from subsonic to supersonic velocities (lhs), the rhs has also to switch sign: from the sonic point on, the sum of the 2nd to 4th term has to become larger than gravity.  \nPressure Driven Winds. For cool main sequence stars, external forces besides gravity (such as radiative acceleration) are weak and usually negligible, and we restrict ourselves to the case of a wind initiated by a high-temperature corona, as firstly realized by Parker (1960). If such a high temperature can be maintained by heating and thermal conduction (see Sect. 2.3), in an isothermal wind the equation changes sign at the sonic ('critical') point, where r s = GM / (2 v 2 s ). For an average temperature of 2 · 10 6 Kthen, v s ≈ 165 kms -1 and r s ≈ 3.5 R ⊙ . The low coronal density implies a low mass-loss rate of roughly 10 -14 M ⊙ yr -1 , irrelevant on evolutionary time-scales of 10 10 yr, and the typical terminal velocity is around 500 kms -1 . Despite the small implications for the Sun's evolution, the solar wind has an obvious impact on communications and space weather.  \nLine-Driven Winds. From improved rocket- and first satellite-based UV observations in the 1960s and 70s on, it became clear that massive OB-stars possess quite strong winds, because of their strong UV P Cygni profiles 11 . As they usually lack a hot corona, other acceleration mechanisms need to be invoked. Pioneering work to explain these winds by radiative line-driving was performed by Lucy and Solomon (1970) and Castor et al. (1975), and although various improvements to the original formulations have been included meanwhile, the basic theory still holds, at least qualitatively. Because of the large oscillator-strengths of line transitions compared to continuum crosssections, and because of the high luminosity of massive stars (10 4 to few 10 6 L ⊙ ), the radiative line acceleration (momentum transfered by line-scattering and absorption) is su ffi cient to accelerate winds to high speeds (couple of 100 to 3000 kms -1 ) at significant mass-loss rates (10 -8 to 10 -5 M ⊙ yr -1 ), which is of major concern for their evolution. For details, we refer to Puls et al. (2008), Vink (2022), and the chapter about 'Stellar Winds' within this Encyclopedia of Astrophysics. We only note here that (i) mostly metal ions are accelerated, which transfer their momentum to the bulk matter (H and He) via Coulomb collisions, and that (ii) without the distance-dependent Doppler shift between the stellar rest frame and the moving ions line acceleration would not work, since then the lines would become already saturated in the upper photosphere, and could no longer accelerate the wind at larger distances from the star. Because of their large densities, line-driven winds need to be accounted for when modeling the atmospheres of hot massive stars (see Sect. 2.1), at least when the actual mass-loss rate is larger than few times 10 -8 M ⊙ yr -1 . For lower mass-loss rates, most diagnostic line-features form in the quasi-hydrostatic part of the atmosphere, and a plane-parallel, hydrostatic modeling becomes possible (Puls, 2009).  \nCool Star Winds. In Red Supergiants and Asymptotic Giant Branch (AGB) stars, their extreme radii and very low gravities enable the formation of giant convective cells (with H / R ≈ 0 . 2), and 3-D simulations (Freytag and Hofner, 2023) show that these can lift material to cool regions ( T < ∼ 1,500 K) where dust can form. Because of high luminosities, a wind is accelerated beyond escape by radiative dustdriving, where the terminal velocities are low (few tens of kms -1 ) but the mass-loss rates high (10 -7 . . . 10 -5 M ⊙ yr -1 ). For AGB stars, a 'pre-acceleration' by their slow pulsations steepening into strong shocks is additionally required, and in Red Supergiants an alternative acceleration might be due to turbulent pressure (Kee et al., 2021). Winds from 'normal' Red Giants, on the other hand, are not understood until now.  \nContinuum Driven Super-Eddington Winds. All above radiation-driven winds require the presence of metals, and are otherwise very weak or even absent. An alternative wind-mechanism in hot massive stars which does not involve any metals - and thus might be particularly important for the very first stellar generation - is (theoretically) given by an acceleration due to Thomson-scattering. If a hot massive star is near or above the Eddington limit 12 , an outwards decreasing porosity (Sect. 3.3) can lead to a Thomson acceleration that is below gravity in photospheric regions, and above beyond, such that a wind can form (see Eq. 20), instead of an expanding envelope. For details and implications, we refer to Owocki et al. (2004) and Smith and Owocki (2006).", '3.2 Impact of Rotation and Magnetic Fields': "Until here, we have built upon a rather simplified atmospheric model, neglecting rotation, magnetic fields, and (see Sect. 3.3) inhomogeneities (e.g., turbulence). Magnetic fields of considerable strength are rare in hot massive stars (detected for ∼ 10% of main-sequence objects, e.g., Grunhut et al. 2017), and their origin is still debated (e.g. Schneider et al., 2016), whereas they play a very important role in cooler low-mass stars (like the Sun), a ff ecting the whole atmosphere and being responsible for the presence of sunspots and coronae. Rotation, on the other hand, is slow in low mass stars, but can reach hundreds of km s -1 in massive hot stars, a ff ecting their geometrical shapes and structure.  \nIn 1-D models, magnetic fields (if sizeable) might be accounted for by means of the corresponding magnetic pressure (adopting a simplified field geometry). Magnetic fields a ff ect the line-profiles by Zeeman-splitting (increasing with field-strength and square of transition wavelength), but, most importantly, lead to circular polarization, which can be used to infer magnetic field strengths averaged over the stellar disk (e.g., Wade et al. 2016).  \n1-D rotation is usually considered in an implicit way only: the atmospheric parameter g grav is re-interpreted as an e ff ective gravity, g e ff = g grav -g cent, to be derived from quantitative spectroscopy (see Sect. 4.3). The actual g grav is then found by correcting g e ff with an estimate for the centrifugal acceleration g cent, averaged over the apparent stellar disk, and in dependence of v rot sin i (Repolust et al. 2004, Appendix A). Here, the latter quantity is the projected rotation speed at the stellar equator, with i the angle between observer and stellar rotational axis, and is the only quantity that can be actually measured from observations (as long as no additional information, e.g., from the motion of stellar spots, is available). To this end, and to allow for a meaningful spectroscopic analysis, 'non-rotated' 1-D synthetic spectra need to be convolved with a corresponding broadening function. The convolved line-profiles extend to ± v rot sin i , and their shapes 13 (see Fig. 5, right panel) allows to measure the projected rotational speed, by adapting v rot sin i until the observed widths, shapes and depths are  \nreproduced. Alternatively, a Fourier method can be used (Sim'on-D'ıaz and Herrero, 2007). One important aspect of rotational broadening is its conservation of equivalent width, i.e., the area of the normalized profile below or above the continuum.  \nBecause of centrifugal acceleration, the stellar surface becomes deformed, with a maximum ratio R eq / R pole ≈ 1 . 5 at critical rotation , i.e., when the total acceleration at the equator becomes zero. Estimates for the surface radius as a function of rotational speed and latitude can be found, e.g., in Cranmer and Owocki (1995) and references therein. Moreover, as already shown by von Zeipel (1924), and somewhat generalized by Maeder (1999), the surface flux of a rotating star is proportional to the e ff ective gravity. Since the flux can be expressed in terms of T e ff , the e ff ective temperature is hotter at the pole than at the equator. Typically, this gravity darkening e ff ect becomes noticeable for rotational speeds > ∼ 70% of the critical one. 14 Photospheric models aiming at including these variations create a suitable mesh over the distorted surface (e.g., by tesselation), and populate this mesh with the emergent intensities from model atmospheres with parameters g e ff and T e ff as a function of position. An integration over the individual intensities results in the final SED, depending on sin i (e.g., Abdul-Masih et al., 2020).  \nBoth rotation and magnetic fields a ff ect the stellar winds from hot stars. Contrasted to the oblate stellar surface resulting from rapid rotation, line-driven winds are predicted to become prolate, because of the larger illumination at the poles (gravity darkening). The polar mass-loss rate becomes larger than the equatorial one, though the total mass-loss rate is barely a ff ected, except for rotational velocities close to critical. Since in line-driven winds terminal velocities scale with g e ff (now including the Thomson acceleration), also the velocities are predicted to become larger at the pole compared to equatorial regions. This di ff erence leads to non-radial terms in the line-acceleration, resulting in a slow velocity component into the polar direction. For details, we refer to Cranmer and Owocki (1995) and Puls et al. (2008).  \nIn a series of papers, ud-Doula and co-workers studied the impact of magnetic fields on line-driven winds (starting with ud-Doula and Owocki 2002), and showed, as one of their major results, that magnetic fields with strengths of few 10 -2 T are able to quench the mass-loss rates significantly. Moreover, because of magnetic braking, the rotational speed decreases on evolutionary time-scales, in dependence of ˙ M .", '3.3 Inhomogeneities': "One last approximation in standard model atmospheres is the assumption of homogeneity. This assumption concerns at least two di ff erent aspects. On the one hand, conventional approaches adopt the chemical abundance pattern to be the same everywhere in the atmosphere. For atmospheres where mixing motions are weak, however, gravitational settling and radiative levitation might set in, and the abundance pattern becomes a function of depth (Michaud, 1970). Well-known examples for this process are Ap-stars or, more generally, Chemically Peculiar stars on the main sequence and in the subdwarf domain (e.g., Michaud et al., 2011).  \nA second aspect of potential inhomogeneities is related to density- and velocity fluctuations, e.g., turbulence and patterns due to strong instabilities and potential shock waves. For cool stars, the most well-known instability is the convective one (see Sect. 2.3), which in solartype stars leads to granulation. Before multi-D simulations became available (but also still at present time), the impact of fluctuating or turbulent velocity fields was 'artificially' included into the calculation of stellar spectra, as so-called micro- and macro-turbulence. Microturbulence ( v mic) adopts that the size of turbulent cells is small compared to the photon mean free path, and is included into the individual profile functions (used within the RT) by an additional term, such that the e ff ective thermal velocity is given by v 2 th = (2 k B T / m + v 2 mic ), with m the atomic / molecular mass. By construction, micro-turbulence does not conserve the equivalent width. Macro-turbulence, v mac, on the other hand, is supposed to be made up by turbulent cells that are typically larger than the photon mean free path, and is, in parallel with rotation, treated by a final convolution of line-profiles with a Gaussian of width v mac (or a corresponding radial-tangential profile, e.g., Gray 2021), thus conserving the equivalent width. One of the big breakthroughs of cool-star multi-D simulations was their capability to reproduce, in particular for the Sun, the observed profile shapes, widths and shifts, without requiring any artificial non-thermal velocity field, i.e., without introducing any micro- and macro-turbulence (Asplund et al., 2009).  \nModelling of hot star atmospheres requires as well the inclusion of micro- and macro-turbulence (Fig. 5). First, the derived v mic values seem to increase with temperature and luminosity class, from values at or close to zero for late B-type dwarfs to values of 20 kms -1 for OB-supergiants, and there are indications that micro-turbulence might be related to sub-surface convection zones (Cantiello et al., 2011). In many stars, the inferred macro-turbulent velocity is highly supersonic, with typical maximum values of roughly 100 kms -1 (Sim'on-D'ıaz and Herrero, 2007). Currently, there are two explanations, namely either a relation to non-radial pulsations (Aerts et al., 2009), or, again, a relation with sub-surface processes. Indeed, first pioneering 2-D simulations for hot star atmospheres by Debnath et al. (2024) including the Fe opacity peak around 200,000 K resulted in large turbulent velocities in the stellar photosphere, comparable to the observed values of v mac.  \nA major result relevant for hot star atmospheres close to the Eddington-limit and relevant in the context of continuum-driven winds (see Sect. 3.1) was found by Shaviv (1998). When considering a locally inhomogeneous medium, he showed that because of the porous structure of the medium, the average radiation force becomes less than in a homogeneous one, such that the mean luminosity can actually exceed the classical Eddington-limit.  \nInhomogenieties play also an important role in line-driven winds of hot stars. As shown by Owocki and Rybicki (1984), the driving agent, line-acceleration, is prone to a strong instability, the so-called line-deshadowing instability : Perturbations in velocity (and velocitygradients) lead to perturbations in the line-acceleration, leading to further growth. The perturbed medium steepens into reverse shocks, which after (mostly radiative) cooling give rise to over-densities, compared to the mean flow. The predicted shock-temperatures are around a couple of million Kelvin, and the implied X-ray emission has been actually observed in all massive OB-stars. In a simple picture, the flow then consists of a collection of dense clumps (with velocities slightly below the smooth-wind predictions), and a fairly thin and fast inter-  \n<!-- image -->  \nFig. 5 Synthetic line profiles of He i 4471 Å , for an O-star with T e ff = 35,000 K, log g = 4.0 (cgs), and a wind of intermediate strength. The second line component to the left of the main feature is a forbidden one. Left: impact of micro-turbulence, with e.w. the equivalent width in Å . Right: impact of rotation and macro-turbulence. For values and colors, see legend.  \n<!-- image -->  \nclump material. First 1-D hydrodynamic simulations have been performed by Owocki et al. (1988) and Feldmeier (1995), and meanwhile few multi-D simulations have been undertaken and studied as well (e.g., Sundqvist et al. 2018).  \nThis conceptually di ff erent, inhomogeneous wind structure needs to be included into the unified (photosphere + wind) atmospheric models of hot massive stars, since in such an inhomogeneous (and partly shocked) medium ionization and excitation are significantly di ff erent compared to the homogeneous case. This inclusion is performed by means of a simplified description in terms of over-densities, density contrasts, and volume filling factors (both for the clumps and for the shocks), where most atmospheric codes rely on the assumption of optically thin clumps. However, also the e ff ects of clumps becoming optically thick (porous) at specific wavelengths (particularly in UV spectral lines) can be treated in an approximate way. For details, we refer to Puls et al. (2008) and references therein, and to Oskinova et al. (2007), Sundqvist and Puls (2018), and Brands et al. (2022). We only mention here that the spectroscopically inferred mass-loss rates using such clumped models are lower (typically by a factor two to three) than derived from smooth-wind models, and that the interclump density seems to be larger than previously expected (e.g., Hawcroft et al. 2021). We stress that uncertainties regarding the inhomogeneous structure of massive star winds lead to sizeable uncertainties in the derived mass-loss rates, with partly drastic e ff ect when transferred to evolutionary calculations.", '3.4 Binarity/Multiplicity': "About half of all solar-type stars are binaries (though the majority is widely separated, e.g., Moe and Di Stefano 2017), and the binary fraction of massive stars is even higher: 70% of the Galactic O-stars are a ff ected from binary interactions, and 24% will finally merge (Sana et al., 2012). If the components are close enough, such interactions need to be included into the modelling of the atmosphere(s) and into the spectroscopic analysis. Because of tidal e ff ects, the surfaces become distorted (in addition to rotational e ff ects), but now as a function of phase. Moreover, the companion illuminates the atmosphere from outside, and the corresponding intensity needs to be specified (again as a function of phase), also accounting for reflection e ff ects. The basic approach is similar to the treatment of (fast) rotation, namely by creating a suitable mesh over the distorted surface, and by populating this mesh with consistently corrected emergent intensities from appropriate, position- and phase-dependent models (Wilson and Devinney 1971, phoebe -code by Prˇsa et al. 2016). This procedure needs to be applied to both components, and the common SED is calculated by integrating over all visible intensities from the complete system as seen by an observer at the considered phase (e.g. Abdul-Masih et al., 2020). If both companions have quite di ff erent spectral types, and we were interested in specific line profiles that form in only one component, it is often su ffi cient to consider only the continuum light from the other (or others, if a 'third light' was present). The same is true if an accretion disc was present in the system.", '3.5 Atomic and Molecular Data': 'Under the assumption of LTE (Sect. 2.5), the local radiation field and the occupation numbers are in balance 15 , collisions play a dominant role, and there is only one temperature describing the velocity distribution for all particles: ions, electrons and molecules. The level populations can then be readily computed using the Saha-Boltzmann equations (with just ionization and excitation energies, statistical weights and partition functions), and the strength of the spectral lines can be determined by solving the RT equation given only the transition probabilities (oscillator strengths), and the damping constants for strong lines.  \nElastic collisions shift and broaden the lines. While collisional shifts have a minor impact, collisional damping is usally important and leaves an obvious mark in stellar spectra. The most important perturber in low-mass stars are hydrogen atoms, while in hotter stars it is  \nmainly free electrons that have a dominant e ff ect. Detailed quantum-mechanical calculations of the interactions provide in many cases reliable data, and in some cases approximate treatments are available.  \nWhen LTE does not hold, photons can travel far from where they have been emitted and deposit energy. The balance between radiative and collisionally-induced transition needs to be determined for each point (rate equations, Sect. 2.5), and many more data become necessary. The full collection of data required to solve the rate equations for each of the relevant ions involved is known as a model atom , and includes the energy levels, photo-ionization cross-sections (including their frequency dependence), collisional ionization strengths, radiative transition probabilities, and collisional excitation strengths. Inelastic collisions with electrons are dominant in intermediate and hot stars, while in cooler types (F and later) collisions with hydrogen atoms can be very relevant, in particular for metal-poor stars. In stars with very low masses, molecular perturbers may need to be considered as well.  \nAb initio quantum mechanical calculations can provide reliable radiative transition probabilities for light atoms / ions, but for complex atomic systems laboratory measurements are usually required for accurate results. Theoretical calculations of atomic structure nowadays give solid predictions for electron-ion recombination rates and photoionization cross-sections (see, e.g. Nahar, 2016; Barklem et al., 2017), and these can be checked against detailed spectrophotometric observations of stars (Allende Prieto, 2023). Reliable calculations are now becoming available also for inelastic collisions with hydrogen atoms (e.g., Barklem et al. 2012; Barklem 2016, 2018). Molecules are included in synthetic spectra assuming LTE for the most part, but their contribution to the equation of state and to the total opacity is now modeled in far more detail thanks to e ff orts to improve partition functions and detailed line lists, by many but in particular by the Exomol group (Tennyson et al., 2024).', '4.1 Observational Data': 'Quantitative spectroscopy is based on observational data, mostly high resolution spectra with a high signal to noise ratio. For many purposes, the optical and near IR range (if molecular bands shall be analysed) is su ffi cient. For the analysis of hot stars (with only few optical lines) and their winds, also the UV ( → P Cygni profiles) might be required. Moreover, an analysis of the outer wind requires the knowledge of the mmand radio regime (free-free emission), and constraints for the shock emission are found from the X-ray band, which needs to be known as well for the analysis of stellar coronae and compact objects.  \nIn addition to spectroscopy, all other astronomical techniques such as interferometry (stellar and wind shape, binarity), polarimetry (inhomogeneities, wind and disk shape, magnetic fields), imaging (stellar surroundings), photometry (integrated fluxes), and astrometry (distances, peculiar velocities, and proper motions) are needed to obtain a consistent picture. Particularly, the combination of photometry and astrometry is inevitable, since otherwise there would be no handle on the stellar radius, which results from a comparison of apparent ( → photometry) and absolute ( → models + distance) fluxes, corrected for reddening.  \nTime series are required to study the presence of companions (stars, exoplanets), temporary structures (spots, narrow absorption components), and the evolution of transient phenomena (outburst, mergers, supernovae). The analysis of pulsation patterns present in all stars from spectroscopic and / or photometric time series has opened the way to the unseen subphotospheric layers and the deep stellar interiors.', '4.2 Numerical Codes': "Because of the di ff erent physical conditions as a function of stellar spectral type and evolutionary phase, we split the various codes into the scheme LTE vs. NLTE and 1-D vs. 3-D. In Table 1, we enumerate only those codes that are / have been frequently used (without aiming at completeness). LTE codes usually include molecules, and 1-D structure codes base on the mixing length theory if convection plays a role. For a detailed description and references, we refer to Crivellari et al. (2019, Chap. 3), except for ASSET (see Koesterke 2009) and for SYNPLE (see github.com/callendeprieto/synple ). Particularly for the LTE case, many codes provide only an atmospheric model (i.e., density and temperature structure), whilst the corresponding SED (in absolute flux-units and / or normalized to the neighbouring continuum) is synthesized by a separate, 'diagnostic' code, partly by (re-)calculating the occupation numbers (sometimes in NLTE, which constitutes a hybrid approach). If, on the other hand, the occupation numbers from the atmospheric model were used, this second step is called the formal integral , since then 'only' the (mostly steady-state) equation of RT (Eq. 5) needs to be solved. In most NLTE approaches, atmosphere and formal integral are still calculated in two steps, but are provided in one common package.", '4.3 Determination of Stellar and Wind Parameters': "The basic idea of quantitative spectroscopy is to compare (by various methods, outlined below) observed and theoretical spectra / SEDs, where the input parameters for the atmospheric models are modified until synthetic and observed spectra / SEDs agree. In a first step, the stellar (and wind parameters) need to be quantified, before individual abundances are derived in a second step. To this end, and in dependence of spectral type, di ff erent observed diagnostic features are compared with model spectra 16 to infer T e ff , log g (or log g e ff , see Sect. 3.2), and often the helium content in hot stars (being the second most abundant element, changes in its abundance may modify the atmospheric structure). The e ff ective temperature might, for cooler stars (spectral types F and later), be derived from photometry, or from specific diagnostic features such as the collisionally-broadened wings of hydrogen lines, or by requiring atomic iron lines with various  \nTable 1 Various numerical codes with different assumptions and purposes: AS - atmospheric structure code; DIA - diagnostic code (see text); FI - formal integral; RMHD - radiation magneto-hydrodynamics code. When not stated differently, and except for RMHD codes, stationary approach used. Abbreviations for features: hs - hydrostatic; hd - hydrodynamic; unif - unified (photosphere+wind, smoothly connected); pp - plane-parallel; ss - spherically symmetric; RE - radiative equilibrium; MLT - mixing length theory; EB electron thermal balance (see Hummer 1963; Kub'at et al. 1999); cart - Cartesian; sph - spherical; cyl - cylindrical  \nIn the following, 'optically thick winds' refer to high mass-loss rates where τ R = 1 is reached within the wind, e.g., winds from classical Wolf-Rayet stars  \n- a optically thin and thick winds. Time-dependent calculations for SN-remnants also possible\n- b optically thin winds only. Fast computation time because of specific treatment of background elements. Optically thick clumping included in NLTE calculations and formal integral. Version 11 (in work) allows for complete CMF transfer\n- c optically thin and thick winds. Molecules included, SN-remnants (stationary) possible d optically thin and thick winds. Optically thick clumping in formal integral\n- e optically thin winds only. SN-remnants (stationary) possible. No clumping included f hybrid approach, see main text\n- g one single atom in NLTE, others in LTE or read in h CoIs: J. Bjørgen, A. Sukhorukov\n- i one single atom in NLTE, others in LTE; hydrogen population can be read in j multiple atoms and molecules\n- k CoIs: M. Carlsson, V. Hansteen, J. Leenaarts, J. Martinez-Sykora l CoIs: K. Galsgaard, R. Collet, R. Stein\n- m used to model various RMHD problems related to stellar evenvelopes (and other realms) such as convection and turbulence. The output of these models (either directly or suitable averages) can be used to synthesize corresponding SEDs.  \nexcitation energies to give the same iron abundance. In early-type stars, the ionization equilibrium (lines from di ff erent ions of the same element shall be reproduced with a similar quality) is exploited (nitrogen, helium, silicon and magnesium ionization equilibrium for hot and cooler O-stars, B-stars, and A-stars, respectively). The (e ff ective) gravity in cooler stars is derived from the damping wings of metal lines, broadened mainly by collisions with hydrogen atoms, or by imposing the ionization balance for atomic and ionized iron. In hotter stars, it is determined from the Stark-broadened wings of H γ and H δ , which are predominantely formed in the photosphere and strongly react on the electron-density controlled by log g (e ff ) (see Eq. 2). In massive stars with a considerable wind strength, many photospheric lines become contaminated by wind-e ff ects (see also Sect. 3.1), and thus the wind-parameters (mass-loss rate, terminal velocity and parameterized velocity-field, plus specific parameters describing the distribution of inhomogeneities) need to be inferred in parallel, mostly from H α , He ii 4686 Å, and, if available, the ultraviolet P Cygni lines. Further details can be found in Gray (2021) for stars of later spectral type, and in Sim'on-D'ıaz (2020) for early type stars. Examples for the parameter determination for a cool and a hot star from optical spectra alone are presented in Fig. 6 and 7, respectively.", '4.4 The Stellar Mass': 'The stellar mass is the primary parameter determining the structure and fate of a star. The best method to obtain stellar masses is to observe and analyze binary stars, and eclipsing binaries in particular. Subject to their mutual gravitational influence, their motion is determined by their respective masses (and orbital separation). For low mass stars, the observation of binaries allows a precise comparison with the theory of stellar structure and evolution, as there is a large number of systems with components that do not interact and behave as isolated stars. The situation is much more complicated for high-mass stars: gravitational fields are more intense, separations smaller, interaction e ff ects stronger and the number of available systems comparatively small. This stresses the importance to obtain masses from high-quality  \nFig. 6 Observed (Bohlin et al., 2019) and synthetic best-fit optical spectrum for the K 0.5 III star 2MASS J17551622+6610116. Synthetic spectra computed with SYNSPEC based on a Kurucz model. Derived parameters: T e ff ≈ 4870 K, log g = 3.0 (cgs), and solar iron abundance. Fitting method: Bayesian algorithm in Synple (see Sect. 4.2).  \n<!-- image -->  \nspectroscopic analyses: After correcting the measured e ff ective gravity for the centrifugal acceleration (Sect. 3.2), a combination of log g with the stellar radius (Sect. 4.1) yields the so-called spectroscopic mass , which is subject to significant uncertainties, mainly linked to the determination of radius and gravity. Though these uncertainties accumulate into relatively large errors for the individual masses (sometimes exceeding 50%), a so-called mass discrepancy has been identified (Herrero et al., 1992), a systematic di ff erence between spectroscopic and evolutionary masses 17 of single stars.  \nIn spite of some decades of e ff orts, this discrepancy has not been fully resolved, with varying results when di ff erent samples have been analyzed. The comparison between both mass determinations has become more complicated after the realization that many massive stars are in binary systems or have su ff ered di ff erent degrees of interaction in their evolution. Beyond the Magellanic Clouds, crowding enhances the di ffi culties as undetected visual companions may contaminate the spectrum and increase the uncertainties. Clearly, reducing the uncertainty in the determination of stellar masses of massive stars from quantitative spectroscopy via model atmospheres will be a major leap forward.', '4.5 Determination of Abundances': 'When the stellar (and wind) parameters have been determined, individual abundances for specific elements can be derived, as long as corresponding spectral lines are visible (although a lack of spectral lines can also be used to constrain the abundance of a given element). Two di ff erent methods might be employed: (i) similar to the procedure outlined above, the observed line profiles are fitted by synthetic ones, where now, for fixed stellar (and wind) parameters, the input values for the abundances are varied, in parallel with the micro-turbulent velocity (Sect. 3.3). A certain disadvantage of this method is its dependence on quite precise values for v rot sin i and v mac. (ii) Alternatively, not the profile shape, but the equivalent width (see Sect. 3.2) is fitted, which avoids the previous problem since the equivalent width is conserved by both broadening processes. This, in turn, has the disadvantage of a certain degeneracy; for example, the line core could be underestimated and the wings overestimated, still matching the equivalent width. Also here, v mic needs to be determined in parallel. Generally, a reasonable solution requires to find the same abundance within any diagnostic line from the atom under consideration (in particular, for lines from di ff erent ions, if present), together with a unique value for v mic. Obviously, the more lines are available, the easier it is to discriminate between systematic and statistical errors. Moreover, it is useful to concentrate on weak and intermediate strong lines (where the profile-strength and equivalent width react linearly on the abundance), to avoid saturation e ff ects and to minimize the role of microturbulence.', '4.6 Fitting Methods': "It remains to be outlined how the above fitting process is actually performed. In most cases, the user needs to define a merit-function, which typically consists of a (weighted) χ 2 , measuring the sum of squared di ff erences between synthetic and observed fluxes / profiles as a function  \nFig. 7 Observed and synthetic best-fit optical spectrum for the O2 dwarf BI237 in the Large Magellanic Cloud. Observations from Doran and Crowther (2011), synthetic spectra for H, He, and N from FASTWIND: T e ff ≈ 53,000 K, log g = 4.1, low ˙ M , nitrogen mildly enriched (see Rivero Gonz'alez et al. 2012). Fitting method: by-eye. Profiles in red: H i ; in blue: He i (one very weak line); in green: He ii ; in orange: N iv ; and in magenta N v . Note the few number of metal lines being present in the optical range. The emission in N iv 4058 Å is a combined wind and NLTE effect.  \n<!-- image -->  \nof wavelength, normalized to the variance due to photon noise (accounting for systematics as well). The best fitting parameters then result from that model which produces the minimum χ 2 , and the errors for the individual parameters can be found from the χ 2 distribution around that minimum. There are various methods to find the global minimum, and all of them are still applied. The oldest method is a by-eye inspection of the fit-quality using a multitude of models, which for a large parameter space (when also wind-parameters need to be obtained) becomes cumbersome (besides being more subjective). A better method is to perform the fit using pre-calculated model grids (partly of quite large dimension, e.g. Allende Prieto et al. 2006; Garc'ıa P'erez et al. 2016; Holgado et al. 2018), or to use genetic algorithms if it is possible to calculate new models on the fly (e.g., Mokiem et al. 2005). In recent years, MCMC approaches (which directly deliver the probability density distribution for the analyzed parameters) and machine-learning methods have become popular, as well as data-driven models (Ness et al., 2015; Ting et al., 2019).", '4.7 Error Budget': 'Typical errors for T e ff and log g are 3-5% and 0.1 dex (but see above), respectively. Mass-loss rates for thinner winds (where H α is still in absorption) can be determined only with a precision of a factor of two, because of an uncertain velocity field. For objects with larger ˙ M , the precision can be higher (up to roughly 10%), but only if the clumping-stratification can be accurately derived, which is di ffi cult and requires a multi-wavelength analysis. Typical errors for the Helium abundance are 10 to 30%, and for the stellar radius 5 to 15% (if reliable distances and reddening properties are available). Regarding individual abundances except for He, there is usually a large di ff erence between the quoted errors for O-type stars and cooler ones. Since in most cases the abundances have been derived for fixed stellar parameters, a careful error propagation would be necessary, though often not done. Moreover, the number of visible metallic lines in O-stars is much less than in cooler ones, and the occupation numbers are often strongly a ff ected by subtle NLTE-e ff ects (see, e.g., Puls et al. 2020 for the case of nitrogen), which might lead to significant systematics. Overall, in stars later than O the abundance errors are on the order of 10%, whilst in O-stars they might reach 0.1 up to 0.2 or even 0.3 dex, except for Helium. We stress that for those elements with extremely few visible lines (e.g., lithium and boron), the error budget is strongly dependent on the precision of the atomic data. Larger errors also result when lines from only one ionization stage were present, since then a consistency check on a correct ionization equilibrium is not possible.', '5 Summary and Conclusions': 'In this chapter, we have summarized the basic theories and approaches to model stellar atmospheres and corresponding synthetic spectra, always discriminating between the pecularities of earlier and laters spectral types. We discussed as well the physics and influence of (various kinds of) stellar winds, rotation, magnetic fields, inhomogeneities, and multiplicity. We stressed the impact of multi-D RMHD models to further our understanding of cool-star atmospheres (e.g., convection) and hot star winds (and atmospheres), reproducing many features  \nin the observed spectra (and images, when considering the Sun). Stellar envelopes are an ideal laboratory to investigate specific physical e ff ects under extreme conditions, such as the line-deshadowing instability and corresponding radiative-accoustic waves. We finalized this chapter by describing the methodology to analyze observed SEDs by means of quantitative spectroscopy, and referred to the so-called mass-discrepancy found in the massive star domain. As a last comment, we like to warn any potential user about a black-box usage of model atmosphere codes (at least as long as specific physical problems have not been settled), and to be aware of the underlying and / or adopted physics.', 'Acknowledgments': "JP gratefully acknowledges the stimulating atmosphere (sic!) at the LMU University Observatory during his recent 40 years of scientific work and lecturing, as well as the fruitful collaboration with colleagues and students from all over the world, in particular R.-P. Kudritzki, S. Owocki, and the late A.W.A. Pauldrach and D.G. Hummer. AH acknowledges the many collaborations with colleagues at the LMU on stellar atmospheres, as well as support from the Spanish Ministry of Science and Innovation (MICINN) through the Spanish State Research Agency through grants PID2021-122397NB-C21, and the Severo Ochoa Programme 2020-2023 (CEX2019-000920-S). CAP is thankful to his lifelong collaborators Y. Osorio, H. Ludwig, L. Koesterke, P. Barklem, M. Asplund, D. Lambert, B. Ruiz-Cobo, and I. Hubeny in particular, for their help, support and so many exciting discussions.  \nSee Also: Payne (1925), Unsold (1955), Aller (1963), Mihalas (1978), Gray (2021), (Hubeny and Mihalas, 2015, H&M), Crivellari et al. (2019), Sim'on-D'ıaz (2020)", 'References': "Abdul-Masih M, Sana H, Conroy KE, Sundqvist J, Prˇsa A, Kochoska A and Puls J (2020), Apr. Spectroscopic patch model for massive stars using PHOEBE II and FASTWIND. A&A 636, A59. doi: 10.1051 / 0004-6361 / 201937341 . 2003.09008 .  \n- Aerts C, Puls J, Godart M and Dupret MA (2009), Dec. Collective pulsational velocity broadening due to gravity modes as a physical explanation for macroturbulence in hot massive stars. A&A 508 (1): 409-419. doi: 10.1051 / 0004-6361 / 200810471 . 0909.3585 .\n- Allende Prieto C (2023), Mar. The Shapes of Stellar Spectra. Atoms 11 (3), 61. doi: 10.3390 / atoms11030061 . 2303.14340 .  \nAllende Prieto C, Beers TC, Wilhelm R, Newberg HJ, Rockosi CM, Yanny B and Lee YS (2006), Jan. A Spectroscopic Study of the Ancient Milky Way: F- and G-Type Stars in the Third Data Release of the Sloan Digital Sky Survey. ApJ 636 (2): 804-820. doi: 10.1086 / 498131 . astro-ph/0509812 .  \nAller LH (1963). Astrophysics. The atmospheres of the sun and stars.  \nAsplund M, Grevesse N, Sauval AJ and Scott P (2009), Sep. The Chemical Composition of the Sun. ARA&A 47 (1): 481-522. doi: 10.1146 / annurev.astro.46.060407.145222 . 0909.0948 .  \nAuer LH and Mihalas D (1969), Nov. Non-Lte Model Atmospheres. III. a Complete-Linearization Method. ApJ 158: 641. doi: 10.1086 / 150226 .  \nBarklem PS (2016), Apr. Excitation and charge transfer in low-energy hydrogen-atom collisions with neutral atoms: Theory, comparisons, and application to Ca. Phys. Rev. A 93 (4), 042705. doi: 10.1103 / PhysRevA.93.042705 . 1603.07097 .  \nBarklem PS (2018), Feb. Excitation and charge transfer in low-energy hydrogen atom collisions with neutral oxygen. A&A 610, A57. doi: 10.1051 / 0004-6361 / 201731968 . 1712.01166 .  \nBarklem PS, Belyaev AK, Spielfiedel A, Guitou M and Feautrier N (2012), May. Inelastic Mg+H collision data for non-LTE applications in stellar atmospheres. A&A 541, A80. doi: 10.1051 / 0004-6361 / 201219081 . 1203.4877 .  \n- Barklem PS, Osorio Y, Fursa DV, Bray I, Zatsarinny O, Bartschat K and Jerkstrand A (2017), Sep. Inelastic e+Mg collision data and its impact on modelling stellar and supernova spectra. A&A 606, A11. doi: 10.1051 / 0004-6361 / 201730864 . 1706.03399 .  \nBergemann M, Lind K, Collet R, Magic Z and Asplund M (2012), Nov. Non-LTE line formation of Fe in late-type stars - I. Standard stars with 1D and ¡3D¿ model atmospheres. MNRAS 427 (1): 27-49. doi: 10.1111 / j.1365-2966.2012.21687.x . 1207.2455 .  \nBohlin RC, Deustua SE and de Rosa G (2019), Nov. Hubble Space Telescope Flux Calibration. I. STIS and CALSPEC. AJ 158 (5), 211. doi: 10.3847 / 1538-3881 / ab480c .  \nBondi H (1952), Jan. On spherically symmetrical accretion. MNRAS 112: 195. doi: 10.1093 / mnras / 112.2.195 .  \nBrands SA, de Koter A, Bestenlehner JM, Crowther PA, Sundqvist JO, Puls J, Caballero-Nieves SM, Abdul-Masih M, Driessen FA, Garc'ıa M, Geen S, Grafener G, Hawcroft C, Kaper L, Keszthelyi Z, Langer N, Sana H, Schneider FRN, Shenar T and Vink JS (2022), Jul. The R136 star cluster dissected with Hubble Space Telescope/STIS. III. The most massive stars and their clumped winds. A&A 663, A36. doi: 10.1051 / 0004-6361 / 202142742 . 2202.11080 .  \nCaffau E, Ludwig HG, Steffen M, Freytag B and Bonifacio P (2011), Feb. Solar Chemical Abundances Determined with a CO5BOLD 3D Model Atmosphere. Sol. Phys. 268 (2): 255-269. doi: 10.1007 / s11207-010-9541-4 . 1003.1190 .  \nCantiello M, Braithwaite J, Brandenburg A, Del Sordo F, Kapyla P and Langer N (2011), Jul., 3D MHD simulations of subsurface convection in OB stars, Neiner C, Wade G, Meynet G and Peters G, (Eds.), Active OB Stars: Structure, Evolution, Mass Loss, and Critical Limits, 272, 32-37, 1009.4462 .  \n- Castor JI, Abbott DC and Klein RI (1975), Jan. Radiation-driven winds in Of stars. ApJ 195: 157-174. doi: 10.1086 / 153315 .\n- Cowley CR (1990), Jan. Second Viscosity of the Gas in the Outer Solar Envelope. ApJ 348: 328. doi: 10.1086 / 168239 .\n- Cranmer SR and Owocki SP (1995), Feb. The Effect of Oblateness and Gravity Darkening on the Radiation Driving in Winds from Rapidly Rotating B Stars. ApJ 440: 308. doi: 10.1086 / 175272 .\n- Crivellari L, Sim'on-D'ıaz S and Ar'evalo MJ (2019). Radiative Transfer in Stellar and Planetary Atmospheres. doi: 10.1017 / 9781108583572 .\n- Debnath D, Sundqvist JO, Moens N, Van der Sijpt C, Verhamme O and Poniatowski LG (2024), Apr. 2D unified atmosphere and wind simulations of O-type stars. A&A 684, A177. doi: 10.1051 / 0004-6361 / 202348206 . 2401.08391 .\n- Doran EI and Crowther PA (2011), Jan. A VLT/UVES spectroscopy study of O2 stars in the LMC. Bulletin de la Societe Royale des Sciences de Liege 80: 129-133.  \nFeldmeier A (1995), Jul. Time-dependent structure and energy transfer in hot star winds. A&A 299: 523.  \nFreytag B and Hofner S (2023), Jan. Global 3D radiation-hydrodynamical models of AGB stars with dust-driven winds. A&A 669, A155. doi: 10.1051 / 0004-6361 / 202244992 . 2301.11836 .  \nGarc'ıa P'erez AE, Allende Prieto C, Holtzman JA, Shetrone M, M'esz'aros S, Bizyaev D, Carrera R, Cunha K, Garc'ıa-Hern'andez DA, Johnson JA, Majewski SR, Nidever DL, Schiavon RP, Shane N, Smith VV, Sobeck J, Troup N, Zamora O, Weinberg DH, Bovy J, Eisenstein DJ, Feuillet D, Frinchaboy PM, Hayden MR, Hearty FR, Nguyen DC, O'Connell RW, Pinsonneault MH, Wilson JC and Zasowski G (2016), Jun. ASPCAP:  \nThe APOGEE Stellar Parameter and Chemical Abundances Pipeline.  \nAJ  \n151 (6), 144. doi:  \n10.3847  \n/  \n0004-6256  \n/  \n151  \n/  \n6  \n/  \n144  \n.  \n1510.07635  \n.  \nGray DF (2021). The Observation and Analysis of Stellar Photospheres.  \nGrunhut JH, Wade GA, Neiner C, Oksala ME, Petit V, Alecian E, Bohlender DA, Bouret JC, Henrichs HF, Hussain GAJ, Kochukhov O and MiMeS Collaboration (2017), Feb. The MiMeS survey of Magnetism in Massive Stars: magnetic analysis of the O-type stars. MNRAS 465 (2): 2432-2470. doi: 10.1093 / mnras / stw2743 . 1610.07895 .  \nHawcroft C, Sana H, Mahy L, Sundqvist JO, Abdul-Masih M, Bouret JC, Brands SA, de Koter A, Driessen FA and Puls J (2021), Nov. Empirical mass-loss rates and clumping properties of Galactic early-type O supergiants. A&A 655, A67. doi: 10.1051 / 0004-6361 / 202140603 . 2108.08340 . Herrero A, Kudritzki RP, Vilchez JM, Kunze D, Butler K and Haser S (1992), Jul. Intrinsic parameters of galactic luminous OB stars. A&A 261: 209-234.  \nHillier DJ and Dessart L (2012), Jul. Time-dependent radiative transfer calculations for supernovae. MNRAS 424 (1): 252-271. doi: 10.1111 / j. 1365-2966.2012.21192.x . 1204.0527 .  \nHolgado G, Sim'on-D'ıaz S, Barb'a RH, Puls J, Herrero A, Castro N, Garcia M, Ma'ız Apell'aniz J, Negueruela I and Sab'ın-Sanjuli'an C (2018),  \nJun. The IACOB project. V. Spectroscopic parameters of the O-type stars in the modern grid of standards for spectral classification. A&A 613, A65. doi: 10.1051 / 0004-6361 / 201731543 . 1711.10043 .  \nHolweger H and Mueller EA (1974), Nov. The Photospheric Barium Spectrum: Solar Abundance and Collision Broadening of Ba II Lines by Hydrogen. Sol. Phys. 39 (1): 19-30. doi: 10.1007 / BF00154968 .  \nHubeny I and Mihalas D (2015). Theory of Stellar Atmospheres. An Introduction to Astrophysical Non-equilibrium Quantitative Spectroscopic Analysis.  \n- Hummer DG (1963), Jan. The ionization structure of planetary nebulae, II. Collisional cooling of pure hydrogen nebulae. MNRAS 125: 461. doi: 10.1093 / mnras / 125.5.461 .  \nHummer DG and Rybicki GB (1971), Jan. Radiative transfer in spherically symmetric systems. The conservative grey case. MNRAS 152: 1. doi: 10.1093 / mnras / 152.1.1 .  \nKee ND, Sundqvist JO, Decin L, de Koter A and Sana H (2021), Feb. Analytic, dust-independent mass-loss rates for red supergiant winds initiated by turbulent pressure. A&A 646, A180. doi: 10.1051 / 0004-6361 / 202039224 . 2101.03070 .  \nKoesterke L (2009), Sep., Quantitative Spectroscopy in 3D, Hubeny I, Stone JM, MacGregor K and Werner K, (Eds.), Recent Directions in Astrophysical Quantitative Spectroscopy and Radiation Hydrodynamics, American Institute of Physics Conference Series, 1171, AIP, 73-84. Kub'at J, Puls J and Pauldrach AWA (1999), Jan. Thermal balance of electrons in calculations of model stellar atmospheres. A&A 341: 587-594. Lucy LB (1971), Jan. The Formation of Resonance Lines in Extended and Expanding Atmospheres. ApJ 163: 95. doi: 10.1086 / 150748 .  \nLucy LB and Solomon PM (1970), Mar. Mass Loss by Hot Stars.  \nApJ  \n159: 879. doi:  \n10.1086  \n/  \n150365  \n.  \nLudwig HG, Caffau E, Steffen M, Freytag B, Bonifacio P and Kuˇcinskas A (2009), Jan. The CIFIST 3D model atmosphere grid. Mem. Soc. Astron. Italiana 80: 711. doi: 10.48550 / arXiv.0908.4496 . 0908.4496 .  \nMaeder A (1999), Jul. Stellar evolution with rotation IV: von Zeipel's theorem and anisotropic losses of mass and angular momentum.  \nA&A  \n347:  \n185-193.  \nMaeder A and Meynet G (2000), Sep. Stellar evolution with rotation. VI. The Eddington and Omega -limits, the rotational mass loss for OB and LBV stars. A&A 361: 159-166. doi: 10.48550 / arXiv.astro-ph / 0006405 . astro-ph/0006405 .  \nMagic Z, Collet R, Asplund M, Trampedach R, Hayek W, Chiavassa A, Stein RF and Nordlund (2013), Sep. The Stagger-grid: A grid of 3D stellar atmosphere models. I. Methods and general properties. A&A 557, A26. doi: 10.1051 / 0004-6361 / 201321274 . 1302.2621 .  \nM'esz'aros S, Allende Prieto C, Edvardsson B, Castelli F, Garc'ıa P'erez AE, Gustafsson B, Majewski SR, Plez B, Schiavon R, Shetrone M and de Vicente A (2012), Oct. New ATLAS9 and MARCS Model Atmosphere Grids for the Apache Point Observatory Galactic Evolution Experiment (APOGEE). AJ 144 (4), 120. doi: 10.1088 / 0004-6256 / 144 / 4 / 120 . 1208.1916 .  \nMichaud G (1970), May. Diffusion Processes in Peculiar a Stars. ApJ 160: 641. doi: 10.1086 / 150459 .  \nMichaud G, Richer J and Richard O (2011), May. Horizontal branch evolution, metallicity, and sdB stars. A&A 529, A60. doi: 10.1051 / 0004-6361 / 201015997 . 1102.1969 .  \nMihalas D (1978). Stellar atmospheres.  \nMoe M and Di Stefano R (2017), Jun. Mind Your Ps and Qs: The Interrelation between Period (P) and Mass-ratio (Q) Distributions of Binary Stars. ApJS 230 (2), 15. doi: 10.3847 / 1538-4365 / aa6fb6 . 1606.05347 .  \nMokiem MR, de Koter A, Puls J, Herrero A, Najarro F and Villamariz MR (2005), Oct. Spectral analysis of early-type stars using a genetic algorithm based fitting method. A&A 441 (2): 711-733. doi: 10.1051 / 0004-6361:20053522 . astro-ph/0506751 .  \nNahar SN (2016), Jul. Photoionization and electron-ion recombination of Ti I. New Astronomy 46: 1-8. doi: 10.1016 / j.newast.2015.11.003 .  \nNess M, Hogg DW, Rix HW, Ho AYQ and Zasowski G (2015), Jul. The Cannon: A data-driven approach to Stellar Label Determination. ApJ 808 (1), 16. doi: 10.1088 / 0004-637X / 808 / 1 / 16 . 1501.07604 .  \nOgibalov VP and Shved GM (2016), Sep. An improved model of radiative transfer for the NLTE problem in the NIR bands of CO 2 and CO molecules in the daytime atmosphere of Mars. 1. Input data and calculation method. Solar System Research 50 (5): 316-328. doi: 10.1134 / S003809461605004X .  \nOskinova LM, Hamann WR and Feldmeier A (2007), Dec. Neglecting the porosity of hot-star winds can lead to underestimating mass-loss rates. A&A 476 (3): 1331-1340. doi: 10.1051 / 0004-6361:20066377 . 0704.2390 .  \nOwocki SP and Rybicki GB (1984), Sep. Instabilities in line-driven stellar winds. I. Dependence on perturbation wavelength. ApJ 284: 337-350. doi: 10.1086 / 162412 .  \nOwocki SP, Castor JI and Rybicki GB (1988), Dec. Time-dependent Models of Radiatively Driven Stellar Winds. I. Nonlinear Evolution of Instabilities for a Pure Absorption Model. ApJ 335: 914. doi: 10.1086 / 166977 .  \nOwocki SP, Gayley KG and Shaviv NJ (2004), Nov. A Porosity-Length Formalism for Photon-Tiring-limited Mass Loss from Stars above the Eddington Limit. ApJ 616 (1): 525-541. doi: 10.1086 / 424910 . astro-ph/0409573 .  \nParker EN (1960), Nov. The Hydrodynamic Theory of Solar Corpuscular Radiation and Stellar Winds. ApJ 132: 821. doi: 10.1086 / 146985 .  \nPayne CH (1925), Jan. Stellar Atmospheres; a Contribution to the Observational Study of High Temperature in the Reversing Layers of Stars. Ph.D. thesis, RADCLIFFE COLLEGE.  \nPopa SA, Hoppe R, Bergemann M, Hansen CJ, Plez B and Beers TC (2023), Feb. Non-local thermodynamic equilibrium analysis of the methylidyne radical molecular lines in metal-poor stellar atmospheres. A&A 670, A25. doi: 10.1051 / 0004-6361 / 202245503 . 2212.06517 . Prandtl L (1925). 7. Bericht uber Untersuchungen zur ausgebildeten Turbulenz. ZAMM-Journal of Applied Mathematics and Mechanics/Zeitschrift  \nf ur Angewandte Mathematik und Mechanik 5 (2): 136-139.  \nPrˇsa A, Conroy KE, Horvat M, Pablo H, Kochoska A, Bloemen S, Giammarco J, Hambleton KM and Degroote P (2016), Dec. Physics Of Eclipsing Binaries. II. Toward the Increased Model Fidelity. ApJS 227 (2), 29. doi: 10.3847 / 1538-4365 / 227 / 2 / 29 . 1609.08135 .  \nPuls J (2009), Jul. Modeling the atmospheres of massive stars. Communications in Asteroseismology 158: 113.  \nPuls J, Vink JS and Najarro F (2008), Dec. Mass loss from hot massive stars. A&A Rev. 16 (3-4): 209-325. doi: 10.1007 / s00159-008-0015-8 . 0811.0487 .  \nPuls J, Najarro F, Sundqvist JO and Sen K (2020), Oct. Atmospheric NLTE models for the spectroscopic analysis of blue stars with winds. V. Complete comoving frame transfer, and updated modeling of X-ray emission. A&A 642, A172. doi: 10.1051 / 0004-6361 / 202038464 . 2011.02310 . Repolust T, Puls J and Herrero A (2004), Feb. Stellar and wind parameters of Galactic O-stars. The influence of line-blocking/blanketing. A&A 415: 349-376. doi: 10.1051 / 0004-6361:20034594 .  \nRivero Gonz'alez JG, Puls J, Najarro F and Brott I (2012), Jan. Nitrogen line spectroscopy of O-stars. II. Surface nitrogen abundances for O-stars in the Large Magellanic Cloud. A&A 537, A79. doi: 10.1051 / 0004-6361 / 201117790 . 1110.5148 .  \nRodr'ıguez D'ıaz LF, Lagae C, Amarsi AM, Bigot L, Zhou Y, Aguirre Børsen-Koch V, Lind K, Trampedach R and Collet R (2024), May. An extended and refined grid of 3D STAGGER model atmospheres. Processed snapshots for stellar spectroscopy. arXiv e-prints , arXiv:2405.07872doi: 10.48550 / arXiv.2405.07872 . 2405.07872 .  \nRybicki GB and Hummer DG (1978), Jan. A generalization of the Sobolev method for flows with nonlocal radiative coupling. ApJ 219: 654-675. doi: 10.1086 / 155826 .  \nSana H, de Mink SE, de Koter A, Langer N, Evans CJ, Gieles M, Gosset E, Izzard RG, Le Bouquin JB and Schneider FRN (2012), Jul. Binary Interaction Dominates the Evolution of Massive Stars. Science 337 (6093): 444. doi: 10.1126 / science.1223344 . 1207.6397 .  \nSchneider FRN, Podsiadlowski P, Langer N, Castro N and Fossati L (2016), Apr. Rejuvenation of stellar mergers and the origin of magnetic fields in massive stars. MNRAS 457 (3): 2355-2365. doi: 10.1093 / mnras / stw148 . 1601.05084 .  \nSchweitzer A, Hauschildt PH, Baron E and Allard F (2003), Jan., Using Superlevels to Calculate Molecular NLTE Problems, Hubeny I, Mihalas D and Werner K, (Eds.), Stellar Atmosphere Modeling, Astronomical Society of the Pacific Conference Series, 288, pp. 339.  \nShaviv NJ (1998), Feb. The Eddington Luminosity Limit for Multiphased Media.  \nApJ  \n494 (2): L193-L197. doi:  \n10.1086  \n/  \n311182  \n.  \nSim'on-D'ıaz S (2020), A Modern Guide to Quantitative Spectroscopy of Massive OB Stars, Reviews in Frontiers of Modern Astrophysics; From Space Debris to Cosmology, 155-187.  \nSim'on-D'ıaz S and Herrero A (2007), Jun. Fourier method of determining the rotational velocities in OB stars. A&A 468 (3): 1063-1073. doi: 10.1051 / 0004-6361:20066060 . astro-ph/0703216 .  \nSmith N and Owocki SP (2006), Jul. On the Role of Continuum-driven Eruptions in the Evolution of Very Massive Stars and Population III Stars. ApJ 645 (1): L45-L48. doi: 10.1086 / 506523 . astro-ph/0606174 .  \nSobolev VV (1960). Moving Envelopes of Stars. doi: 10.4159 / harvard.9780674864658 .  \nSteffen M and Freytag B (1991), Jan. Hydrodynamics of the Solar Photosphere: Model Calculations and Spectroscopic Observations.  \nReviews  \nin Modern Astronomy  \n4: 43-60. doi:  \n10.1007  \n/  \n978-3-642-76750-0 3  \n.  \n- Stein RF and Nordlund A (1989), Jul. Topology of Convection beneath the Solar Surface. ApJ 342: L95. doi: 10.1086 / 185493 .  \nSundqvist JO and Puls J (2018), Nov. Atmospheric NLTE models for the spectroscopic analysis of blue stars with winds. IV. Porosity in physical and velocity space. A&A 619, A59. doi: 10.1051 / 0004-6361 / 201832993 . 1805.11010 .  \nSundqvist JO, Owocki SP and Puls J (2018), Mar. 2D wind clumping in hot, massive stars from hydrodynamical line-driven instability simulations using a pseudo-planar approach. A&A 611, A17. doi: 10.1051 / 0004-6361 / 201731718 . 1710.07780 .  \nTennyson J and Yurchenko SN (2018), May. The ExoMol Atlas of Molecular Opacities. Atoms 6 (2), 26. doi: 10.3390 / atoms6020026 . 1805.03711 . Tennyson J, Yurchenko SN, Zhang J, Bowesman CA, Brady RP, Buldyreva J, Chubb KL, Gamache RR, Gorman MN, Guest ER, Hill C, Kefala K, Lynas-Gray AE, Mellor TM, McKemmish LK, Mitev GB, Mizus II, Owens A, Peng Z, Perri AN, Pezzella M, Polyansky OL, Qu Q, Semenov M, Smola O, Solokov A, Somogyi W, Upadhyay A, Wright SOM and Zobov NF (2024), Jun. The 2024 release of the ExoMol database: molecular line lists for exoplanet and other hot atmospheres. arXiv e-prints , arXiv:2406.06347doi: 10.48550 / arXiv.2406.06347 . 2406.06347 .  \nTing YS, Conroy C, Rix HW and Cargile P (2019), Jul. The Payne: Self-consistent ab initio Fitting of Stellar Spectra. ApJ 879 (2), 69. doi: 10.3847 / 1538-4357 / ab2331 . 1804.01530 .  \nud-Doula A and Owocki SP (2002), Sep. Dynamical Simulations of Magnetically Channeled Line-driven Stellar Winds. I. Isothermal, Nonrotating, Radially Driven Flow. ApJ 576 (1): 413-428. doi: 10.1086 / 341543 . astro-ph/0201195 .  \nUnsold A (1955). Physik der Sternatmospharen, mit besonderer Berucksichtigung der Sonne.  \nVink JS (2022), Aug. Theory and Diagnostics of Hot Star Mass Loss. ARA&A 60: 203-246. doi: 10.1146 / annurev-astro-052920-094949 . 2109.08164 . von Zeipel H (1924), Jun. The radiative equilibrium of a rotating system of gaseous masses. MNRAS 84: 665-683. doi: 10.1093 / mnras / 84.9.665 .  \nWade GA, Neiner C, Alecian E, Grunhut JH, Petit V, Batz Bd, Bohlender DA, Cohen DH, Henrichs HF, Kochukhov O, Landstreet JD, Manset N, Martins F, Mathis S, Oksala ME, Owocki SP, Rivinius T, Shultz ME, Sundqvist JO, Townsend RHD, ud-Doula A, Bouret JC, Braithwaite J, Briquet M, Carciofi AC, David-Uraz A, Folsom CP, Fullerton AW, Leroy B, Marcolino WLF, Moffat AFJ, Naz'e Y, Louis NS, Auri'ere M, Bagnulo S, Bailey JD, Barb'a RH, Blaz'ere A, Bohm T, Catala C, Donati JF, Ferrario L, Harrington D, Howarth ID, Ignace R, Kaper L, Luftinger T, Prinja R, Vink JS, Weiss WW and Yakunin I (2016), Feb. The MiMeS survey of magnetism in massive stars: introduction and overview. MNRAS 456 (1): 2-22. doi: 10.1093 / mnras / stv2568 . 1511.08425 .  \nWerner K and Husfeld D (1985), Jul. Multi-level non-LTE line formation calculations using approximate Lambda-operators. A&A 148 (2): 417422.  \n- Wilson RE and Devinney EJ (1971), Jun. Realization of Accurate Close-Binary Light Curves: Application to MR Cygni. ApJ 166: 605. doi: 10.1086 / 150986 .  \nYounsi Z, Wu K and Fuerst SV (2012), Sep. General relativistic radiative transfer: formulation and emission from structured tori around black holes. A&A 545, A13. doi: 10.1051 / 0004-6361 / 201219599 . 1207.4234 ."}