Free · Thermodynamics and heat calculators 🌡️

Ideal Gas Density from Molar Mass

Relate positive gas density, absolute pressure, absolute temperature and molar mass using the ideal gas law, with gas presets and custom molar mass.

  • Formula & worked example
  • Private in your browser
  • No signup
Go to tool

Calculator inputs

Loading calculator…

How to use this calculator

  1. Enter the known values in the units shown. Results update as you type.
  2. Where results are editable, change one to solve backwards. Lock a value to hold it fixed.
  3. Use the worked example to check the method. Reset restores the starting fields.

Private by default

Inputs and results stay in this browser tab. Bookify does not upload or store the values you enter.

Formula and method

For a custom 28 g/mol ideal gas at 100000 Pa and 300 K, density is approximately 1.12254 kg/m³.

ρ = Mp/(RᵤT); Rₛ = Rᵤ/M; Rᵤ = 8.31446261815324 J/(mol·K).

Worked example

Enter these known values and leave the other values blank.

Substance
Custom gas substance
Molar mass
28 g/mol
Absolute pressure
100000 Pa
Absolute temperature
300 K
Specific gas constant
296.95 J/(kg·K)
Ideal gas density
1.1225 kg/m³

Assumptions and limitations

  • Use absolute pressure and a thermodynamic temperature above 0 K. Celsius and Fahrenheit selections are converted to Kelvin for the gas equation. Gauge pressure must first be converted to absolute pressure.
  • The gas is ideal: molecular volume, intermolecular forces, condensation, ionization and compressibility factors are omitted. The calculation does not predict whether a gas is stable at the supplied state.
  • The universal gas constant is the exact SI product of the Avogadro and Boltzmann constants. Gas presets provide rounded nominal molar masses; they are convenient composition assumptions, not precision certificates.
  • Air uses the preset nominal molar mass 28.97 g/mol. Humidity and changing air composition are not inferred. Use a custom mixture molar mass when composition matters.
  • Molar mass, density, pressure and temperature can be edited to solve an inverse. The specific gas constant is derived from molar mass; it is not an independent composition measurement.
  • Some customary density and pressure selectors retain captured rounded conversion coefficients; SI input is preferable for precision work.
  • Pure-gas presets use a declared nominal CIAAW abridged atomic-weight basis: H1.0080, C12.011, N14.007, O15.999, He4.0026, Ne20.180 and Ar39.95. Molecular masses are sums of these nominal atomic values, not exact isotope-specific measurements.
  • Controls accept decimal/scientific-notation numbers and bounded exact finite-decimal arithmetic. Expressions that lose input digits or exceed the proof budget are rejected. Nonzero entered values below 10⁻¹⁰⁰⁰⁰ in equation base units are outside the supported working range. Arithmetic results use 64 significant digits; tiny representable values use scientific notation, and an overflowing or zero-losing unit conversion is withheld with an error.
  • The specific-gas-constant selector BTU/(lb·°F) retains the captured coefficient 4186 J/(kg·K), rather than 4186.8 J/(kg·K) for the International Table BTU convention. This convention/rounding difference changes the displayed value by approximately 0.01911%; use J/(kg·K) or another SI unit for precision work.

Common questions

Can I enter gauge pressure?

Convert it to absolute pressure first by adding the relevant ambient pressure. The ideal gas equation requires absolute pressure.

Does doubling pressure double density?

Yes, for fixed positive absolute temperature and molar mass in the ideal model.

What does the specific gas constant mean?

It is Rᵤ divided by molar mass, expressed per kilogram rather than per mole.

References

Use the exact SI molar gas constant as an immutable literal in both physical identities and every corresponding inverse. The captured hidden Ru field remains unchanged for capture fidelity but cannot absorb locked conflicts or silently disable visible-quantity identity checks. The constant equals exact kB multiplied by exact NA.

Explore thermodynamics and heat calculators 🌡️ or browse all physics calculators.