Kinetic theory

Watch gas particles bounce around a box. The pressure is counted from their hits on the walls and compared with the gas law; a live histogram shows the speeds settle into the Maxwell shape. Then see the rms speed and average energy of real gases at any temperature.

Keep it one tap away for everyday use.

Bookmark Kinetic theory?

Press Ctrl + D now. Your browser opens its own bookmark box, where you choose the name and folder.

  1. Heat, squash
  2. Watch hits
  3. Speeds
  4. Check
Nothing is uploadedWorks offline once open

Gas in a box

Speeds right now

Bars: how many particles have each speed (averaged over the last few seconds). Line: the Maxwell shape for a gas in a flat (two-dimensional) box. The box is a flat model with a few dozen discs, so pressures are shown relative to its starting state (300 K, 60 particles, full width).

A real gas at this temperature

Try this

  • Push the piston in to half the width: the particles hit the walls twice as often and the pressure doubles (Boyle's law).
  • Double the number of particles: twice as many hits, twice the pressure.
  • Raise the temperature from 300 K to 1,200 K: the particles move twice as fast and the pressure becomes four times bigger.
  • Start again and watch the histogram: every particle starts at the same speed, then collisions spread the speeds into the Maxwell shape.
  • Compare helium and carbon dioxide at the same temperature: same average energy, but light helium molecules move more than three times faster.

Check yourself

What it does

A gas is a huge number of tiny particles flying about and bouncing off each other and off the walls. Every bounce gives the wall a small push; billions of pushes each second add up to the steady pressure you measure. This page puts a few dozen particles in a box with a movable piston. It really counts the push from every wall hit and compares the result with the gas law: more particles, a smaller box or a higher temperature all mean more and harder hits. A live histogram shows the particles’ speeds: they all start equal, then collisions spread them into the Maxwell shape. A second card gives the rms speed and average kinetic energy of real gases at the same temperature.

It follows the school topics on gases: Class 11 Physics, Kinetic Theory (molecular nature of matter, behaviour of gases, kinetic theory of an ideal gas, pressure of an ideal gas, kinetic interpretation of temperature, rms speed), and Class 11 Chemistry, States of Matter (gas laws and the kinetic molecular theory). Before this, see states of matter and heating curve; afterwards, real gas calculator shows when real gases stop obeying the ideal law, and random walk follows one particle’s zig-zag path.

How to use it

  1. Set the temperature in kelvin. Heating makes every particle move faster (speed ∝ √T).
  2. Set the number of particles and push the piston in or out with the box width slider.
  3. Read the pressure from wall hits (averaged over the last few seconds) and the ideal-gas value, both relative to the starting box (300 K, 60 particles, full width). Give the count a few seconds to settle after a change.
  4. Watch the speed histogram. Start again gives every particle the same speed so you can watch the spread grow.
  5. In the second card, pick a gas to see its rms, average and most likely speeds and the average energy per molecule at the same temperature.

Worked example

For nitrogen (M = 0.02801 kg/mol) at 300 K: v_rms = √(3 × 8.314 × 300 / 0.02801) = 516.8 m/s, about 1,861 km/h. The average speed is √(8RT/πM) = 476.2 m/s and the most likely speed √(2RT/M) = 422 m/s. The average kinetic energy per molecule is (3/2)kT = 6.213 × 10⁻²¹ J, the same for every gas at 300 K. One mole of any ideal gas in 22.4 L at 300 K has a pressure of 111.4 kPa. Helium at the same temperature has v_rms = 1,367 m/s, because its molecules are 7 times lighter.

In the box, set 1,200 K: the ideal value becomes 4.00 times the start, and the counted pressure follows it. Halve the width at 300 K and it becomes 2.00.

Check yourself

Five questions, fresh each time: the rms speed of a gas, how the rms speed changes with temperature, the average kinetic energy of a molecule, the pressure from PV = nRT, and what happens to the pressure when you halve the volume. Nothing is saved.

Tips

  • Temperature is a measure of the average kinetic energy of the particles: (3/2)kT per molecule, whatever the gas.
  • The counted pressure comes out a few percent above the ideal value because the discs take up some of the box. Real molecules do the same at high pressure; that is the b in the van der Waals equation.
  • The box is flat (two-dimensional) to keep it simple, so its Maxwell curve is the 2D shape; the real-gas numbers use the full 3D formulas.

FAQ

Why do the speeds spread out if every particle starts the same? In a collision one particle usually speeds up and the other slows down, while their total energy stays the same. After many collisions the speeds settle into the Maxwell shape.

Why is pressure ∝ T and not √T? Faster particles hit the walls both harder and more often; each is ∝ √T, so together ∝ T.

Is this from NCERT? No. It is an independent study aid that follows the same school topics, with its own pictures and numbers.

Where the numbers come from

  • Kinetic theory of an ideal gas: pressure from molecular collisions, PV = nRT, average kinetic energy (3/2)kT, v_rms = √(3RT/M), mean speed √(8RT/πM), most probable speed √(2RT/M), the Maxwell distribution and its two-dimensional (Rayleigh) form, hard-disc second virial coefficient πσ²/2: standard physics.
  • R = 8.314462618 J/(mol K) and k = 1.380649 × 10⁻²³ J/K (SI, exact); molar masses from standard atomic weights.
  • Checked against an independent Python calculation; the disc model is tested for energy conservation, its counted wall pressure against the 2D gas law with the hard-disc correction (within 3%), and its speeds against the 2D Maxwell shape.

Standard scientific values, such as constants, atomic weights and melting points, are facts found in every textbook; we name where ours were checked. If you are an author or publisher and want a value, a credit or a table changed or removed, tell us and we will act quickly.

Last updated 2026-11-09.

Change log for Kinetic theory

  1. Add #1066 Gas in a box Details on GitHub

Every change to fibub

Related tools

Real gas calculator #T651 Compare the ideal gas law with four cubic equations of state for any gas: compressibility factor Z, molar volume, density and fugacity side by side, the saturation pressure each equation predicts, and charts of Z against pressure, the P-V isotherm and a generalised Z chart. Random walk #T657 Simulate lattice or Gaussian random walks in 1, 2 or 3 dimensions and watch the mean square displacement grow as 2dDt, or paste your own particle tracks to fit the diffusion coefficient, localisation error and anomalous exponent from the time-averaged MSD. States of matter #L28 Heat or cool water, ethanol, oxygen or iron and watch the particles vibrate in place, slide past each other or fly apart. Stop at the melting and boiling points, change °C to kelvin, and race diffusion in liquids and gases. Heating curve #L29 Heat ice at a steady rate and watch the temperature climb, stop while it melts, climb again and stop while it boils. See the heat and time for each stage, and use the mixer to find the final temperature when hot and cold things, or ice and water, are mixed. Photoelectric effect lab #L31 Shine light on caesium, sodium, zinc and other metals. Change the frequency, brightness and collector voltage, watch the current, and record the stopping potential at several frequencies to measure Planck's constant and the work function from a straight line. Wind from pressure #L108 Land and sea side by side with air moving over them. Warm one side and the air above it rises, the pressure falls and air blows in from the cooler side. See a sea breeze by day, a land breeze by night and the Indian monsoon. Temperature scales #L208 Drag one thermometer and read Celsius, Fahrenheit and kelvin side by side, with the conversion worked out. See a gas thermometer's straight lines all reach zero pressure at −273.15 °C, and at Class 11 add Rankine and make a scale of your own. Carnot engine #L210 Set the hot and cold temperatures and see the best possible engine's efficiency, with heat and work arrows drawn to scale. Run it backwards as a refrigerator or heat pump for the COP, watch the cycle go round on a p–V diagram, and test an inventor's claim against the second law. Equipartition #L211 Watch a helium atom, a nitrogen molecule, a CO₂ molecule and a water molecule move, turn and vibrate. Count their degrees of freedom, give each ½kT, and get the internal energy, Cv, Cp and γ with the numbers filled in; then mix two gases. Mean free path #L212 Watch molecules bounce in a box while one leaves a zig-zag trail, and measure the average flight between collisions as you crowd them or make them bigger. Then get the real mean free path, number of molecules, mean speed and collisions per second for air, helium or CO₂ from sea level to deep vacuum. Nitrogen estimation #L224 Work out the percent nitrogen in an organic compound by the Dumas method (volume of N₂ gas reduced to STP, with aqueous tension) or the Kjeldahl method (ammonia caught in H₂SO₄ or HCl, by direct or back titration). Every step is shown with your numbers, beside a sketch of the apparatus and known compounds to compare. Henry's law #L284 See Henry's law p = KH x at work. Pressurise a bottle of soda, warm it, then open it and watch the CO₂ escape. Compare how well CO₂, oxygen and nitrogen dissolve, and see why divers get the bends and climbers run short of oxygen.