Calc Lab Online
Sponsored • Leaderboard

Ideal Gas Law Calculator (PV = nRT)

Solve for pressure (P), volume (V), molar quantity (n), temperature (T), or gas density (ρ) using the ideal gas equation of state. Features 10 real gas molar mass presets, standard reference conditions (STP, SATP, NTP), and multi-unit conversions.

Standard sea-level dry atmospheric gas mixture (78.08% N₂, 20.95% O₂, 0.93% Ar).

Total physical container capacity occupied by gas

1 mole = 6.022 × 10²³ constituent gas molecules

Thermodynamic absolute thermal state of the gas

Primary Calculated Ideal Gas Property
1 atm
Absolute Pressure
1.0000 atm
(101.3 kPa)
Gas Density (ρ)
1.2925 kg/m³
(0.0807 lb/ft³)
Total Mass (m)
28.97 grams
(0.0639 lbs)
Molar Volume (V_m)
22.414 L/mol
At 273.1 K
Constituent Molecules
6.022e+23 particles
Absolute Kelvin Temperature
273.15 K
Universal Gas Constant (R)
8.3145 J / (mol · K)

Step-by-Step Mathematical Derivation

1. Formula: P = (n · R · T) / V
2. Convert V: 22.414 L = 0.02241 m³
3. Convert n: 1 mol = 1 mol
4. Convert T: 0 C = 273.1 K
5. Substitute: P = (1 mol · 8.3145 J/mol·K · 273.1 K) / 0.02241 m³ = 101300 Pa

Equivalent Pressure Units Reference Matrix

Atmospheres1.0000 atm
Bar1.0132 bar
Kilopascals101.32 kPa
Pounds per sq in14.70 psi

Real-World Gas Thermodynamics Benchmarks

Comparing thermodynamic pressure, temperature, density, and molar volumes across natural and industrial gas systems.

Thermodynamic Matrix
Physical SystemGas CompositionPressure (P)Temperature (T)Density (ρ)Molar Volume (V_m)Engineering Role
Standard Sea-Level AtmosphereDry Air (28.97 g/mol)1.00 atm (101.3 kPa)15 °C (288.15 K)1.225 kg/m³23.64 L/molBaseline terrestrial life envelope
Helium Party BalloonHelium He (4.00 g/mol)1.05 atm (106.4 kPa)20 °C (293.15 K)0.175 kg/m³22.91 L/molBuoyancy lift in air (Δρ = 1.05 kg/m³)
Passenger Car Highway TireAir / N₂ (28.0 g/mol)32.0 psi (2.18 atm)25 °C (298.15 K)2.54 kg/m³11.23 L/molVehicle sidewall cushioning load
Scuba Diving Aluminum Tank (Full)Compressed Air (29 g/mol)3,000 psi (204 atm)20 °C (293.15 K)243.8 kg/m³0.118 L/molUnderwater breathing reserve supply
Atmosphere of Mars (Surface)CO₂ (95.3%, 43.3 g/mol)0.006 atm (610 Pa)-60 °C (213.15 K)0.015 kg/m³2,907 L/molThin Martian planetary atmosphere
Atmosphere of Venus (Surface)CO₂ (96.5%, 43.5 g/mol)92.0 atm (9.3 MPa)464 °C (737.15 K)65.0 kg/m³0.658 L/molSupercritical planetary pressure cook
High-Pressure Steam BoilerSteam H₂O (18.02 g/mol)40.0 bar (39.5 atm)350 °C (623.15 K)14.1 kg/m³1.29 L/molIndustrial turbine electric generator
Cryogenic Liquid Nitrogen Tank (Ullage)Cold N₂ Gas (28.0 g/mol)1.50 bar (150 kPa)-196 °C (77.15 K)6.54 kg/m³4.28 L/molBoil-off pressure relief headspace
Commercial Aircraft Cabin (Cruising)Air (28.97 g/mol)0.75 atm (76.0 kPa)22 °C (295.15 K)0.896 kg/m³32.28 L/mol8,000 ft equivalent cabin altitude

1. Theoretical Foundations: The Ideal Gas Equation of State

The Ideal Gas Law is the fundamental equation of state governing the macroscopic behavior of an idealized gas. First stated in 1834 by French engineer Benoît Paul Émile Clapeyron as a combination of four empirical 17th- and 18th-century gas laws, the modern equation is written as:

