Sunshine In = Earthshine Out

No computer simulations have ever had broader consequences for human life than the current generation of climate models. The models tell us that rising levels of atmospheric carbon dioxide and other greenhouse gases can trigger abrupt shifts in the planet’s climate; to avert those changes or mitigate their effects, the entire human population is urged to make fundamental economic and technological adjustments. In particular, we may have to forgo exploiting most of the world’s remaining reserves of fossil fuels. It’s not every day that the output of a computer program leads to a call for seven billion people to change their behavior.

Thus sayeth I in my latest American Scientist column (HTML, PDF). Climate is a subject I take up with a certain foreboding. The public “debate” over global warming has become so shrill and dysfunctional that I can barely force myself to pay attention, much less join the fray. As I worked on writing the column, I found myself tiptoeing through the polemical minefield, carefully avoiding any phrase that might be picked up by “the other side” and used against me. (“Even a writer for American Scientist has doubts about . . .”). When I handed in the text, my editors went over it with the same cautious anxiety—and they found a few places where they thought I hadn’t been careful enough.

This is not the kind of science I enjoy. I would much prefer to dwell in less-contentious corners of the cosmos, where I can play with my sticky spheres or my crinkly curves, and never give a thought to “the other side.” But now and then one must return to the home planet. Besides, the computer modeling that plays a major role in climate science is just my kind of thing.

So, for the past few months climate models have been my breakfast, lunch, and dinner, and my bedtime snack. I’ve been reading in the literature, and poring over source code; I’ve managed to get a couple of serious models running on a laptop. The American Scientist column says more about the rewards and frustrations of all these undertakings. Here I want to talk about a lighter side of the project: a little climate model of my own. The image below is just a static screen grab, but you can go play with the real thing if you’d like.

Screen grab of the energy-balance model user interface

Okay, it’s not really all my own. The physics behind the model was explored more than 100 years ago by Svante Arrhenius. The first computer implementations were done by M. I. Budyko and William Sellers in 1969, and a third version was published by Stephen Schneider and Tevi Gal-Chen in 1973. But the JavaScript is mine. (Any mistakes are mine, too.)

The model is a simple one. The planet it describes is not the Earth we know and love but a bald sphere without continents or oceans, seasons or storms, or even day and night. Temperature is the only climatic variable. The globe is divided into latitudinal stripes five degrees wide, and temperatures are always uniform throughout a stripe. Other than warming and cooling, the only thing that can happen on this planet is freezing: If the temperature in a stripe falls below –10 degrees Celsius, it grows an ice sheet.

Why pay any attention to such a primitive model? Although a zillion details are missing, some important physical principles emerge with particular clarity. At the heart of the model is the concept of energy balance: If the Earth is to remain in thermal equilibrium with its surroundings, then it must radiate away as much energy as it receives from the Sun. The planet’s temperature will rise or fall in order to maintain this balance. The governing equation is:

\[Q (1 - \alpha) = \sigma T^{4}.\]

Here \(Q\) is the average intensity of incoming solar radiation in watts per square meter, \(\alpha\) is the albedo, or reflectivity, and \(T\) is temperature in Kelvins; \(\sigma\) is the Stefan-Boltzmann constant, which relates thermal emission to temperature. The numerical value of \(\sigma\) is \(5.67 \times 10^{-8} \mathrm{W m^{-2} K^{-4}}\). In other words, sunshine in = earthshine out.

If we know the solar input, we can calculate the Earth’s temperature at equilibrium by solving for \(T\):

\[T = \sqrt[4]{\frac{Q (1 - \alpha)}{\sigma}}\]

This is exactly what the energy-balance model does.

Two more effects need to be taken into account. First, most of the sun’s energy is received in the tropics, but it doesn’t all stay there. On the Earth, heat is redistributed by the process we call weather—evaporation and condensation, winds, storms, etc.—and also by ocean currents. In the model, the effect of all that swirly fluid dynamics is crudely approximated by a diffusive flow that simply smooths out temperature gradients.

