Double Interpolation: Reading a Table Between Two Rows and Two Columns

You need double interpolation when a table has two inputs, such as pressure and temperature, and your values fall between the listed entries for both. Do it in three linear interpolations:

For a quick answer, the bilinear interpolation calculator does double interpolation from the four surrounding table values.

  1. Interpolate along the first input (for example temperature) at the lower value of the second input.
  2. Repeat at the upper value of the second input.
  3. Interpolate between those two results along the second input (pressure).

Each step is an ordinary straight-line interpolation, so you can run all three in our interpolation calculator. In mathematics this procedure is called bilinear interpolation. Engineering students usually meet it as “double interpolation” in superheated steam tables.

When do you need double interpolation?

You need it whenever a property depends on two inputs and both fall between grid values. Common cases:

  • Superheated steam and refrigerant tables, where properties depend on pressure and temperature
  • Compressibility charts and gas property tables, with temperature and pressure inputs
  • Engineering design tables such as beam load tables, pipe friction tables and wind load coefficients
  • Finance and actuarial tables, with rate and term inputs
  • Any two-way lookup table in a spreadsheet or in code

If only one input is off-grid, you need just one interpolation. Our steam table interpolation guide covers that simpler case.

Worked example 1: superheated steam at 1.1 MPa and 325 °C

Problem: Find the enthalpy h of superheated steam at 1.1 MPa and 325 °C. The table has pressure blocks at 1.0 and 1.2 MPa, with rows every 50 °C.

Here are the four table entries that surround the point. Values come from the IAPWS-IF97 formulation, rounded as in printed tables.

300 °C 350 °C
1.0 MPa h = 3051.7 kJ/kg h = 3158.2 kJ/kg
1.2 MPa h = 3046.4 kJ/kg h = 3154.1 kJ/kg

Step 1: interpolate in temperature at 1.0 MPa

Fraction in temperature = (325 − 300) / (350 − 300) = 0.5

h(1.0 MPa, 325 °C) = 3051.7 + 0.5 × (3158.2 − 3051.7) = 3104.95 kJ/kg

Step 2: interpolate in temperature at 1.2 MPa

h(1.2 MPa, 325 °C) = 3046.4 + 0.5 × (3154.1 − 3046.4) = 3100.25 kJ/kg

Step 3: interpolate in pressure

Fraction in pressure = (1.1 − 1.0) / (1.2 − 1.0) = 0.5

h(1.1 MPa, 325 °C) = 3104.95 + 0.5 × (3100.25 − 3104.95) = 3102.60 kJ/kg

Accuracy check: The exact IF97 value at 1.1 MPa and 325 °C is 3102.8 kJ/kg. The double-interpolated answer is 0.2 kJ/kg low, an error under 0.01 percent.

Does the order matter?

No. Interpolate in pressure first instead:

  • At 300 °C: 3051.7 + 0.5 × (3046.4 − 3051.7) = 3049.05 kJ/kg
  • At 350 °C: 3158.2 + 0.5 × (3154.1 − 3158.2) = 3156.15 kJ/kg
  • At 325 °C: 3049.05 + 0.5 × (3156.15 − 3049.05) = 3102.60 kJ/kg

You get the same answer either way. Bilinear interpolation always gives the same result whichever direction you take first, so choose whichever order is less work.

Check it with the calculator

Run the interpolation calculator three times, leaving Y3 empty each time:

Run X1 Y1 X2 Y2 X3 Result (Y3)
1 (1.0 MPa) 300 3051.7 350 3158.2 325 3104.95
2 (1.2 MPa) 300 3046.4 350 3154.1 325 3100.25
3 (pressure) 1.0 3104.95 1.2 3100.25 1.1 3102.60

A trap: specific volume is not linear in pressure

Do the same double interpolation for specific volume v, using these table values:

300 °C 350 °C
1.0 MPa v = 0.25798 m³/kg v = 0.28249 m³/kg
1.2 MPa v = 0.21385 m³/kg v = 0.23454 m³/kg
  • At 1.0 MPa, 325 °C: v = 0.27024 m³/kg
  • At 1.2 MPa, 325 °C: v = 0.224195 m³/kg
  • At 1.1 MPa: v = 0.24721 m³/kg

The exact value is 0.24519 m³/kg, so this answer is about 0.8 percent high, more than 100 times the relative error we got for enthalpy. Volume in the vapor region is close to inversely proportional to pressure (v ≈ RT/P), and a straight line is a poor fit to a 1/P curve.

A better approach: interpolate the product P × v, which is nearly constant at fixed temperature, then divide by your pressure:

  • P × v at 1.0 MPa = 1.0 × 0.27024 = 0.27024
  • P × v at 1.2 MPa = 1.2 × 0.224195 = 0.26903
  • P × v at 1.1 MPa = 0.26963, so v = 0.26963 / 1.1 = 0.24512 m³/kg

That cuts the error from about 0.002 to under 0.0001 m³/kg. Your exam probably expects straight double interpolation of v, so use that unless told otherwise. In real calculations, transforming a variable before interpolating is a standard trick.

