Atmospheric Temperature Profiles

Temperature and refraction

To calculate the path of a ray of light in the atmosphere, we must know the refractive index n [or, equivalently, the refractivity, ( n − 1 )] of the air at every height. What determines this refractivity profile?

The refractivity of air is very nearly proportional to its density, which the perfect-gas law says is proportional to the pressure, p, and inversely proportional to the (absolute) temperature, T. But p and T are also related, because the atmosphere is very nearly in hydrostatic equilibrium — that is, the pressure at every point is just the weight of the overlying gas column. [I have a more technical discussion of formulae for the refractivity of air, if you are interested.]

The upshot of all this is that the refractivity profile is determined by the temperature profile. So, what determines the temperature profile?

Temperature profiles and boundary layers

Mirages and green flashes are produced by thermal structure near the surface of the Earth. Temperatures in this region are strongly affected by the temperature of the underlying surface. The interaction between air and the adjacent surface is confined to a relatively thin boundary layer; the study of these layers is called “boundary-layer theory.”

Boundary layers are so important in meteorology that there is a whole journal devoted to this topic. They are also extremely important in aerodynamics. There are sub-fields of boundary-layer theory devoted to the transfer of energy and momentum across boundary layers; but the part we need has to do with the transfer of heat.


Meteorologists classify boundary layers as stable or unstable. (The names refer to stability against convection: stable layers suppress convection and turbulent mixing, and so tend to retain their structure.)

The dividing line between stable and unstable air corresponds to a lapse rate of about 10 K/km. That is, if the temperature falls by less than 10 (Celsius) degrees for each kilometer of height, the atmosphere is stable.

(The reason this critical lapse rate is not zero is that a parcel of gas expands and cools when it moves up to a region of lower pressure. In expanding, it has to “do work on” the surrounding gas, pushing it aside. The energy to do this work comes from the internal thermal energy of the parcel; so the parcel becomes cooler as it rises.)

On the average, as represented by the Standard Atmosphere, the lapse rate is only about 6.5° per km in the lower atmosphere, so it is weakly stable.

When the surface is colder than the overlying air, the atmosphere is very stable. Then the boundary layer will contain one or more thermal inversions. Thermal inversions are so stable that they effective decouple the air above them from the air below. Often a whole series of inversions develops, with a sort of layer-cake structure. These situations are not well understood theoretically.

On the other hand, if the surface is warmer than the overlying air, the air next to the warm surface will be heated, and become less dense than the air around it; then it is unstable, and convection occurs. There are good theoretical models for unstable, convecting boundary layers.


Sometimes textbook writers like to use oversimplified models of the atmospheric thermal structure, in explaining the optics of mirages. For an early example of such models, see the papers on mirage optics by Alfred Wegener, who represented thermal inversions as discontinuities in temperature.

But the real world does not allow temperature profile to be discontinuous. Even though heat conduction in gases is small, it guarantees that temperature gradients must remain finite: a discontinuous jump in temperature, such as Wegener assumed, would produce an infinite temperature gradient, and an infinite heat flow across the discontinuity. This would instantly restore a continuous temperature profile.

Continuous temperature profiles, composed of segments with constant lapse rates, are often used in meteorology textbooks. Such “piecewise linear” profiles are continuous, but not smooth (they have sharp corners where one straight line segment joins the next). The program I use for calculating refraction is based on such profiles. (In the language of calculus, they have discontinuous first derivatives.)

But the real world does not even permit that. A constant temperature gradient corresponds to a constant heat flow down the gradient. But a discontinuity in the gradient means a discontinuity in the heat flow: at this point, an infinitely thin layer of air would have a finite amount of heat added to it every second. Because an infinitely thin layer has zero heat capacity, this finite heat load would produce an infinite heating rate at the sharp corner in the profile.

So, in reality, atmospheric temperature profiles must be smooth as well as continuous. (In the language of calculus, they must have continuous first derivatives.) In other words, the lapse rate must be a continuous function of height. Sharp corners are an oversimplification; they really must be rounded off. This turns out to be important: there are several observed refraction phenomena that appear primarily in these rounded corners (e.g., the mock-mirage green flash; see this simulation).

For the purposes of refraction calculations, I represent the rounded corners by thousands of very thin sub-layers, each with a gradient very slightly different from the next. By making the layers very thin, I can approximate the real world very closely.


Given a realistic temperature profile, I can calculate the corresponding refraction at every point in the sky, and for any given wavelength. This allows simulated images of the low Sun. These simulations can be compared to actual photographs of low-Sun phenomena, such as green flashes. Likewise, it's possible to simulate mirages.

The comparison of simulated with real images allows the real situations to be interpreted, if a close simulation can be obtained. The simulations also show how the observed phenomena vary with height of the eye, which can be useful as a guide in obtaining more observations. From this interplay between theory and observation, it's possible to learn something about green flashes, mirages, and other refraction phenomena.

Copyright © 2002 – 2008, 2012, 2014 Andrew T. Young

Back to the ...
GF reading page

or the GF pictures page

or the main mirage page

or the GF home page

or the Overview page