1 | |
---|
2 | |
---|
3 | *** PARANOIA TEST *** |
---|
4 | paranoia version 1.1 [cygnus] |
---|
5 | Program is now RUNNING tests on small integers: |
---|
6 | TEST: 0+0 != 0, 1-1 != 0, 1 <= 0, or 1+1 != 2 |
---|
7 | PASS: 0+0 != 0, 1-1 != 0, 1 <= 0, or 1+1 != 2 |
---|
8 | TEST: 3 != 2+1, 4 != 3+1, 4+2*(-2) != 0, or 4-3-1 != 0 |
---|
9 | PASS: 3 != 2+1, 4 != 3+1, 4+2*(-2) != 0, or 4-3-1 != 0 |
---|
10 | TEST: -1+1 != 0, (-1)+abs(1) != 0, or -1+(-1)*(-1) != 0 |
---|
11 | PASS: -1+1 != 0, (-1)+abs(1) != 0, or -1+(-1)*(-1) != 0 |
---|
12 | TEST: 1/2 + (-1) + 1/2 != 0 |
---|
13 | PASS: 1/2 + (-1) + 1/2 != 0 |
---|
14 | TEST: 9 != 3*3, 27 != 9*3, 32 != 8*4, or 32-27-4-1 != 0 |
---|
15 | PASS: 9 != 3*3, 27 != 9*3, 32 != 8*4, or 32-27-4-1 != 0 |
---|
16 | TEST: 5 != 4+1, 240/3 != 80, 240/4 != 60, or 240/5 != 48 |
---|
17 | PASS: 5 != 4+1, 240/3 != 80, 240/4 != 60, or 240/5 != 48 |
---|
18 | -1, 0, 1/2, 1, 2, 3, 4, 5, 9, 27, 32 & 240 are O.K. |
---|
19 | |
---|
20 | Searching for Radix and Precision. |
---|
21 | Radix = 2.000000 . |
---|
22 | Closest relative separation found is U1 = 1.1102230e-16 . |
---|
23 | |
---|
24 | Recalculating radix and precision |
---|
25 | confirms closest relative separation U1 . |
---|
26 | Radix confirmed. |
---|
27 | TEST: Radix is too big: roundoff problems |
---|
28 | PASS: Radix is too big: roundoff problems |
---|
29 | TEST: Radix is not as good as 2 or 10 |
---|
30 | PASS: Radix is not as good as 2 or 10 |
---|
31 | TEST: (1-U1)-1/2 < 1/2 is FALSE, prog. fails? |
---|
32 | PASS: (1-U1)-1/2 < 1/2 is FALSE, prog. fails? |
---|
33 | TEST: Comparison is fuzzy,X=1 but X-1/2-1/2 != 0 |
---|
34 | PASS: Comparison is fuzzy,X=1 but X-1/2-1/2 != 0 |
---|
35 | The number of significant digits of the Radix is 53.000000 . |
---|
36 | TEST: Precision worse than 5 decimal figures |
---|
37 | PASS: Precision worse than 5 decimal figures |
---|
38 | TEST: Subtraction is not normalized X=Y,X+Z != Y+Z! |
---|
39 | PASS: Subtraction is not normalized X=Y,X+Z != Y+Z! |
---|
40 | Subtraction appears to be normalized, as it should be. |
---|
41 | Checking for guard digit in *, /, and -. |
---|
42 | TEST: * gets too many final digits wrong. |
---|
43 | |
---|
44 | PASS: * gets too many final digits wrong. |
---|
45 | |
---|
46 | TEST: Division lacks a Guard Digit, so error can exceed 1 ulp |
---|
47 | or 1/3 and 3/9 and 9/27 may disagree |
---|
48 | PASS: Division lacks a Guard Digit, so error can exceed 1 ulp |
---|
49 | or 1/3 and 3/9 and 9/27 may disagree |
---|
50 | TEST: Computed value of 1/1.000..1 >= 1 |
---|
51 | PASS: Computed value of 1/1.000..1 >= 1 |
---|
52 | TEST: * and/or / gets too many last digits wrong |
---|
53 | PASS: * and/or / gets too many last digits wrong |
---|
54 | *, /, and - appear to have guard digits, as they should. |
---|
55 | Checking rounding on multiply, divide and add/subtract. |
---|
56 | TEST: X * (1/X) differs from 1 |
---|
57 | PASS: X * (1/X) differs from 1 |
---|
58 | * is neither chopped nor correctly rounded. |
---|
59 | / is neither chopped nor correctly rounded. |
---|
60 | TEST: Radix * ( 1 / Radix ) differs from 1 |
---|
61 | PASS: Radix * ( 1 / Radix ) differs from 1 |
---|
62 | TEST: Incomplete carry-propagation in Addition |
---|
63 | PASS: Incomplete carry-propagation in Addition |
---|
64 | Addition/Subtraction neither rounds nor chops. |
---|
65 | Sticky bit used incorrectly or not at all. |
---|
66 | TEST: lack(s) of guard digits or failure(s) to correctly round or chop |
---|
67 | (noted above) count as one flaw in the final tally below |
---|
68 | ERROR: Severity: FLAW: lack(s) of guard digits or failure(s) to correctly round or chop |
---|
69 | (noted above) count as one flaw in the final tally below. |
---|
70 | PASS: lack(s) of guard digits or failure(s) to correctly round or chop |
---|
71 | (noted above) count as one flaw in the final tally below |
---|
72 | |
---|
73 | Does Multiplication commute? Testing on 20 random pairs. |
---|
74 | No failures found in 20 integer pairs. |
---|
75 | |
---|
76 | Running test of square root(x). |
---|
77 | TEST: Square root of 0.0, -0.0 or 1.0 wrong |
---|
78 | PASS: Square root of 0.0, -0.0 or 1.0 wrong |
---|
79 | Testing if sqrt(X * X) == X for 20 Integers X. |
---|
80 | Test for sqrt monotonicity. |
---|
81 | sqrt has passed a test for Monotonicity. |
---|
82 | Testing whether sqrt is rounded or chopped. |
---|
83 | Square root is neither chopped nor correctly rounded. |
---|
84 | Observed errors run from -5.0000000e-01 to 5.0000000e-01 ulps. |
---|
85 | TEST: sqrt gets too many last digits wrong |
---|
86 | PASS: sqrt gets too many last digits wrong |
---|
87 | Testing powers Z^i for small Integers Z and i. |
---|
88 | ... no discrepancies found. |
---|
89 | |
---|
90 | Seeking Underflow thresholds UfThold and E0. |
---|
91 | Smallest strictly positive number found is E0 = 4.94066e-324 . |
---|
92 | Since comparison denies Z = 0, evaluating (Z + Z) / Z should be safe. |
---|
93 | What the machine gets for (Z + Z) / Z is 2.00000000000000000e+00 . |
---|
94 | This is O.K., provided Over/Underflow has NOT just been signaled. |
---|
95 | Underflow is gradual; it incurs Absolute Error = |
---|
96 | (roundoff in UfThold) < E0. |
---|
97 | The Underflow threshold is 2.22507385850720188e-308, below which |
---|
98 | calculation may suffer larger Relative error than merely roundoff. |
---|
99 | Since underflow occurs below the threshold |
---|
100 | UfThold = (2.00000000000000000e+00) ^ (-1.02200000000000000e+03) |
---|
101 | only underflow should afflict the expression |
---|
102 | (2.00000000000000000e+00) ^ (-2.04400000000000000e+03); |
---|
103 | actually calculating yields: 0.00000000000000000e+00 . |
---|
104 | This computed value is O.K. |
---|
105 | |
---|
106 | Testing X^((X + 1) / (X - 1)) vs. exp(2) = 7.38905609893065218e+00 as X -> 1. |
---|
107 | Accuracy seems adequate. |
---|
108 | Testing powers Z^Q at four nearly extreme values. |
---|
109 | ... no discrepancies found. |
---|
110 | |
---|
111 | Searching for Overflow threshold: |
---|
112 | This may generate an error. |
---|
113 | Can `Z = -Y' overflow? |
---|
114 | Trying it on Y = -inf . |
---|
115 | Seems O.K. |
---|
116 | Overflow threshold is V = 1.79769313486231571e+308 . |
---|
117 | Overflow saturates at V0 = inf . |
---|
118 | No Overflow should be signaled for V * 1 = 1.79769313486231571e+308 |
---|
119 | nor for V / 1 = 1.79769313486231571e+308 . |
---|
120 | Any overflow signal separating this * from the one |
---|
121 | above is a DEFECT. |
---|
122 | |
---|
123 | |
---|
124 | What message and/or values does Division by Zero produce? |
---|
125 | Trying to compute 1 / 0 produces ... inf . |
---|
126 | |
---|
127 | Trying to compute 0 / 0 produces ... nan . |
---|
128 | |
---|
129 | The number of FLAWs discovered = 1. |
---|
130 | |
---|
131 | The arithmetic diagnosed seems Satisfactory though flawed. |
---|
132 | END OF TEST. |
---|
133 | *** END OF PARANOIA TEST *** |
---|