The octane rating of gasoline tells you how much the fuel can be compressed before it spontaneously ignites.

Justin Sullian/Getty Images

Introduction to How Gasoline Works

In the United States and the rest of the industrialized world, gasoline is definitely a vital fluid. It is as vital to the economy as blood is to a person. Without gasoline (and diesel fuel), the world as we know it would grind to a halt. The U.S. alone consumes something like 130 billion gallons (almost 500 billion liters) of gasoline per year!

What is it in gasoline that makes it so important? In this article, you will learn exactly what gasoline is and where it comes from.

What is gasoline?

­ ­Gasoline is known as an aliphatic hydrocarbon. In other words, gasoline is made up of molecules composed of nothing but hydrogen and carbon arranged in chains. Gasoline molecules have from seven to 11 carbons in each chain. Here are some common configurations:

H H H H H H H     | | | | | | |   H-C-C-C-C-C-C-C-H         Heptane     | | | | | | |     H H H H H H H     H H H H H H H H     | | | | | | | |   H-C-C-C-C-C-C-C-C-H       Octane     | | | | | | | |     H H H H H H H H     H H H H H H H H H     | | | | | | | | |   H-C-C-C-C-C-C-C-C-C-H     Nonane     | | | | | | | | |     H H H H H H H H H     H H H H H H H H H H     | | | | | | | | | |   H-C-C-C-C-C-C-C-C-C-C-H   Decane     | | | | | | | | | |     H H H H H H H H H H

Typical molecules found in gasoline

When you burn gasoline under ideal conditions, with plenty of oxygen, you get carbon dioxide (from the carbon atoms in gasoline), water (from the hydrogen atoms) and lots of heat. A gallon of gasoline contains about 132x106 joules of energy, which is equivalent to 125,000 BTU or 36,650 watt-hours:

  • If you took a 1,500-watt space heater and left it on full blast for a full 24-hour day, that's about how much heat is in a gallon of gas.
  • If it were possible for human beings to digest gasoline, a gallon would contain about 31,000 food calories -- the energy in a gallon of gasoline is equivalent to the energy in about 110 McDonalds hamburgers!

Where does gasoline come from?

­ ­Gasoline is made from crude oil. The crude oil pumped out of the ground is a black liquid called petroleum. This liquid contains hydrocarbons, and the carbon atoms in crude oil link together in chains of different lengths.

It turns out that hydrocarbon molecules of different lengths have different properties and behaviors. For example, a chain with just one carbon atom in it (CH4) is the lightest chain, known as methane. Methane is a gas so light that it floats like helium. As the chains get longer, they get heavier.

The first four chains -- CH4 (methane), C2H6 (ethane), C3H8 (propane) and C4H10 (butane) -- are all gases, and they boil at -161, -88, -46 and -1 degrees F, respectively (-107, -67, -43 and -18 degrees C). The chains up through C18H32 or so are all liquids at room temperature, and the chains above C19 are all solids at room temperature.

The different chain lengths have progressively higher boiling points, so they can be separated out by distillation. This is what happens in an oil refinery -- crude oil is heated and the different chains are pulled out by their vaporization temperatures. (See How Oil Refining Works for details.)

The chains in the C5, C6 and C7 range are all very light, easily vaporized, clear liquids called naphthas. They are used as solvents -- dry cleaning fluids can be made from these liquids, as well as paint solvents and other quick-drying products.

The chains from C7H16 through C11H24 are blended together and used for gasoline. All of them vaporize at temperatures below the boiling point of water. That's why if you spill gasoline on the ground it evaporates very quickly.

Next is kerosene, in the C12 to C15 range, followed by diesel fuel and heavier fuel oils (like heating oil for houses).

Next come the lubricating oils. These oils no longer vaporize in any way at normal temperatures. For example, engine oil can run all day at 250 degrees F (121 degrees C) without vaporizing at all. Oils go from very light (like 3-in-1 oil) through various thicknesses of motor oil through very thick gear oils and then semi-solid greases. Vasoline falls in there as well.

Chains above the C20 range form solids, starting with paraffin wax, then tar and finally asphaltic bitumen, which used to make asphalt roads.

All of these different substances come from crude oil. The only difference is the length of the carbon chains!

What is octane?

­If you've read How Car Engines Work, you know that almost all cars use four-­stroke gasoline engines. One of the strokes is the compression stroke, where the engine compresses a cylinder-full of air and gas into a much smaller volume before igniting it with a spark plug. The amount of compression is called the compression ratio of the engine. A typical engine might have a compression ratio of 8-to-1. (See How Car Engines Work for details.)

The octane rating of gasoline tells you how much the fuel can be compressed before it spontaneously ignites. When gas ignites by compression rather than because of the spark from the spark plug, it causes knocking in the engine. Knocking can damage an engine, so it is not something you want to have happening. Lower-octane gas (like "regular" 87-octane gasoline) can handle the least amount of compression before igniting.

