The ideal gas law: PV = nRT
The ideal gas law PV = nRT unites all gas variables. Density, molar mass, R values, and worked molar-mass examples.
Quick answer
The ideal gas law, PV = nRT, relates all four gas variables at once: pressure, volume, moles, and absolute temperature, joined by the gas constant R. It assumes point-like particles with no attractions.
Example: A 0.500 g sample of vapor in a 0.250 L flask at 1.00 atm and 400 K has molar mass M = mRT/(PV) = (0.500 × 0.08206 × 400)/(1.00 × 0.250) ≈ 65.6 g/mol.
What you will learn
- State the ideal gas law and define each variable with units.
- Select the correct R value for the given units.
- Derive and use the density form d = PM/RT.
- Determine molar mass from mass, P, V, and T measurements.
One equation for all four variables
The combined gas law handled changing conditions for a fixed sample, but it could not answer 'how many moles?' The ideal gas law promotes amount to a full variable:
Pressure times volume equals moles times the gas constant times absolute temperature. One equation now links all four measurable properties of a gas, and every simple gas law falls out of it: hold and constant and is constant, which is Boyle's law, and so on.
The constant is the bridge between the macroscopic world of liters and atmospheres and the particulate world of moles. Its two essential forms are and . Choose by units, never by habit.
A worked example: what volume does 2.50 mol of gas occupy at 1.20 atm and (300 K)? L. Three multiplications and a division replace an entire chain of proportional reasoning.
Density from the law: d = PM/RT
Substitute , mass over molar mass, into and rearrange:
where is density in mass per volume. Gas density is directly proportional to pressure and molar mass, and inversely proportional to temperature. This is why hot-air balloons float and why cold air sinks.
A worked example: what is the density of air at STP? Air averages g/mol. g/L. Now heat that air to (373 K) at the same pressure: g/L, about 27 percent lighter. A balloon envelope full of that hot air displaces 1.29 g/L of outside air while weighing only 0.948 g/L inside, and the difference is lift.
Weighing the invisible: molar mass from vapor
The same substitution solved for turns the gas law into an analytical instrument:
Vaporize a weighed sample of an unknown volatile liquid in a flask of known volume, record and , and the molar mass drops out. This is the Dumas method, nearly two centuries old and still taught because it works.
A worked example: 0.500 g of an unknown liquid vaporizes completely in a 0.250 L flask at 1.00 atm and (400 K). g/mol. That molar mass narrows the identity dramatically: among common solvents it sits near 2-propanol at 60.1 g/mol or acetic acid at 60.05, close enough to guide the next test. The method needs only a balance, a flask, and a thermometer.
Stoichiometry with gases
Gas stoichiometry runs on the law too. Reactions that involve gases quote amounts in liters, but balanced equations speak in moles, and is the translator.
A worked example: how many liters of oxygen at STP are needed to burn 10.0 g of methane? The equation demands 2 mol O2 per mol CH4. Moles of methane: mol, so oxygen needed: mol. At STP the molar volume is 22.4 L/mol, giving L of O2. Away from STP you would use instead; the mole bridge is the same.
A second worked check at non-STP conditions: the same 1.247 mol at (298 K) and 1.00 atm occupies L, sensibly larger than the STP volume because the gas is warmer.
Limits and the unit-discipline habit
The law's fine print matters. It assumes point particles with no attractions, so it frays at high pressure, where particle volume matters, and near condensation, where attractions matter. It also assumes equilibrium: a gas mid-explosion is not described by one , one , one .
Unit discipline is the practical pitfall. Temperature in kelvins, always. matched to pressure and volume units, always. And gauge pressures converted to absolute before use.
A worked example of the classic blunder: 0.100 mol at 2.00 atm and 300 K in liters. Correct: L. With the wrong : L, off by a factor of 101. The absurd answer is the tell: a tenth of a mole at 2 atm should occupy about a soda bottle, not a bathtub. When a gas-law answer looks ridiculous, check first.
Common mistakes
R is universal but unit-dependent: 0.08206 L·atm/(mol·K) equals 8.314 J/(mol·K). The number changes with your units; the physics does not.
It works at any temperature and pressure where the gas behaves ideally. STP is just a convenient reference point, not a requirement.
At fixed T and P, density is fixed: d = PM/RT. A thimble and a tank of the same gas at the same conditions have identical densities.
Real-world applications
Computing gas density for balloon and airship design
Finding molar masses of unknown volatile liquids
Sizing industrial gas storage vessels
Converting between gas mass and volume in stoichiometry
Frequently asked questions
Which value of R should I use?
Match R to your pressure and volume units. Use 0.08206 L·atm/(mol·K) with atm and liters, or 8.314 J/(mol·K) with pascals and cubic meters. Mixing them is the most common ideal-gas error.
Can the ideal gas law find a molar mass?
Yes. Substitute n = m/M into PV = nRT and solve for M: M = mRT/(PV). Measure the mass, pressure, volume, and temperature of a gas sample and the molar mass follows.
Does PV = nRT work for real gases?
No. The law describes ideal gases; real gases deviate at high pressure and low temperature. It also cannot handle changing amounts mid-problem unless you track n1 and n2 separately.
Why does R have such strange units?
Because R carries the units that make both sides match: PV has units of energy, and nT has units of mol·K. The constant converts between them, which is why its value depends on your unit choices.