# Calculating the uncertainty on an expression

In one of my labs I had to calculate the an expression for a constant $$m$$, where $$m$$ is defined as $$m = \frac{T}{L^2v^2}$$, with $$T$$ being tension (constant), $$L$$ being length and $$v$$ being frequency. Now in order to do this accurately, I found 6 values for $$L$$ and $$v$$ - the tension was constant for all of these values. Then I used excel to plot a graph of $$T$$ against $$L^2v^2$$ and the gradient of the line of best fit gave me my value for $$m$$. Now the thing that I'm having problems with is finding out if it's possible for me to find the uncertainty on $$m$$. I know that I can find the uncertainty for $$m$$ if I know the uncertainties for $$T$$, $$L^2$$ and $$v^2$$ using the formula below:

$$\left. \begin{array}{l} Z = A \times B \\ or \\ Z = \frac{A}{B}\\ \end{array} \right\} \Rightarrow \biggl (\frac{\Delta Z}{Z} \biggr )^2 = \biggl (\frac{\Delta A}{A} \biggr )^2 + \biggl (\frac{\Delta B}{B} \biggr )^2$$

I'm able to calculate the uncertainty on $$T$$ but I'm not sure if I can calculate the uncertainties for $$v^2$$ and $$L^2$$. I know that the uncertainties for each value of $$v$$ and $$L$$ were $$\pm 0.1$$ Hz and $$\pm 0.05$$ Hz. However, in order to calculate the uncertainties for $$v^2$$ and $$L^2$$ I need to use the formula:

$$Z = A^n \Rightarrow \frac{\Delta Z}{Z} = n \biggr ( \frac{\Delta A}{A} \biggl )$$

which requires values for $$v$$ and $$L$$, which I do not have since I used the gradient of the line of best fit to find $$m$$ and not specific values of $$L$$ and $$v$$. So I'm wondering if it would be sensible for me to perhaps use the average of my values for $$L$$ and $$v$$ in order to calculate the uncertainties for $$L^2$$ and $$v^2$$ or if it is sensible at all to even calculate an uncertainty for $$m$$ in this situation.

• You can estimate the uncertainty in the slope from the deviations of the measured points to the fitted line.
– user137289
Mar 5 '18 at 17:14
• In general, the uncertainty of $Z$ (let it be $\Delta z$) is defined as $\Delta z=\Sigma_{i}\big|\frac{\partial Z}{\partial x_i}\big|\Delta x_i$ if $Z=Z(\{x_i\})$ Mar 5 '18 at 17:21
• @Pieter How exactly would I do that? Is there a reference for that sort of technique?
– Hai
Mar 5 '18 at 17:22
• Method of least squares, minimizing the sum of the squares of deviations. For a straight line it is called linear regression. These are terms you can google. An alternative is to make a graphic estimate by eye, see what slope is roughly consistent with data points.
– user137289
Mar 5 '18 at 17:26

## 1 Answer

Absolute error of function is defined as : $$\Delta_f = \sum_n \left| \frac{\partial f(x_1,x_2,\ldots, x_n)} {~\partial x_n} \right| \cdot \Delta {x_n}$$

And relative error of function is just : $$\delta_f = \frac{\Delta_f}{\left|f(x_1,x_2,\ldots, x_n)\right|}$$

So for your function : $$m = \frac{T}{L^2v^2}$$ with two variables $$L,v$$, find partial derivatives with respect to them and substitute into first formula for absolute error :

$$\Delta_m = \frac {2~T}{L^3 v^2} \Delta L ~+~ \frac{2~T}{L^2 v^3}\Delta v$$

Substitute average values of $$L,v,T$$ and measurement errors $$\Delta L,\Delta v$$ and you will get $$m(L,v)$$ function absolute error. If you need a relative error, then according to second formula - just divide found absolute error by $$m$$ function value.