Worked example 2: a general two-way table (air density)

Double interpolation works on any two-way table. This table gives dry air density in kg/m³ at two pressures and two temperatures, calculated from the ideal gas law ρ = P / (R × T) with R = 287.05 J/(kg·K):

10 °C 20 °C
90 kPa 1.1073 1.0695
100 kPa 1.2303 1.1884

Problem: Find the density at 95.5 kPa and 14 °C.

Step 1, along temperature at 90 kPa: fraction = (14 − 10) / (20 − 10) = 0.4

ρ = 1.1073 + 0.4 × (1.0695 − 1.1073) = 1.09218 kg/m³

Step 2, along temperature at 100 kPa:

ρ = 1.2303 + 0.4 × (1.1884 − 1.2303) = 1.21354 kg/m³

Step 3, along pressure: fraction = (95.5 − 90) / (100 − 90) = 0.55

ρ = 1.09218 + 0.55 × (1.21354 − 1.09218) = 1.15893 kg/m³

The exact ideal gas value at 95.5 kPa and 14 °C is 1.15861 kg/m³, so the error is about 0.03 percent.

Calculator tip: the calculator shows two decimal places, and densities like 1.09218 would display as 1.09. Enter the values in g/m³ instead (1107.3, 1069.5, 1230.3, 1188.4) and divide the result by 1000.

The one-line formula (weights method)

You can also write double interpolation as a weighted average of the four corners. Let tx be the fraction along the first input and ty the fraction along the second:

f ≈ (1 − tx)(1 − ty) × f11 + tx(1 − ty) × f21 + (1 − tx)ty × f12 + tx × ty × f22

For the air density example, tx = 0.4 and ty = 0.55, so the weights are:

Corner Weight Value Weight × value
90 kPa, 10 °C 0.6 × 0.45 = 0.27 1.1073 0.298971
90 kPa, 20 °C 0.4 × 0.45 = 0.18 1.0695 0.192510
100 kPa, 10 °C 0.6 × 0.55 = 0.33 1.2303 0.405999
100 kPa, 20 °C 0.4 × 0.55 = 0.22 1.1884 0.261448
Sum 1.00 1.15893

The four weights always add up to 1, and the sum matches the three-step answer. The weights form is convenient in a spreadsheet, and it shows clearly that the nearest corner gets the most weight.

Tips for getting double interpolation right

  • Lay out the 2 × 2 box first. Write the four corner values in a small table before you calculate anything. Most mistakes come from reading the wrong cell.
  • Keep extra digits in the two intermediate results, and round only at the end.
  • Check the answer is inside the box. The result must lie between the smallest and largest of the four corners.
  • Watch for phase boundaries. In steam tables, if any of the four corners lies in a different phase (for example compressed liquid), the box is invalid. Use the saturated table or a closer grid.
  • Use transformations for curved properties, such as P × v for gas volume, or the logarithm for values that change exponentially.

Frequently asked questions

Is double interpolation the same as bilinear interpolation?

Yes. Both mean linear interpolation in two directions on a rectangular grid. “Double interpolation” is the engineering term and “bilinear interpolation” the mathematical one. See our bilinear interpolation article for the general formula and a geometric explanation.

Do I have to interpolate temperature first?

No. Either order gives the same answer, as Example 1 shows. Pick the order that needs fewer steps. If one input sits exactly on a table value, you only need one interpolation.

What if my pressure is exactly a table value but the temperature is not?

Then it is a single interpolation. At exactly 1.2 MPa and 325 °C, for instance, h = 3046.4 + 0.5 × (3154.1 − 3046.4) = 3100.25 kJ/kg, against an exact value of 3100.5 kJ/kg.

How do I do double interpolation in Excel or Python?

In Excel, put the three-step formulas in cells, or use the weights formula above. In Python, scipy.interpolate.RegularGridInterpolator with method="linear" does bilinear interpolation on a grid (SciPy documentation). Our lookup table interpolation guide shows one-dimensional versions in Excel, Python and C.

Related guides

If single interpolation is still new to you, start with how to interpolate, then come back to the two-input case.

Soren Vance
Soren Vance

Soren Vance is the Director of Quantitative Analysis & Algorithms at Interpolation Calculator, where he leads the design and optimization of the company’s core interpolation engines and data processing frameworks.

With a master’s in Computational Mathematics and over 8 years of experience in analytical modeling and numerical computing, Soren oversees the development of high‑performance methods — from spline interpolation and polynomial regressions to multidimensional estimators for real‑world datasets.

Known for his clarity of thought, Soren builds systems that balance mathematical rigor with computational efficiency. He collaborates closely with product, engineering, and UX teams to ensure users get reliable, transparent, and fast results. Outside of work, he contributes to open‑source math libraries and teaches data science workshops at local universities.

Articles: 21

Interpolation Calculator is a mathematical method used to estimate an unknown value between known data points.

Privacy

Disclaimer

Terms

GDPR

Affiliate

Refund

Company

About Us

Contact Us