The compression ratio of your engine determines the octane rating of the gas you must use in the car. One way to increase the horsepower of an engine of a given displacement is to increase its compression ratio. So a "high-performance engine" has a higher compression ratio and requires higher-octane fuel. The advantage of a high compression ratio is that it gives your engine a higher horsepower rating for a given engine weight -- that is what makes the engine "high performance." The disadvantage is that the gasoline for your engine costs more.

The name "octane" comes from the following fact: When you take crude oil and "crack" it in a refinery, you end up getting hydrocarbon chains of different lengths. These different chain lengths can then be separated from each other and blended to form different fuels. For example, methane, propane and butane are all hydrocarbons. Methane has a single carbon atom. Propane has three carbon atoms chained together. Butane has four carbon atoms chained together. Pentane has five, hexane has six, heptane has seven and octane has eight carbons chained together.

It turns out that heptane handles compression very poorly. Compress it just a little and it ignites spontaneously. Octane handles compression very well -- you can compress it a lot and nothing happens. Eighty-seven-octane gasoline is gasoline that contains 87-percent octane and 13-percent heptane (or some other combination of fuels that has the same performance of the 87/13 combination of octane/heptane). It spontaneously ignites at a given compression level, and can only be used in engines that do not exceed that compression ratio.

Gasoline Additives

­ Dur­ing WWI, it was discovered that you can add a chemical called tetraethyl lead to gasoline and significantly improve its octane rating. Cheaper grades of gasoline could be made usable by adding this chemical. This led to the widespread use of "ethyl" or "leaded" gasoline. Unfortunately, the side effects of adding lead to gasoline are:

­

­When lead was banned, gasoline got more expensive because refineries could not boost the octane ratings of cheaper grades any more. Airplanes are still allowed to use leaded gasoline, and octane ratings of 115 are commonly used in super-high-performance piston airplane engines (jet engines burn kerosene, by the way).

Another common additive is MTBE. MTBE is the acronym for methyl tertiary butyl ether, a fairly simple molecule that is created from methanol. 

MTBE gets added to gasoline for two reasons:

  1. It boosts octane
  2. It is an oxygenate, meaning that it adds oxygen to the reaction when it burns. Ideally, an oxygenate reduces the amount of unburned hydrocarbons and carbon monoxide in the exhaust.

MTBE started getting added to gasoline in a big way after the Clean Air Act of 1990 went into effect. Gasoline can contain as much as 10 percent to 15 percent MTBE.

The main problem with MTBE is that it is thought to be carcinogenic and it mixes easily with water. If gasoline containing MTBE leaks from an underground tank at a gas station, it can get into groundwater and contaminate wells. Of course, MTBE isn't the only thing getting into the groundwater when a tank leaks -- so is gasoline and a host of other gasoline additives.

According to this page at the EPA:

Although there is no established drinking-water regulation, USEPA has issued a drinking-water advisory of 20 to 40 micrograms per liter (µg/L) on the basis of taste and odor thresholds. This advisory concentration is intended to provide a large margin of safety for noncancer effects and is in the range of margins typically provided for potential carcinogenic effects.

­

­The most likely thing to replace MTBE in gasoline is ethanol -- normal alcohol. It is somewhat more expensive than MTBE, but it is not a cancer threat.

Problems With Gasoline

­ ­Gasoline has two problems when burned in car engines. The first problem has to do with smog and ozone in big cities. The second problem has to do with carbon and greenhouse gases.

When cars burn gasoline, they would ideally burn it perfectly and create nothing but carbon dioxide and water in their exhaust. Unfortunately, the internal combustion engine is not perfect. In the process of burning the gasoline, it also produces:

  • Carbon monoxide, a poisonous gas
  • Nitrogen oxides, the main source of urban smog
  • Unburned hydrocarbons, the main source of urban ozone

Catalytic converters eliminate much of this pollution, but they aren't perfect either. Air pollution from cars and power plants is a real problem in big cities.

Carbon is also a problem. When it burns, it turns into lots of carbon dioxide gas. Gasoline is mostly carbon by weight, so a gallon of gas might release 5 to 6 pounds (2.5 kg) of carbon into the atmosphere. The U.S. is releasing roughly 2 billion pounds of carbon into the atmosphere each day.

If it were solid carbon, it would be extremely noticeable -- it would be like throwing a 5-pound bag of sugar out the window of your car for every gallon of gas burned. But because the 5 pounds of carbon comes out as an invisible gas (carbon dioxide), most of us are oblivious to it. The carbon dioxide coming out of every car's tailpipe is a greenhouse gas. The ultimate effects are unknown, but it is a strong possibility that, eventually, there will be dramatic climate changes that affect everyone on the planet (for example, sea levels may rise, flooding or destroying coastal cities). For this reason, there are growing efforts to replace gasoline with hydrogen. See How the Hydrogen Economy Works for details.