Linear Interpolation Calculator
Enter two known points and a target x or y. Calculate the other coordinate, view the straight-line model and clearly distinguish interpolation from extrapolation.
YOUR CALCULATION
Result
β
Calculation steps
Work through one step at a time or reveal the complete calculation. The steps use your current inputs.
How to calculate
Compute the fraction of the distance between the two known coordinates. Use the same fraction between the other two coordinates. Targets outside the known interval are extrapolation and are explicitly labelled.
t = (xβxβ)/(xββxβ); y = yβ+t(yββyβ). Inverse: t = (yβyβ)/(yββyβ); x = xβ+t(xββxβ).
Worked example
For points (0, 10) and (100, 30), x = 25 gives t = 0.25 and y = 15. At x = 150 the same line gives y = 40, which is extrapolation rather than interpolation.
Assumptions and input details
The two x coordinates must differ. Inverse interpolation also requires different y values. Both x entries and the target x must use one consistent unit; the same rule applies separately to y. This fits a straight line through two entered points, with no physical accuracy guarantee or uncertainty estimate. The chart includes the target point even outside the segment. Inputs and results with absolute magnitude above 1e100 are rejected.
References: OpenStax: linear functions
Using this calculator
Can I enter my own problem?
Yes. Replace the example values with your own inputs. The result, calculation steps, tables and applicable diagrams update from those inputs. Blank or invalid values clear the result; example values are never silently substituted for missing inputs.
Are the results exact?
Results use floating-point arithmetic and displayed rounding. Read the formula, assumptions and any stated data precision before interpreting the result.
Is my input uploaded?
The calculation runs in your browser. No account, file upload or external AI service is required. Inputs are not saved between page reloads.
Solve two linear equations in x and y. See determinants, substitution checks and the two lines, including parallel or coincident cases.
Find real length, drawing length or a scale ratio. Mix length units and compare linear, area and volume scale factors with a size diagram.
Enter a list of numbers to calculate mean, median, modes, quartiles, population and sample standard deviation, with a frequency histogram.
Reserved advertising space.