P · V = n · R · T

Where each variable represents a primary thermodynamic state parameter:

  • P (Absolute Pressure): Force exerted by gas molecules per unit area on container walls, measured in Pascals (Pa), atmospheres (atm), bar, or psi.
  • V (Volume): Three-dimensional spatial capacity of the gas container, measured in cubic meters (m³), Liters (L), or cubic feet (ft³).
  • n (Amount of Substance): Quantity of gas measured in moles (mol), where 1 mol = 6.02214076 × 10²³ elementary particles (Avogadro's number NA).
  • R (Universal Gas Constant): Physical constant relating thermal energy scale to molar temperature: R = 8.314462618 J / (mol · K).
  • T (Absolute Temperature): Thermodynamic temperature measured on an absolute scale strictly in Kelvin (K = °C + 273.15) or Rankine (°R = °F + 459.67).

2. Solving for Individual Variables: Algebraic Formulas

To Solve Pressure (P)
P = nRT / V

Directly proportional to moles and temperature; inversely proportional to volume.

To Solve Volume (V)
V = nRT / P

Volume expands with heating or molar addition; compresses under elevated pressure.

To Solve Moles (n)
n = PV / RT

Quantity of gas molecules confined inside known container geometry.

To Solve Temperature (T)
T = PV / nR

Thermodynamic absolute thermal state required to sustain given pressure and volume.

3. Gas Density & Mass Formulations (ρ = PM / RT)

Because the number of moles n equals total gas mass (m) divided by its molar mass (M), we can substitute n = m / M directly into the ideal gas equation:

P · V = (m / M) · R · T

Dividing both sides by volume V yields the fundamental expression for Gas Density (ρ = m / V):

ρ = (P · M) / (R · T)

Key Engineering Takeaways:

  • Heavier gases are denser: Carbon dioxide (M = 44 g/mol) is ~1.5× denser than dry air (M = 29 g/mol) at identical temperature and pressure, explaining why CO₂ settles into basements and low-lying trenches.
  • Heating decreases density: Hot air expands, lowering its density relative to surrounding cooler air, providing buoyant lift for hot air balloons (Archimedes' principle).

4. The Four Empirical Precursor Gas Laws

Boyle's Law (P ∝ 1/V at constant T, n)

Discovered by Robert Boyle in 1662: At constant temperature, pressure and volume are inversely proportional: P₁V₁ = P₂V₂. Halving container volume doubles gas pressure.

Charles's Law (V ∝ T at constant P, n)

Formulated by Jacques Charles in 1787: At constant pressure, gas volume scales linearly with absolute Kelvin temperature: V₁/T₁ = V₂/T₂.

Gay-Lussac's Law (P ∝ T at constant V, n)

Established in 1802: In a rigid sealed container of fixed volume, gas pressure is directly proportional to Kelvin temperature: P₁/T₁ = P₂/T₂.

Avogadro's Law (V ∝ n at constant P, T)

Hypothesized by Amedeo Avogadro in 1811: Equal volumes of all gases at the same temperature and pressure contain an identical number of molecules: V₁/n₁ = V₂/n₂.

5. Universal Gas Constant (R) Across Different Unit Systems

Value of RUnitsTypical Discipline
8.314462 J / (mol · K)Pa · m³ / (mol · K)International Standard SI Physics
0.082057 L · atm / (mol · K)dm³ · atm / (mol · K)Chemistry Laboratory & Acid-Base Gas Stoichiometry
62.3637 L · mmHg / (mol · K)L · Torr / (mol · K)Barometric & Vacuum Systems Engineering
10.7316 psi · ft³ / (lbmol · °R)psi · ft³ / (lbmol · °R)US Customary HVAC & Petrochemical Refining
1.9872 cal / (mol · K)cal / (mol · K)Combustion & Chemical Thermodynamics

6. Real Gas Deviations & Van der Waals Corrections

The Ideal Gas Law is extraordinarily accurate for monatomic and simple diatomic gases at ambient room temperatures and moderate pressures. However, real gases deviate from ideality under extreme regimes:

  1. High Pressure: As gas is compressed, molecular volume (b) occupies a significant fraction of total container volume, making the actual gas less compressible than predicted.
  2. Low Temperature: As kinetic energy drops, intermolecular attraction forces (a) draw molecules together, reducing the impact pressure exerted on container walls.

To correct for these microscopic phenomena, Dutch physicist Johannes Diderik van der Waals introduced the Van der Waals Equation (1873):

[P + a · (n / V)²] · (V - n · b) = n · R · T

Frequently Asked Questions About the Ideal Gas Law

What is the Ideal Gas Law formula?↓

The Ideal Gas Law is expressed as PV = nRT, where P is pressure, V is volume, n is the amount of gas in moles, R is the universal gas constant (8.31446 J/(mol·K)), and T is absolute temperature in Kelvin.

What is the value of the Universal Gas Constant (R)?↓

The value of R depends on the measurement units used: in SI units it is 8.3145 J/(mol·K) or Pa·m³/(mol·K); in atmospheric chemistry units it is 0.08206 L·atm/(mol·K); in barometric units it is 62.364 L·mmHg/(mol·K); and in imperial engineering units it is 10.732 psi·ft³/(lbmol·R).

Why must temperature always be in Kelvin for gas calculations?↓

Gas pressure and volume are proportional to the average kinetic energy of molecular motion, which reaches zero at absolute zero (0 Kelvin). Celsius and Fahrenheit are relative scales with arbitrary zero points, which would lead to mathematically impossible negative volumes or division by zero. Always convert temperatures to Kelvin (K = °C + 273.15).

What is the volume of 1 mole of an ideal gas at STP?↓

Under IUPAC classic Standard Temperature and Pressure (STP: 0 °C / 273.15 K and 1 atm / 101.325 kPa), exactly 1 mole of any ideal gas occupies 22.414 Liters (0.022414 m³). Under SATP (25 °C and 1 bar), 1 mole occupies 24.789 Liters.

How do you calculate gas density using the Ideal Gas Law?↓

By substituting moles n = m / M (where m is mass and M is molar mass) into PV = nRT, we get PV = (m / M)RT. Rearranging for density ρ = m / V gives ρ = (P · M) / (R · T). At higher pressures or lower temperatures, gas density increases.

When does the Ideal Gas Law fail for real gases?↓

The ideal gas model assumes point-like particles with zero volume and zero intermolecular attractive forces. The law deviates significantly at very high pressures (where particle volumes become non-negligible) and very low temperatures (where intermolecular London dispersion and dipole forces cause condensation into liquids). In these conditions, the Van der Waals equation [P + a(n/V)²][V - nb] = nRT provides greater accuracy.

Related Calculators

Quick Suggestions
Science & Engineering Calculators

Hooke's Law Calculator (F = -k · x)

Free online Hooke's Law Calculator. Compute spring force (F = -kx), spring constant (k = F/x), or displacement with step-by-step physics formulas, elastic potential energy, and unit conversions.

Open Calculator
Science & Engineering Calculators

Elastic Potential Energy Calculator

Free online Elastic Potential Energy Calculator. Calculate stored spring energy (U = 0.5 k x²), spring constant, extension displacement, restoring force, and launch velocity with multi-unit conversions.

Open Calculator
Science & Engineering Calculators

Density Calculator (Physics)

Free online Density Calculator (Physics). Solve for density (ρ = m/V), mass (m = ρ×V), or volume (V = m/ρ) with material presets, specific gravity, and buoyancy analysis.

Open Calculator
Science & Engineering Calculators

Force Calculator (Physics: F = ma)

Free online Force Calculator. Calculate force, mass, or acceleration using Newton’s Second Law (F = ma) with multi-unit conversions (Newtons, lbf, dyn, kgf) and kinematics problem solving.

Open Calculator
Science & Engineering Calculators

Average Velocity Calculator

Free online Average Velocity Calculator. Solve for average velocity, displacement, or time using kinematics formulas (v = Δx/Δt and v = (u+v)/2) with unit conversions.

Open Calculator
Science & Engineering Calculators

Molecular Weight Calculator (Molar Mass & Formula Weight)

Free online Molecular Weight Calculator. Calculate molar mass (g/mol), formula weight, percent composition by mass, and mole-to-gram conversions for any chemical formula.

Open Calculator