A relative error of in the expression occurs when and , where . The exact difference is . However, when computing the answer using only digits, the rightmost digit of gets shifted off, and so the computed difference is . Thus the error is , and the relative error is .
When , the relative error can be as large as the result, and when , it can be 9 times larger. Or to put it another way, when , equation (3) shows that the number of contaminated digits is . That is, all of the digits in the result are wrong!
Suppose that one extra digit is added to guard against this situation (a guard digit). That is, the smaller number is truncated to digits, and then the result of the subtraction is rounded to digits. With a guard digit, the previous example becomes
Thus the answer is exact. With a single guard digit, the relative error of the result may be greater than , as in .
This rounds to , compared with the correct answer of , for a relative error of , which is greater than . In general, the relative error of the result can be only slightly larger than .