Why van der Waals gets a 70 MPa hydrogen tank wrong by a third
A 2025 study finds the equation of state in a hydrogen refuelling model changes the computed pressure by up to 35 %. We recompute hydrogen at tank pressures and get the same spread.
A car’s hydrogen tank is filled to 70 MPa, about 700 times atmospheric pressure. At that squeeze hydrogen is nothing like an ideal gas: its molecules get in each other’s way, so the same mass needs far more room than the ideal gas law predicts. Filling models have to pick an equation of state to describe this, and a 2025 paper in Applied Sciences shows the choice is not a detail: swapping one equation for another moved the computed tank pressure by up to a third. This article recomputes hydrogen at tank conditions with the real gas calculator and reproduces the size of that error. For the easier cases, start with the gas law calculator, and for heavier petroleum gases see the PVT correlations.
The paper in brief
The authors built a lumped-parameter model of a hydrogen tank being refuelled: a zero-dimensional model of the gas inside coupled to a one-dimensional model of heat flowing through the tank wall. They checked the model against experiments, then ran it with several equations of state in turn: van der Waals, the standard modifications of it (Redlich-Kwong, Soave-Redlich-Kwong, Peng-Robinson), and a polynomial equation they fitted to NIST reference data themselves.
Using the NIST-based pressure as the benchmark, their fitted polynomial was off by 0.30 %, Redlich-Kwong by 1.83 % and plain van der Waals by 17.90 %. In a second case with a hotter inlet and a faster fill, the van der Waals error grew to 34.57 %: the higher the pressure, the worse it gets. They also report that the choice of equation barely changed the computed temperature while changing the computed pressure a lot, and that among the three modifications Redlich-Kwong reproduced the Joule-Thomson inversion curve best.
That is a useful warning, but it is buried in a coupled simulation. The obvious question for anyone else is: how much of that error is the equation itself, with no tank, no wall and no fill rate? That part anyone can check in a browser.
Checked with the tools
This is a recomputation, not a simulation of their tank. We take hydrogen as the Real gas calculator ships it (critical point 33.2 K and 13.0 bar, acentric factor −0.216, molar mass 2.016 g/mol: rounded general values, not the paper’s) at 15 °C, our choice of a filling-station temperature, and ask each equation what it says.
Step 1: the equations fan out with pressure. Figure 1 plots the compressibility factor Z = PV/(RT), which is 1 for an ideal gas and tells you directly how much more room the real gas needs. At 70 MPa the five answers are Z = 1 (ideal), 1.679 (van der Waals), 1.505 (Redlich-Kwong), 1.484 (Soave-Redlich-Kwong) and 1.396 (Peng-Robinson). So the ideal gas law would let you believe a 70 MPa tank holds about 50 % more hydrogen than it really does, and the equations disagree with each other by up to 20 %.
Step 2: the same gas, the same density, five pressures. A tank has a fixed volume and a fixed mass of hydrogen in it, so the right comparison is at fixed molar volume: all the equations describe the same gas, and the question is what pressure they report. We take the molar volume Redlich-Kwong gives at each pressure (51.51 cm³/mol at 70 MPa, against 34.23 cm³/mol for an ideal gas) and ask the others for their pressure at that same density. Redlich-Kwong is our reference because the paper found it the closest cubic to NIST, within 1.83 %.
Van der Waals then reads 5.7 % high at 30 MPa, 18.2 % high at 60 MPa and 23.8 % high at 70 MPa, crossing the paper’s 17.90 % at about 59 MPa and its 34.57 % at about 86 MPa (Figure 2). The ideal gas law is worse and in the other direction: 33.5 % low at 70 MPa. Soave-Redlich-Kwong stays within 2.2 % of Redlich-Kwong everywhere, and Peng-Robinson drifts to about 10 % low.
Step 3: one real tank. A 5 kg hydrogen tank of 128 litres (a typical size for a car; our numbers) holds 2,480 mol at a molar volume of 51.61 cm³/mol. At 15 °C the tool’s Gas in a container card gives 69.78 MPa from Redlich-Kwong, which is a full tank, 68.30 from Soave-Redlich-Kwong, 62.45 from Peng-Robinson, 86.29 from van der Waals and 46.42 from the ideal gas law. Read as a safety margin, van der Waals would have you believe the same tank is 16 MPa over its rating, and the ideal gas law that it is 23 MPa under.
| Check | Paper | Our tool result |
|---|---|---|
| van der Waals pressure error | 17.90 % (first case) | +18.2 % against Redlich-Kwong at 60 MPa, 15 °C |
| van der Waals error at higher pressure | 34.57 % (second case) | +34.6 % reached at about 86 MPa |
| Redlich-Kwong against the benchmark | 1.83 % | not testable in the browser (no NIST data offline); SRK sits within 2.2 % of it |
| Error grows with pressure | stated | +5.7 % at 30 MPa to +23.8 % at 70 MPa for van der Waals |
| Ideal gas law | not reported | −33.5 % at 70 MPa, 15 °C |
Two honest caveats. First, our reference is Redlich-Kwong, not NIST, because nothing about the user leaves the browser and the tool carries no reference tables; the paper’s own figure of 1.83 % is what lets us use it. Second, the paper’s errors come out of a coupled fill simulation at its own conditions, while ours are the bare thermodynamics at 15 °C. That the two agree to about a percentage point is the point: the error is the equation, not the plumbing.
How we made the graphs
Both charts and every number above come from scripts/blog-figures/hydrogen-tank-equation-of-state-pressure-error.mjs in fibub’s public code. It calls zCurve, solveTP, pressure and containerPressures from src/lib/sci/phrealgas.ts, the maths behind the real gas calculator. solveTP builds the cubic in Z for the chosen equation, takes its real roots and keeps the stable one (the lowest fugacity coefficient); pressure runs the equation the other way, from temperature and molar volume.
Where the numbers come from: the three error percentages and the ranking of the equations are from the paper’s text; hydrogen’s critical constants and acentric factor are the tool’s own rounded values; the 15 °C temperature, the 5 kg / 128 L tank and the choice of Redlich-Kwong as the reference are our assumptions.
How we test the maths
On every change to fibub, tests/sci.mjs runs tests/sci-tools/real-gas-calculator.mjs, which pins all four cubics against an independent NumPy/SciPy solution (polynomial roots in volume, fugacity from the residual Helmholtz energy, saturation pressure by Brent’s method):
- Carbon dioxide at 300 K and 50 bar must give Z = 0.7314551466 (van der Waals), 0.6974474900 (Redlich-Kwong) and 0.6711773034 (Peng-Robinson), to eight significant figures, with matching ln φ.
- The Peng-Robinson saturation pressure of carbon dioxide at 280 K must be 4,162,542.39 Pa, and no saturation point may be found above the critical temperature.
- On the van der Waals critical isotherm, Z at the critical point must come out at 3/8, the equation’s own exact value.
- New with this article: hydrogen at 288.15 K and 70 MPa must give Z = 1.0000, 1.6789, 1.5049, 1.4842 and 1.3959 for the five equations in order, and 5 kg of hydrogen in a 128-litre tank at 288.15 K must give 46.42, 86.29, 69.78, 68.30 and 62.45 MPa.
Check it yourself
On the real gas calculator:
- In Gas, choose Hydrogen (H₂). The critical constants fill in: Tc 33.2 K, Pc 13 bar, ω −0.216, molar mass 2.016 g/mol.
- Set Temperature to 15 and Temperature unit to °C. Set Pressure to 70 and Pressure unit to MPa.
- The headline reads Z = 1.396 (Peng-Robinson): 140 % of the ideal-gas volume, with a molar volume of 0.04778 L/mol and a density of 42.2 kg/m³ (an ideal gas would be 0.03423 L/mol).
- In the table Every equation at these conditions, read Z down the column: 1 (ideal gas), 1.679 (van der Waals), 1.505 (Redlich-Kwong), 1.484 (Soave-Redlich-Kwong), 1.396 (Peng-Robinson). Hydrogen needs 68 % more room than an ideal gas by one equation and 40 % more by another.
- In Gas in a container, type Amount of gas 5 with Amount unit kg, and Container volume 128 with Volume unit litres. The table gives 46.42, 86.29, 69.78, 68.30 and 62.45 MPa for the five equations, and the line above it says an ideal gas would give 46.42 MPa.
- Change Container volume to 160 litres and watch every pressure fall: Redlich-Kwong to 50.36 MPa, van der Waals to 57.16. The gap narrows because the gas is less squeezed.
What researchers can use it for
- Sanity-check a model’s equation of state before trusting its pressures: run your state point through all five equations and see how much of your result is physics and how much is the closure you picked.
- Size a vessel or a fill: the Gas in a container card turns a mass and a volume into the pressure each equation predicts, which is the number a relief valve cares about.
- Teach where the ideal gas law stops working: hydrogen at 70 MPa is a 50 % error, and students can see it in one chart.
- Compare fuels on the same footing: methane, nitrogen, carbon dioxide and helium are in the same list, so a compressed-gas comparison takes a minute.
- Report the equation, not just the number: if your paper gives a tank pressure, say which equation produced it, as this one does.
The fine print
- Our reference is Redlich-Kwong, not NIST data: the tool is offline and carries no reference tables. The paper’s 1.83 % figure is what makes that reference usable.
- The paper’s errors come from a coupled fill simulation with heat flow into the tank wall; ours are the equations alone at one temperature. The agreement is in size, not in setup.
- Cubic equations are mean-field models. Near the critical point, or in metastable states, none of them should be trusted, as the paper says itself.
- Hydrogen’s critical temperature is only 33 K, so at room temperature it is far above critical and the acentric factor (−0.216) is well outside the range Soave and Peng-Robinson were fitted for. That is part of why the cubics disagree so much here.
- We did not test the paper’s own fitted polynomial equation, which is not in the tool.
Sources
- Luo, H., Xin, Q., Yao, C., Li, C., Yang, T., Wu, X., Chahine, R. and Xiao, J. (2025), Effect of Real Gas Equations on Calculation Accuracy of Thermodynamic State in Hydrogen Storage Tank, Applied Sciences 15(20): 11151, doi:10.3390/app152011151. Licence CC BY, checked on the MDPI article page, 2026-11-24. Values used here: relative pressure errors against a NIST-based benchmark of 0.30 % (their fitted polynomial equation), 1.83 % (Redlich-Kwong) and 17.90 % (van der Waals), rising to 34.57 % for van der Waals in a higher-pressure case (20 °C inlet gas, 16 g/s); all three van der Waals modifications fitted the Joule-Thomson inversion curve with R² of 0.99 or better; the equation of state changed the computed pressure strongly but the computed temperature only a little.
- Equations of state and their constants: van der Waals (1873); Redlich, O. and Kwong, J. N. S. (1949), Chemical Reviews 44: 233; Soave, G. (1972), Chemical Engineering Science 27: 1197; Peng, D.-Y. and Robinson, D. B. (1976), Industrial and Engineering Chemistry Fundamentals 15: 59.
- Hydrogen's critical point (33.2 K, 13.0 bar), acentric factor (−0.216) and molar mass (2.016 g/mol): rounded general values as the Real gas calculator ships them, not taken from the paper. Gas constant R from CODATA (exact since 2019).
If you are an author or publisher and want a credit or a passage changed or removed, tell us and we will act quickly.