How to use the error propagation calculator
- Type a formula using the letters a, b, c and d, such as a / (b * c). You can use + - * / ^, parentheses and functions like sqrt, sin, exp and ln.
- Enter the value and the uncertainty of each letter the formula uses. Leave the others blank. Use 0 as the uncertainty for an exact value.
- Read the result with its combined uncertainty, and the table that shows how much each input contributes.
- Use the share of variance column to see which measurement to improve first.
Formula
combined uncertainty = sqrt(sum of (df/dx(i) x u(i))^2)
df/dx(i) is the sensitivity of the formula to input i
relative uncertainty = combined uncertainty / |result|
The sensitivities are partial derivatives found numerically with a central difference and one extrapolation step, so any smooth formula works. The result is reported with the uncertainty rounded to two significant digits. As a check, 20,000 draws from normal distributions with a fixed seed give a spread that should be close to the combined uncertainty.
A quotient with three measured inputs
Take a / (b * c) with a = 12.5 plus or minus 0.1, b = 2 plus or minus 0.05 and c = 3 plus or minus 0.02. The result is 2.0833, and the sensitivities are 0.1667 for a, -1.0417 for b and -0.6944 for c.
The combined uncertainty is sqrt((0.1667 x 0.1)^2 + (1.0417 x 0.05)^2 + (0.6944 x 0.02)^2) = 0.05642, shown as 2.083 +/- 0.056, a relative uncertainty of 2.71%. The input b contributes 85.2% of the variance, so a better measurement of b would help most. The simulation gives a spread of 0.0572, close to the formula.
How the combination works
Each input's uncertainty is scaled by how strongly the result depends on it, then the scaled uncertainties are added in quadrature, which means squared, summed and rooted. Independent errors partly cancel, so the total is smaller than the plain sum. For a sum or difference the absolute uncertainties combine this way, and for a product or quotient the relative uncertainties do.
A power of an input counts its uncertainty more strongly: for a to the third power, the relative uncertainty of the result is three times that of a. You get that automatically from the sensitivities.
When the method is not enough
This first-order method assumes the inputs are independent and their uncertainties are small compared with the values. If two inputs come from the same instrument, their errors are linked and the combined value is wrong. For formulas that curve strongly over the range of the inputs, compare with the simulated spread shown on the page; a large gap means the first-order result should be treated with caution. To judge a single reading, the Percent Error Calculator compares a result with a known value, and the Standard Error Calculator gives the uncertainty of a mean.
More math tools
For other numerical methods, try the Minimum Spanning Tree Calculator, Polynomial Root Finder and Root Finder.
Assumptions and limits
- Each uncertainty is one standard uncertainty, and the inputs are independent of each other.
- The formula is smooth near the values entered, so it can be approximated by a straight line there.
- Up to four inputs, named a, b, c and d, with values between -1e12 and 1e12.
- The simulation uses normal distributions and a fixed seed, so it gives the same answer each time.
Frequently asked questions
Should I add the uncertainties instead?
Adding them directly is the worst case, and it overstates the total for independent errors. Adding in quadrature gives the usual combined standard uncertainty. If errors are linked, neither is exactly right.
What does it mean when one input has a huge share?
It dominates the error budget. Improving the other inputs will change little, so spend effort on the measurement with the largest share.
How many digits should I report?
The page shows the uncertainty to two significant digits and the result rounded to the same decimal place, which is a common way to report a measurement.
Why does the page refuse my formula?
It may use a letter other than a to d, divide by zero at the values entered, or take the square root of a negative number. The message names the cause.