Finally, there’s the greenhouse effect. Solar radiation at visible wavelengths passes through the Earth’s atmosphere to warm the surface, but the Earth emits at longer wavelengths, in the infrared; radiation in that part of the spectrum is absorbed by water vapor, carbon dioxide, and other minor constituents of the atmosphere. The blocked infrared emission raises the temperature at the surface by 30 degrees Celsius or more. The Earth would be a very chilly place without this effect, but the burning issue of the moment is how to avoid overheating. The model sidesteps all the complexities of atmospheric chemistry and absorption spectra; a single parameter, H, simply determines the fraction of outgoing radiation trapped by greenhouse gases.

The interface to the model has four controls—sliders that adjust the incident solar flux, the albedo of land, the albedo of ice-covered regions, and the greenhouse parameter. While playing with the slider settings, it’s not hard to get the model into a state from which there is no easy recovery. That’s what the reset button is for. (Too bad the real planet doesn’t have one.)

Some experiments you might try:

  • The default greenhouse setting is H = 0.4, meaning that 40 percent of the outgoing radiation is intercepted. Lower the slider to below 0.2. The model enters a “snowball Earth” state, where ice sheets descend all the way to the Equator. Now return the greenhouse slider to the default setting of 0.4. The ice persists, and it will not melt away until the control is moved to a still higher setting. When the thaw does come, it is sudden and overshoots, leaving the planet in a much warmer state.
  • Raise the greenhouse slider to about 0.45, where the polar ice cap disappears. Returning the slider to 0.4 does not restore the ice cap, and the polar areas remain several degrees warmer than they were before the greenhouse excursion.
  • Raising the land albedo (so that more sunlight is reflected from snowfree surfaces, and less is absorbed) reveals another “ratchet” mechanism. Once the planet becomes totally icebound, further changes in the land albedo have no effect at all. The reason is simply that no ice-free land is exposed.
  • Push the greenhouse slider toward the top of the scale. Beyond H = 0.75, tropical temperatures approach the boiling point of water, and the planet has obviously become uninhabitable. Question: What will happen at H = 1.0, where no radiation at all can escape the atmosphere?

Some of the extreme parameter values mentioned above yield fanciful results that would never be seen on the Earth. But certain interesting aspects of the model seem quite plausible. I am particularly intrigued by the presence of abrupt changes of state that look much like phase transitions. If we consider just the value of the greenhouse parameter H and the average global temperature T, we can draw a two-dimensional phase diagram in the (H, T) plane. The plot below traces the system’s trajectory as H is lowered from 0.4 to 0.2, then raised to 0.5, and finally returned to the initial setting of 0.4.

Greenhouse hysteresis plot

That four-sided loop is the hallmark of hysteresis (a term first introduced in the study of magnetic materials). Initially, as the greenhouse effect weakens, temperature falls off linearly. Then, at about H = 0.3, the curve steepens. (The stairsteps represent the freezing of successive zones of latitude.) Just below H = 0.218, the temperature falls off a cliff, dropping suddenly by 20 degrees Celsius. On the next segment of the curve, as H increases again, the temperature again responds linearly, but in a much colder regime. Only when H reaches 0.459 is warmth restored to the world, and this time there’s an abrupt upward jump of almost 35 degrees.

It’s no mystery what’s causing this behavior. There’s a strong feedback effect between cooling/freezing and warming/thawing. When the temperature in a latitude band falls below the –10 degree threshold, the zone ices over; the ice-covered surface is more reflective, and so less heat is absorbed, cooling the planet still more. Going in the other direction, when the ice melts, the exposed land absorbs more heat and brings still more warming.

