What is the definition of correct significant digits?

191 Views Asked by At

When I read the book "Accuracy and Stability of Numerical Algorithms", I came to the concept "correct significant digits" which I really can't understand.

The definition in the book is

  Here is a possible definition of correct significant digits: an approximation x' to x has p correct significant digits if x' and x round to the same number to p significant digits. Rounding is the act of replacing a given number by the nearest ...

I was confused with the description of x' and x round to the same number to p significant digits.

Does that mean the absolute value of x' minus x, and the significant digits of the absolute value is the correct significant digits? I googled it but there was nothing else helped. Could any one give me an example, or more precise description? Thanks, guys.


Editor's note: original picture of text.

2

There are 2 best solutions below

0
On

You have a function round(val,p) that rounds val to the nearest number with p significant digits (with the convention that if there is a tie, you round upwards). So round(0.9954,3) is equal to 0.995 and round(0.9954,2)=1.0.

Another way to state your definition is that x_approx has p correct significant digits to x if round(x,p)==round(x_approx,p).

If x=3.14159 and x_approx=3.141585 then you can say that x_approx has 6 correct digits, since round(x,6)==3.14159==round(x_approx,6).

Note that this definition is problematic, as explained in the book, since if you have x=.9949 and x_approx=.9952 then x_approx is correct to 1 digit and three significant digits, but NOT correct to two significant digits, which is one of the reasons relative error is a preferred measurement of accuracy for approximations.

0
On
  1. an approximation x' to x

    So you have two numbers, x' and x, and they're not (necessarily) the same. They probably differ somewhere.

  2. ... if x' and x round to the same number to p significant digits

    Pick a number p. Then we'll write out both x and x' to p digits. If the first p digits of x' and x are the same, we can say the approximation x' is correct to p significant digits.

Let's pick some concrete numbers.

  • x = π
  • x' = 22/7
  • p = 3

Now, round each of x and x' to 3 significant digits. π becomes 3.14and 22/7 is 3.14. (I'm assuming you know how to round, since you didn't ask about that, and cut out the text explaining it).

So, we can say as an approximation to π, 22/7 is correct to 3 significant digits.

If we instead choose p = 5, we get

  • π -> 3.1416 (the real value is 3.141592....)
  • 22/7 -> 3.1429 (the real value is 3.142857...)

so as an approximation to π, 22/7 is not correct to 5 significant digits.