Suppose we have a planet whose atmosphere is perfectly transparent to short-wave radiation from the Sun. The surface of the planet is made of sand, which warms up quickly. It warms until it loses heat by radiation and convection as fast as it receives heat from the Sun. Meanwhile, we suppose that the lower atmosphere is opaque to long-wave radiation so all the heat from the Sun ends up in the lower atmosphere. The lower atmosphere gets hot. It rises. Like all atmospheres, this one gets thinner as we ascend. Eventually it is so thin that it becomes transparent to long-wave radiation. This layer of the atmosphere is the tropopause. The tropopause radiates heat into space according to Stefan's Law. Air in the tropopause cools until it becomes so dense that it sinks towards the surface. And so atmospheric convection begins. The heat arriving from the Sun passes into the lower atmosphere, is carried up to the tropopause by convection, and is radiated into space.
We have described such a planet and atmosphere before, in Planetary Greenhouse. Today's CC3 program simulates the transportation of heat through such an atmosphere. You can download the program here. Running in its Planetary Greenhouse configuration, CC3 supplies heat to cells in the bottom row at a constant rate. Each bottom cell heats up by Q_heating K per iteration, regardless of its temperature. Meanwhile, a cell in the top row at temperature T_balance cools by Q_heating K per iteration. At other temperatures, the cooling rate of the upper cells increases as the fourth power of the cell temperature.
In the simulation, Q_heating represents the heat arriving from the Sun. The top cells represent the tropopause, and the heat they lose is the heat radiated by the tropopause into space. The heat radiated into space by the top cells will be equal to the heat arriving from the Sun when the temperature of all the top cells is T_balance. We start the simulation with all cells at 250 K, Q_heating = 0.01 K, and T_balance = 250 K. The top cells start to cool immediately. The lower cells start to heat up.
In CC3, we corrected our implementation of heat mixing in accordance with the suggestions made by Michele. You will find our new implementation in the heat routine. We added a reporting text window, as you can see in the screen shot above. You open the window with the Reporting button. The program calls report every reporting_interval iterations, or whenever you press the Report button. We instructed report to print the average temperature of the cell rows. We added a check procedure that checks for convergence of the simulation, as requested by Peter. In the comments below I'll provide some convergence code that you can paste into the check routine. In order to accommodate the planetary greenhouse temperature variations, we doubled the breadth of the color-coded temperature range. Red is now 320 K and blue is 220 K. The Configure button allows you to change the simulation parameters while the simulation is running. Be careful not to enter invalid numbers or else the program will abort with an error.
We're running the program now. It takes several hundred thousand iterations to reach equilibrium. In our next post, will present the vertical temperature profile under various conditions. We are curious to see how the temperature of the surface is affected by the amount of heat the atmosphere must transport, and by the amount of mixing we allow between cells.