Air density is mass per unit volume, calculated as ρ = m/V; for dry air treated as an ideal gas, calculate it from pressure, temperature, and molar mass with ρ = pM/(RT). Enter pressure in kPa and temperature in °C to get density in kg/m³, with the calculator also showing the ideal-gas estimate’s assumptions and converted SI values.
Formula
The general definition of density is mass divided by volume:
ρ = m/V
For a gas modeled as ideal, the ideal gas law is pV = nRT. Replacing amount of gas n with m/M, where M is molar mass, and rearranging gives:
ρ = pM/(RT)
- ρ is air density in kg/m³.
- p is absolute pressure in pascals (Pa). The calculator input is in kPa, so it multiplies by 1,000 Pa/kPa.
- M is the molar mass in kg/mol. The input is in g/mol, so it is divided by 1,000 g/kg.
- R is the molar gas constant, 8.31446261815324 J/(mol·K).
- T is absolute temperature in kelvins, calculated from °C as T = t + 273.15.
The calculator uses 28.965 g/mol as a conventional average molar mass for dry air. Air is a mixture, so its exact mean molar mass varies slightly with composition. The direct mass-per-volume formula is also valid, but it requires mass and volume measurements rather than atmospheric conditions.
Worked Example
Using the defaults—pressure 101.325 kPa, temperature 20 °C, and dry-air molar mass 28.965 g/mol—first convert the quantities into the units required by the ideal-gas equation:
T = 20 + 273.15 = 293.15 K
p = 101.325 × 1,000 = 101,325 Pa
M = 28.965 / 1,000 = 0.028965 kg/mol
Then substitute into the density equation:
ρ = (101,325 × 0.028965) / (8.31446261815324 × 293.15)
ρ ≈ 1.204 kg/m³
Rounded to the calculator’s three decimal places, the result is 1.204 kg/m³. This is a model estimate for dry air at the stated pressure and temperature, not a universal density for air.
Assumptions
- Air behaves as an ideal gas at the stated conditions.
- The air is dry, and its average molar mass is taken as 28.965 g/mol.
- Pressure is absolute pressure, not gauge pressure.
- Temperature is converted from Celsius to kelvins before calculation.
- For bench or field work, follow your method, the safety data sheet (SDS), and your supervisor’s instructions.
How Pressure and Temperature Affect Density
At fixed temperature and composition, the ideal-gas equation says density rises in direct proportion to absolute pressure. Compressing air into a smaller volume raises its pressure and density. At fixed pressure, density falls as absolute temperature rises: warmer air occupies more volume for the same amount of gas.
Use kelvins when comparing temperatures in gas equations. Celsius values cannot be divided directly to find a proportional change because zero on the Celsius scale is not absolute zero. For example, 20 °C is 293.15 K, not 20 K.
Pressure must likewise be absolute. A gauge reading reports pressure relative to the surrounding atmosphere, so it cannot be substituted as though it were absolute pressure. For a gauge measurement, add the local atmospheric pressure to obtain absolute pressure; the atmospheric value changes with altitude and weather.
When This Calculation Is Useful
Air density is relevant whenever air mass matters, including estimating buoyancy, comparing atmospheric conditions, and making engineering calculations involving airflow. It is also useful for understanding why the same volume of air can contain different masses on a hot day and a cold day, or at a high-elevation site and near sea level.
Choose the calculation that matches the information available:
- If mass and volume are measured, use ρ = m/V.
- If pressure, temperature, and gas composition are known, use ρ = pM/(RT) for an ideal-gas estimate.
- If water vapor is significant or high accuracy is important, use a moist-air or real-gas method suited to the conditions instead of treating the air as dry ideal gas.
Moist Air, Accuracy, and Common Mistakes
Real atmospheric air contains water vapor, whose molar mass is lower than the average molar mass of dry air. At the same total pressure and temperature, humid air is therefore generally less dense than dry air. The calculator does not take relative humidity or water-vapor pressure as inputs, so it cannot make that correction. For precise meteorological or engineering work, use a recognized moist-air calculation and appropriate measured conditions.
The ideal-gas approximation is practical for many ordinary atmospheric calculations. At unusually high pressures, or when a demanding accuracy target applies, departures from ideal behavior can matter. The suitable correction depends on conditions and the required precision; do not treat the displayed result as an exact measurement.
- Using gauge pressure: convert to absolute pressure before entering it.
- Mixing units: the formula requires Pa, kg/mol, and K; the calculator explicitly converts kPa, g/mol, and °C.
- Using Celsius in the gas equation: convert with +273.15, not by treating the Celsius number as kelvins.
- Assuming all air has the same density: pressure, temperature, humidity, and composition all influence the result.
- Rounding too early: retain the converted values through the calculation and round the final density to the precision your application supports.
Frequently Asked Questions
What is the formula for air density?
For measured mass and volume, use ρ = m/V. When pressure and temperature are known, the ideal-gas form is ρ = pM/(RT), with absolute pressure and kelvin temperature.
What is the density of air at 20 °C?
At 101.325 kPa, the calculator’s dry-air ideal-gas estimate at 20 °C is 1.204 kg/m³. The value changes with pressure, temperature, humidity, and composition.
Does air density increase with temperature?
At constant pressure, it decreases as temperature rises. At constant volume, heating a sealed quantity of air instead raises its pressure; the conditions held fixed matter.
Should I use gauge pressure or absolute pressure?
Use absolute pressure in the ideal-gas equation. If you have a gauge reading, add the local atmospheric pressure to it first.
How does humidity affect air density?
At the same temperature and total pressure, water vapor generally makes air less dense than dry air. This calculator assumes dry air and does not apply a humidity correction.
What units are used for air density?
The SI unit is kg/m³. Some references also report g/L; numerically, 1 kg/m³ equals 1 g/L.
Related
Formula used
in p | Absolute pressure | kPa | 101.325 | 0 in t | Air temperature | °C | 20 | -273.15 in m | Molar mass of dry air | g/mol | 28.965 | 0 out d | Air density | kg/m³ | (p * 1000) * (m / 1000) / (8.31446261815324 * (t + 273.15)) | 3 out tk | Temperature | K | t + 273.15 | 2
Each line is one input (in, sel, list) or one result (out: label, unit, formula, decimals). How the calculators work
Method: the standard formula for this calculation with the constants and conversion factors written on the page, rounded as each result states. See method and constants, the disclaimer or report an error.
More in this section
- Mean and Median Calculation Example
- Right Triangle Trigonometry Angle Calculation
- Simple Interest Rate Calculation Example$150.00
- Mean Absolute Deviation Calculation Example
- Ladder Height Calculation Problem?24.74 ft
- Average Speed Calculation Problem?100.00 km