How many bits of difference in a relative error?

109 Views Asked by At

I would like to know if there is a formula or any other way to find out how many bits of difference between two values given the relative error. For instance:

$$\epsilon_{\text{rel}} = \frac{V - V_\text{approx}}{V}$$

so, my relative error for instance could be calculated:

$$\epsilon_{\text{rel}} = \frac{10936907150.600960- 10936907150.600958}{10936907150.600960} = 1.82\times 10^{-16}$$

How can I know how many bits of difference I have here?

1

There are 1 best solutions below

2
On

That depends on the number of bits in the floating numbers. If you are using 53-Bit IEEE-Double arithmetic, a relative error of $1.82\times 10^{-16}$ means that the error is 1 or 2 bits.