World Energy and Climate
Gerard Westendorp, 2010

On this web page, I want to get some facts straight about global warming and global energy.
I'll try to be "non-political": I am not trying to work towards a particular outcome, but I just want to get some estimates about what is going on.

Temperature of the earth

Model description
The simplest model I can think of, that still reflects the main effects is shown below.
Thermal model of earth
The earth is radiated from the sun.
Averaged over 24 hours, and over latitude, 30% reflection subtracted, you get about 235 W/m2 of radiation.
This radiation is mainly visible light, so it basically goes straight through the atmosphere, and then heats the earth's surface.
Assume all radiation that is not reflected is absorbed, and the re-radiated as black body radiation.
This black body radiation goes partly to outer space, partly to the atmosphere.
The atmosphere also radiates, but the amount it radiates and absorbs depends on the so-called "gas emissivity" (εgas).

Gas emissivity
To estimate the gas emissivity (εgas), we can use the same graphs as are used for combustion chambers.
The atmosphere contains mainly 20%O2, 79%N2, 0.03%CO2 and 1%Argon. In addition, it has water vapour, which is about 1% if the air is 20'C, and 0.2% at -20'C.
To get the number, we need to multiply the partial pressure by the ray length through the gas.
The partial pressure of CO2 will be about 0.0003 at sea level. To get the "ray length", we need an extra graph, that tells us how CO2 pressure varies with height in km. This graph is also included: (pCO2 varies as exp[-mgh/kT]). The effective ray length turns out to be 5.3 km, so we look up 5300*0.0003=1.58 in the left graph.

gas emmisivity of CO2 gas emmisivity of H2O
These graphs are used in furnaces, but can also be applied to the atmosphere (much less CO2, but much longer ray length)
CO2 pressure in atmosphere
This graph is used to estimate the integral of partial pressure of CO2 integrated over the atmosphere

Combining the graphs, we get a contribution of CO2 to the gas emissivity of about 0.2 (An emissivity of 1 would mean all radiation from the earth is absorbed into the atmosphere.)
It is clear that the contribution due to water vapour is significantly higher that that due to CO2. But water vapour is more complicated, because it depends on condensation of water, rather than on gravity. But these are details to keep the experts busy.
The total emissivity will be somewhere between 0.6 to 0.9. with the total CO2 contribution in the order of 0.2.

Now for the result:
I put the model into a spreadsheet that solves the equations, assuming the temperature is in equilibrium. The result is in the graph below. 
Temperature of the earth
Results from the simplified model

Clouds and snow
The reflection of sunlight can change due cloud changes and changes in snow distribution. This can be a significant effect, 10% more sun = 6 degrees.  However, the model will become very complex by including this. Which is cool if you are an expert, but an inconvenient truth if you don't have much time.

Model results for other planets
Mercury (εgas = 0, Q_sun =2500W/m2) : 186'C (Approximately correct)
Venus (εgas = 1, Q_sun = 500W/m2) : 92'C (Real value = 460'C)
Mars (εgas = 0, Q_sun = 140W/m2) : -53'C(Approximately correct)

1. If there was no atmosphere (εgas = 0) , the earth would be about -19'C. This averaged over latitude and day/night. [Check: This should also be the correct result for our moon. According to Wikipedia, the moon the surface temperature averages 107 °C, and during the lunar night, it averages −153 °C. The average of that is -23'C, which is close enough to -19'C, considering the simplicity of our model.]

2. The present temperature is 14'C (Again averaged over latitude+time of day). So the effective emissivity of the atmosphere is about 0.6-0.7, which is in the range of what we estimated earlier.

3. If  εgas = 1 earth surface would be 30'C average. (But see point 6)

3. Doubling CO2 concentration would  increase the temperature of the earth by a couple of degrees.

4. A 10% increase in the effective sun radiation would heat up the earth about 6 degrees. recent natural variation in sun radiation is about 0.1%. But the "albedo", or reflectivity, may change, for example due to an ice age.

5. These result agree more or less  with the Wikipedia article on global warming.

