If you're seeing this message, it means we're having trouble loading external resources on our website.

If you're behind a web filter, please make sure that the domains *.kastatic.org and *.kasandbox.org are unblocked.

Main content

Non-ideal behavior of gases

How real gases differ from ideal gases, and when intermolecular attractions and gas molecule volume matter

Because sometimes life isn't ideal

By now you've probably heard a lot about the ideal gas law, and you may have a sense of how to use the ideal gas equation to look at the relationships between pressure (P), volume (V), moles of gas (n), and temperature (T). But when do gases follow the ideal gas law and why? What if we want to study a gas that behaves in a “non-ideal” way? When we use the ideal gas law, we make a couple assumptions:
1. We can ignore the volume taken up by the imaginary ideal gas molecules
2. The gas molecules do not attract or repel each other
However, we know that in real life, gases are made up of atoms and molecules that actually take up some finite volume, and we also know that atoms and molecules interact with each other through intermolecular forces.

Compressibility: A measure of ideal behavior

One way we can look at how accurately the ideal gas law describes our system is by comparing the molar volume of our real gas, Vm, to the molar volume of an ideal gas at the same temperature and pressure. To be more specific, at some temperature we can take n moles of our gas and measure the volume it takes up at a given pressure (or measure the pressure for a known volume). We can also calculate the molar volume of the ideal gas at the same temperature and pressure, and then take the ratio of the two volumes.
Z=VnRTP=PVnRT
This ratio is called the compressibility or compression factor, Z. For a gas with ideal behavior, Vm of the gas is the same as Vm of an ideal gas so Z=1. It turns out that this is reasonably accurate for real gases under specific circumstances that also depend on the identity of the gas. Let’s look at the compressibility Z for a couple different gases.
Image from: UC Davis ChemWiki.
This graph shows the compression factor Z over a range of pressures at 273 K for nitrogen (N2), oxygen (O2), hydrogen (H2), and carbon dioxide (CO2). For all of the real gases in this graph, you might notice that the shapes of the curves look a little different for each gas, and most of the curves only approximately resemble the ideal gas line at Z=1 over a limited pressure range. Also, for all the real gases Z is sometimes less than 1 at very low pressures, which tells us that the molar volume is less than that of an ideal gas. As you increase the pressure past a certain point that depends on the gas, Z gets increasingly larger than 1. That is, at high pressures the Vm of the gas is larger than Vm of the ideal gas, and Vm of the real gas increases with pressure. Why is that?

High pressures: When gas molecules take up too much space

At high pressures, the gas molecules get more crowded and the amount of empty space between the molecules is reduced. How might this affect Vm and Z? It helps to remember that the volume we use in the ideal gas equation is the empty volume that the gas molecules have to move around in. We usually assume that this is the same as the volume of the container when the gas molecules don’t take up much space. But what happens when this is not the case, such as at high pressures?
Initially the gas molecules move around to take up the entire volume of the container. Once you put all the gas molecules in one corner, you can see the total space in container minus the volume of the gas molecules.
For a given pressure, the real gas will end up taking up a greater volume than predicted by the ideal gas law since we also have to take into account the additional volume of the gas molecules themselves. This increases our molar volume relative to an ideal gas, which results in a value of Z that is greater than 1. The error in molar volume gets worse the more compressed the gas becomes, which is why the difference between Z for the real and ideal gas increases with pressure.

Low temperatures and intermolecular Forces

To examine the effect of intermolecular forces, let’s look at the compressibility of a single kind of gas at different temperatures.
Image from: UC Davis ChemWiki.
For nitrogen, you can see that at T=300 K and 400 K with pressures below 200 bar, the curve looks relatively similar to what you would expect for an ideal gas. As you lower the temperature to 200 K and 100 K, the curves look much less ideal. In particular, at low pressures we see that Z for real gases is noticeably less than 1 for T=200 K, and this effect is even more pronounced at 100 K. What’s going on at lower temperatures?
Imagine our gas molecules bouncing around in the container. The pressure we measure comes from the force of the gas molecules hitting the walls of the container. Attractive forces between the molecules will pull them a little closer together, which effectively slows the molecule down a little before it hits the container wall.
This results in a decrease in volume if the pressure is constant compared to what you would expect based on the ideal gas equation. The decreased volume gives a corresponding decrease in Vm compared to the ideal gas so Z<1. The effect of intermolecular forces is much more prominent at low temperatures because the molecules have less kinetic energy to overcome the intermolecular attractions.

The van der Waals equation

We can use a number of different equations to model the behavior of real gases, but one of the simplest is the van der Waals (VdW) equation. The VdW equation basically incorporates the effect of gas molecule volume and intermolecular forces into the ideal gas equation.
[P+an2V2][Vnb]=nRT
where:
P= measured pressure
V= volume of container
n= moles of gas
R= gas constant
T= temperature (in Kelvin)
Compared to the ideal gas law, the VdW equation includes a “correction” to the pressure term, an2V2, which accounts for the measured pressure being lower due to attraction between gas molecules. The “correction” to the volume, nb, subtracts out the volume of the gas molecules from the total volume of the container to get a more accurate measure of the empty space available for the gas molecules. a and b are measured constants for a specific gas (and they might have some slight temperature and pressure dependence).
At low temperatures and low pressure, the correction for volume is not as important as the one for pressure, so Z is less than 1. At high pressures, the correction for the volume of the molecules becomes more important so Z is greater than 1. At some range of intermediate pressure, the two corrections cancel out and the gas appears to follow the relationship given by the ideal gas equation.

