Linear Interpolation Calculator

Use the linear interpolation formula y = y1 + (x - x1)(y2 - y1)/(x2 - x1) to find unknown values between two known points. Free online linear interpolator with slope and equation.

Interpolate between two points

Enter two known points and the target x value:

About This Calculator

The Linear Interpolation Calculator estimates an unknown y value that lies between two known data points using the straight-line assumption. Given two points (x1, y1) and (x2, y2), the calculator computes the interpolated y for any target x using the formula: y = y1 + (x - x1) x (y2 - y1) / (x2 - x1).

This method assumes a linear relationship between the two points, making it ideal for filling gaps in data tables, estimating intermediate measurements, and creating smooth transitions. The calculator also displays the slope and the full line equation for reference.

Linear interpolation is one of the most fundamental numerical methods used across mathematics, engineering, data science, and finance. While simple, it provides exact results when the underlying function is linear and serves as the building block for more advanced techniques like bilinear and spline interpolation.

When to Use Interpolation vs Extrapolation

Interpolation (x between x1 and x2) is more reliable because you are estimating within the known data range. Extrapolation (x outside the range) is less certain because it assumes the linear trend continues beyond the observed data. Use extrapolation with caution, especially for financial or scientific predictions.

International Usage

Linear interpolation is a universal mathematical method used worldwide. The calculator works with any numeric values -- no region-specific settings are needed. Students and professionals in India, the US, UK, and globally use linear interpolation for data analysis, engineering calculations, and statistical estimation.

Frequently Asked Questions

What is linear interpolation?

Linear interpolation estimates an unknown value that falls between two known data points by assuming the relationship is a straight line. It uses the formula y = y1 + (x - x1)(y2 - y1)/(x2 - x1) where (x1,y1) and (x2,y2) are the known endpoints.

How do you use the linear interpolation calculator?

Enter the x and y coordinates of two known points (x1,y1 and x2,y2), then enter the target x value you want to interpolate at. The calculator instantly returns the interpolated y value, the slope of the line, and the full line equation.

What is the difference between interpolation and extrapolation?

Interpolation estimates values within the range of known data points (between x1 and x2). Extrapolation estimates values outside this range. Our calculator supports both -- enter an x value between x1 and x2 for interpolation, or outside for extrapolation.

Where is linear interpolation used?

Linear interpolation is widely used in mathematics, engineering, finance, data science, computer graphics, and statistics. Common applications include filling missing data points, creating smooth transitions in animation, estimating intermediate values in tables, and signal processing.

Is linear interpolation accurate?

Linear interpolation is exact when the true relationship between points is linear. For nonlinear relationships, accuracy depends on how close the points are; closer points produce more accurate estimates. It is a first-order approximation and may introduce error for curved functions.

What happens if the two x values are equal?

If x1 equals x2, linear interpolation is undefined because the slope formula has a zero denominator (vertical line). The calculator prevents this by requiring distinct x values for the two known points.