Error propagation of the logarithmic mean of two variables

320 Views Asked by At

My problem is fairly simple to explain: I am calculating the logarithmic mean, $M_{lm}$ of two variables, $x$ and $y$, both associated with an error, $\sigma x$ and $\sigma y$, and need to propagate the corresponding error.

$x = 3977$, $\sigma x = \pm 397$

$y = 3788$, $\sigma y = \pm 381$

$M_{lm} = \frac{x-y}{\ln x-\ln y} = 3882$

In an attempt to derive the error propagation equation, I split the logmean equation into two parts, (a) the numerator and (b) the denominator, and propagated their errors separately:

$(a) = x-y$

$(b) = \ln x-\ln y$

$\sigma (a) = \sqrt{\sigma x^2+\sigma y^2}$

$\sigma (b) = \sqrt{(\frac{\sigma x}{x})^2+(\frac{\sigma x}{x})^2}$

The error of $M_{lm}$ would then be calculated as follows:

$\sigma M_{lm} = M_{lm}\sqrt{\left(\frac{\sqrt{\sigma x^2+\sigma y^2}}{x-y}\right)^2-\left(\frac{\sqrt{(\frac{\sigma x}{x})^2+(\frac{\sigma x}{x})^2}}{\ln x-\ln y}\right)^2} = 15981$

Since this error seemed to be far too large, I used several online tools/Matlab scripts/Wolfram Alpha to calculate the error actual error all of which returning the same error of $\sigma M_{lm} = 275$.

This is the equation Wolfram Alpha uses:

$\sigma M_{lm} = \sqrt{\frac{\sigma x^2 y^2 (x \ln y + x + x (-\ln x) - y)^2 + \sigma y^2 x^2 (-y \ln x + x - y + y \ln y)^2}{x^2 y^2 (\ln x - \ln y)^4}}$

I have tried to derive this equation all day but can't seem to get there. Any help would be kindly appreciated!

Cheers Jake