Ideal Gas Law Calculator
Use the ideal gas law to solve for pressure, volume, moles, or temperature. Enter known values and apply pV equals nRT with unit conversion.
Ideal Gas Law Calculator
mol
Result will appear here...
What the ideal gas law calculator does
The state of a gas is tied together by one famous relationship between its pressure, volume, amount, and temperature. This calculator applies that relationship, the ideal gas law, taking the pressure, the volume, and the amount of gas in moles, and working out the temperature.
Below is what the ideal gas law is, the equation behind it, the gas constant that ties it together, and a worked example.
How to use it
- Enter the pressure and the volume of the gas, each with its unit. The menus cover a wide range, from pascals to atmospheres and from millilitres to cubic metres.
- Enter the amount of gas in moles.
- Press Calculate for the temperature, which you can read in Celsius, Fahrenheit, or kelvin, or Reset to clear it.
What the ideal gas law is
The ideal gas law is the single equation that captures how a gas behaves. It links four quantities, the pressure pushing outward, the volume the gas fills, the amount of gas present, and its temperature, and says they are bound together so that fixing any three settles the fourth. It is one of the cornerstones of thermodynamics and chemistry, summing up centuries of experiments on gases in one clean statement.
What it describes matches everyday intuition. Heat a sealed gas and its pressure rises. Squeeze it into a smaller space and the pressure climbs too. Add more gas to a fixed container and, again, the pressure goes up. The ideal gas law puts exact numbers to these tendencies and ties them all into one relationship, which is why it appears everywhere from weather science to engine design. This calculator uses it to find the temperature from the other three quantities.
The equation it uses
The ideal gas law is written compactly as:
P V = n R T
Here P is the pressure, V is the volume, n is the amount of gas in moles, T is the absolute temperature, and R is the gas constant. To find the temperature, the calculator rearranges this to:
T = P V ÷ (n R)
In words, the temperature is the pressure times the volume, divided by the amount of gas times the gas constant. The calculator converts your pressure and volume into base units, applies this formula, and reports the temperature. The same equation can be rearranged on paper to find the pressure, volume, or amount instead, though this calculator solves for the temperature from the pressure, volume, and moles.
The gas constant
The letter R is the gas constant, the fixed number that makes the equation balance, with a value of about 8.314 joules per mole per kelvin. It is universal, the same for every gas, which is part of what makes the ideal gas law so powerful: helium, nitrogen, carbon dioxide, all of them follow the same relationship with the same constant, as long as they behave ideally.
That universality is a genuinely remarkable fact about nature. It means a gas does not much care what it is made of when it comes to this basic behaviour, only how much of it there is. The gas constant is what encodes that shared behaviour into the equation, and the calculator uses its standard value automatically so you never need to enter it.
What makes a gas ideal
The law is called the ideal gas law because it describes an idealised gas, one whose molecules are imagined as tiny points that take up no space themselves and exert no forces on one another except when they collide. No real gas is exactly like this, but many come remarkably close under ordinary conditions, which is why the law is so widely useful.
The idealisation holds best when a gas is dilute, warm, and well away from turning into a liquid, conditions where the molecules are far apart and their own size and mutual attractions barely matter. It begins to slip when a gas is squeezed to high pressure or cooled toward its condensation point, where those neglected effects start to count. For most everyday situations, though, the ideal gas law is an excellent description, and where it falls short, the van der Waals equation refines it.
Units and precision
The calculator works in SI units underneath, converting your pressure and volume into pascals and cubic metres, taking the amount in moles, and computing the temperature in kelvin before showing it in your chosen scale. The pressure and volume menus are extensive, covering scientific and everyday units alike. Temperature, being an absolute quantity here, converts cleanly between Celsius, Fahrenheit, and kelvin. The relationship is exact for an ideal gas. Results carry several significant figures.
A worked example
Take 1 mole of gas at a pressure of 101,325 pascals, which is one standard atmosphere, filling a volume of 0.0224 cubic metres, which is 22.4 litres.
The temperature is T = PV ÷ (nR) = (101,325 × 0.0224) ÷ (1 × 8.314) ≈ 273 kelvin, which is 0 degrees Celsius. This is no coincidence: one mole of an ideal gas really does occupy 22.4 litres at one atmosphere and the freezing point of water, a standard reference point in chemistry.
Questions people ask
What is the ideal gas law formula?
PV = nRT, where P is pressure, V is volume, n is the amount in moles, T is the absolute temperature, and R is the gas constant, about 8.314 joules per mole per kelvin.
What is R in the ideal gas law?
R is the universal gas constant, about 8.314 joules per mole per kelvin. It is the same for every gas, which is what lets one equation describe them all.
Why must temperature be in kelvin?
Because the law uses absolute temperature, measured from absolute zero. The calculator handles the conversion, so you can enter or read the temperature in Celsius or Fahrenheit, but the physics works in kelvin.
When does the ideal gas law stop working?
At high pressures or low temperatures, near where a gas would condense, because real molecules have size and attract one another. Under ordinary dilute, warm conditions the law is very accurate.
References
A quick note on where the physics comes from. The ideal gas law and the gas constant are standard thermodynamics, set out in OpenStax's University Physics and in Georgia State University's HyperPhysics. The value of the gas constant follows the US National Institute of Standards and Technology. The HyperPhysics link is worth a quick click to confirm it lands where you expect.
- OpenStax, University Physics Volume 2, Section 2.1, Molecular Model of an Ideal Gas. https://openstax.org/books/university-physics-volume-2/pages/2-1-molecular-model-of-an-ideal-gas
- HyperPhysics, Ideal Gas Law. http://hyperphysics.phy-astr.gsu.edu/hbase/Kinetic/idegas.html
- National Institute of Standards and Technology (NIST), Fundamental Physical Constants, Molar gas constant. https://physics.nist.gov/cgi-bin/cuu/Value?r
Bibek Lal Karna is a PhD student and graduate teaching assistant at the University of Mississippi, with deep interests in theoretical and gravitational physics. He is also the founder of NRCC and is strongly engaged in scientific teaching and communication. At Eon Tools, he reviews physics tools.
Other Tools
- Absolute Humidity Calculator
- Air Density Calculator
- Boyle's Law Calculator
- Calorimetry Calculator
- Dew Point Calculator
- Enthalpy Calculator
- Heat Capacity Calculator
- Heat Index Calculator
- Heat Transfer Calculator
- Mixed Air Calculator
- Psychrometric Calculator
- Relative Humidity Calculator
- Specific Heat Calculator
- Wet Bulb Calculator