The sharp, discontinuous transitions in the graph above could not happen on the real planet. They are possible in the model because it has no notion of heat capacity or latent heat; after every perturbation, the system instantly snaps back to equilibrium. But if the hysteresis loop in the model has unrealistically sharp corners, its basic shape is not impossible on a physical planet. What’s most important about the loop is that over a wide range of greenhouse parameters, the system has two stable states. At H = 0.4, for example, the world can have an average temperature of either 14 degrees of –22 degrees. That kind of bistability may well be possible in terrestrial climate.

Snowball Earth is not a fate we need to worry about anytime soon, but there is evidence that the planet actually went through such frozen states early in its history. The runaway greenhouse effect that would boil away the oceans is also not an immediate threat. So can we rest easy about living on a sedate, linear segment of the H-T curve? That’s a question that climate models are supposed to answer, but it’s beyond the scope of this particular model.

This entry was posted in computing, featured, physics.

3 Responses to Sunshine In = Earthshine Out

  1. Stephen E Schwartz says:

    Hello Brian Hayes

    I greatly appreciate your effort to make and make available a transparent climate model. So I was looking forward to running it and even more to seeing what was in it.

    Unfortunately I got hung up on the readme file. I am used to readme files that open and you read them. This one installed a program called Calibre, which I cannot get to read the document. I push every logical button and at best I get it to attempt to download another copy of the file. I am sure that there is something I am not doing right, but I hope that the opacity of the readme file is not indicative of the opacity of the climate model.

    As for the model itself, there are several key parameters that must be hidden under the hood. Important are the heat capacity for each compartment and some measure of the rate of transfer of heat from the surface compartment to the deeper compartment. Also with a zonal model you need some sort of coefficient of meridional heat transfer: You are absorbing more solar energy at low latitudes and moving that heat to high latitudes. So that requires a (probably zonally dependent) heat transfer coefficient. Also, of course the albedo must be a function of zone. Similarly the normalized GH effect must be a function of zone: more water vapor at lower latitudes (higher temperatures). I had hoped this sort of information would be in the readme, but as I say, I am unable to read the readme, pretty near a first time for that.

    Thanks for listening.


    • Brian Hayes says:

      Your questions about a readme file baffled me for a moment, because I wrote no readme file. (Perhaps I should have.)

      Then I realized that you are looking at the file inside the folder named “noUiSlider-7.0.0.” This is a code library that I didn’t write; I’m just using it to provide the sliders that control the model onscreen. You won’t find anything about the model inside that file, but if you want to see what’s inside you can open it as an ordinary text file. (I don’t know what Calibre is, but apparently your system thinks that Calibre is the program that opens files with extension “md”. That extension stands for Markdown, a sort of abbreviated HTML.)

      Anyway, if you want to know what’s inside the model, the place to look is the file ebm.js, which has the JavaScript source code. That file, too, should open in an ordinary text editor. The program includes verbose comments explaining what’s going on.

      As for your other questions, I think I should just reiterate that this is a very simple model — as I said above, it’s not the Earth we know and love but a bald sphere….

      You are quite right that any realistic model would make albedo and atmospheric water vapor a function of latitude, but this isn’t a realistic model. As a matter of fact, there is no water vapor on the model planet. Heat capacity is also not an issue, because the model has no dynamics, no concept of time; after any change in the controlling parameters, it immediate shifts to the new equilibrium state. The transport of heat between latitude zones is based on the temperature difference between each zone and the global average temperature, which is not a physically plausible mechanism. (This scheme for heat transport comes from the 1969 models by Budyko and Sellers mentioned above. Steve Schneider used the same scheme a few years later, but he tried adding heat capacity and dynamics.)

      The more realistic kinds of physics that you mention could be added to the model, and if you are interested in giving that a try, I encourage you to do so.

      Are energy-balance models like this one a good starting point for simulations that seek to make quantitative predictions about the Earth’s climate? History says no. After the work of Budyko, Sellers, and Schneider, this line of work was largely abandoned, and attention shifted to general circulation models, which are still the main paradigm for computational climate science. Maybe it’s time to go back for a second look at paths not taken; I don’t know.

  2. Stephen E Schwartz says:

    Hello again Brian Hayes. Thanks for clarification on the Readme files; no I dont want to get into java code; climate is complex enough. I had thought that the Readme was telling me more about the climate model, not about the java code.

    Let me first of all extend my compliments to you for trying to demystify climate models and the climate system. The unpertubed climate system may be thought of as a steady state, as you describe. Shortwave (solar) radiation in; Longwave (thermal infrared) out. (NOT an equilibrium, which requires equal and opposite fluxes on all paths — detailed balance requirement).

    Part of the reason I asked about the parameters of your climate model is my view that in climate models in general there are more parameters than knowns; the more parameters one adds to a climate model, e.g., coupling between different latitude zones, the more one has to adjust them to meet some target. This is manifested in the current crop (and previous crops) of large scale climate models — so called GCMs (global climate models, but the acronym previously stood for general circulation models), which incorporate representations of many physical processes such as organized flows that occur on resolved scales but also many parametrizations of processes that take place on unresolved scales. The current climate models get global mean temperature to what one might say is very good accuracy, about 1%. This is remarkably good in the context of measurements of radiative fluxes, for example, that are highly variable in space and time, and indeed radiation is tough to measure at 1% accuracy. But one percent in global mean temperature is still 3 K, which is a huge span in temperature, some 4 times the measured increase in global temperature from 1880 to present. A variation of 3 K should result in a very different climate: ice lines, sea ice, water vapor in atmosphere … Yet despite this, the current crop of models all accurately reproduce the increase in global temperature over the twentieth century of about 0.8 K. How can this be? Compensating errors. There are lots of other comparisons one can make of climate model output with observations. For example the climate models all get more or less the observed planetary albedo, but the seasonal and latitudinal representation of albedo differs from observations by as much as ± 0.1, a huge amount in terms of radiation.

    Because of concerns such as these I favor simple models of Earth’s climate system (Determination of Earth’s transient and equilibrium climate sensitivities from observations over the twentieth century: Strong dependence on assumed forcing. Schwartz S. E. Surveys Geophys. 33, 745-777 (2012). DOI 10.1007/s10712-012-9180-4) and it is that perspective that prompted my interest in your model. A two compartment climate model consisting of an upper compartment, radiatively coupled to space (solar radiation in and IR out), and thermally coupled to a lower, deep ocean compartment. If the system, considered initially in steady state, is perturbed, then such a model responds to the perturbation. The time constant of the deep ocean compartment (inferred from the volume of the deep ocean and the coupling constant to the upper compartment is so large (ca 500 yrs) that one can omit the reverse heat flow to good accuracy. The deep ocean is then a sink for the perturbation just like the enhanced longwave out the top of the atmosphere that results from increasing the radiative temperature of the surface. It is these two sinks: thermal to the deep ocean and radiative to space (also including any change in albedo) that govern the planetary sensitivity to perturbation in radiative budget on time scale of say a century. As the perturbation from greenhouse gases and other human influences has been gradual, the system responds like a forced, single time constant system (think RC circuit), lagging the perturbation by one time constant. Based on observation of response of the system (change in temperature and heat content) to the anthropogenic perturbation one can infer a time constant, about 5-10 years, and heat capacity.

    In any event, you and your followers might want to consider even such a simpler model, which does include temporal response and seems to rather accurately represent the dynamics of the temperature response of the system that is based on observations. To my thinking such a model is very useful in understanding prior climate change and in projecting future response to prospective changes, for example changes in future CO2 emissions.

Leave a Reply

Your email address will not be published. Required fields are marked *


In addition to the basic HTML formatting options offered by the buttons above, you can also enter LaTeX math commands. Enclose LaTeX content in \( ... \) for inline mode or \[ ... \] for display mode.