]>
Commit | Line | Data |
---|---|---|
4710c53d | 1 | ------------------------------------------------------------------------\r |
2 | -- ddNextPlus.decTest -- decDouble next that is greater [754r nextup] --\r | |
3 | -- Copyright (c) IBM Corporation, 1981, 2008. All rights reserved. --\r | |
4 | ------------------------------------------------------------------------\r | |
5 | -- Please see the document "General Decimal Arithmetic Testcases" --\r | |
6 | -- at http://www2.hursley.ibm.com/decimal for the description of --\r | |
7 | -- these testcases. --\r | |
8 | -- --\r | |
9 | -- These testcases are experimental ('beta' versions), and they --\r | |
10 | -- may contain errors. They are offered on an as-is basis. In --\r | |
11 | -- particular, achieving the same results as the tests here is not --\r | |
12 | -- a guarantee that an implementation complies with any Standard --\r | |
13 | -- or specification. The tests are not exhaustive. --\r | |
14 | -- --\r | |
15 | -- Please send comments, suggestions, and corrections to the author: --\r | |
16 | -- Mike Cowlishaw, IBM Fellow --\r | |
17 | -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK --\r | |
18 | -- mfc@uk.ibm.com --\r | |
19 | ------------------------------------------------------------------------\r | |
20 | version: 2.59\r | |
21 | \r | |
22 | -- All operands and results are decDoubles.\r | |
23 | precision: 16\r | |
24 | maxExponent: 384\r | |
25 | minExponent: -383\r | |
26 | extended: 1\r | |
27 | clamp: 1\r | |
28 | rounding: half_even\r | |
29 | \r | |
30 | ddnextp001 nextplus 0.9999999999999995 -> 0.9999999999999996\r | |
31 | ddnextp002 nextplus 0.9999999999999996 -> 0.9999999999999997\r | |
32 | ddnextp003 nextplus 0.9999999999999997 -> 0.9999999999999998\r | |
33 | ddnextp004 nextplus 0.9999999999999998 -> 0.9999999999999999\r | |
34 | ddnextp005 nextplus 0.9999999999999999 -> 1.000000000000000\r | |
35 | ddnextp006 nextplus 1.000000000000000 -> 1.000000000000001\r | |
36 | ddnextp007 nextplus 1.0 -> 1.000000000000001\r | |
37 | ddnextp008 nextplus 1 -> 1.000000000000001\r | |
38 | ddnextp009 nextplus 1.000000000000001 -> 1.000000000000002\r | |
39 | ddnextp010 nextplus 1.000000000000002 -> 1.000000000000003\r | |
40 | ddnextp011 nextplus 1.000000000000003 -> 1.000000000000004\r | |
41 | ddnextp012 nextplus 1.000000000000004 -> 1.000000000000005\r | |
42 | ddnextp013 nextplus 1.000000000000005 -> 1.000000000000006\r | |
43 | ddnextp014 nextplus 1.000000000000006 -> 1.000000000000007\r | |
44 | ddnextp015 nextplus 1.000000000000007 -> 1.000000000000008\r | |
45 | ddnextp016 nextplus 1.000000000000008 -> 1.000000000000009\r | |
46 | ddnextp017 nextplus 1.000000000000009 -> 1.000000000000010\r | |
47 | ddnextp018 nextplus 1.000000000000010 -> 1.000000000000011\r | |
48 | ddnextp019 nextplus 1.000000000000011 -> 1.000000000000012\r | |
49 | \r | |
50 | ddnextp021 nextplus -0.9999999999999995 -> -0.9999999999999994\r | |
51 | ddnextp022 nextplus -0.9999999999999996 -> -0.9999999999999995\r | |
52 | ddnextp023 nextplus -0.9999999999999997 -> -0.9999999999999996\r | |
53 | ddnextp024 nextplus -0.9999999999999998 -> -0.9999999999999997\r | |
54 | ddnextp025 nextplus -0.9999999999999999 -> -0.9999999999999998\r | |
55 | ddnextp026 nextplus -1.000000000000000 -> -0.9999999999999999\r | |
56 | ddnextp027 nextplus -1.0 -> -0.9999999999999999\r | |
57 | ddnextp028 nextplus -1 -> -0.9999999999999999\r | |
58 | ddnextp029 nextplus -1.000000000000001 -> -1.000000000000000\r | |
59 | ddnextp030 nextplus -1.000000000000002 -> -1.000000000000001\r | |
60 | ddnextp031 nextplus -1.000000000000003 -> -1.000000000000002\r | |
61 | ddnextp032 nextplus -1.000000000000004 -> -1.000000000000003\r | |
62 | ddnextp033 nextplus -1.000000000000005 -> -1.000000000000004\r | |
63 | ddnextp034 nextplus -1.000000000000006 -> -1.000000000000005\r | |
64 | ddnextp035 nextplus -1.000000000000007 -> -1.000000000000006\r | |
65 | ddnextp036 nextplus -1.000000000000008 -> -1.000000000000007\r | |
66 | ddnextp037 nextplus -1.000000000000009 -> -1.000000000000008\r | |
67 | ddnextp038 nextplus -1.000000000000010 -> -1.000000000000009\r | |
68 | ddnextp039 nextplus -1.000000000000011 -> -1.000000000000010\r | |
69 | ddnextp040 nextplus -1.000000000000012 -> -1.000000000000011\r | |
70 | \r | |
71 | -- Zeros\r | |
72 | ddnextp100 nextplus 0 -> 1E-398\r | |
73 | ddnextp101 nextplus 0.00 -> 1E-398\r | |
74 | ddnextp102 nextplus 0E-300 -> 1E-398\r | |
75 | ddnextp103 nextplus 0E+300 -> 1E-398\r | |
76 | ddnextp104 nextplus 0E+30000 -> 1E-398\r | |
77 | ddnextp105 nextplus -0 -> 1E-398\r | |
78 | ddnextp106 nextplus -0.00 -> 1E-398\r | |
79 | ddnextp107 nextplus -0E-300 -> 1E-398\r | |
80 | ddnextp108 nextplus -0E+300 -> 1E-398\r | |
81 | ddnextp109 nextplus -0E+30000 -> 1E-398\r | |
82 | \r | |
83 | -- specials\r | |
84 | ddnextp150 nextplus Inf -> Infinity\r | |
85 | ddnextp151 nextplus -Inf -> -9.999999999999999E+384\r | |
86 | ddnextp152 nextplus NaN -> NaN\r | |
87 | ddnextp153 nextplus sNaN -> NaN Invalid_operation\r | |
88 | ddnextp154 nextplus NaN77 -> NaN77\r | |
89 | ddnextp155 nextplus sNaN88 -> NaN88 Invalid_operation\r | |
90 | ddnextp156 nextplus -NaN -> -NaN\r | |
91 | ddnextp157 nextplus -sNaN -> -NaN Invalid_operation\r | |
92 | ddnextp158 nextplus -NaN77 -> -NaN77\r | |
93 | ddnextp159 nextplus -sNaN88 -> -NaN88 Invalid_operation\r | |
94 | \r | |
95 | -- Nmax, Nmin, Ntiny, subnormals\r | |
96 | ddnextp170 nextplus -9.999999999999999E+384 -> -9.999999999999998E+384\r | |
97 | ddnextp171 nextplus -9.999999999999998E+384 -> -9.999999999999997E+384\r | |
98 | ddnextp172 nextplus -1E-383 -> -9.99999999999999E-384\r | |
99 | ddnextp173 nextplus -1.000000000000000E-383 -> -9.99999999999999E-384\r | |
100 | ddnextp174 nextplus -9E-398 -> -8E-398\r | |
101 | ddnextp175 nextplus -9.9E-397 -> -9.8E-397\r | |
102 | ddnextp176 nextplus -9.99999999999E-387 -> -9.99999999998E-387\r | |
103 | ddnextp177 nextplus -9.99999999999999E-384 -> -9.99999999999998E-384\r | |
104 | ddnextp178 nextplus -9.99999999999998E-384 -> -9.99999999999997E-384\r | |
105 | ddnextp179 nextplus -9.99999999999997E-384 -> -9.99999999999996E-384\r | |
106 | ddnextp180 nextplus -0E-398 -> 1E-398\r | |
107 | ddnextp181 nextplus -1E-398 -> -0E-398\r | |
108 | ddnextp182 nextplus -2E-398 -> -1E-398\r | |
109 | \r | |
110 | ddnextp183 nextplus 0E-398 -> 1E-398\r | |
111 | ddnextp184 nextplus 1E-398 -> 2E-398\r | |
112 | ddnextp185 nextplus 2E-398 -> 3E-398\r | |
113 | ddnextp186 nextplus 10E-398 -> 1.1E-397\r | |
114 | ddnextp187 nextplus 100E-398 -> 1.01E-396\r | |
115 | ddnextp188 nextplus 100000E-398 -> 1.00001E-393\r | |
116 | ddnextp189 nextplus 1.00000000000E-383 -> 1.000000000000001E-383\r | |
117 | ddnextp190 nextplus 1.000000000000000E-383 -> 1.000000000000001E-383\r | |
118 | ddnextp191 nextplus 1E-383 -> 1.000000000000001E-383\r | |
119 | ddnextp192 nextplus 9.999999999999998E+384 -> 9.999999999999999E+384\r | |
120 | ddnextp193 nextplus 9.999999999999999E+384 -> Infinity\r | |
121 | \r | |
122 | -- Null tests\r | |
123 | ddnextp900 nextplus # -> NaN Invalid_operation\r | |
124 | \r |