6. The model does not work for Venus. This is because if  εgas ~ 1, the atmosphere should not be modeled as a single layer. On Venus, the atmosphere is 95% CO2,  at 90Atm pressure. This results in a much higher surface temperature than predicted by our model: 460'C versus 96 'C.

Put into historical perspective:
During the recent ice ages, the temperature was about 5 degrees lower, and the CO2 was 0.02% instead of 0.03%.
100 million years ago, during the Cretaceous period, temperatures were about 5'C higher, and CO2 was probably higher than 0.1%.

Paleoclimatology also has some warnings for us: There are quite a lot of ways in which feed-forward loops can amplify climate changes. For example, the abrupt end of ice ages are probably caused by a trigger, which then self-amplifies. (eg. less snow, less reflection, more greenhouse water vapour etc)

The cause of recent CO2 rise
Did we cause the recent rise in CO2 (0.032% in 1960, to 0.038% in 2010)?

The nicest picture of the Carbon cycle I could find was this:
Carbon cycle
Picture found on the Internet (I can't find the original author) The land use flux is CO2 released when forest soil is converted to agricultural soil.

Fossil fuel burning is a relatively small flux. But because it is a recently added flux, the system will adapt to a new equilibrium, which will be at a higher atmospheric concentration. As can be seen from the diagram, the vegetation and ocean uptake is trying to respond to the 7.9 Gton/yr with a net 3.1 Gton/yr. Assume this net flux was zero in pre-industrial times, (equilibrium!) when the CO2 concentration was 0.028%. If the compensating flux is proportional to the deviation from 0.028% concentration equilibrium, then the concentration will rise until it is 0.028 + 7.9/3.1* (0.036-0.028) = 0.048%, with the present fossil burning + land re-use rate.

There is uncertainty in these numbers, but is pretty certain that we tipped the balance toward the recent CO2 increase. For example, the "new" CO2 has less C-14 isotope, which indicates that is old carbon, coming from fossil fuel.

Note that the carbon stored in the ocean is very large. It is almost 10 times the total carbon stored as fossil fuel, which is estimated at 4000 Gton. 39000 Gton is roughly what you would expect for equilibrium with the atmosphere, at a water pressure of 50 bar, which exists at a depth of 500 meter.

Note on volcano's:
The "Volcano flux" is about 0.3 Gton/yr. But in geological times, this was not always true. Also, CO2 removal by geological mechanisms (formation of carbonates, fossil fuel, chemical absorption) is small. But because this part of the "cycle" is partly irreversible, all carbon will eventually be drained from the atmosphere. Ironically, we will ultimately be killed by lack of CO2...

Global energy
Assume that we want to replace fossil fuel by something else. What are the numbers?

A human eats about 10 MJ of energy per day. This is 115 Watts of power.
At the same time, the world primary energy consumption, divided by the wold population, is 3000 Watts per person.
This perhaps characterizes the challenge: We don't just need to find food, we need to find 26 times the amount, to sustain our way of life.
This energy goes into heating homes, transportation, entertainment, making steel, aluminium,  etc.
Note: The 3000 Watts is primary fuel. Electricity is generated with 35% efficiency from this, so we need only 1000 Watt of electric power.

To change to non-fossil fuel, we have to solve 3 problems
 1. Generate 15 TeraWatt (1.5 E13 Watt) of power, or 3000W per person.
 2. Storage: Store energy for periods when supply < demand (ie no wind or sun)
 3. Portability: Supply 30% of the energy in a portable form for cars and planes(batteries, hydrogen, synthetic fuel)

Fossil fuel
The required 3000 Watt is about 8 liter of oil per day.
With a cost of $100 per barrel, this is $1900 per year (remember, this is not just you energy bill and petrol bill, but also those of all the industries that are indirectly working for you.)
The investment cost for fossil-fuel power plants are about $1 per Watt electric, or $1000 per person. For a family of 4 people, this is $4000.

1000 Watt electric per person , with an efficiency of 10% and solar flux of 235 W/m2 ,would mean a solar panel of 42 m2.
The price of panels is about 4 dollar per Watt max power [2010 ad], say $12  per Watt average power.
You can make portable energy in the form of hydrogen, but you need to take into account an efficiency of 35%, (70% for making H2, 50% for reconverting to electric) so you need to generate 3 times the primary power for the portable section of your total need.
If you want do all that with solar, you need (0.7 + 0.3/0.35)*12*1000 = $18000 per person. For a family of 4 people, this is $72000. 
Probably, everyone is waiting for solar to become cheaper. Note in 2016: It is getting quite a lot cheaper.

There is  enough wind on earth to power our needs.
The cost per installed Watt is about $1 per Watt max power. But with a "capacity factor" of  12%, this means $8 per Watt electric
Cheaper than solar, but still $48000 for a family of 4 people.
"Capacity factor" is delivered power/ installed power, which is lower than 100% because the wind supply is not constant.

The investment per Watt per person is about 2 times that of a fossil fuel power plant. This makes it the cheapest alternative to fossil fuel, with the present prices. Remember we also need to generate double the conventional power, to create 30% portable energy. So the investment is $4000 per person. For a family of 4 people, this is $16000. Although Nuclear is the cheapest option, discussions about safety prevent it from being the obvious choice for the future.

Nuclear fusion
The process that makes the sun shine might one day work on earth.

The total amount of harvestable wave energy is estimated at 4 TeraWatt. Not enough for humanity, but perhaps interesting in some regions.

The earth gives off 44 TeraWatt of internal heat. 3 times the total need, but it is spread out over the whole surface of the planet. Only in some places it can be harvested economically. In these places, it can be interesting, but it will not solve the global problem.

Muscle power
Unfortunately, generating 100 Watt for 1 hour is pretty tiring for a human being. We need 1000 Watt. 

Bio fuel
Probably the oldest form of power after muscle power.
The 1E11 ton/year of captured carbon by photosynthesis is equivalent to 114 TeraWatt, or 7.6 times the world primary energy need.
Maybe possible, but it means that 15-20% of all plant life and algae on earth is being burnt in our furnaces.
Note on Photosynthesis versus photoelectric
Plants are cheaper than solar panels, but they are less efficient.  The photosynthetic efficiency is 1 to 4%. Theoretically, 11% could be reached, for example with algae. But so far, no one has succeeded in putting this in practice after subtracting all kinds of associated energy costs. (eg pumping air into the algae reactor)
The photosynthesis in the sea is limited by mineral availability. Locally fertilizing the sea might work.

Storage of energy and infrastructure
Solar and wind have a mayor storage problem: What to do when there is no wind or sun?
A good way to store energy that needs not be portable is hydroelectric.
A 1000X1000X10 meter3 lake at  100 meter altitude is 2.7 GW-hour.
If you need power, and there is no wind or sun, you either get it from another region where there is, or from storage.
This means we will need a "super power grid": a grid that can transport power with low loss over large distances.

An exciting new idea for energy storage is using bags filled with pressurised air under water, at a depth where the surrounding water pressure helps to contain the air pressure. I had this idea myself, but found out that other people were working on it already. Here is a youtube clip explaining the concept and its development.
"Energy bags": A possible low cost way of storing wind energy.

Portability of energy
A problem that is easy with oil, but hard with alternatives is the portability.
One possibility is Hydrogen. You can electrolyze it from water, and then burn it, or get power from a fuel cell.
The volume per Joule of energy is about 5 times more than petrol, if you use 700 atmosphere compression.
Batteries are a possibility. It is hard to say if they will beat hydrogen fuel cells in the long run. The energy per volume is worse, but the charging/ discharging efficiency is better.

Hydrogen or synthetic hydrocarbon might also be an energy storage solution, especially in regions with a lot of supply and little demand. (Deserts, oceans)

Total impact of transition from fossil fuel
The investments mentioned, could add up to about $20000 per human being.
This is comparable to the GDP per capita of a typical country. If we spend 5% of GDP on it, it would take us 20 years.
Seems like a fun project, better than making war.

Further reading
There is a huge amount of stuff on the Internet that you can read. All of the things I wrote are quite rough first estimates. I could supply links, but you may as well Google them yourself. Unfortunately, I do not have the time to keep the administration of the best links up to date.