Summary

In a nutshell, the ideal gas equation works well when intermolecular attractions between gas molecules are negligible and the gas molecules themselves do not occupy a significant part of the whole volume. This is usually true when the pressure is low (around 1 bar) and the temperature is high. In other situations such as high pressures and/or low temperatures, the ideal gas law might give answers that are different from what we observe experimentally. In these cases, you can use the van der Waals (or a similar) equation to take into account the fact that gases do not always behave as ideal gases.

Want to join the conversation?

  • blobby green style avatar for user santanuchemistry6
    Why do gas molecules behave ideally in high temperature & low pressure
    (26 votes)
    Default Khan Academy avatar avatar for user
    • starky ultimate style avatar for user Swarna
      Real gases behave ideally in high temperatures because at high temperature intermolecular forces are nearly negligible. [At very low temperatures, intermolecular forces become significant and molecules travel with low average speed and hence, can be captured by one other due to their attractive forces more easily than when at high temperatures]
      (34 votes)
  • leaf green style avatar for user Prakriti Marwah
    In the van der waals equation, we add something to P. However, in a real gas, we account for intermolecular forces of attraction where particles attract each other- should this not 'reduce' the pressure since now the particles are attracted to other particles so they might not hit the wall with the same force or speed?
    (9 votes)
    Default Khan Academy avatar avatar for user
    • starky ultimate style avatar for user t r
      The VdW equation above is a derived form. If you divide both sides by [V-nb] and then subtract [an^2/V^2] from both sides, you can see that the pressure P = nRT/(V-nb) - (an^2/V^2) <--- this is the inter-molecular force correction which you can now see becomes significantly subtractive when T is small.
      (18 votes)
  • blobby green style avatar for user P
    I dont understand the "can we be more precise" part (just before the Summary). Can someone explain the math part? How the equations simplify? If this is explained I'll likely grasp Z. Thanks in advance.
    (6 votes)
    Default Khan Academy avatar avatar for user
    • female robot grace style avatar for user tyersome
      Lets see, you re-derive the Z equation using Van der Waals version of the gas law.
      Z = [P + ​an²/V²] * [V - nb] / nRT

      Then you say what happens if P is really big (and n stays small) then P + an²/V² will become very close to P (i.e. the other term will become insignificant). This gives us:
      Z = P * [V - nb] / nRT
      = (PV - nbP) / nRT


      If we replaced PV by nRT (I'm not sure that makes sense ...) and simplify, we get:

      Z = 1 - bP/RT

      Hmmm ... I guess I don't understand what they are doing here either ...
      (7 votes)
  • leaf green style avatar for user Prakriti Marwah
    i dont understand why in the VDW equation something was added to P. Since for real gases, the forces of attraction slow down the particles and they hit the wall with 'less pressure'. So in this case, something should be subtracted from P right?
    (3 votes)
    Default Khan Academy avatar avatar for user
  • blobby green style avatar for user Kyler
    What exactly is the "real molar volume" and" Ideal molar volume"? What are the equations to calculate the real and ideal molar volumes to even be able to compare the ratio? I've only ever heard of molar volume being 22.41(at stp), how are we getting two different molar volumes at the same temperature and pressure?
    (3 votes)
    Default Khan Academy avatar avatar for user
    • spunky sam blue style avatar for user Ernest Zinck
      The "ideal molar volume" is the volume that one mole of a gas would occupy if its molecules had zero volume and no intermolecular forces of attraction.
      No real gas is ideal. All molecules have a volume and intermolecular forces of attraction.
      So a "real molar volume" is different from an ideal molar volume.
      At STP ( 0 °C and 1 bar of pressure), the ideal molar volume is 22.71 L.
      (7 votes)
  • aqualine seedling style avatar for user Lisa Trinh
    What makes a gas non-ideal.
    (5 votes)
    Default Khan Academy avatar avatar for user
    • blobby green style avatar for user liweiong272
      The higher the temperature and the lower the pressure, the less the deviation from ideal gas behaviour. Under these conditions, the volume of the gas particles compared to the volume of the container which contains the gas can be considered negligible, and so are the intermolecular forces of attraction and repulsion between the gas particles.
      (2 votes)
  • duskpin ultimate style avatar for user Debanil
    In the pv/nrt vs pressure graphs , do the lines become straight lines later on ?
    (2 votes)
    Default Khan Academy avatar avatar for user
  • spunky sam blue style avatar for user Siva Narayanan
    what is the value and the meaning of the variables used in the vander walls equation?
    (2 votes)
    Default Khan Academy avatar avatar for user
  • aqualine seed style avatar for user manisha mahay
    Under what conditions of pressure and temperature is the ideal gas equation valid?
    (3 votes)
    Default Khan Academy avatar avatar for user
  • blobby green style avatar for user Faiqah Batrisyia
    in terms of calculations, if we calculated the substances using ideal and non ideal gas eq, which one is more accurate?
    (1 vote)
    Default Khan Academy avatar avatar for user
    • male robot hal style avatar for user RN
      There is no "non ideal gas equation" so I assume you are referring to the Van der Waal's equation and in regards to accuracy for real gases the Van der Waal's equation would be more so because we are assuming there will be some inter molecular attractions and the real gas will take up some volume in the container.
      (3 votes)