The air we breathe is made up of significant quantities of four gases:

  1. Nitrogen (78%)
  2. Oxygen (21%)
  3. Argon (0.94%)
  4. Carbon dioxide (0.04%)

When we breathe in air, our bodies consume its oxygen and convert it to carbon dioxide. Exhaled air contains about 4.5-percent carbon dioxide. Our bodies do not do anything with nitrogen or argon.

A submarine (or a space ship, for that matter) is a sealed container that contains people and a limited supply of air. There are three things that must happen in order to keep air in a submarine breathable:

  1. Oxygen has to be replenished as it is consumed. If the percentage of oxygen in the air falls too low, a person suffocates.
  2. Carbon dioxide must be removed from the air. As the concentration of carbon dioxide rises, it becomes a toxin.
  3. The moisture that we exhale in our breath must be removed.

Oxygen is supplied either from pressurized tanks, an oxygen generator (which can form oxygen from the electrolysis of water or by some other means) or some sort of "oxygen canister" (You may remember these canisters because of their problems on the MIR space station -- they release oxygen by a very hot chemical reaction). Oxygen is either released continuously by a computerized system that senses the percentage of oxygen in the air, or it is released in batches periodically through the day.

Carbon dioxide can be removed from the air chemically using soda lime (sodium hydroxide and calcium hydroxide). The carbon dioxide is trapped in the soda lime by a chemical reaction and removed from the air. Other similar reactions can accomplish the same goal.

The moisture can be removed by a dehumidifier or chemically. This prevents it from condensing on the walls and equipment inside the ship.

Here are some interesting links: