]>
Commit | Line | Data |
---|---|---|
4710c53d | 1 | ------------------------------------------------------------------------\r |
2 | -- base.decTest -- base decimal <--> string conversions --\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 | extended: 1\r | |
22 | \r | |
23 | -- This file tests base conversions from string to a decimal number\r | |
24 | -- and back to a string (in either Scientific or Engineering form)\r | |
25 | \r | |
26 | -- Note that unlike other operations the operand is subject to rounding\r | |
27 | -- to conform to emax and precision settings (that is, numbers will\r | |
28 | -- conform to rules and exponent will be in permitted range).\r | |
29 | \r | |
30 | precision: 16\r | |
31 | rounding: half_up\r | |
32 | maxExponent: 384\r | |
33 | minExponent: -383\r | |
34 | \r | |
35 | basx001 toSci 0 -> 0\r | |
36 | basx002 toSci 1 -> 1\r | |
37 | basx003 toSci 1.0 -> 1.0\r | |
38 | basx004 toSci 1.00 -> 1.00\r | |
39 | basx005 toSci 10 -> 10\r | |
40 | basx006 toSci 1000 -> 1000\r | |
41 | basx007 toSci 10.0 -> 10.0\r | |
42 | basx008 toSci 10.1 -> 10.1\r | |
43 | basx009 toSci 10.4 -> 10.4\r | |
44 | basx010 toSci 10.5 -> 10.5\r | |
45 | basx011 toSci 10.6 -> 10.6\r | |
46 | basx012 toSci 10.9 -> 10.9\r | |
47 | basx013 toSci 11.0 -> 11.0\r | |
48 | basx014 toSci 1.234 -> 1.234\r | |
49 | basx015 toSci 0.123 -> 0.123\r | |
50 | basx016 toSci 0.012 -> 0.012\r | |
51 | basx017 toSci -0 -> -0\r | |
52 | basx018 toSci -0.0 -> -0.0\r | |
53 | basx019 toSci -00.00 -> -0.00\r | |
54 | \r | |
55 | basx021 toSci -1 -> -1\r | |
56 | basx022 toSci -1.0 -> -1.0\r | |
57 | basx023 toSci -0.1 -> -0.1\r | |
58 | basx024 toSci -9.1 -> -9.1\r | |
59 | basx025 toSci -9.11 -> -9.11\r | |
60 | basx026 toSci -9.119 -> -9.119\r | |
61 | basx027 toSci -9.999 -> -9.999\r | |
62 | \r | |
63 | basx030 toSci '123456789.123456' -> '123456789.123456'\r | |
64 | basx031 toSci '123456789.000000' -> '123456789.000000'\r | |
65 | basx032 toSci '123456789123456' -> '123456789123456'\r | |
66 | basx033 toSci '0.0000123456789' -> '0.0000123456789'\r | |
67 | basx034 toSci '0.00000123456789' -> '0.00000123456789'\r | |
68 | basx035 toSci '0.000000123456789' -> '1.23456789E-7'\r | |
69 | basx036 toSci '0.0000000123456789' -> '1.23456789E-8'\r | |
70 | \r | |
71 | basx037 toSci '0.123456789012344' -> '0.123456789012344'\r | |
72 | basx038 toSci '0.123456789012345' -> '0.123456789012345'\r | |
73 | \r | |
74 | -- String [many more examples are implicitly tested elsewhere]\r | |
75 | -- strings without E cannot generate E in result\r | |
76 | basx040 toSci "12" -> '12'\r | |
77 | basx041 toSci "-76" -> '-76'\r | |
78 | basx042 toSci "12.76" -> '12.76'\r | |
79 | basx043 toSci "+12.76" -> '12.76'\r | |
80 | basx044 toSci "012.76" -> '12.76'\r | |
81 | basx045 toSci "+0.003" -> '0.003'\r | |
82 | basx046 toSci "17." -> '17'\r | |
83 | basx047 toSci ".5" -> '0.5'\r | |
84 | basx048 toSci "044" -> '44'\r | |
85 | basx049 toSci "0044" -> '44'\r | |
86 | basx050 toSci "0.0005" -> '0.0005'\r | |
87 | basx051 toSci "00.00005" -> '0.00005'\r | |
88 | basx052 toSci "0.000005" -> '0.000005'\r | |
89 | basx053 toSci "0.0000050" -> '0.0000050'\r | |
90 | basx054 toSci "0.0000005" -> '5E-7'\r | |
91 | basx055 toSci "0.00000005" -> '5E-8'\r | |
92 | basx056 toSci "12345678.543210" -> '12345678.543210'\r | |
93 | basx057 toSci "2345678.543210" -> '2345678.543210'\r | |
94 | basx058 toSci "345678.543210" -> '345678.543210'\r | |
95 | basx059 toSci "0345678.54321" -> '345678.54321'\r | |
96 | basx060 toSci "345678.5432" -> '345678.5432'\r | |
97 | basx061 toSci "+345678.5432" -> '345678.5432'\r | |
98 | basx062 toSci "+0345678.5432" -> '345678.5432'\r | |
99 | basx063 toSci "+00345678.5432" -> '345678.5432'\r | |
100 | basx064 toSci "-345678.5432" -> '-345678.5432'\r | |
101 | basx065 toSci "-0345678.5432" -> '-345678.5432'\r | |
102 | basx066 toSci "-00345678.5432" -> '-345678.5432'\r | |
103 | -- examples\r | |
104 | basx067 toSci "5E-6" -> '0.000005'\r | |
105 | basx068 toSci "50E-7" -> '0.0000050'\r | |
106 | basx069 toSci "5E-7" -> '5E-7'\r | |
107 | \r | |
108 | -- [No exotics as no Unicode]\r | |
109 | \r | |
110 | -- rounded with dots in all (including edge) places\r | |
111 | basx071 toSci .1234567890123456123 -> 0.1234567890123456 Inexact Rounded\r | |
112 | basx072 toSci 1.234567890123456123 -> 1.234567890123456 Inexact Rounded\r | |
113 | basx073 toSci 12.34567890123456123 -> 12.34567890123456 Inexact Rounded\r | |
114 | basx074 toSci 123.4567890123456123 -> 123.4567890123456 Inexact Rounded\r | |
115 | basx075 toSci 1234.567890123456123 -> 1234.567890123456 Inexact Rounded\r | |
116 | basx076 toSci 12345.67890123456123 -> 12345.67890123456 Inexact Rounded\r | |
117 | basx077 toSci 123456.7890123456123 -> 123456.7890123456 Inexact Rounded\r | |
118 | basx078 toSci 1234567.890123456123 -> 1234567.890123456 Inexact Rounded\r | |
119 | basx079 toSci 12345678.90123456123 -> 12345678.90123456 Inexact Rounded\r | |
120 | basx080 toSci 123456789.0123456123 -> 123456789.0123456 Inexact Rounded\r | |
121 | basx081 toSci 1234567890.123456123 -> 1234567890.123456 Inexact Rounded\r | |
122 | basx082 toSci 12345678901.23456123 -> 12345678901.23456 Inexact Rounded\r | |
123 | basx083 toSci 123456789012.3456123 -> 123456789012.3456 Inexact Rounded\r | |
124 | basx084 toSci 1234567890123.456123 -> 1234567890123.456 Inexact Rounded\r | |
125 | basx085 toSci 12345678901234.56123 -> 12345678901234.56 Inexact Rounded\r | |
126 | basx086 toSci 123456789012345.6123 -> 123456789012345.6 Inexact Rounded\r | |
127 | basx087 toSci 1234567890123456.123 -> 1234567890123456 Inexact Rounded\r | |
128 | basx088 toSci 12345678901234561.23 -> 1.234567890123456E+16 Inexact Rounded\r | |
129 | basx089 toSci 123456789012345612.3 -> 1.234567890123456E+17 Inexact Rounded\r | |
130 | basx090 toSci 1234567890123456123. -> 1.234567890123456E+18 Inexact Rounded\r | |
131 | \r | |
132 | -- Numbers with E\r | |
133 | basx130 toSci "0.000E-1" -> '0.0000'\r | |
134 | basx131 toSci "0.000E-2" -> '0.00000'\r | |
135 | basx132 toSci "0.000E-3" -> '0.000000'\r | |
136 | basx133 toSci "0.000E-4" -> '0E-7'\r | |
137 | basx134 toSci "0.00E-2" -> '0.0000'\r | |
138 | basx135 toSci "0.00E-3" -> '0.00000'\r | |
139 | basx136 toSci "0.00E-4" -> '0.000000'\r | |
140 | basx137 toSci "0.00E-5" -> '0E-7'\r | |
141 | basx138 toSci "+0E+9" -> '0E+9'\r | |
142 | basx139 toSci "-0E+9" -> '-0E+9'\r | |
143 | basx140 toSci "1E+9" -> '1E+9'\r | |
144 | basx141 toSci "1e+09" -> '1E+9'\r | |
145 | basx142 toSci "1E+90" -> '1E+90'\r | |
146 | basx143 toSci "+1E+009" -> '1E+9'\r | |
147 | basx144 toSci "0E+9" -> '0E+9'\r | |
148 | basx145 toSci "1E+9" -> '1E+9'\r | |
149 | basx146 toSci "1E+09" -> '1E+9'\r | |
150 | basx147 toSci "1e+90" -> '1E+90'\r | |
151 | basx148 toSci "1E+009" -> '1E+9'\r | |
152 | basx149 toSci "000E+9" -> '0E+9'\r | |
153 | basx150 toSci "1E9" -> '1E+9'\r | |
154 | basx151 toSci "1e09" -> '1E+9'\r | |
155 | basx152 toSci "1E90" -> '1E+90'\r | |
156 | basx153 toSci "1E009" -> '1E+9'\r | |
157 | basx154 toSci "0E9" -> '0E+9'\r | |
158 | basx155 toSci "0.000e+0" -> '0.000'\r | |
159 | basx156 toSci "0.000E-1" -> '0.0000'\r | |
160 | basx157 toSci "4E+9" -> '4E+9'\r | |
161 | basx158 toSci "44E+9" -> '4.4E+10'\r | |
162 | basx159 toSci "0.73e-7" -> '7.3E-8'\r | |
163 | basx160 toSci "00E+9" -> '0E+9'\r | |
164 | basx161 toSci "00E-9" -> '0E-9'\r | |
165 | basx162 toSci "10E+9" -> '1.0E+10'\r | |
166 | basx163 toSci "10E+09" -> '1.0E+10'\r | |
167 | basx164 toSci "10e+90" -> '1.0E+91'\r | |
168 | basx165 toSci "10E+009" -> '1.0E+10'\r | |
169 | basx166 toSci "100e+9" -> '1.00E+11'\r | |
170 | basx167 toSci "100e+09" -> '1.00E+11'\r | |
171 | basx168 toSci "100E+90" -> '1.00E+92'\r | |
172 | basx169 toSci "100e+009" -> '1.00E+11'\r | |
173 | \r | |
174 | basx170 toSci "1.265" -> '1.265'\r | |
175 | basx171 toSci "1.265E-20" -> '1.265E-20'\r | |
176 | basx172 toSci "1.265E-8" -> '1.265E-8'\r | |
177 | basx173 toSci "1.265E-4" -> '0.0001265'\r | |
178 | basx174 toSci "1.265E-3" -> '0.001265'\r | |
179 | basx175 toSci "1.265E-2" -> '0.01265'\r | |
180 | basx176 toSci "1.265E-1" -> '0.1265'\r | |
181 | basx177 toSci "1.265E-0" -> '1.265'\r | |
182 | basx178 toSci "1.265E+1" -> '12.65'\r | |
183 | basx179 toSci "1.265E+2" -> '126.5'\r | |
184 | basx180 toSci "1.265E+3" -> '1265'\r | |
185 | basx181 toSci "1.265E+4" -> '1.265E+4'\r | |
186 | basx182 toSci "1.265E+8" -> '1.265E+8'\r | |
187 | basx183 toSci "1.265E+20" -> '1.265E+20'\r | |
188 | \r | |
189 | basx190 toSci "12.65" -> '12.65'\r | |
190 | basx191 toSci "12.65E-20" -> '1.265E-19'\r | |
191 | basx192 toSci "12.65E-8" -> '1.265E-7'\r | |
192 | basx193 toSci "12.65E-4" -> '0.001265'\r | |
193 | basx194 toSci "12.65E-3" -> '0.01265'\r | |
194 | basx195 toSci "12.65E-2" -> '0.1265'\r | |
195 | basx196 toSci "12.65E-1" -> '1.265'\r | |
196 | basx197 toSci "12.65E-0" -> '12.65'\r | |
197 | basx198 toSci "12.65E+1" -> '126.5'\r | |
198 | basx199 toSci "12.65E+2" -> '1265'\r | |
199 | basx200 toSci "12.65E+3" -> '1.265E+4'\r | |
200 | basx201 toSci "12.65E+4" -> '1.265E+5'\r | |
201 | basx202 toSci "12.65E+8" -> '1.265E+9'\r | |
202 | basx203 toSci "12.65E+20" -> '1.265E+21'\r | |
203 | \r | |
204 | basx210 toSci "126.5" -> '126.5'\r | |
205 | basx211 toSci "126.5E-20" -> '1.265E-18'\r | |
206 | basx212 toSci "126.5E-8" -> '0.000001265'\r | |
207 | basx213 toSci "126.5E-4" -> '0.01265'\r | |
208 | basx214 toSci "126.5E-3" -> '0.1265'\r | |
209 | basx215 toSci "126.5E-2" -> '1.265'\r | |
210 | basx216 toSci "126.5E-1" -> '12.65'\r | |
211 | basx217 toSci "126.5E-0" -> '126.5'\r | |
212 | basx218 toSci "126.5E+1" -> '1265'\r | |
213 | basx219 toSci "126.5E+2" -> '1.265E+4'\r | |
214 | basx220 toSci "126.5E+3" -> '1.265E+5'\r | |
215 | basx221 toSci "126.5E+4" -> '1.265E+6'\r | |
216 | basx222 toSci "126.5E+8" -> '1.265E+10'\r | |
217 | basx223 toSci "126.5E+20" -> '1.265E+22'\r | |
218 | \r | |
219 | basx230 toSci "1265" -> '1265'\r | |
220 | basx231 toSci "1265E-20" -> '1.265E-17'\r | |
221 | basx232 toSci "1265E-8" -> '0.00001265'\r | |
222 | basx233 toSci "1265E-4" -> '0.1265'\r | |
223 | basx234 toSci "1265E-3" -> '1.265'\r | |
224 | basx235 toSci "1265E-2" -> '12.65'\r | |
225 | basx236 toSci "1265E-1" -> '126.5'\r | |
226 | basx237 toSci "1265E-0" -> '1265'\r | |
227 | basx238 toSci "1265E+1" -> '1.265E+4'\r | |
228 | basx239 toSci "1265E+2" -> '1.265E+5'\r | |
229 | basx240 toSci "1265E+3" -> '1.265E+6'\r | |
230 | basx241 toSci "1265E+4" -> '1.265E+7'\r | |
231 | basx242 toSci "1265E+8" -> '1.265E+11'\r | |
232 | basx243 toSci "1265E+20" -> '1.265E+23'\r | |
233 | \r | |
234 | basx250 toSci "0.1265" -> '0.1265'\r | |
235 | basx251 toSci "0.1265E-20" -> '1.265E-21'\r | |
236 | basx252 toSci "0.1265E-8" -> '1.265E-9'\r | |
237 | basx253 toSci "0.1265E-4" -> '0.00001265'\r | |
238 | basx254 toSci "0.1265E-3" -> '0.0001265'\r | |
239 | basx255 toSci "0.1265E-2" -> '0.001265'\r | |
240 | basx256 toSci "0.1265E-1" -> '0.01265'\r | |
241 | basx257 toSci "0.1265E-0" -> '0.1265'\r | |
242 | basx258 toSci "0.1265E+1" -> '1.265'\r | |
243 | basx259 toSci "0.1265E+2" -> '12.65'\r | |
244 | basx260 toSci "0.1265E+3" -> '126.5'\r | |
245 | basx261 toSci "0.1265E+4" -> '1265'\r | |
246 | basx262 toSci "0.1265E+8" -> '1.265E+7'\r | |
247 | basx263 toSci "0.1265E+20" -> '1.265E+19'\r | |
248 | \r | |
249 | -- some more negative zeros [systematic tests below]\r | |
250 | basx290 toSci "-0.000E-1" -> '-0.0000'\r | |
251 | basx291 toSci "-0.000E-2" -> '-0.00000'\r | |
252 | basx292 toSci "-0.000E-3" -> '-0.000000'\r | |
253 | basx293 toSci "-0.000E-4" -> '-0E-7'\r | |
254 | basx294 toSci "-0.00E-2" -> '-0.0000'\r | |
255 | basx295 toSci "-0.00E-3" -> '-0.00000'\r | |
256 | basx296 toSci "-0.0E-2" -> '-0.000'\r | |
257 | basx297 toSci "-0.0E-3" -> '-0.0000'\r | |
258 | basx298 toSci "-0E-2" -> '-0.00'\r | |
259 | basx299 toSci "-0E-3" -> '-0.000'\r | |
260 | \r | |
261 | -- Engineering notation tests\r | |
262 | basx301 toSci 10e12 -> 1.0E+13\r | |
263 | basx302 toEng 10e12 -> 10E+12\r | |
264 | basx303 toSci 10e11 -> 1.0E+12\r | |
265 | basx304 toEng 10e11 -> 1.0E+12\r | |
266 | basx305 toSci 10e10 -> 1.0E+11\r | |
267 | basx306 toEng 10e10 -> 100E+9\r | |
268 | basx307 toSci 10e9 -> 1.0E+10\r | |
269 | basx308 toEng 10e9 -> 10E+9\r | |
270 | basx309 toSci 10e8 -> 1.0E+9\r | |
271 | basx310 toEng 10e8 -> 1.0E+9\r | |
272 | basx311 toSci 10e7 -> 1.0E+8\r | |
273 | basx312 toEng 10e7 -> 100E+6\r | |
274 | basx313 toSci 10e6 -> 1.0E+7\r | |
275 | basx314 toEng 10e6 -> 10E+6\r | |
276 | basx315 toSci 10e5 -> 1.0E+6\r | |
277 | basx316 toEng 10e5 -> 1.0E+6\r | |
278 | basx317 toSci 10e4 -> 1.0E+5\r | |
279 | basx318 toEng 10e4 -> 100E+3\r | |
280 | basx319 toSci 10e3 -> 1.0E+4\r | |
281 | basx320 toEng 10e3 -> 10E+3\r | |
282 | basx321 toSci 10e2 -> 1.0E+3\r | |
283 | basx322 toEng 10e2 -> 1.0E+3\r | |
284 | basx323 toSci 10e1 -> 1.0E+2\r | |
285 | basx324 toEng 10e1 -> 100\r | |
286 | basx325 toSci 10e0 -> 10\r | |
287 | basx326 toEng 10e0 -> 10\r | |
288 | basx327 toSci 10e-1 -> 1.0\r | |
289 | basx328 toEng 10e-1 -> 1.0\r | |
290 | basx329 toSci 10e-2 -> 0.10\r | |
291 | basx330 toEng 10e-2 -> 0.10\r | |
292 | basx331 toSci 10e-3 -> 0.010\r | |
293 | basx332 toEng 10e-3 -> 0.010\r | |
294 | basx333 toSci 10e-4 -> 0.0010\r | |
295 | basx334 toEng 10e-4 -> 0.0010\r | |
296 | basx335 toSci 10e-5 -> 0.00010\r | |
297 | basx336 toEng 10e-5 -> 0.00010\r | |
298 | basx337 toSci 10e-6 -> 0.000010\r | |
299 | basx338 toEng 10e-6 -> 0.000010\r | |
300 | basx339 toSci 10e-7 -> 0.0000010\r | |
301 | basx340 toEng 10e-7 -> 0.0000010\r | |
302 | basx341 toSci 10e-8 -> 1.0E-7\r | |
303 | basx342 toEng 10e-8 -> 100E-9\r | |
304 | basx343 toSci 10e-9 -> 1.0E-8\r | |
305 | basx344 toEng 10e-9 -> 10E-9\r | |
306 | basx345 toSci 10e-10 -> 1.0E-9\r | |
307 | basx346 toEng 10e-10 -> 1.0E-9\r | |
308 | basx347 toSci 10e-11 -> 1.0E-10\r | |
309 | basx348 toEng 10e-11 -> 100E-12\r | |
310 | basx349 toSci 10e-12 -> 1.0E-11\r | |
311 | basx350 toEng 10e-12 -> 10E-12\r | |
312 | basx351 toSci 10e-13 -> 1.0E-12\r | |
313 | basx352 toEng 10e-13 -> 1.0E-12\r | |
314 | \r | |
315 | basx361 toSci 7E12 -> 7E+12\r | |
316 | basx362 toEng 7E12 -> 7E+12\r | |
317 | basx363 toSci 7E11 -> 7E+11\r | |
318 | basx364 toEng 7E11 -> 700E+9\r | |
319 | basx365 toSci 7E10 -> 7E+10\r | |
320 | basx366 toEng 7E10 -> 70E+9\r | |
321 | basx367 toSci 7E9 -> 7E+9\r | |
322 | basx368 toEng 7E9 -> 7E+9\r | |
323 | basx369 toSci 7E8 -> 7E+8\r | |
324 | basx370 toEng 7E8 -> 700E+6\r | |
325 | basx371 toSci 7E7 -> 7E+7\r | |
326 | basx372 toEng 7E7 -> 70E+6\r | |
327 | basx373 toSci 7E6 -> 7E+6\r | |
328 | basx374 toEng 7E6 -> 7E+6\r | |
329 | basx375 toSci 7E5 -> 7E+5\r | |
330 | basx376 toEng 7E5 -> 700E+3\r | |
331 | basx377 toSci 7E4 -> 7E+4\r | |
332 | basx378 toEng 7E4 -> 70E+3\r | |
333 | basx379 toSci 7E3 -> 7E+3\r | |
334 | basx380 toEng 7E3 -> 7E+3\r | |
335 | basx381 toSci 7E2 -> 7E+2\r | |
336 | basx382 toEng 7E2 -> 700\r | |
337 | basx383 toSci 7E1 -> 7E+1\r | |
338 | basx384 toEng 7E1 -> 70\r | |
339 | basx385 toSci 7E0 -> 7\r | |
340 | basx386 toEng 7E0 -> 7\r | |
341 | basx387 toSci 7E-1 -> 0.7\r | |
342 | basx388 toEng 7E-1 -> 0.7\r | |
343 | basx389 toSci 7E-2 -> 0.07\r | |
344 | basx390 toEng 7E-2 -> 0.07\r | |
345 | basx391 toSci 7E-3 -> 0.007\r | |
346 | basx392 toEng 7E-3 -> 0.007\r | |
347 | basx393 toSci 7E-4 -> 0.0007\r | |
348 | basx394 toEng 7E-4 -> 0.0007\r | |
349 | basx395 toSci 7E-5 -> 0.00007\r | |
350 | basx396 toEng 7E-5 -> 0.00007\r | |
351 | basx397 toSci 7E-6 -> 0.000007\r | |
352 | basx398 toEng 7E-6 -> 0.000007\r | |
353 | basx399 toSci 7E-7 -> 7E-7\r | |
354 | basx400 toEng 7E-7 -> 700E-9\r | |
355 | basx401 toSci 7E-8 -> 7E-8\r | |
356 | basx402 toEng 7E-8 -> 70E-9\r | |
357 | basx403 toSci 7E-9 -> 7E-9\r | |
358 | basx404 toEng 7E-9 -> 7E-9\r | |
359 | basx405 toSci 7E-10 -> 7E-10\r | |
360 | basx406 toEng 7E-10 -> 700E-12\r | |
361 | basx407 toSci 7E-11 -> 7E-11\r | |
362 | basx408 toEng 7E-11 -> 70E-12\r | |
363 | basx409 toSci 7E-12 -> 7E-12\r | |
364 | basx410 toEng 7E-12 -> 7E-12\r | |
365 | basx411 toSci 7E-13 -> 7E-13\r | |
366 | basx412 toEng 7E-13 -> 700E-15\r | |
367 | \r | |
368 | -- Exacts remain exact up to precision ..\r | |
369 | precision: 9\r | |
370 | basx420 toSci 100 -> 100\r | |
371 | basx421 toEng 100 -> 100\r | |
372 | basx422 toSci 1000 -> 1000\r | |
373 | basx423 toEng 1000 -> 1000\r | |
374 | basx424 toSci 999.9 -> 999.9\r | |
375 | basx425 toEng 999.9 -> 999.9\r | |
376 | basx426 toSci 1000.0 -> 1000.0\r | |
377 | basx427 toEng 1000.0 -> 1000.0\r | |
378 | basx428 toSci 1000.1 -> 1000.1\r | |
379 | basx429 toEng 1000.1 -> 1000.1\r | |
380 | basx430 toSci 10000 -> 10000\r | |
381 | basx431 toEng 10000 -> 10000\r | |
382 | basx432 toSci 100000 -> 100000\r | |
383 | basx433 toEng 100000 -> 100000\r | |
384 | basx434 toSci 1000000 -> 1000000\r | |
385 | basx435 toEng 1000000 -> 1000000\r | |
386 | basx436 toSci 10000000 -> 10000000\r | |
387 | basx437 toEng 10000000 -> 10000000\r | |
388 | basx438 toSci 100000000 -> 100000000\r | |
389 | basx439 toEng 100000000 -> 100000000\r | |
390 | basx440 toSci 1000000000 -> 1.00000000E+9 Rounded\r | |
391 | basx441 toEng 1000000000 -> 1.00000000E+9 Rounded\r | |
392 | basx442 toSci 1000000000 -> 1.00000000E+9 Rounded\r | |
393 | basx443 toEng 1000000000 -> 1.00000000E+9 Rounded\r | |
394 | basx444 toSci 1000000003 -> 1.00000000E+9 Rounded Inexact\r | |
395 | basx445 toEng 1000000003 -> 1.00000000E+9 Rounded Inexact\r | |
396 | basx446 toSci 1000000005 -> 1.00000001E+9 Rounded Inexact\r | |
397 | basx447 toEng 1000000005 -> 1.00000001E+9 Rounded Inexact\r | |
398 | basx448 toSci 10000000050 -> 1.00000001E+10 Rounded Inexact\r | |
399 | basx449 toEng 10000000050 -> 10.0000001E+9 Rounded Inexact\r | |
400 | basx450 toSci 1000000009 -> 1.00000001E+9 Rounded Inexact\r | |
401 | basx451 toEng 1000000009 -> 1.00000001E+9 Rounded Inexact\r | |
402 | basx452 toSci 10000000000 -> 1.00000000E+10 Rounded\r | |
403 | basx453 toEng 10000000000 -> 10.0000000E+9 Rounded\r | |
404 | basx454 toSci 10000000003 -> 1.00000000E+10 Rounded Inexact\r | |
405 | basx455 toEng 10000000003 -> 10.0000000E+9 Rounded Inexact\r | |
406 | basx456 toSci 10000000005 -> 1.00000000E+10 Rounded Inexact\r | |
407 | basx457 toEng 10000000005 -> 10.0000000E+9 Rounded Inexact\r | |
408 | basx458 toSci 10000000009 -> 1.00000000E+10 Rounded Inexact\r | |
409 | basx459 toEng 10000000009 -> 10.0000000E+9 Rounded Inexact\r | |
410 | basx460 toSci 100000000000 -> 1.00000000E+11 Rounded\r | |
411 | basx461 toEng 100000000000 -> 100.000000E+9 Rounded\r | |
412 | basx462 toSci 100000000300 -> 1.00000000E+11 Rounded Inexact\r | |
413 | basx463 toEng 100000000300 -> 100.000000E+9 Rounded Inexact\r | |
414 | basx464 toSci 100000000500 -> 1.00000001E+11 Rounded Inexact\r | |
415 | basx465 toEng 100000000500 -> 100.000001E+9 Rounded Inexact\r | |
416 | basx466 toSci 100000000900 -> 1.00000001E+11 Rounded Inexact\r | |
417 | basx467 toEng 100000000900 -> 100.000001E+9 Rounded Inexact\r | |
418 | basx468 toSci 1000000000000 -> 1.00000000E+12 Rounded\r | |
419 | basx469 toEng 1000000000000 -> 1.00000000E+12 Rounded\r | |
420 | basx470 toSci 1000000003000 -> 1.00000000E+12 Rounded Inexact\r | |
421 | basx471 toEng 1000000003000 -> 1.00000000E+12 Rounded Inexact\r | |
422 | basx472 toSci 1000000005000 -> 1.00000001E+12 Rounded Inexact\r | |
423 | basx473 toEng 1000000005000 -> 1.00000001E+12 Rounded Inexact\r | |
424 | basx474 toSci 1000000009000 -> 1.00000001E+12 Rounded Inexact\r | |
425 | basx475 toEng 1000000009000 -> 1.00000001E+12 Rounded Inexact\r | |
426 | \r | |
427 | -- all-nines rounding\r | |
428 | precision: 9\r | |
429 | rounding: half_up\r | |
430 | basx270 toSci 999999999 -> 999999999\r | |
431 | basx271 toSci 9999999990 -> 9.99999999E+9 Rounded\r | |
432 | basx272 toSci 9999999991 -> 9.99999999E+9 Rounded Inexact\r | |
433 | basx273 toSci 9999999992 -> 9.99999999E+9 Rounded Inexact\r | |
434 | basx274 toSci 9999999993 -> 9.99999999E+9 Rounded Inexact\r | |
435 | basx275 toSci 9999999994 -> 9.99999999E+9 Rounded Inexact\r | |
436 | basx276 toSci 9999999995 -> 1.00000000E+10 Rounded Inexact\r | |
437 | basx277 toSci 9999999996 -> 1.00000000E+10 Rounded Inexact\r | |
438 | basx278 toSci 9999999997 -> 1.00000000E+10 Rounded Inexact\r | |
439 | basx279 toSci 9999999998 -> 1.00000000E+10 Rounded Inexact\r | |
440 | basx280 toSci 9999999999 -> 1.00000000E+10 Rounded Inexact\r | |
441 | basx281 toSci 9999999999999999 -> 1.00000000E+16 Rounded Inexact\r | |
442 | \r | |
443 | -- check rounding modes heeded\r | |
444 | precision: 5\r | |
445 | rounding: ceiling\r | |
446 | bsrx401 toSci 1.23450 -> 1.2345 Rounded\r | |
447 | bsrx402 toSci 1.234549 -> 1.2346 Rounded Inexact\r | |
448 | bsrx403 toSci 1.234550 -> 1.2346 Rounded Inexact\r | |
449 | bsrx404 toSci 1.234551 -> 1.2346 Rounded Inexact\r | |
450 | rounding: up\r | |
451 | bsrx405 toSci 1.23450 -> 1.2345 Rounded\r | |
452 | bsrx406 toSci 1.234549 -> 1.2346 Rounded Inexact\r | |
453 | bsrx407 toSci 1.234550 -> 1.2346 Rounded Inexact\r | |
454 | bsrx408 toSci 1.234551 -> 1.2346 Rounded Inexact\r | |
455 | rounding: floor\r | |
456 | bsrx410 toSci 1.23450 -> 1.2345 Rounded\r | |
457 | bsrx411 toSci 1.234549 -> 1.2345 Rounded Inexact\r | |
458 | bsrx412 toSci 1.234550 -> 1.2345 Rounded Inexact\r | |
459 | bsrx413 toSci 1.234551 -> 1.2345 Rounded Inexact\r | |
460 | rounding: half_down\r | |
461 | bsrx415 toSci 1.23450 -> 1.2345 Rounded\r | |
462 | bsrx416 toSci 1.234549 -> 1.2345 Rounded Inexact\r | |
463 | bsrx417 toSci 1.234550 -> 1.2345 Rounded Inexact\r | |
464 | bsrx418 toSci 1.234650 -> 1.2346 Rounded Inexact\r | |
465 | bsrx419 toSci 1.234551 -> 1.2346 Rounded Inexact\r | |
466 | rounding: half_even\r | |
467 | bsrx421 toSci 1.23450 -> 1.2345 Rounded\r | |
468 | bsrx422 toSci 1.234549 -> 1.2345 Rounded Inexact\r | |
469 | bsrx423 toSci 1.234550 -> 1.2346 Rounded Inexact\r | |
470 | bsrx424 toSci 1.234650 -> 1.2346 Rounded Inexact\r | |
471 | bsrx425 toSci 1.234551 -> 1.2346 Rounded Inexact\r | |
472 | rounding: down\r | |
473 | bsrx426 toSci 1.23450 -> 1.2345 Rounded\r | |
474 | bsrx427 toSci 1.234549 -> 1.2345 Rounded Inexact\r | |
475 | bsrx428 toSci 1.234550 -> 1.2345 Rounded Inexact\r | |
476 | bsrx429 toSci 1.234551 -> 1.2345 Rounded Inexact\r | |
477 | rounding: half_up\r | |
478 | bsrx431 toSci 1.23450 -> 1.2345 Rounded\r | |
479 | bsrx432 toSci 1.234549 -> 1.2345 Rounded Inexact\r | |
480 | bsrx433 toSci 1.234550 -> 1.2346 Rounded Inexact\r | |
481 | bsrx434 toSci 1.234650 -> 1.2347 Rounded Inexact\r | |
482 | bsrx435 toSci 1.234551 -> 1.2346 Rounded Inexact\r | |
483 | -- negatives\r | |
484 | rounding: ceiling\r | |
485 | bsrx501 toSci -1.23450 -> -1.2345 Rounded\r | |
486 | bsrx502 toSci -1.234549 -> -1.2345 Rounded Inexact\r | |
487 | bsrx503 toSci -1.234550 -> -1.2345 Rounded Inexact\r | |
488 | bsrx504 toSci -1.234551 -> -1.2345 Rounded Inexact\r | |
489 | rounding: up\r | |
490 | bsrx505 toSci -1.23450 -> -1.2345 Rounded\r | |
491 | bsrx506 toSci -1.234549 -> -1.2346 Rounded Inexact\r | |
492 | bsrx507 toSci -1.234550 -> -1.2346 Rounded Inexact\r | |
493 | bsrx508 toSci -1.234551 -> -1.2346 Rounded Inexact\r | |
494 | rounding: floor\r | |
495 | bsrx510 toSci -1.23450 -> -1.2345 Rounded\r | |
496 | bsrx511 toSci -1.234549 -> -1.2346 Rounded Inexact\r | |
497 | bsrx512 toSci -1.234550 -> -1.2346 Rounded Inexact\r | |
498 | bsrx513 toSci -1.234551 -> -1.2346 Rounded Inexact\r | |
499 | rounding: half_down\r | |
500 | bsrx515 toSci -1.23450 -> -1.2345 Rounded\r | |
501 | bsrx516 toSci -1.234549 -> -1.2345 Rounded Inexact\r | |
502 | bsrx517 toSci -1.234550 -> -1.2345 Rounded Inexact\r | |
503 | bsrx518 toSci -1.234650 -> -1.2346 Rounded Inexact\r | |
504 | bsrx519 toSci -1.234551 -> -1.2346 Rounded Inexact\r | |
505 | rounding: half_even\r | |
506 | bsrx521 toSci -1.23450 -> -1.2345 Rounded\r | |
507 | bsrx522 toSci -1.234549 -> -1.2345 Rounded Inexact\r | |
508 | bsrx523 toSci -1.234550 -> -1.2346 Rounded Inexact\r | |
509 | bsrx524 toSci -1.234650 -> -1.2346 Rounded Inexact\r | |
510 | bsrx525 toSci -1.234551 -> -1.2346 Rounded Inexact\r | |
511 | rounding: down\r | |
512 | bsrx526 toSci -1.23450 -> -1.2345 Rounded\r | |
513 | bsrx527 toSci -1.234549 -> -1.2345 Rounded Inexact\r | |
514 | bsrx528 toSci -1.234550 -> -1.2345 Rounded Inexact\r | |
515 | bsrx529 toSci -1.234551 -> -1.2345 Rounded Inexact\r | |
516 | rounding: half_up\r | |
517 | bsrx531 toSci -1.23450 -> -1.2345 Rounded\r | |
518 | bsrx532 toSci -1.234549 -> -1.2345 Rounded Inexact\r | |
519 | bsrx533 toSci -1.234550 -> -1.2346 Rounded Inexact\r | |
520 | bsrx534 toSci -1.234650 -> -1.2347 Rounded Inexact\r | |
521 | bsrx535 toSci -1.234551 -> -1.2346 Rounded Inexact\r | |
522 | \r | |
523 | -- a few larger exponents\r | |
524 | maxExponent: 999999999\r | |
525 | minExponent: -999999999\r | |
526 | basx480 toSci "0.09e999" -> '9E+997'\r | |
527 | basx481 toSci "0.9e999" -> '9E+998'\r | |
528 | basx482 toSci "9e999" -> '9E+999'\r | |
529 | basx483 toSci "9.9e999" -> '9.9E+999'\r | |
530 | basx484 toSci "9.99e999" -> '9.99E+999'\r | |
531 | basx485 toSci "9.99e-999" -> '9.99E-999'\r | |
532 | basx486 toSci "9.9e-999" -> '9.9E-999'\r | |
533 | basx487 toSci "9e-999" -> '9E-999'\r | |
534 | basx489 toSci "99e-999" -> '9.9E-998'\r | |
535 | basx490 toSci "999e-999" -> '9.99E-997'\r | |
536 | basx491 toSci '0.9e-998' -> '9E-999'\r | |
537 | basx492 toSci '0.09e-997' -> '9E-999'\r | |
538 | basx493 toSci '0.1e1000' -> '1E+999'\r | |
539 | basx494 toSci '10e-1000' -> '1.0E-999'\r | |
540 | \r | |
541 | rounding: half_up\r | |
542 | precision: 9\r | |
543 | \r | |
544 | -- The 'baddies' tests from DiagBigDecimal, plus some new ones\r | |
545 | basx500 toSci '1..2' -> NaN Conversion_syntax\r | |
546 | basx501 toSci '.' -> NaN Conversion_syntax\r | |
547 | basx502 toSci '..' -> NaN Conversion_syntax\r | |
548 | basx503 toSci '++1' -> NaN Conversion_syntax\r | |
549 | basx504 toSci '--1' -> NaN Conversion_syntax\r | |
550 | basx505 toSci '-+1' -> NaN Conversion_syntax\r | |
551 | basx506 toSci '+-1' -> NaN Conversion_syntax\r | |
552 | basx507 toSci '12e' -> NaN Conversion_syntax\r | |
553 | basx508 toSci '12e++' -> NaN Conversion_syntax\r | |
554 | basx509 toSci '12f4' -> NaN Conversion_syntax\r | |
555 | basx510 toSci ' +1' -> NaN Conversion_syntax\r | |
556 | basx511 toSci '+ 1' -> NaN Conversion_syntax\r | |
557 | basx512 toSci '12 ' -> NaN Conversion_syntax\r | |
558 | basx513 toSci ' + 1' -> NaN Conversion_syntax\r | |
559 | basx514 toSci ' - 1 ' -> NaN Conversion_syntax\r | |
560 | basx515 toSci 'x' -> NaN Conversion_syntax\r | |
561 | basx516 toSci '-1-' -> NaN Conversion_syntax\r | |
562 | basx517 toSci '12-' -> NaN Conversion_syntax\r | |
563 | basx518 toSci '3+' -> NaN Conversion_syntax\r | |
564 | basx519 toSci '' -> NaN Conversion_syntax\r | |
565 | basx520 toSci '1e-' -> NaN Conversion_syntax\r | |
566 | basx521 toSci '7e99999a' -> NaN Conversion_syntax\r | |
567 | basx522 toSci '7e123567890x' -> NaN Conversion_syntax\r | |
568 | basx523 toSci '7e12356789012x' -> NaN Conversion_syntax\r | |
569 | basx524 toSci '' -> NaN Conversion_syntax\r | |
570 | basx525 toSci 'e100' -> NaN Conversion_syntax\r | |
571 | basx526 toSci '\u0e5a' -> NaN Conversion_syntax\r | |
572 | basx527 toSci '\u0b65' -> NaN Conversion_syntax\r | |
573 | basx528 toSci '123,65' -> NaN Conversion_syntax\r | |
574 | basx529 toSci '1.34.5' -> NaN Conversion_syntax\r | |
575 | basx530 toSci '.123.5' -> NaN Conversion_syntax\r | |
576 | basx531 toSci '01.35.' -> NaN Conversion_syntax\r | |
577 | basx532 toSci '01.35-' -> NaN Conversion_syntax\r | |
578 | basx533 toSci '0000..' -> NaN Conversion_syntax\r | |
579 | basx534 toSci '.0000.' -> NaN Conversion_syntax\r | |
580 | basx535 toSci '00..00' -> NaN Conversion_syntax\r | |
581 | basx536 toSci '111e*123' -> NaN Conversion_syntax\r | |
582 | basx537 toSci '111e123-' -> NaN Conversion_syntax\r | |
583 | basx538 toSci '111e+12+' -> NaN Conversion_syntax\r | |
584 | basx539 toSci '111e1-3-' -> NaN Conversion_syntax\r | |
585 | basx540 toSci '111e1*23' -> NaN Conversion_syntax\r | |
586 | basx541 toSci '111e1e+3' -> NaN Conversion_syntax\r | |
587 | basx542 toSci '1e1.0' -> NaN Conversion_syntax\r | |
588 | basx543 toSci '1e123e' -> NaN Conversion_syntax\r | |
589 | basx544 toSci 'ten' -> NaN Conversion_syntax\r | |
590 | basx545 toSci 'ONE' -> NaN Conversion_syntax\r | |
591 | basx546 toSci '1e.1' -> NaN Conversion_syntax\r | |
592 | basx547 toSci '1e1.' -> NaN Conversion_syntax\r | |
593 | basx548 toSci '1ee' -> NaN Conversion_syntax\r | |
594 | basx549 toSci 'e+1' -> NaN Conversion_syntax\r | |
595 | basx550 toSci '1.23.4' -> NaN Conversion_syntax\r | |
596 | basx551 toSci '1.2.1' -> NaN Conversion_syntax\r | |
597 | basx552 toSci '1E+1.2' -> NaN Conversion_syntax\r | |
598 | basx553 toSci '1E+1.2.3' -> NaN Conversion_syntax\r | |
599 | basx554 toSci '1E++1' -> NaN Conversion_syntax\r | |
600 | basx555 toSci '1E--1' -> NaN Conversion_syntax\r | |
601 | basx556 toSci '1E+-1' -> NaN Conversion_syntax\r | |
602 | basx557 toSci '1E-+1' -> NaN Conversion_syntax\r | |
603 | basx558 toSci '1E''1' -> NaN Conversion_syntax\r | |
604 | basx559 toSci "1E""1" -> NaN Conversion_syntax\r | |
605 | basx560 toSci "1E""""" -> NaN Conversion_syntax\r | |
606 | -- Near-specials\r | |
607 | basx561 toSci "qNaN" -> NaN Conversion_syntax\r | |
608 | basx562 toSci "NaNq" -> NaN Conversion_syntax\r | |
609 | basx563 toSci "NaNs" -> NaN Conversion_syntax\r | |
610 | basx564 toSci "Infi" -> NaN Conversion_syntax\r | |
611 | basx565 toSci "Infin" -> NaN Conversion_syntax\r | |
612 | basx566 toSci "Infini" -> NaN Conversion_syntax\r | |
613 | basx567 toSci "Infinit" -> NaN Conversion_syntax\r | |
614 | basx568 toSci "-Infinit" -> NaN Conversion_syntax\r | |
615 | basx569 toSci "0Inf" -> NaN Conversion_syntax\r | |
616 | basx570 toSci "9Inf" -> NaN Conversion_syntax\r | |
617 | basx571 toSci "-0Inf" -> NaN Conversion_syntax\r | |
618 | basx572 toSci "-9Inf" -> NaN Conversion_syntax\r | |
619 | basx573 toSci "-sNa" -> NaN Conversion_syntax\r | |
620 | basx574 toSci "xNaN" -> NaN Conversion_syntax\r | |
621 | basx575 toSci "0sNaN" -> NaN Conversion_syntax\r | |
622 | \r | |
623 | -- some baddies with dots and Es and dots and specials\r | |
624 | basx576 toSci 'e+1' -> NaN Conversion_syntax\r | |
625 | basx577 toSci '.e+1' -> NaN Conversion_syntax\r | |
626 | basx578 toSci '+.e+1' -> NaN Conversion_syntax\r | |
627 | basx579 toSci '-.e+' -> NaN Conversion_syntax\r | |
628 | basx580 toSci '-.e' -> NaN Conversion_syntax\r | |
629 | basx581 toSci 'E+1' -> NaN Conversion_syntax\r | |
630 | basx582 toSci '.E+1' -> NaN Conversion_syntax\r | |
631 | basx583 toSci '+.E+1' -> NaN Conversion_syntax\r | |
632 | basx584 toSci '-.E+' -> NaN Conversion_syntax\r | |
633 | basx585 toSci '-.E' -> NaN Conversion_syntax\r | |
634 | \r | |
635 | basx586 toSci '.NaN' -> NaN Conversion_syntax\r | |
636 | basx587 toSci '-.NaN' -> NaN Conversion_syntax\r | |
637 | basx588 toSci '+.sNaN' -> NaN Conversion_syntax\r | |
638 | basx589 toSci '+.Inf' -> NaN Conversion_syntax\r | |
639 | basx590 toSci '.Infinity' -> NaN Conversion_syntax\r | |
640 | \r | |
641 | -- Zeros\r | |
642 | basx601 toSci 0.000000000 -> 0E-9\r | |
643 | basx602 toSci 0.00000000 -> 0E-8\r | |
644 | basx603 toSci 0.0000000 -> 0E-7\r | |
645 | basx604 toSci 0.000000 -> 0.000000\r | |
646 | basx605 toSci 0.00000 -> 0.00000\r | |
647 | basx606 toSci 0.0000 -> 0.0000\r | |
648 | basx607 toSci 0.000 -> 0.000\r | |
649 | basx608 toSci 0.00 -> 0.00\r | |
650 | basx609 toSci 0.0 -> 0.0\r | |
651 | basx610 toSci .0 -> 0.0\r | |
652 | basx611 toSci 0. -> 0\r | |
653 | basx612 toSci -.0 -> -0.0\r | |
654 | basx613 toSci -0. -> -0\r | |
655 | basx614 toSci -0.0 -> -0.0\r | |
656 | basx615 toSci -0.00 -> -0.00\r | |
657 | basx616 toSci -0.000 -> -0.000\r | |
658 | basx617 toSci -0.0000 -> -0.0000\r | |
659 | basx618 toSci -0.00000 -> -0.00000\r | |
660 | basx619 toSci -0.000000 -> -0.000000\r | |
661 | basx620 toSci -0.0000000 -> -0E-7\r | |
662 | basx621 toSci -0.00000000 -> -0E-8\r | |
663 | basx622 toSci -0.000000000 -> -0E-9\r | |
664 | \r | |
665 | basx630 toSci 0.00E+0 -> 0.00\r | |
666 | basx631 toSci 0.00E+1 -> 0.0\r | |
667 | basx632 toSci 0.00E+2 -> 0\r | |
668 | basx633 toSci 0.00E+3 -> 0E+1\r | |
669 | basx634 toSci 0.00E+4 -> 0E+2\r | |
670 | basx635 toSci 0.00E+5 -> 0E+3\r | |
671 | basx636 toSci 0.00E+6 -> 0E+4\r | |
672 | basx637 toSci 0.00E+7 -> 0E+5\r | |
673 | basx638 toSci 0.00E+8 -> 0E+6\r | |
674 | basx639 toSci 0.00E+9 -> 0E+7\r | |
675 | \r | |
676 | basx640 toSci 0.0E+0 -> 0.0\r | |
677 | basx641 toSci 0.0E+1 -> 0\r | |
678 | basx642 toSci 0.0E+2 -> 0E+1\r | |
679 | basx643 toSci 0.0E+3 -> 0E+2\r | |
680 | basx644 toSci 0.0E+4 -> 0E+3\r | |
681 | basx645 toSci 0.0E+5 -> 0E+4\r | |
682 | basx646 toSci 0.0E+6 -> 0E+5\r | |
683 | basx647 toSci 0.0E+7 -> 0E+6\r | |
684 | basx648 toSci 0.0E+8 -> 0E+7\r | |
685 | basx649 toSci 0.0E+9 -> 0E+8\r | |
686 | \r | |
687 | basx650 toSci 0E+0 -> 0\r | |
688 | basx651 toSci 0E+1 -> 0E+1\r | |
689 | basx652 toSci 0E+2 -> 0E+2\r | |
690 | basx653 toSci 0E+3 -> 0E+3\r | |
691 | basx654 toSci 0E+4 -> 0E+4\r | |
692 | basx655 toSci 0E+5 -> 0E+5\r | |
693 | basx656 toSci 0E+6 -> 0E+6\r | |
694 | basx657 toSci 0E+7 -> 0E+7\r | |
695 | basx658 toSci 0E+8 -> 0E+8\r | |
696 | basx659 toSci 0E+9 -> 0E+9\r | |
697 | \r | |
698 | basx660 toSci 0.0E-0 -> 0.0\r | |
699 | basx661 toSci 0.0E-1 -> 0.00\r | |
700 | basx662 toSci 0.0E-2 -> 0.000\r | |
701 | basx663 toSci 0.0E-3 -> 0.0000\r | |
702 | basx664 toSci 0.0E-4 -> 0.00000\r | |
703 | basx665 toSci 0.0E-5 -> 0.000000\r | |
704 | basx666 toSci 0.0E-6 -> 0E-7\r | |
705 | basx667 toSci 0.0E-7 -> 0E-8\r | |
706 | basx668 toSci 0.0E-8 -> 0E-9\r | |
707 | basx669 toSci 0.0E-9 -> 0E-10\r | |
708 | \r | |
709 | basx670 toSci 0.00E-0 -> 0.00\r | |
710 | basx671 toSci 0.00E-1 -> 0.000\r | |
711 | basx672 toSci 0.00E-2 -> 0.0000\r | |
712 | basx673 toSci 0.00E-3 -> 0.00000\r | |
713 | basx674 toSci 0.00E-4 -> 0.000000\r | |
714 | basx675 toSci 0.00E-5 -> 0E-7\r | |
715 | basx676 toSci 0.00E-6 -> 0E-8\r | |
716 | basx677 toSci 0.00E-7 -> 0E-9\r | |
717 | basx678 toSci 0.00E-8 -> 0E-10\r | |
718 | basx679 toSci 0.00E-9 -> 0E-11\r | |
719 | \r | |
720 | basx680 toSci 000000. -> 0\r | |
721 | basx681 toSci 00000. -> 0\r | |
722 | basx682 toSci 0000. -> 0\r | |
723 | basx683 toSci 000. -> 0\r | |
724 | basx684 toSci 00. -> 0\r | |
725 | basx685 toSci 0. -> 0\r | |
726 | basx686 toSci +00000. -> 0\r | |
727 | basx687 toSci -00000. -> -0\r | |
728 | basx688 toSci +0. -> 0\r | |
729 | basx689 toSci -0. -> -0\r | |
730 | \r | |
731 | -- Specials\r | |
732 | precision: 4\r | |
733 | basx700 toSci "NaN" -> NaN\r | |
734 | basx701 toSci "nan" -> NaN\r | |
735 | basx702 toSci "nAn" -> NaN\r | |
736 | basx703 toSci "NAN" -> NaN\r | |
737 | basx704 toSci "+NaN" -> NaN\r | |
738 | basx705 toSci "+nan" -> NaN\r | |
739 | basx706 toSci "+nAn" -> NaN\r | |
740 | basx707 toSci "+NAN" -> NaN\r | |
741 | basx708 toSci "-NaN" -> -NaN\r | |
742 | basx709 toSci "-nan" -> -NaN\r | |
743 | basx710 toSci "-nAn" -> -NaN\r | |
744 | basx711 toSci "-NAN" -> -NaN\r | |
745 | basx712 toSci 'NaN0' -> NaN\r | |
746 | basx713 toSci 'NaN1' -> NaN1\r | |
747 | basx714 toSci 'NaN12' -> NaN12\r | |
748 | basx715 toSci 'NaN123' -> NaN123\r | |
749 | basx716 toSci 'NaN1234' -> NaN1234\r | |
750 | basx717 toSci 'NaN01' -> NaN1\r | |
751 | basx718 toSci 'NaN012' -> NaN12\r | |
752 | basx719 toSci 'NaN0123' -> NaN123\r | |
753 | basx720 toSci 'NaN01234' -> NaN1234\r | |
754 | basx721 toSci 'NaN001' -> NaN1\r | |
755 | basx722 toSci 'NaN0012' -> NaN12\r | |
756 | basx723 toSci 'NaN00123' -> NaN123\r | |
757 | basx724 toSci 'NaN001234' -> NaN1234\r | |
758 | basx725 toSci 'NaN12345' -> NaN Conversion_syntax\r | |
759 | basx726 toSci 'NaN123e+1' -> NaN Conversion_syntax\r | |
760 | basx727 toSci 'NaN12.45' -> NaN Conversion_syntax\r | |
761 | basx728 toSci 'NaN-12' -> NaN Conversion_syntax\r | |
762 | basx729 toSci 'NaN+12' -> NaN Conversion_syntax\r | |
763 | \r | |
764 | basx730 toSci "sNaN" -> sNaN\r | |
765 | basx731 toSci "snan" -> sNaN\r | |
766 | basx732 toSci "SnAn" -> sNaN\r | |
767 | basx733 toSci "SNAN" -> sNaN\r | |
768 | basx734 toSci "+sNaN" -> sNaN\r | |
769 | basx735 toSci "+snan" -> sNaN\r | |
770 | basx736 toSci "+SnAn" -> sNaN\r | |
771 | basx737 toSci "+SNAN" -> sNaN\r | |
772 | basx738 toSci "-sNaN" -> -sNaN\r | |
773 | basx739 toSci "-snan" -> -sNaN\r | |
774 | basx740 toSci "-SnAn" -> -sNaN\r | |
775 | basx741 toSci "-SNAN" -> -sNaN\r | |
776 | basx742 toSci 'sNaN0000' -> sNaN\r | |
777 | basx743 toSci 'sNaN7' -> sNaN7\r | |
778 | basx744 toSci 'sNaN007234' -> sNaN7234\r | |
779 | basx745 toSci 'sNaN72345' -> NaN Conversion_syntax\r | |
780 | basx746 toSci 'sNaN72.45' -> NaN Conversion_syntax\r | |
781 | basx747 toSci 'sNaN-72' -> NaN Conversion_syntax\r | |
782 | \r | |
783 | basx748 toSci "Inf" -> Infinity\r | |
784 | basx749 toSci "inf" -> Infinity\r | |
785 | basx750 toSci "iNf" -> Infinity\r | |
786 | basx751 toSci "INF" -> Infinity\r | |
787 | basx752 toSci "+Inf" -> Infinity\r | |
788 | basx753 toSci "+inf" -> Infinity\r | |
789 | basx754 toSci "+iNf" -> Infinity\r | |
790 | basx755 toSci "+INF" -> Infinity\r | |
791 | basx756 toSci "-Inf" -> -Infinity\r | |
792 | basx757 toSci "-inf" -> -Infinity\r | |
793 | basx758 toSci "-iNf" -> -Infinity\r | |
794 | basx759 toSci "-INF" -> -Infinity\r | |
795 | \r | |
796 | basx760 toSci "Infinity" -> Infinity\r | |
797 | basx761 toSci "infinity" -> Infinity\r | |
798 | basx762 toSci "iNfInItY" -> Infinity\r | |
799 | basx763 toSci "INFINITY" -> Infinity\r | |
800 | basx764 toSci "+Infinity" -> Infinity\r | |
801 | basx765 toSci "+infinity" -> Infinity\r | |
802 | basx766 toSci "+iNfInItY" -> Infinity\r | |
803 | basx767 toSci "+INFINITY" -> Infinity\r | |
804 | basx768 toSci "-Infinity" -> -Infinity\r | |
805 | basx769 toSci "-infinity" -> -Infinity\r | |
806 | basx770 toSci "-iNfInItY" -> -Infinity\r | |
807 | basx771 toSci "-INFINITY" -> -Infinity\r | |
808 | \r | |
809 | -- Specials and zeros for toEng\r | |
810 | basx772 toEng "NaN" -> NaN\r | |
811 | basx773 toEng "-Infinity" -> -Infinity\r | |
812 | basx774 toEng "-sNaN" -> -sNaN\r | |
813 | basx775 toEng "-NaN" -> -NaN\r | |
814 | basx776 toEng "+Infinity" -> Infinity\r | |
815 | basx778 toEng "+sNaN" -> sNaN\r | |
816 | basx779 toEng "+NaN" -> NaN\r | |
817 | basx780 toEng "INFINITY" -> Infinity\r | |
818 | basx781 toEng "SNAN" -> sNaN\r | |
819 | basx782 toEng "NAN" -> NaN\r | |
820 | basx783 toEng "infinity" -> Infinity\r | |
821 | basx784 toEng "snan" -> sNaN\r | |
822 | basx785 toEng "nan" -> NaN\r | |
823 | basx786 toEng "InFINITY" -> Infinity\r | |
824 | basx787 toEng "SnAN" -> sNaN\r | |
825 | basx788 toEng "nAN" -> NaN\r | |
826 | basx789 toEng "iNfinity" -> Infinity\r | |
827 | basx790 toEng "sNan" -> sNaN\r | |
828 | basx791 toEng "Nan" -> NaN\r | |
829 | basx792 toEng "Infinity" -> Infinity\r | |
830 | basx793 toEng "sNaN" -> sNaN\r | |
831 | \r | |
832 | -- Zero toEng, etc.\r | |
833 | basx800 toEng 0e+1 -> "0.00E+3" -- doc example\r | |
834 | \r | |
835 | basx801 toEng 0.000000000 -> 0E-9\r | |
836 | basx802 toEng 0.00000000 -> 0.00E-6\r | |
837 | basx803 toEng 0.0000000 -> 0.0E-6\r | |
838 | basx804 toEng 0.000000 -> 0.000000\r | |
839 | basx805 toEng 0.00000 -> 0.00000\r | |
840 | basx806 toEng 0.0000 -> 0.0000\r | |
841 | basx807 toEng 0.000 -> 0.000\r | |
842 | basx808 toEng 0.00 -> 0.00\r | |
843 | basx809 toEng 0.0 -> 0.0\r | |
844 | basx810 toEng .0 -> 0.0\r | |
845 | basx811 toEng 0. -> 0\r | |
846 | basx812 toEng -.0 -> -0.0\r | |
847 | basx813 toEng -0. -> -0\r | |
848 | basx814 toEng -0.0 -> -0.0\r | |
849 | basx815 toEng -0.00 -> -0.00\r | |
850 | basx816 toEng -0.000 -> -0.000\r | |
851 | basx817 toEng -0.0000 -> -0.0000\r | |
852 | basx818 toEng -0.00000 -> -0.00000\r | |
853 | basx819 toEng -0.000000 -> -0.000000\r | |
854 | basx820 toEng -0.0000000 -> -0.0E-6\r | |
855 | basx821 toEng -0.00000000 -> -0.00E-6\r | |
856 | basx822 toEng -0.000000000 -> -0E-9\r | |
857 | \r | |
858 | basx830 toEng 0.00E+0 -> 0.00\r | |
859 | basx831 toEng 0.00E+1 -> 0.0\r | |
860 | basx832 toEng 0.00E+2 -> 0\r | |
861 | basx833 toEng 0.00E+3 -> 0.00E+3\r | |
862 | basx834 toEng 0.00E+4 -> 0.0E+3\r | |
863 | basx835 toEng 0.00E+5 -> 0E+3\r | |
864 | basx836 toEng 0.00E+6 -> 0.00E+6\r | |
865 | basx837 toEng 0.00E+7 -> 0.0E+6\r | |
866 | basx838 toEng 0.00E+8 -> 0E+6\r | |
867 | basx839 toEng 0.00E+9 -> 0.00E+9\r | |
868 | \r | |
869 | basx840 toEng 0.0E+0 -> 0.0\r | |
870 | basx841 toEng 0.0E+1 -> 0\r | |
871 | basx842 toEng 0.0E+2 -> 0.00E+3\r | |
872 | basx843 toEng 0.0E+3 -> 0.0E+3\r | |
873 | basx844 toEng 0.0E+4 -> 0E+3\r | |
874 | basx845 toEng 0.0E+5 -> 0.00E+6\r | |
875 | basx846 toEng 0.0E+6 -> 0.0E+6\r | |
876 | basx847 toEng 0.0E+7 -> 0E+6\r | |
877 | basx848 toEng 0.0E+8 -> 0.00E+9\r | |
878 | basx849 toEng 0.0E+9 -> 0.0E+9\r | |
879 | \r | |
880 | basx850 toEng 0E+0 -> 0\r | |
881 | basx851 toEng 0E+1 -> 0.00E+3\r | |
882 | basx852 toEng 0E+2 -> 0.0E+3\r | |
883 | basx853 toEng 0E+3 -> 0E+3\r | |
884 | basx854 toEng 0E+4 -> 0.00E+6\r | |
885 | basx855 toEng 0E+5 -> 0.0E+6\r | |
886 | basx856 toEng 0E+6 -> 0E+6\r | |
887 | basx857 toEng 0E+7 -> 0.00E+9\r | |
888 | basx858 toEng 0E+8 -> 0.0E+9\r | |
889 | basx859 toEng 0E+9 -> 0E+9\r | |
890 | \r | |
891 | basx860 toEng 0.0E-0 -> 0.0\r | |
892 | basx861 toEng 0.0E-1 -> 0.00\r | |
893 | basx862 toEng 0.0E-2 -> 0.000\r | |
894 | basx863 toEng 0.0E-3 -> 0.0000\r | |
895 | basx864 toEng 0.0E-4 -> 0.00000\r | |
896 | basx865 toEng 0.0E-5 -> 0.000000\r | |
897 | basx866 toEng 0.0E-6 -> 0.0E-6\r | |
898 | basx867 toEng 0.0E-7 -> 0.00E-6\r | |
899 | basx868 toEng 0.0E-8 -> 0E-9\r | |
900 | basx869 toEng 0.0E-9 -> 0.0E-9\r | |
901 | \r | |
902 | basx870 toEng 0.00E-0 -> 0.00\r | |
903 | basx871 toEng 0.00E-1 -> 0.000\r | |
904 | basx872 toEng 0.00E-2 -> 0.0000\r | |
905 | basx873 toEng 0.00E-3 -> 0.00000\r | |
906 | basx874 toEng 0.00E-4 -> 0.000000\r | |
907 | basx875 toEng 0.00E-5 -> 0.0E-6\r | |
908 | basx876 toEng 0.00E-6 -> 0.00E-6\r | |
909 | basx877 toEng 0.00E-7 -> 0E-9\r | |
910 | basx878 toEng 0.00E-8 -> 0.0E-9\r | |
911 | basx879 toEng 0.00E-9 -> 0.00E-9\r | |
912 | \r | |
913 | \r | |
914 | rounding: half_up\r | |
915 | precision: 9\r | |
916 | -- subnormals and overflows\r | |
917 | basx906 toSci '99e999999999' -> Infinity Overflow Inexact Rounded\r | |
918 | basx907 toSci '999e999999999' -> Infinity Overflow Inexact Rounded\r | |
919 | basx908 toSci '0.9e-999999999' -> 9E-1000000000 Subnormal\r | |
920 | basx909 toSci '0.09e-999999999' -> 9E-1000000001 Subnormal\r | |
921 | basx910 toSci '0.1e1000000000' -> 1E+999999999\r | |
922 | basx911 toSci '10e-1000000000' -> 1.0E-999999999\r | |
923 | basx912 toSci '0.9e9999999999' -> Infinity Overflow Inexact Rounded\r | |
924 | basx913 toSci '99e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
925 | basx914 toSci '111e9999999999' -> Infinity Overflow Inexact Rounded\r | |
926 | basx915 toSci '1111e-9999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
927 | basx916 toSci '1111e-99999999999' -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
928 | basx917 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
929 | -- negatives the same\r | |
930 | basx918 toSci '-99e999999999' -> -Infinity Overflow Inexact Rounded\r | |
931 | basx919 toSci '-999e999999999' -> -Infinity Overflow Inexact Rounded\r | |
932 | basx920 toSci '-0.9e-999999999' -> -9E-1000000000 Subnormal\r | |
933 | basx921 toSci '-0.09e-999999999' -> -9E-1000000001 Subnormal\r | |
934 | basx922 toSci '-0.1e1000000000' -> -1E+999999999\r | |
935 | basx923 toSci '-10e-1000000000' -> -1.0E-999999999\r | |
936 | basx924 toSci '-0.9e9999999999' -> -Infinity Overflow Inexact Rounded\r | |
937 | basx925 toSci '-99e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
938 | basx926 toSci '-111e9999999999' -> -Infinity Overflow Inexact Rounded\r | |
939 | basx927 toSci '-1111e-9999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
940 | basx928 toSci '-1111e-99999999999' -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
941 | basx929 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
942 | \r | |
943 | rounding: ceiling\r | |
944 | basx930 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
945 | basx931 toSci '-7e1000000000' -> -9.99999999E+999999999 Overflow Inexact Rounded\r | |
946 | rounding: up\r | |
947 | basx932 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
948 | basx933 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
949 | rounding: down\r | |
950 | basx934 toSci '7e1000000000' -> 9.99999999E+999999999 Overflow Inexact Rounded\r | |
951 | basx935 toSci '-7e1000000000' -> -9.99999999E+999999999 Overflow Inexact Rounded\r | |
952 | rounding: floor\r | |
953 | basx936 toSci '7e1000000000' -> 9.99999999E+999999999 Overflow Inexact Rounded\r | |
954 | basx937 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
955 | \r | |
956 | rounding: half_up\r | |
957 | basx938 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
958 | basx939 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
959 | rounding: half_even\r | |
960 | basx940 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
961 | basx941 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
962 | rounding: half_down\r | |
963 | basx942 toSci '7e1000000000' -> Infinity Overflow Inexact Rounded\r | |
964 | basx943 toSci '-7e1000000000' -> -Infinity Overflow Inexact Rounded\r | |
965 | \r | |
966 | rounding: half_even\r | |
967 | \r | |
968 | \r | |
969 | -- Giga exponent initial tests\r | |
970 | maxExponent: 999999999\r | |
971 | minExponent: -999999999\r | |
972 | \r | |
973 | basx951 toSci '99e999' -> '9.9E+1000'\r | |
974 | basx952 toSci '999e999' -> '9.99E+1001'\r | |
975 | basx953 toSci '0.9e-999' -> '9E-1000'\r | |
976 | basx954 toSci '0.09e-999' -> '9E-1001'\r | |
977 | basx955 toSci '0.1e1001' -> '1E+1000'\r | |
978 | basx956 toSci '10e-1001' -> '1.0E-1000'\r | |
979 | basx957 toSci '0.9e9999' -> '9E+9998'\r | |
980 | basx958 toSci '99e-9999' -> '9.9E-9998'\r | |
981 | basx959 toSci '111e9997' -> '1.11E+9999'\r | |
982 | basx960 toSci '1111e-9999' -> '1.111E-9996'\r | |
983 | basx961 toSci '99e9999' -> '9.9E+10000'\r | |
984 | basx962 toSci '999e9999' -> '9.99E+10001'\r | |
985 | basx963 toSci '0.9e-9999' -> '9E-10000'\r | |
986 | basx964 toSci '0.09e-9999' -> '9E-10001'\r | |
987 | basx965 toSci '0.1e10001' -> '1E+10000'\r | |
988 | basx966 toSci '10e-10001' -> '1.0E-10000'\r | |
989 | basx967 toSci '0.9e99999' -> '9E+99998'\r | |
990 | basx968 toSci '99e-99999' -> '9.9E-99998'\r | |
991 | basx969 toSci '111e99999' -> '1.11E+100001'\r | |
992 | basx970 toSci '1111e-99999' -> '1.111E-99996'\r | |
993 | basx971 toSci "0.09e999999999" -> '9E+999999997'\r | |
994 | basx972 toSci "0.9e999999999" -> '9E+999999998'\r | |
995 | basx973 toSci "9e999999999" -> '9E+999999999'\r | |
996 | basx974 toSci "9.9e999999999" -> '9.9E+999999999'\r | |
997 | basx975 toSci "9.99e999999999" -> '9.99E+999999999'\r | |
998 | basx976 toSci "9.99e-999999999" -> '9.99E-999999999'\r | |
999 | basx977 toSci "9.9e-999999999" -> '9.9E-999999999'\r | |
1000 | basx978 toSci "9e-999999999" -> '9E-999999999'\r | |
1001 | basx979 toSci "99e-999999999" -> '9.9E-999999998'\r | |
1002 | basx980 toSci "999e-999999999" -> '9.99E-999999997'\r | |
1003 | \r | |
1004 | -- Varying exponent maximums\r | |
1005 | precision: 5\r | |
1006 | maxexponent: 0\r | |
1007 | minexponent: 0\r | |
1008 | emax001 toSci -1E+2 -> -Infinity Overflow Inexact Rounded\r | |
1009 | emax002 toSci -100 -> -Infinity Overflow Inexact Rounded\r | |
1010 | emax003 toSci -10 -> -Infinity Overflow Inexact Rounded\r | |
1011 | emax004 toSci -9.9 -> -9.9\r | |
1012 | emax005 toSci -9 -> -9\r | |
1013 | emax006 toSci -1 -> -1\r | |
1014 | emax007 toSci 0 -> 0\r | |
1015 | emax008 toSci 1 -> 1\r | |
1016 | emax009 toSci 9 -> 9\r | |
1017 | emax010 toSci 9.9 -> 9.9\r | |
1018 | emax011 toSci 10 -> Infinity Overflow Inexact Rounded\r | |
1019 | emax012 toSci 100 -> Infinity Overflow Inexact Rounded\r | |
1020 | emax013 toSci 1E+2 -> Infinity Overflow Inexact Rounded\r | |
1021 | emax014 toSci 0.99 -> 0.99 Subnormal\r | |
1022 | emax015 toSci 0.1 -> 0.1 Subnormal\r | |
1023 | emax016 toSci 0.01 -> 0.01 Subnormal\r | |
1024 | emax017 toSci 1E-1 -> 0.1 Subnormal\r | |
1025 | emax018 toSci 1E-2 -> 0.01 Subnormal\r | |
1026 | \r | |
1027 | maxexponent: 1\r | |
1028 | minexponent: -1\r | |
1029 | emax100 toSci -1E+3 -> -Infinity Overflow Inexact Rounded\r | |
1030 | emax101 toSci -1E+2 -> -Infinity Overflow Inexact Rounded\r | |
1031 | emax102 toSci -100 -> -Infinity Overflow Inexact Rounded\r | |
1032 | emax103 toSci -10 -> -10\r | |
1033 | emax104 toSci -9.9 -> -9.9\r | |
1034 | emax105 toSci -9 -> -9\r | |
1035 | emax106 toSci -1 -> -1\r | |
1036 | emax107 toSci 0 -> 0\r | |
1037 | emax108 toSci 1 -> 1\r | |
1038 | emax109 toSci 9 -> 9\r | |
1039 | emax110 toSci 9.9 -> 9.9\r | |
1040 | emax111 toSci 10 -> 10\r | |
1041 | emax112 toSci 100 -> Infinity Overflow Inexact Rounded\r | |
1042 | emax113 toSci 1E+2 -> Infinity Overflow Inexact Rounded\r | |
1043 | emax114 toSci 1E+3 -> Infinity Overflow Inexact Rounded\r | |
1044 | emax115 toSci 0.99 -> 0.99\r | |
1045 | emax116 toSci 0.1 -> 0.1\r | |
1046 | emax117 toSci 0.01 -> 0.01 Subnormal\r | |
1047 | emax118 toSci 1E-1 -> 0.1\r | |
1048 | emax119 toSci 1E-2 -> 0.01 Subnormal\r | |
1049 | emax120 toSci 1E-3 -> 0.001 Subnormal\r | |
1050 | emax121 toSci 1.1E-3 -> 0.0011 Subnormal\r | |
1051 | emax122 toSci 1.11E-3 -> 0.00111 Subnormal\r | |
1052 | emax123 toSci 1.111E-3 -> 0.00111 Subnormal Underflow Inexact Rounded\r | |
1053 | emax124 toSci 1.1111E-3 -> 0.00111 Subnormal Underflow Inexact Rounded\r | |
1054 | emax125 toSci 1.11111E-3 -> 0.00111 Subnormal Underflow Inexact Rounded\r | |
1055 | \r | |
1056 | maxexponent: 2\r | |
1057 | minexponent: -2\r | |
1058 | precision: 9\r | |
1059 | emax200 toSci -1E+3 -> -Infinity Overflow Inexact Rounded\r | |
1060 | emax201 toSci -1E+2 -> -1E+2\r | |
1061 | emax202 toSci -100 -> -100\r | |
1062 | emax203 toSci -10 -> -10\r | |
1063 | emax204 toSci -9.9 -> -9.9\r | |
1064 | emax205 toSci -9 -> -9\r | |
1065 | emax206 toSci -1 -> -1\r | |
1066 | emax207 toSci 0 -> 0\r | |
1067 | emax208 toSci 1 -> 1\r | |
1068 | emax209 toSci 9 -> 9\r | |
1069 | emax210 toSci 9.9 -> 9.9\r | |
1070 | emax211 toSci 10 -> 10\r | |
1071 | emax212 toSci 100 -> 100\r | |
1072 | emax213 toSci 1E+2 -> 1E+2\r | |
1073 | emax214 toSci 1E+3 -> Infinity Overflow Inexact Rounded\r | |
1074 | emax215 toSci 0.99 -> 0.99\r | |
1075 | emax216 toSci 0.1 -> 0.1\r | |
1076 | emax217 toSci 0.01 -> 0.01\r | |
1077 | emax218 toSci 0.001 -> 0.001 Subnormal\r | |
1078 | emax219 toSci 1E-1 -> 0.1\r | |
1079 | emax220 toSci 1E-2 -> 0.01\r | |
1080 | emax221 toSci 1E-3 -> 0.001 Subnormal\r | |
1081 | emax222 toSci 1E-4 -> 0.0001 Subnormal\r | |
1082 | emax223 toSci 1E-5 -> 0.00001 Subnormal\r | |
1083 | emax224 toSci 1E-6 -> 0.000001 Subnormal\r | |
1084 | emax225 toSci 1E-7 -> 1E-7 Subnormal\r | |
1085 | emax226 toSci 1E-8 -> 1E-8 Subnormal\r | |
1086 | emax227 toSci 1E-9 -> 1E-9 Subnormal\r | |
1087 | emax228 toSci 1E-10 -> 1E-10 Subnormal\r | |
1088 | emax229 toSci 1E-11 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped\r | |
1089 | emax230 toSci 1E-12 -> 0E-10 Underflow Subnormal Inexact Rounded Clamped\r | |
1090 | \r | |
1091 | maxexponent: 7\r | |
1092 | minexponent: -7\r | |
1093 | emax231 toSci 1E-8 -> 1E-8 Subnormal\r | |
1094 | emax232 toSci 1E-7 -> 1E-7\r | |
1095 | emax233 toSci 1E-6 -> 0.000001\r | |
1096 | emax234 toSci 1E-5 -> 0.00001\r | |
1097 | emax235 toSci 1E+5 -> 1E+5\r | |
1098 | emax236 toSci 1E+6 -> 1E+6\r | |
1099 | emax237 toSci 1E+7 -> 1E+7\r | |
1100 | emax238 toSci 1E+8 -> Infinity Overflow Inexact Rounded\r | |
1101 | \r | |
1102 | maxexponent: 9\r | |
1103 | minexponent: -9\r | |
1104 | emax240 toSci 1E-21 -> 0E-17 Subnormal Underflow Inexact Rounded Clamped\r | |
1105 | emax241 toSci 1E-10 -> 1E-10 Subnormal\r | |
1106 | emax242 toSci 1E-9 -> 1E-9\r | |
1107 | emax243 toSci 1E-8 -> 1E-8\r | |
1108 | emax244 toSci 1E-7 -> 1E-7\r | |
1109 | emax245 toSci 1E+7 -> 1E+7\r | |
1110 | emax246 toSci 1E+8 -> 1E+8\r | |
1111 | emax247 toSci 1E+9 -> 1E+9\r | |
1112 | emax248 toSci 1E+10 -> Infinity Overflow Inexact Rounded\r | |
1113 | \r | |
1114 | maxexponent: 10 -- boundary\r | |
1115 | minexponent: -10\r | |
1116 | emax250 toSci 1E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped\r | |
1117 | emax251 toSci 1E-11 -> 1E-11 Subnormal\r | |
1118 | emax252 toSci 1E-10 -> 1E-10\r | |
1119 | emax253 toSci 1E-9 -> 1E-9\r | |
1120 | emax254 toSci 1E-8 -> 1E-8\r | |
1121 | emax255 toSci 1E+8 -> 1E+8\r | |
1122 | emax256 toSci 1E+9 -> 1E+9\r | |
1123 | emax257 toSci 1E+10 -> 1E+10\r | |
1124 | emax258 toSci 1E+11 -> Infinity Overflow Inexact Rounded\r | |
1125 | \r | |
1126 | emax260 toSci 1.00E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped\r | |
1127 | emax261 toSci 1.00E-11 -> 1.00E-11 Subnormal\r | |
1128 | emax262 toSci 1.00E-10 -> 1.00E-10\r | |
1129 | emax263 toSci 1.00E-9 -> 1.00E-9\r | |
1130 | emax264 toSci 1.00E-8 -> 1.00E-8\r | |
1131 | emax265 toSci 1.00E+8 -> 1.00E+8\r | |
1132 | emax266 toSci 1.00E+9 -> 1.00E+9\r | |
1133 | emax267 toSci 1.00E+10 -> 1.00E+10\r | |
1134 | emax268 toSci 1.00E+11 -> Infinity Overflow Inexact Rounded\r | |
1135 | emax270 toSci 9.99E-21 -> 0E-18 Underflow Subnormal Inexact Rounded Clamped\r | |
1136 | emax271 toSci 9.99E-11 -> 9.99E-11 Subnormal\r | |
1137 | emax272 toSci 9.99E-10 -> 9.99E-10\r | |
1138 | emax273 toSci 9.99E-9 -> 9.99E-9\r | |
1139 | emax274 toSci 9.99E-8 -> 9.99E-8\r | |
1140 | emax275 toSci 9.99E+8 -> 9.99E+8\r | |
1141 | emax276 toSci 9.99E+9 -> 9.99E+9\r | |
1142 | emax277 toSci 9.99E+10 -> 9.99E+10\r | |
1143 | emax278 toSci 9.99E+11 -> Infinity Overflow Inexact Rounded\r | |
1144 | \r | |
1145 | maxexponent: 99\r | |
1146 | minexponent: -99\r | |
1147 | emax280 toSci 1E-120 -> 0E-107 Underflow Subnormal Inexact Rounded Clamped\r | |
1148 | emax281 toSci 1E-100 -> 1E-100 Subnormal\r | |
1149 | emax282 toSci 1E-99 -> 1E-99\r | |
1150 | emax283 toSci 1E-98 -> 1E-98\r | |
1151 | emax284 toSci 1E+98 -> 1E+98\r | |
1152 | emax285 toSci 1E+99 -> 1E+99\r | |
1153 | emax286 toSci 1E+100 -> Infinity Overflow Inexact Rounded\r | |
1154 | \r | |
1155 | maxexponent: 999\r | |
1156 | minexponent: -999\r | |
1157 | emax291 toSci 1E-1000 -> 1E-1000 Subnormal\r | |
1158 | emax292 toSci 1E-999 -> 1E-999\r | |
1159 | emax293 toSci 1E+999 -> 1E+999\r | |
1160 | emax294 toSci 1E+1000 -> Infinity Overflow Inexact Rounded\r | |
1161 | maxexponent: 9999\r | |
1162 | minexponent: -9999\r | |
1163 | emax301 toSci 1E-10000 -> 1E-10000 Subnormal\r | |
1164 | emax302 toSci 1E-9999 -> 1E-9999\r | |
1165 | emax303 toSci 1E+9999 -> 1E+9999\r | |
1166 | emax304 toSci 1E+10000 -> Infinity Overflow Inexact Rounded\r | |
1167 | maxexponent: 99999\r | |
1168 | minexponent: -99999\r | |
1169 | emax311 toSci 1E-100000 -> 1E-100000 Subnormal\r | |
1170 | emax312 toSci 1E-99999 -> 1E-99999\r | |
1171 | emax313 toSci 1E+99999 -> 1E+99999\r | |
1172 | emax314 toSci 1E+100000 -> Infinity Overflow Inexact Rounded\r | |
1173 | maxexponent: 999999\r | |
1174 | minexponent: -999999\r | |
1175 | emax321 toSci 1E-1000000 -> 1E-1000000 Subnormal\r | |
1176 | emax322 toSci 1E-999999 -> 1E-999999\r | |
1177 | emax323 toSci 1E+999999 -> 1E+999999\r | |
1178 | emax324 toSci 1E+1000000 -> Infinity Overflow Inexact Rounded\r | |
1179 | maxexponent: 9999999\r | |
1180 | minexponent: -9999999\r | |
1181 | emax331 toSci 1E-10000000 -> 1E-10000000 Subnormal\r | |
1182 | emax332 toSci 1E-9999999 -> 1E-9999999\r | |
1183 | emax333 toSci 1E+9999999 -> 1E+9999999\r | |
1184 | emax334 toSci 1E+10000000 -> Infinity Overflow Inexact Rounded\r | |
1185 | maxexponent: 99999999\r | |
1186 | minexponent: -99999999\r | |
1187 | emax341 toSci 1E-100000000 -> 1E-100000000 Subnormal\r | |
1188 | emax342 toSci 1E-99999999 -> 1E-99999999\r | |
1189 | emax343 toSci 1E+99999999 -> 1E+99999999\r | |
1190 | emax344 toSci 1E+100000000 -> Infinity Overflow Inexact Rounded\r | |
1191 | \r | |
1192 | maxexponent: 999999999\r | |
1193 | minexponent: -999999999\r | |
1194 | emax347 toSci 1E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
1195 | emax348 toSci 1E-1000000007 -> 1E-1000000007 Subnormal\r | |
1196 | emax349 toSci 1E-1000000000 -> 1E-1000000000 Subnormal\r | |
1197 | emax350 toSci 1E-999999999 -> 1E-999999999\r | |
1198 | emax351 toSci 1E+999999999 -> 1E+999999999\r | |
1199 | emax352 toSci 1E+1000000000 -> Infinity Overflow Inexact Rounded\r | |
1200 | emax353 toSci 1.000E-1000000000 -> 1.000E-1000000000 Subnormal\r | |
1201 | emax354 toSci 1.000E-999999999 -> 1.000E-999999999\r | |
1202 | emax355 toSci 1.000E+999999999 -> 1.000E+999999999\r | |
1203 | emax356 toSci 1.000E+1000000000 -> Infinity Overflow Inexact Rounded\r | |
1204 | emax357 toSci 1.001E-1000000008 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
1205 | emax358 toSci 1.001E-1000000007 -> 1E-1000000007 Subnormal Inexact Rounded Underflow\r | |
1206 | emax359 toSci 1.001E-1000000000 -> 1.001E-1000000000 Subnormal\r | |
1207 | emax360 toSci 1.001E-999999999 -> 1.001E-999999999\r | |
1208 | emax361 toSci 1.001E+999999999 -> 1.001E+999999999\r | |
1209 | emax362 toSci 1.001E+1000000000 -> Infinity Overflow Inexact Rounded\r | |
1210 | emax363 toSci 9.000E-1000000000 -> 9.000E-1000000000 Subnormal\r | |
1211 | emax364 toSci 9.000E-999999999 -> 9.000E-999999999\r | |
1212 | emax365 toSci 9.000E+999999999 -> 9.000E+999999999\r | |
1213 | emax366 toSci 9.000E+1000000000 -> Infinity Overflow Inexact Rounded\r | |
1214 | emax367 toSci 9.999E-1000000009 -> 0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
1215 | emax368 toSci 9.999E-1000000008 -> 1E-1000000007 Underflow Subnormal Inexact Rounded\r | |
1216 | emax369 toSci 9.999E-1000000007 -> 1.0E-1000000006 Underflow Subnormal Inexact Rounded\r | |
1217 | emax370 toSci 9.999E-1000000000 -> 9.999E-1000000000 Subnormal\r | |
1218 | emax371 toSci 9.999E-999999999 -> 9.999E-999999999\r | |
1219 | emax372 toSci 9.999E+999999999 -> 9.999E+999999999\r | |
1220 | \r | |
1221 | emax373 toSci 9.999E+1000000000 -> Infinity Overflow Inexact Rounded\r | |
1222 | emax374 toSci -1E-1000000000 -> -1E-1000000000 Subnormal\r | |
1223 | emax375 toSci -1E-999999999 -> -1E-999999999\r | |
1224 | emax376 toSci -1E+999999999 -> -1E+999999999\r | |
1225 | emax377 toSci -1E+1000000000 -> -Infinity Overflow Inexact Rounded\r | |
1226 | emax378 toSci -1.000E-1000000000 -> -1.000E-1000000000 Subnormal\r | |
1227 | emax379 toSci -1.000E-999999999 -> -1.000E-999999999\r | |
1228 | emax380 toSci -1.000E+999999999 -> -1.000E+999999999\r | |
1229 | emax381 toSci -1.000E+1000000000 -> -Infinity Overflow Inexact Rounded\r | |
1230 | emax382 toSci -1.001E-1000000008 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
1231 | emax383 toSci -1.001E-999999999 -> -1.001E-999999999\r | |
1232 | emax384 toSci -1.001E+999999999 -> -1.001E+999999999\r | |
1233 | emax385 toSci -1.001E+1000000000 -> -Infinity Overflow Inexact Rounded\r | |
1234 | emax386 toSci -9.000E-1000000123 -> -0E-1000000007 Underflow Subnormal Inexact Rounded Clamped\r | |
1235 | emax387 toSci -9.000E-999999999 -> -9.000E-999999999\r | |
1236 | emax388 toSci -9.000E+999999999 -> -9.000E+999999999\r | |
1237 | emax389 toSci -9.000E+1000000000 -> -Infinity Overflow Inexact Rounded\r | |
1238 | emax390 toSci -9.999E-1000000008 -> -1E-1000000007 Underflow Subnormal Inexact Rounded\r | |
1239 | emax391 toSci -9.999E-999999999 -> -9.999E-999999999\r | |
1240 | emax392 toSci -9.999E+999999999 -> -9.999E+999999999\r | |
1241 | emax393 toSci -9.999E+1000000000 -> -Infinity Overflow Inexact Rounded\r | |
1242 | \r | |
1243 | -- Now check 854 rounding of subnormals and proper underflow to 0\r | |
1244 | precision: 5\r | |
1245 | maxExponent: 999\r | |
1246 | minexponent: -999\r | |
1247 | rounding: half_even\r | |
1248 | \r | |
1249 | emax400 toSci 1.0000E-999 -> 1.0000E-999\r | |
1250 | emax401 toSci 0.1E-999 -> 1E-1000 Subnormal\r | |
1251 | emax402 toSci 0.1000E-999 -> 1.000E-1000 Subnormal\r | |
1252 | emax403 toSci 0.0100E-999 -> 1.00E-1001 Subnormal\r | |
1253 | emax404 toSci 0.0010E-999 -> 1.0E-1002 Subnormal\r | |
1254 | emax405 toSci 0.0001E-999 -> 1E-1003 Subnormal\r | |
1255 | emax406 toSci 0.00010E-999 -> 1E-1003 Subnormal Rounded\r | |
1256 | emax407 toSci 0.00013E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded\r | |
1257 | emax408 toSci 0.00015E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1258 | emax409 toSci 0.00017E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1259 | emax410 toSci 0.00023E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1260 | emax411 toSci 0.00025E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1261 | emax412 toSci 0.00027E-999 -> 3E-1003 Underflow Subnormal Inexact Rounded\r | |
1262 | emax413 toSci 0.000149E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded\r | |
1263 | emax414 toSci 0.000150E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1264 | emax415 toSci 0.000151E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1265 | emax416 toSci 0.000249E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1266 | emax417 toSci 0.000250E-999 -> 2E-1003 Underflow Subnormal Inexact Rounded\r | |
1267 | emax418 toSci 0.000251E-999 -> 3E-1003 Underflow Subnormal Inexact Rounded\r | |
1268 | emax419 toSci 0.00009E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded\r | |
1269 | emax420 toSci 0.00005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1270 | emax421 toSci 0.00003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1271 | emax422 toSci 0.000009E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1272 | emax423 toSci 0.000005E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1273 | emax424 toSci 0.000003E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1274 | \r | |
1275 | emax425 toSci 0.001049E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded\r | |
1276 | emax426 toSci 0.001050E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded\r | |
1277 | emax427 toSci 0.001051E-999 -> 1.1E-1002 Underflow Subnormal Inexact Rounded\r | |
1278 | emax428 toSci 0.001149E-999 -> 1.1E-1002 Underflow Subnormal Inexact Rounded\r | |
1279 | emax429 toSci 0.001150E-999 -> 1.2E-1002 Underflow Subnormal Inexact Rounded\r | |
1280 | emax430 toSci 0.001151E-999 -> 1.2E-1002 Underflow Subnormal Inexact Rounded\r | |
1281 | \r | |
1282 | emax432 toSci 0.010049E-999 -> 1.00E-1001 Underflow Subnormal Inexact Rounded\r | |
1283 | emax433 toSci 0.010050E-999 -> 1.00E-1001 Underflow Subnormal Inexact Rounded\r | |
1284 | emax434 toSci 0.010051E-999 -> 1.01E-1001 Underflow Subnormal Inexact Rounded\r | |
1285 | emax435 toSci 0.010149E-999 -> 1.01E-1001 Underflow Subnormal Inexact Rounded\r | |
1286 | emax436 toSci 0.010150E-999 -> 1.02E-1001 Underflow Subnormal Inexact Rounded\r | |
1287 | emax437 toSci 0.010151E-999 -> 1.02E-1001 Underflow Subnormal Inexact Rounded\r | |
1288 | \r | |
1289 | emax440 toSci 0.10103E-999 -> 1.010E-1000 Underflow Subnormal Inexact Rounded\r | |
1290 | emax441 toSci 0.10105E-999 -> 1.010E-1000 Underflow Subnormal Inexact Rounded\r | |
1291 | emax442 toSci 0.10107E-999 -> 1.011E-1000 Underflow Subnormal Inexact Rounded\r | |
1292 | emax443 toSci 0.10113E-999 -> 1.011E-1000 Underflow Subnormal Inexact Rounded\r | |
1293 | emax444 toSci 0.10115E-999 -> 1.012E-1000 Underflow Subnormal Inexact Rounded\r | |
1294 | emax445 toSci 0.10117E-999 -> 1.012E-1000 Underflow Subnormal Inexact Rounded\r | |
1295 | \r | |
1296 | emax450 toSci 1.10730E-1000 -> 1.107E-1000 Underflow Subnormal Inexact Rounded\r | |
1297 | emax451 toSci 1.10750E-1000 -> 1.108E-1000 Underflow Subnormal Inexact Rounded\r | |
1298 | emax452 toSci 1.10770E-1000 -> 1.108E-1000 Underflow Subnormal Inexact Rounded\r | |
1299 | emax453 toSci 1.10830E-1000 -> 1.108E-1000 Underflow Subnormal Inexact Rounded\r | |
1300 | emax454 toSci 1.10850E-1000 -> 1.108E-1000 Underflow Subnormal Inexact Rounded\r | |
1301 | emax455 toSci 1.10870E-1000 -> 1.109E-1000 Underflow Subnormal Inexact Rounded\r | |
1302 | \r | |
1303 | -- make sure sign OK\r | |
1304 | emax456 toSci -0.10103E-999 -> -1.010E-1000 Underflow Subnormal Inexact Rounded\r | |
1305 | emax457 toSci -0.10105E-999 -> -1.010E-1000 Underflow Subnormal Inexact Rounded\r | |
1306 | emax458 toSci -0.10107E-999 -> -1.011E-1000 Underflow Subnormal Inexact Rounded\r | |
1307 | emax459 toSci -0.10113E-999 -> -1.011E-1000 Underflow Subnormal Inexact Rounded\r | |
1308 | emax460 toSci -0.10115E-999 -> -1.012E-1000 Underflow Subnormal Inexact Rounded\r | |
1309 | emax461 toSci -0.10117E-999 -> -1.012E-1000 Underflow Subnormal Inexact Rounded\r | |
1310 | \r | |
1311 | -- '999s' cases\r | |
1312 | emax464 toSci 999999E-999 -> 1.0000E-993 Inexact Rounded\r | |
1313 | emax465 toSci 99999.0E-999 -> 9.9999E-995 Rounded\r | |
1314 | emax466 toSci 99999.E-999 -> 9.9999E-995\r | |
1315 | emax467 toSci 9999.9E-999 -> 9.9999E-996\r | |
1316 | emax468 toSci 999.99E-999 -> 9.9999E-997\r | |
1317 | emax469 toSci 99.999E-999 -> 9.9999E-998\r | |
1318 | emax470 toSci 9.9999E-999 -> 9.9999E-999\r | |
1319 | emax471 toSci 0.99999E-999 -> 1.0000E-999 Underflow Subnormal Inexact Rounded\r | |
1320 | emax472 toSci 0.099999E-999 -> 1.000E-1000 Underflow Subnormal Inexact Rounded\r | |
1321 | emax473 toSci 0.0099999E-999 -> 1.00E-1001 Underflow Subnormal Inexact Rounded\r | |
1322 | emax474 toSci 0.00099999E-999 -> 1.0E-1002 Underflow Subnormal Inexact Rounded\r | |
1323 | emax475 toSci 0.000099999E-999 -> 1E-1003 Underflow Subnormal Inexact Rounded\r | |
1324 | emax476 toSci 0.0000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1325 | emax477 toSci 0.00000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1326 | emax478 toSci 0.000000099999E-999 -> 0E-1003 Underflow Subnormal Inexact Rounded Clamped\r | |
1327 | \r | |
1328 | -- Exponents with insignificant leading zeros\r | |
1329 | precision: 16\r | |
1330 | maxExponent: 999999999\r | |
1331 | minexponent: -999999999\r | |
1332 | basx1001 toSci 1e999999999 -> 1E+999999999\r | |
1333 | basx1002 toSci 1e0999999999 -> 1E+999999999\r | |
1334 | basx1003 toSci 1e00999999999 -> 1E+999999999\r | |
1335 | basx1004 toSci 1e000999999999 -> 1E+999999999\r | |
1336 | basx1005 toSci 1e000000000000999999999 -> 1E+999999999\r | |
1337 | basx1006 toSci 1e000000000001000000007 -> Infinity Overflow Inexact Rounded\r | |
1338 | basx1007 toSci 1e-999999999 -> 1E-999999999\r | |
1339 | basx1008 toSci 1e-0999999999 -> 1E-999999999\r | |
1340 | basx1009 toSci 1e-00999999999 -> 1E-999999999\r | |
1341 | basx1010 toSci 1e-000999999999 -> 1E-999999999\r | |
1342 | basx1011 toSci 1e-000000000000999999999 -> 1E-999999999\r | |
1343 | basx1012 toSci 1e-000000000001000000007 -> 1E-1000000007 Subnormal\r | |
1344 | \r | |
1345 | -- Edge cases for int32 exponents...\r | |
1346 | basx1021 tosci 1e+2147483649 -> Infinity Overflow Inexact Rounded\r | |
1347 | basx1022 tosci 1e+2147483648 -> Infinity Overflow Inexact Rounded\r | |
1348 | basx1023 tosci 1e+2147483647 -> Infinity Overflow Inexact Rounded\r | |
1349 | basx1024 tosci 1e-2147483647 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped\r | |
1350 | basx1025 tosci 1e-2147483648 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped\r | |
1351 | basx1026 tosci 1e-2147483649 -> 0E-1000000014 Underflow Subnormal Inexact Rounded Clamped\r | |
1352 | -- same unbalanced\r | |
1353 | precision: 7\r | |
1354 | maxExponent: 96\r | |
1355 | minexponent: -95\r | |
1356 | basx1031 tosci 1e+2147483649 -> Infinity Overflow Inexact Rounded\r | |
1357 | basx1032 tosci 1e+2147483648 -> Infinity Overflow Inexact Rounded\r | |
1358 | basx1033 tosci 1e+2147483647 -> Infinity Overflow Inexact Rounded\r | |
1359 | basx1034 tosci 1e-2147483647 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped\r | |
1360 | basx1035 tosci 1e-2147483648 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped\r | |
1361 | basx1036 tosci 1e-2147483649 -> 0E-101 Underflow Subnormal Inexact Rounded Clamped\r | |
1362 | \r | |
1363 | -- check for double-rounded subnormals\r | |
1364 | precision: 5\r | |
1365 | maxexponent: 79\r | |
1366 | minexponent: -79\r | |
1367 | basx1041 toSci 1.52444E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow\r | |
1368 | basx1042 toSci 1.52445E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow\r | |
1369 | basx1043 toSci 1.52446E-80 -> 1.524E-80 Inexact Rounded Subnormal Underflow\r | |
1370 | \r | |
1371 | -- clamped zeros [see also clamp.decTest]\r | |
1372 | precision: 34\r | |
1373 | maxExponent: 6144\r | |
1374 | minExponent: -6143\r | |
1375 | \r | |
1376 | basx1061 apply 0e+10000 -> 0E+6144 Clamped\r | |
1377 | basx1062 apply 0e-10000 -> 0E-6176 Clamped\r | |
1378 | basx1063 apply -0e+10000 -> -0E+6144 Clamped\r | |
1379 | basx1064 apply -0e-10000 -> -0E-6176 Clamped\r | |
1380 | \r | |
1381 | precision: 16\r | |
1382 | maxExponent: 384\r | |
1383 | minExponent: -383\r | |
1384 | \r | |
1385 | basx1065 apply 0e+10000 -> 0E+384 Clamped\r | |
1386 | basx1066 apply 0e-10000 -> 0E-398 Clamped\r | |
1387 | basx1067 apply -0e+10000 -> -0E+384 Clamped\r | |
1388 | basx1068 apply -0e-10000 -> -0E-398 Clamped\r | |
1389 | \r | |
1390 | -- same with IEEE clamping\r | |
1391 | clamp: 1\r | |
1392 | \r | |
1393 | precision: 34\r | |
1394 | maxExponent: 6144\r | |
1395 | minExponent: -6143\r | |
1396 | \r | |
1397 | basx1071 apply 0e+10000 -> 0E+6111 Clamped\r | |
1398 | basx1072 apply 0e-10000 -> 0E-6176 Clamped\r | |
1399 | basx1073 apply -0e+10000 -> -0E+6111 Clamped\r | |
1400 | basx1074 apply -0e-10000 -> -0E-6176 Clamped\r | |
1401 | \r | |
1402 | precision: 16\r | |
1403 | maxExponent: 384\r | |
1404 | minExponent: -383\r | |
1405 | \r | |
1406 | basx1075 apply 0e+10000 -> 0E+369 Clamped\r | |
1407 | basx1076 apply 0e-10000 -> 0E-398 Clamped\r | |
1408 | basx1077 apply -0e+10000 -> -0E+369 Clamped\r | |
1409 | basx1078 apply -0e-10000 -> -0E-398 Clamped\r | |
1410 | \r | |
1411 | \r |