Absolute and Relative Error in Measurement and Calculation
Measure how wrong a value is in units and in proportion, and track how errors grow when you add, multiply, raise to powers or subtract.
Key takeaways
- Absolute error is the size of the difference between the approximation and the true value, with units.
- Relative error divides that difference by the size of the true value and is often quoted as a percentage.
- When adding or subtracting, absolute error bounds add, while in multiplying and dividing, small relative error bounds approximately add.
- Subtracting nearly equal numbers can turn small relative errors into huge ones.
- When the true value is unknown, report an uncertainty range and say how you obtained it.
Absolute error is how far an approximate value is from the true one, expressed in the same units. Relative error is that distance divided by the size of the true value, so it tells you how large the mistake is in proportion.
You need both. An error of 1 centimeter is serious if you are cutting a shelf and trivial if you are measuring the distance between two towns. Absolute error says how much, and relative error says how much that matters compared with the quantity itself.
The two definitions
Let x be the true value and a the approximation.
absolute error = |a − x|
relative error = |a − x| / |x| (requires x ≠ 0)
percent error = relative error × 100% The vertical bars mean absolute value, which discards the sign. If the direction matters, you can report the signed error a − x, positive when the approximation is too high.
Apply this to a door and a road. Suppose each measurement is off by 1 cm. On a door 2 m tall, the relative error is 1/200 = 0.5 percent. On a road 100 km long, it is 1 part in 10 million. The absolute errors match, and the relative errors differ by a factor of 50,000.
Relative error has no units, so it lets you compare the quality of measurements of quite different things, such as a mass and a time.
Judging approximations
The familiar approximations of π make a tidy example, using π ≈ 3.141593.
| Approximation | Value | Absolute error | Relative error |
|---|---|---|---|
| 3 | 3.000000 | about 0.1416 | about 4.5% |
| 3.14 | 3.140000 | about 0.0016 | about 0.05% |
| 22/7 | 3.142857 | about 0.0013 | about 0.04% |
| 355/113 | 3.141593 | about 0.0000003 | about 0.0000085% |
So 22/7 is slightly better than 3.14, even though the decimal looks more precise to many people. The fraction is too high by about one part in 2,500, and the decimal is too low by about one part in 2,000.
The table also shows how relative error links to correct digits. A relative error near 0.05 percent goes with three or four reliable digits. Each extra correct digit cuts the relative error by roughly a factor of ten. If you round to n significant figures, the relative error is at most 5 × 10⁻ⁿ, a connection developed in significant figures and rounding.
When you do not know the true value
In real measurement the true value is unknown, which is the reason for measuring. So you state a bound or an uncertainty, such as 25.0 ± 0.1 cm.
For a simple bound, this means you believe the true length lies from 24.9 to 25.1 cm. The relative uncertainty is about 0.1/25.0 = 0.4 percent. Scientific reports often use a standard uncertainty instead, a statistical spread that does not guarantee the value lies inside. Say which kind you mean.
If you compare two measurements and neither is the reference, a common choice is the percent difference: |a − b| divided by their average, (a + b)/2, assuming both are positive. This is a different quantity from percent error, which assumes one value is accepted as correct.
Also separate accuracy from precision. Precision is how closely repeated readings agree. Accuracy is how close they are to the truth. A scale that always reads 200 grams heavy can be very precise and quite inaccurate.
Errors in sums and differences
Suppose a is known to within Δa and b to within Δb, where Δ means the size of the possible error. Then the sum and the difference are each known to within Δa + Δb.
(12.0 ± 0.1) + (8.0 ± 0.2) = 20.0 ± 0.3
(12.0 ± 0.1) − (8.0 ± 0.2) = 4.0 ± 0.3 Notice that subtraction does not cancel uncertainty. In the worst case, one value errs high while the other errs low.
This is a guaranteed bound. If errors are independent and random, with standard uncertainties, they typically combine as √(Δa² + Δb²), here about 0.22. That smaller figure relies on the independence, which you must be able to justify.
Errors in products and quotients
For multiplication and division, work with relative errors. When they are small, the relative error bound of a product or quotient is approximately the sum of the relative bounds.
Take a rectangle measured as 20.0 ± 0.1 cm by 5.0 ± 0.1 cm.
relative errors: 0.1/20 = 0.5% 0.1/5 = 2.0%
area: 100 cm², within about 2.5%, so ± 2.5 cm²
exact extremes: 19.9 × 4.9 = 97.51
20.1 × 5.1 = 102.51 The approximation matches closely. The tiny mismatch comes from the product of the two small errors, which the shortcut ignores.
The shorter side dominates. Halving the error on the long side would gain little, while halving it on the short side would help much more.
Powers and roots
Raising a value to a power n multiplies its relative error by about |n|. If the side of a cube is 1 percent too long, the volume is about 3 percent too big. The exact figure is 1.01³ = 1.030301.
A square root halves the relative error: if an area is uncertain by 4 percent, the side length is uncertain by about 2 percent. These are approximations for small errors, and they come from the first-order behavior that calculus makes precise.
A worked example: fuel economy
Say you drive a distance recorded as 400 km, believed good to within 4 km, and refill with 32.0 L of fuel, good to within 0.2 L.
economy = 400 / 32.0 = 12.5 km per liter
distance, relative = 4 / 400 = 1.0%
fuel, relative = 0.2 / 32.0 ≈ 0.6%
economy, relative ≈ 1.0% + 0.6% = 1.6%
economy, absolute ≈ 0.016 × 12.5 ≈ 0.2 km per liter Report this as about 12.5 ± 0.2 km per liter. Now suppose next month's figure is 12.6. The change of 0.1 sits inside the uncertainty, so it gives you no good reason to believe anything improved.
That is the practical value of an error estimate. It tells you which differences deserve an explanation and which could easily come from the way the numbers were collected. It also hides an assumption: that you fill the tank to the same level each time. If you do not, the real uncertainty is larger than the pump's reading suggests.
Errors that come from the method
Not all error comes from measurement. Some comes from replacing an exact process with a shorter one, which is called truncation error. The number e is the sum 1 + 1 + 1/2 + 1/6 + 1/24 and so on without end.
| Terms kept | Sum | Absolute error | Relative error |
|---|---|---|---|
| through 1/6 | about 2.6667 | about 0.0516 | about 1.9% |
| through 1/24 | about 2.7083 | about 0.0099 | about 0.37% |
Each added term improves the result. Numerical analysts try to bound the size of everything left out, so that they can promise an accuracy without knowing the exact answer.
Rounding error is a second kind, introduced whenever a calculation keeps only finitely many digits. A good computation arranges for both truncation and rounding to be much smaller than the uncertainty already present in the input data. Pushing them far below that level costs effort and gains nothing.
The danger of subtracting close values
Combine the subtraction rule with relative error and a trap appears. Suppose two readings are 1,000 ± 1 and 990 ± 1.
difference = 10 ± 2
relative error of each reading ≈ 0.1%
relative error of the difference = 2/10 = 20% Two excellent measurements produced a poor one. The same thing happens inside computers when nearly equal stored values are subtracted, as described in floating-point arithmetic and rounding errors.
The remedy is often algebraic. For large x, computing √(x + 1) − √x directly loses digits. The equivalent form 1/(√(x + 1) + √x) avoids the subtraction. Some problems, however, are sensitive by nature, which is the topic of condition numbers.
When relative error misleads
Relative error breaks down when the true value is zero and becomes enormous when it is near zero. It also depends on where a scale puts its zero.
An error of 1 degree on a temperature of 2 °C looks like 50 percent. The same temperature is 275.15 kelvin, where 1 degree is about 0.36 percent. The Celsius zero is a convention, so relative error on that scale means little. For such quantities, report the absolute error.
Common mistakes
- Dividing by the approximation instead of the true or accepted value. For small errors the difference is slight, but for large ones it is not.
- Mixing percent and percentage points when comparing two percentage readings.
- Adding relative errors in a sum, where absolute ones belong.
- Adding absolute errors in a product, where they would carry mismatched units.
- Treating the last digit on a digital display as proof of accuracy. A display can show hundredths while the sensor behind it is off by whole units.
A short habit protects against most of these. Write the units beside every error, and ask whether the figure you calculated has units (absolute) or is a pure ratio (relative).
Reporting results well
- Give the value, the uncertainty and the units together.
- Round the uncertainty to one or two significant figures, and round the value to the same decimal place.
- Say whether it is a hard bound, a standard uncertainty or a judgment.
- Separate random scatter, which averaging reduces, from systematic bias, which it does not.
- Keep unrounded numbers during the calculation.
A bare number with many digits invites false trust. Checking units with dimensional analysis and comparing against a rough estimate will catch gross mistakes that no error formula covers, since those formulas assume the calculation itself was set up correctly.