float-formats 0.2.1 → 0.3.0

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,5 @@
1
1
  #Float-Formats -- Native Ruby Float support tools
2
2
 
3
- require 'nio'
4
- require 'nio/sugar'
5
3
  require 'flt'
6
4
  require 'flt/float'
7
5
  require 'float-formats/bytes'
@@ -12,22 +10,22 @@ module_function
12
10
 
13
11
  # shortest decimal unambiguous reprentation
14
12
  def float_shortest_dec(x)
15
- x.nio_write(Nio::Fmt.prec(:exact))
13
+ Numerals::Format[:short].write(x)
16
14
  end
17
15
 
18
16
  # decimal representation showing all significant digits
19
17
  def float_significant_dec(x)
20
- x.nio_write(Nio::Fmt.prec(:exact).show_all_digits(true))
18
+ Numerals::Format[:free].write(x)
21
19
  end
22
20
 
23
21
  # complete exact decimal representation
24
22
  def float_dec(x)
25
- x.nio_write(Nio::Fmt.prec(:exact).approx_mode(:exact))
23
+ Numerals::Format[:free, :exact_input].write(x)
26
24
  end
27
25
 
28
26
  # binary representation
29
27
  def float_bin(x)
30
- x.nio_write(Nio::Fmt.mode(:sci,:exact).base(2))
28
+ Numerals::Format[:free, :exact_input, :scientific, base: 2].write(x)
31
29
  end
32
30
 
33
31
  # decompose a float into a signed integer significand and exponent (base Float::RADIX)
@@ -50,57 +48,14 @@ end
50
48
 
51
49
  # convert a float to C99's hexadecimal notation
52
50
  def hex_from_float(v)
53
- if Float::RADIX==2
54
- sgn,s,e = float_to_integral_sign_significand_exponent(v)
55
- else
56
- txt = v.nio_write(Fmt.base(2).sep('.')).upcase
57
- p = txt.index('E')
58
- exp = 0
59
- if p
60
- exp = rep[p+1..-1].to_i
61
- txt = rep[0...p]
62
- end
63
- p = txt.index('.')
64
- if p
65
- exp -= (txt.size-p-1)
66
- txt.tr!('.','')
67
- end
68
- s = txt.to_i(2)
69
- e = exp
70
- end
71
- "0x#{sgn<0 ? '-' : ''}#{s.to_s(16)}p#{e}"
51
+ Numerals::Format[:hexbin].write(v)
72
52
  end
73
53
 
74
54
  # convert a string formatted in C99's hexadecimal notation to a float
75
55
  def hex_to_float(txt)
76
- txt = txt.strip.upcase
77
- txt = txt[2..-1] if txt[0,2]=='0X'
78
- p = txt.index('P')
79
- if p
80
- exp = txt[p+1..-1].to_i
81
- txt = txt[0...p]
82
- else
83
- exp = 0
84
- end
85
- p = txt.index('.')
86
- if p
87
- exp -= (txt.size-p-1)*4
88
- txt.tr!('.','')
89
- end
90
- if Float::RADIX==2
91
- v = txt.to_i(16)
92
- if v==0 && txt.include?('-')
93
- sign = -1
94
- elsif v<0
95
- sign = -1
96
- v = -v
97
- else
98
- sign = +1
99
- end
100
- float_from_integral_sign_significand_exponent(sign,v,exp)
101
- else
102
- (txt.to_i(16)*(2**exp)).to_f
103
- end
56
+ # Numerals::Format[:hexbin].read(txt, type: Float)
57
+ # txt.scanf("%A").first
58
+ Float(txt)
104
59
  end
105
60
 
106
61
  # ===== IEEE types =====================================================================================
@@ -142,4 +97,4 @@ def dbl_to_float(sgl, little_endian=true)
142
97
  sgl.unpack(code)[0]
143
98
  end
144
99
 
145
- end
100
+ end
@@ -1,5 +1,5 @@
1
1
  module Flt
2
2
  module Frmts
3
- VERSION = '0.2.1'
3
+ VERSION = '0.3.0'
4
4
  end
5
5
  end
@@ -1,43 +1,49 @@
1
1
  require File.expand_path(File.join(File.dirname(__FILE__),'test_helper.rb'))
2
- require 'yaml'
3
2
 
4
- include Flt
3
+ class TestBytes < Test::Unit::TestCase
5
4
 
6
- def test_bits
7
- assert_equal 11, Bits.new(11).size
8
- assert_equal "00000", Bits.new(5).to_s
9
- assert_equal "011010101010", Bits.from_s("011010101010").to_s
10
- assert_equal 0b011010101010, Bits.from_s("011010101010").to_i
11
- assert_equal 0b011010101010, Bits.from_i(0b011010101010).to_i
12
- assert_equal "011010101010", Bits.from_i(0b011010101010).to_s
13
- b = Bits.from_s("0111010100110")
14
- assert_equal 0,b[0]
15
- assert_equal 1,b[1]
16
- assert_equal 1,b[2]
17
- assert_equal 0,b[3]
18
- assert_equal 0,b[4]
19
- assert_equal 1,b[5]
20
- assert_equal 0,b[12]
21
- assert_equal 0,b[13]
22
- b[1] = 0
23
- assert_equal 0,b[0]
24
- assert_equal 0,b[1]
25
- assert_equal 1,b[2]
26
- assert_equal 0,b[3]
27
- b[1] = 1
28
- assert_equal 0,b[0]
29
- assert_equal 1,b[1]
30
- assert_equal 1,b[2]
31
- assert_equal 0,b[3]
32
- end
5
+ include Flt
6
+
7
+ def test_bits
8
+ assert_equal 11, Bits.new(11).size
9
+ assert_equal "00000", Bits.new(5).to_s
10
+ assert_equal "011010101010", Bits.from_s("011010101010").to_s
11
+ assert_equal 0b011010101010, Bits.from_s("011010101010").to_i
12
+ assert_equal 0b011010101010, Bits.from_i(0b011010101010).to_i
13
+ assert_equal "11010101010", Bits.from_i(0b011010101010).to_s
14
+ b = Bits.from_s("0111010100110")
15
+ assert_equal 0,b[0]
16
+ assert_equal 1,b[1]
17
+ assert_equal 1,b[2]
18
+ assert_equal 0,b[3]
19
+ assert_equal 0,b[4]
20
+ assert_equal 1,b[5]
21
+ assert_equal 0,b[12]
22
+ assert_equal 0,b[13]
23
+ b[1] = 0
24
+ assert_equal 0,b[0]
25
+ assert_equal 0,b[1]
26
+ assert_equal 1,b[2]
27
+ assert_equal 0,b[3]
28
+ b[1] = 1
29
+ assert_equal 0,b[0]
30
+ assert_equal 1,b[1]
31
+ assert_equal 1,b[2]
32
+ assert_equal 0,b[3]
33
+ end
34
+
35
+ def test_bytes
36
+ b = Bytes.from_hex("AF237B93")
37
+ assert_equal "AF237B93", b.to_hex
38
+ assert_equal 0x937B23AF, b.to_bits.to_i
39
+ assert_equal 0xAF237B93, b.to_i(:big_endian)
40
+ b = Bytes.from_i(0xAF237B93, 4, :big_endian)
41
+ assert_equal "AF237B93", b.to_hex
42
+
43
+ b = Bytes.from_bits(Bits.from_i(0xAF237B93))
44
+ assert_equal "937B23AF", b.to_hex
45
+ assert_equal 0xAF237B93, b.to_bits.to_i
46
+ assert_equal 0x937B23AF, b.to_i(:big_endian)
47
+ end
33
48
 
34
- def test_bytes
35
- b = Bytes.from_hex("AF237B93")
36
- assert_equal "AF237B93", b.to_hex
37
- assert_equal 0xAF237B93, b.to_bits.to_i
38
- assert_equal 0xAF237B93, b.to_i
39
- b = Bytes.from_bits(Bits.from_i(0xAF237B93))
40
- assert_equal "AF237B93", b.to_hex
41
- assert_equal 0xAF237B93, b.to_bits.to_i
42
- assert_equal 0xAF237B93, b.to_i
43
49
  end
@@ -1,6 +1,6 @@
1
- ---
2
- C51_BCD_FLOAT:
3
- parameters:
1
+ ---
2
+ C51_BCD_FLOAT:
3
+ parameters:
4
4
  - total_bits: 32
5
5
  - radix: 10
6
6
  - significand_digits: 6
@@ -10,21 +10,21 @@ C51_BCD_FLOAT:
10
10
  - decimal_digits_necessary: 6
11
11
  - decimal_min_exp: -65
12
12
  - decimal_max_exp: 62
13
- values:
13
+ values:
14
14
  - Rational(1, 3): 40 33 33 33
15
15
  - Rational(1, 10): 40 00 00 10
16
16
  - Rational(2, 3): 40 67 66 66
17
- - Rational(1, 1024): 3C 25 56 76 09
17
+ - Rational(1, 1024): 3D 62 65 97
18
18
  - Rational(1, 1000): 3E 00 00 10
19
19
  - Rational(1024, 1): 44 00 24 10
20
20
  - Rational(1024, 1): 44 00 24 10
21
- special:
21
+ special:
22
22
  - min_value: 00 00 00 10
23
23
  - min_normalized_value: 00 00 00 10
24
24
  - max_value: 7F 99 99 99
25
25
  - epsilon: 3C 00 00 10
26
26
  - strict_epsilon: 3C 00 00 10
27
- numerals:
27
+ numerals:
28
28
  - "+0": 00 00 00 00
29
29
  - "-0": 80 00 00 00
30
30
  - "+1": 41 00 00 10
@@ -48,8 +48,8 @@ C51_BCD_FLOAT:
48
48
  - 1E-5: 3C 00 00 10
49
49
  - 1E-5: 3C 00 00 10
50
50
  base: :bytes
51
- IBM64:
52
- parameters:
51
+ IBM64:
52
+ parameters:
53
53
  - total_bits: 64
54
54
  - radix: 16
55
55
  - significand_digits: 14
@@ -59,7 +59,7 @@ IBM64:
59
59
  - decimal_digits_necessary: 18
60
60
  - decimal_min_exp: -77
61
61
  - decimal_max_exp: 77
62
- values:
62
+ values:
63
63
  - Rational(1, 3): 40 55 55 55 55 55 55 55
64
64
  - Rational(1, 10): 40 19 99 99 99 99 99 9A
65
65
  - Rational(2, 3): 40 AA AA AA AA AA AA AB
@@ -67,13 +67,13 @@ IBM64:
67
67
  - Rational(1, 1000): 3E 41 89 37 4B C6 A7 F0
68
68
  - Rational(1024, 1): 43 40 00 00 00 00 00 00
69
69
  - Rational(1024, 1): 43 40 00 00 00 00 00 00
70
- special:
70
+ special:
71
71
  - min_value: 00 10 00 00 00 00 00 00
72
72
  - min_normalized_value: 00 10 00 00 00 00 00 00
73
73
  - max_value: 7F FF FF FF FF FF FF FF
74
74
  - epsilon: 34 10 00 00 00 00 00 00
75
75
  - strict_epsilon: 34 10 00 00 00 00 00 00
76
- numerals:
76
+ numerals:
77
77
  - "+0": 00 00 00 00 00 00 00 00
78
78
  - "-0": 80 00 00 00 00 00 00 00
79
79
  - "+1": 41 10 00 00 00 00 00 00
@@ -97,8 +97,8 @@ IBM64:
97
97
  - "2.22044604925031308E-16": 34 10 00 00 00 00 00 00
98
98
  - "2.22044604925031308E-16": 34 10 00 00 00 00 00 00
99
99
  base: :bytes
100
- VAX_D:
101
- parameters:
100
+ VAX_D:
101
+ parameters:
102
102
  - total_bits: 64
103
103
  - radix: 2
104
104
  - significand_digits: 56
@@ -108,7 +108,7 @@ VAX_D:
108
108
  - decimal_digits_necessary: 18
109
109
  - decimal_min_exp: -38
110
110
  - decimal_max_exp: 38
111
- values:
111
+ values:
112
112
  - Rational(1, 3): AA 3F AA AA AA AA AB AA
113
113
  - Rational(1, 10): CC 3E CC CC CC CC CD CC
114
114
  - Rational(2, 3): 2A 40 AA AA AA AA AB AA
@@ -116,13 +116,13 @@ VAX_D:
116
116
  - Rational(1, 1000): 83 3B 6E 12 8D 97 DF 4F
117
117
  - Rational(1024, 1): 80 45 00 00 00 00 00 00
118
118
  - Rational(1024, 1): 80 45 00 00 00 00 00 00
119
- special:
119
+ special:
120
120
  - min_value: 80 00 00 00 00 00 00 00
121
121
  - min_normalized_value: 80 00 00 00 00 00 00 00
122
122
  - max_value: FF 7F FF FF FF FF FF FF
123
123
  - epsilon: 00 25 00 00 00 00 00 00
124
124
  - strict_epsilon: 00 25 00 00 00 00 00 00
125
- numerals:
125
+ numerals:
126
126
  - "+0": 00 00 00 00 00 00 00 00
127
127
  - "-0": 00 80 00 00 00 00 00 00
128
128
  - "+1": 80 40 00 00 00 00 00 00
@@ -146,8 +146,8 @@ VAX_D:
146
146
  - "2.77555756156289135E-17": 00 25 00 00 00 00 00 00
147
147
  - "2.77555756156289135E-17": 00 25 00 00 00 00 00 00
148
148
  base: :bytes
149
- IEEE_SINGLE:
150
- parameters:
149
+ IEEE_SINGLE:
150
+ parameters:
151
151
  - total_bits: 32
152
152
  - radix: 2
153
153
  - significand_digits: 24
@@ -157,7 +157,7 @@ IEEE_SINGLE:
157
157
  - decimal_digits_necessary: 9
158
158
  - decimal_min_exp: -37
159
159
  - decimal_max_exp: 38
160
- values:
160
+ values:
161
161
  - Rational(1, 3): AB AA AA 3E
162
162
  - Rational(1, 10): CD CC CC 3D
163
163
  - Rational(2, 3): AB AA 2A 3F
@@ -165,13 +165,13 @@ IEEE_SINGLE:
165
165
  - Rational(1, 1000): 6F 12 83 3A
166
166
  - Rational(1024, 1): 00 00 80 44
167
167
  - Rational(1024, 1): 00 00 80 44
168
- special:
168
+ special:
169
169
  - min_value: 01 00 00 00
170
170
  - min_normalized_value: 00 00 80 00
171
171
  - max_value: FF FF 7F 7F
172
172
  - epsilon: 00 00 00 34
173
173
  - strict_epsilon: 01 00 80 33
174
- numerals:
174
+ numerals:
175
175
  - "+0": 00 00 00 00
176
176
  - "-0": 00 00 00 80
177
177
  - "+1": 00 00 80 3F
@@ -195,8 +195,8 @@ IEEE_SINGLE:
195
195
  - "1.1920929E-7": 00 00 00 34
196
196
  - "5.96046519E-8": 01 00 80 33
197
197
  base: :bytes
198
- UNIVAC_DOUBLE:
199
- parameters:
198
+ UNIVAC_DOUBLE:
199
+ parameters:
200
200
  - total_bits: 72
201
201
  - radix: 2
202
202
  - significand_digits: 60
@@ -206,7 +206,7 @@ UNIVAC_DOUBLE:
206
206
  - decimal_digits_necessary: 20
207
207
  - decimal_min_exp: -308
208
208
  - decimal_max_exp: 308
209
- values:
209
+ values:
210
210
  - Rational(1, 3): 3FFAAAAAAAAAAAAAAB
211
211
  - Rational(1, 10): 3FDCCCCCCCCCCCCCCD
212
212
  - Rational(2, 3): 400AAAAAAAAAAAAAAB
@@ -214,13 +214,13 @@ UNIVAC_DOUBLE:
214
214
  - Rational(1, 1000): 3F783126E978D4FDF4
215
215
  - Rational(1024, 1): 40B800000000000000
216
216
  - Rational(1024, 1): 40B800000000000000
217
- special:
217
+ special:
218
218
  - min_value: 000800000000000000
219
219
  - min_normalized_value: 000800000000000000
220
220
  - max_value: 7FFFFFFFFFFFFFFFFF
221
221
  - epsilon: 3C6800000000000000
222
222
  - strict_epsilon: 3C6800000000000000
223
- numerals:
223
+ numerals:
224
224
  - "+0": "000000000000000000"
225
225
  - "-0": FFFFFFFFFFFFFFFFFF
226
226
  - "+1": "401800000000000000"
@@ -244,8 +244,8 @@ UNIVAC_DOUBLE:
244
244
  - "1.7347234759768070944E-18": 3C6800000000000000
245
245
  - "1.7347234759768070944E-18": 3C6800000000000000
246
246
  base: 16
247
- IBM32:
248
- parameters:
247
+ IBM32:
248
+ parameters:
249
249
  - total_bits: 32
250
250
  - radix: 16
251
251
  - significand_digits: 6
@@ -255,7 +255,7 @@ IBM32:
255
255
  - decimal_digits_necessary: 9
256
256
  - decimal_min_exp: -77
257
257
  - decimal_max_exp: 77
258
- values:
258
+ values:
259
259
  - Rational(1, 3): 40 55 55 55
260
260
  - Rational(1, 10): 40 19 99 9A
261
261
  - Rational(2, 3): 40 AA AA AB
@@ -263,13 +263,13 @@ IBM32:
263
263
  - Rational(1, 1000): 3E 41 89 37
264
264
  - Rational(1024, 1): 43 40 00 00
265
265
  - Rational(1024, 1): 43 40 00 00
266
- special:
266
+ special:
267
267
  - min_value: 00 10 00 00
268
268
  - min_normalized_value: 00 10 00 00
269
269
  - max_value: 7F FF FF FF
270
270
  - epsilon: 3C 10 00 00
271
271
  - strict_epsilon: 3C 10 00 00
272
- numerals:
272
+ numerals:
273
273
  - "+0": 00 00 00 00
274
274
  - "-0": 80 00 00 00
275
275
  - "+1": 41 10 00 00
@@ -293,8 +293,8 @@ IBM32:
293
293
  - "9.53674316E-7": 3C 10 00 00
294
294
  - "9.53674316E-7": 3C 10 00 00
295
295
  base: :bytes
296
- PDP11_D:
297
- parameters:
296
+ PDP11_D:
297
+ parameters:
298
298
  - total_bits: 64
299
299
  - radix: 2
300
300
  - significand_digits: 56
@@ -304,7 +304,7 @@ PDP11_D:
304
304
  - decimal_digits_necessary: 18
305
305
  - decimal_min_exp: -38
306
306
  - decimal_max_exp: 38
307
- values:
307
+ values:
308
308
  - Rational(1, 3): AA 3F AA AA AA AA AB AA
309
309
  - Rational(1, 10): CC 3E CC CC CC CC CD CC
310
310
  - Rational(2, 3): 2A 40 AA AA AA AA AB AA
@@ -312,13 +312,13 @@ PDP11_D:
312
312
  - Rational(1, 1000): 83 3B 6E 12 8D 97 DF 4F
313
313
  - Rational(1024, 1): 80 45 00 00 00 00 00 00
314
314
  - Rational(1024, 1): 80 45 00 00 00 00 00 00
315
- special:
315
+ special:
316
316
  - min_value: 00 00 00 00 00 00 01 00
317
317
  - min_normalized_value: 00 00 00 00 00 00 01 00
318
318
  - max_value: FF 7F FF FF FF FF FF FF
319
319
  - epsilon: 00 25 00 00 00 00 00 00
320
320
  - strict_epsilon: 00 25 00 00 00 00 00 00
321
- numerals:
321
+ numerals:
322
322
  - "+0": 00 00 00 00 00 00 00 00
323
323
  - "-0": 00 80 00 00 00 00 00 00
324
324
  - "+1": 80 40 00 00 00 00 00 00
@@ -342,8 +342,8 @@ PDP11_D:
342
342
  - "2.77555756156289135E-17": 00 25 00 00 00 00 00 00
343
343
  - "2.77555756156289135E-17": 00 25 00 00 00 00 00 00
344
344
  base: :bytes
345
- C51_BCD_DOUBLE:
346
- parameters:
345
+ C51_BCD_DOUBLE:
346
+ parameters:
347
347
  - total_bits: 48
348
348
  - radix: 10
349
349
  - significand_digits: 10
@@ -353,7 +353,7 @@ C51_BCD_DOUBLE:
353
353
  - decimal_digits_necessary: 10
354
354
  - decimal_min_exp: -65
355
355
  - decimal_max_exp: 62
356
- values:
356
+ values:
357
357
  - Rational(1, 3): 40 33 33 33 33 33
358
358
  - Rational(1, 10): 40 00 00 00 00 10
359
359
  - Rational(2, 3): 40 67 66 66 66 66
@@ -361,13 +361,13 @@ C51_BCD_DOUBLE:
361
361
  - Rational(1, 1000): 3E 00 00 00 00 10
362
362
  - Rational(1024, 1): 44 00 00 00 24 10
363
363
  - Rational(1024, 1): 44 00 00 00 24 10
364
- special:
364
+ special:
365
365
  - min_value: 00 00 00 00 00 10
366
366
  - min_normalized_value: 00 00 00 00 00 10
367
367
  - max_value: 7F 99 99 99 99 99
368
368
  - epsilon: 38 00 00 00 00 10
369
369
  - strict_epsilon: 38 00 00 00 00 10
370
- numerals:
370
+ numerals:
371
371
  - "+0": 00 00 00 00 00 00
372
372
  - "-0": 80 00 00 00 00 00
373
373
  - "+1": 41 00 00 00 00 10
@@ -391,8 +391,8 @@ C51_BCD_DOUBLE:
391
391
  - 1E-9: 38 00 00 00 00 10
392
392
  - 1E-9: 38 00 00 00 00 10
393
393
  base: :bytes
394
- VAX_F:
395
- parameters:
394
+ VAX_F:
395
+ parameters:
396
396
  - total_bits: 32
397
397
  - radix: 2
398
398
  - significand_digits: 24
@@ -402,7 +402,7 @@ VAX_F:
402
402
  - decimal_digits_necessary: 9
403
403
  - decimal_min_exp: -38
404
404
  - decimal_max_exp: 38
405
- values:
405
+ values:
406
406
  - Rational(1, 3): AA 3F AB AA
407
407
  - Rational(1, 10): CC 3E CD CC
408
408
  - Rational(2, 3): 2A 40 AB AA
@@ -410,13 +410,13 @@ VAX_F:
410
410
  - Rational(1, 1000): 83 3B 6F 12
411
411
  - Rational(1024, 1): 80 45 00 00
412
412
  - Rational(1024, 1): 80 45 00 00
413
- special:
413
+ special:
414
414
  - min_value: 80 00 00 00
415
415
  - min_normalized_value: 80 00 00 00
416
416
  - max_value: FF 7F FF FF
417
417
  - epsilon: 00 35 00 00
418
418
  - strict_epsilon: 00 35 00 00
419
- numerals:
419
+ numerals:
420
420
  - "+0": 00 00 00 00
421
421
  - "-0": 00 80 00 00
422
422
  - "+1": 80 40 00 00
@@ -440,8 +440,8 @@ VAX_F:
440
440
  - "1.1920929E-7": 00 35 00 00
441
441
  - "1.1920929E-7": 00 35 00 00
442
442
  base: :bytes
443
- XS256_DOUBLE:
444
- parameters:
443
+ XS256_DOUBLE:
444
+ parameters:
445
445
  - total_bits: 64
446
446
  - radix: 2
447
447
  - significand_digits: 55
@@ -451,7 +451,7 @@ XS256_DOUBLE:
451
451
  - decimal_digits_necessary: 18
452
452
  - decimal_min_exp: -76
453
453
  - decimal_max_exp: 77
454
- values:
454
+ values:
455
455
  - Rational(1, 3): 3F 95 55 55 55 55 55 55
456
456
  - Rational(1, 10): 3F 26 66 66 66 66 66 66
457
457
  - Rational(2, 3): 3F D5 55 55 55 55 55 55
@@ -459,13 +459,13 @@ XS256_DOUBLE:
459
459
  - Rational(1, 1000): 3D 81 89 37 4B C6 A7 F0
460
460
  - Rational(1024, 1): 42 80 00 00 00 00 00 00
461
461
  - Rational(1024, 1): 42 80 00 00 00 00 00 00
462
- special:
462
+ special:
463
463
  - min_value: 00 00 00 00 00 00 00 01
464
464
  - min_normalized_value: 00 00 00 00 00 00 00 01
465
465
  - max_value: 7F FF FF FF FF FF FF FF
466
466
  - epsilon: 32 80 00 00 00 00 00 00
467
467
  - strict_epsilon: 32 40 00 00 00 00 00 00
468
- numerals:
468
+ numerals:
469
469
  - "+0": 00 00 00 00 00 00 00 00
470
470
  - "-0": 80 00 00 00 00 00 00 00
471
471
  - "+1": 40 00 00 00 00 00 00 00
@@ -489,8 +489,8 @@ XS256_DOUBLE:
489
489
  - "5.5511151231257827E-17": 32 80 00 00 00 00 00 00
490
490
  - "2.77555756156289135E-17": 32 40 00 00 00 00 00 00
491
491
  base: :bytes
492
- IEEE_DOUBLE:
493
- parameters:
492
+ IEEE_DOUBLE:
493
+ parameters:
494
494
  - total_bits: 64
495
495
  - radix: 2
496
496
  - significand_digits: 53
@@ -500,7 +500,7 @@ IEEE_DOUBLE:
500
500
  - decimal_digits_necessary: 17
501
501
  - decimal_min_exp: -307
502
502
  - decimal_max_exp: 308
503
- values:
503
+ values:
504
504
  - Rational(1, 3): 55 55 55 55 55 55 D5 3F
505
505
  - Rational(1, 10): 9A 99 99 99 99 99 B9 3F
506
506
  - Rational(2, 3): 55 55 55 55 55 55 E5 3F
@@ -508,13 +508,13 @@ IEEE_DOUBLE:
508
508
  - Rational(1, 1000): FC A9 F1 D2 4D 62 50 3F
509
509
  - Rational(1024, 1): 00 00 00 00 00 00 90 40
510
510
  - Rational(1024, 1): 00 00 00 00 00 00 90 40
511
- special:
511
+ special:
512
512
  - min_value: 01 00 00 00 00 00 00 00
513
513
  - min_normalized_value: 00 00 00 00 00 00 10 00
514
514
  - max_value: FF FF FF FF FF FF EF 7F
515
515
  - epsilon: 00 00 00 00 00 00 B0 3C
516
516
  - strict_epsilon: 01 00 00 00 00 00 A0 3C
517
- numerals:
517
+ numerals:
518
518
  - "+0": 00 00 00 00 00 00 00 00
519
519
  - "-0": 00 00 00 00 00 00 00 80
520
520
  - "+1": 00 00 00 00 00 00 F0 3F
@@ -538,8 +538,8 @@ IEEE_DOUBLE:
538
538
  - "2.2204460492503131E-16": 00 00 00 00 00 00 B0 3C
539
539
  - "1.1102230246251568E-16": 01 00 00 00 00 00 A0 3C
540
540
  base: :bytes
541
- CDC_DOUBLE:
542
- parameters:
541
+ CDC_DOUBLE:
542
+ parameters:
543
543
  - total_bits: 120
544
544
  - radix: 2
545
545
  - significand_digits: 96
@@ -549,7 +549,7 @@ CDC_DOUBLE:
549
549
  - decimal_digits_necessary: 30
550
550
  - decimal_min_exp: -279
551
551
  - decimal_max_exp: 322
552
- values:
552
+ values:
553
553
  - Rational(1, 3): AB AA AA AA AA AA 9E A3 AA AA AA AA AA EA 3C
554
554
  - Rational(1, 10): CD CC CC CC CC CC 9C C3 CC CC CC CC CC CC 3C
555
555
  - Rational(2, 3): AB AA AA AA AA AA 9F A3 AA AA AA AA AA FA 3C
@@ -557,13 +557,13 @@ CDC_DOUBLE:
557
557
  - Rational(1, 1000): AC 1C 5A 64 3B DF 96 F3 D4 78 E9 26 31 68 3C
558
558
  - Rational(1024, 1): 00 00 00 00 00 00 AA 03 00 00 00 00 00 A8 3D
559
559
  - Rational(1024, 1): 00 00 00 00 00 00 AA 03 00 00 00 00 00 A8 3D
560
- special:
560
+ special:
561
561
  - min_value: 00 00 00 00 00 00 00 00 00 00 00 00 00 08 03
562
562
  - min_normalized_value: 00 00 00 00 00 00 00 00 00 00 00 00 00 08 03
563
563
  - max_value: FF FF FF FF FF FF FF F7 FF FF FF FF FF FF 7F
564
564
  - epsilon: 00 00 00 00 00 00 41 03 00 00 00 00 00 18 37
565
565
  - strict_epsilon: 00 00 00 00 00 00 41 03 00 00 00 00 00 18 37
566
- numerals:
566
+ numerals:
567
567
  - "+0": 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
568
568
  - "-0": FF FF FF FF FF FF FF FF FF FF FF FF FF FF FF
569
569
  - "+1": 00 00 00 00 00 00 A0 03 00 00 00 00 00 08 3D
@@ -587,8 +587,8 @@ CDC_DOUBLE:
587
587
  - "2.5243548967072377773175314089E-29": 00 00 00 00 00 00 41 03 00 00 00 00 00 18 37
588
588
  - "2.5243548967072377773175314089E-29": 00 00 00 00 00 00 41 03 00 00 00 00 00 18 37
589
589
  base: :bytes
590
- PDP11_F:
591
- parameters:
590
+ PDP11_F:
591
+ parameters:
592
592
  - total_bits: 32
593
593
  - radix: 2
594
594
  - significand_digits: 24
@@ -598,7 +598,7 @@ PDP11_F:
598
598
  - decimal_digits_necessary: 9
599
599
  - decimal_min_exp: -38
600
600
  - decimal_max_exp: 38
601
- values:
601
+ values:
602
602
  - Rational(1, 3): AA 3F AB AA
603
603
  - Rational(1, 10): CC 3E CD CC
604
604
  - Rational(2, 3): 2A 40 AB AA
@@ -606,13 +606,13 @@ PDP11_F:
606
606
  - Rational(1, 1000): 83 3B 6F 12
607
607
  - Rational(1024, 1): 80 45 00 00
608
608
  - Rational(1024, 1): 80 45 00 00
609
- special:
609
+ special:
610
610
  - min_value: 00 00 01 00
611
611
  - min_normalized_value: 00 00 01 00
612
612
  - max_value: FF 7F FF FF
613
613
  - epsilon: 00 35 00 00
614
614
  - strict_epsilon: 00 35 00 00
615
- numerals:
615
+ numerals:
616
616
  - "+0": 00 00 00 00
617
617
  - "-0": 00 80 00 00
618
618
  - "+1": 80 40 00 00
@@ -636,8 +636,8 @@ PDP11_F:
636
636
  - "1.1920929E-7": 00 35 00 00
637
637
  - "1.1920929E-7": 00 35 00 00
638
638
  base: :bytes
639
- VAX_G:
640
- parameters:
639
+ VAX_G:
640
+ parameters:
641
641
  - total_bits: 64
642
642
  - radix: 2
643
643
  - significand_digits: 53
@@ -647,7 +647,7 @@ VAX_G:
647
647
  - decimal_digits_necessary: 17
648
648
  - decimal_min_exp: -307
649
649
  - decimal_max_exp: 308
650
- values:
650
+ values:
651
651
  - Rational(1, 3): F5 3F 55 55 55 55 55 55
652
652
  - Rational(1, 10): D9 3F 99 99 99 99 9A 99
653
653
  - Rational(2, 3): 05 40 55 55 55 55 55 55
@@ -655,13 +655,13 @@ VAX_G:
655
655
  - Rational(1, 1000): 70 3F 4D 62 F1 D2 FC A9
656
656
  - Rational(1024, 1): B0 40 00 00 00 00 00 00
657
657
  - Rational(1024, 1): B0 40 00 00 00 00 00 00
658
- special:
658
+ special:
659
659
  - min_value: 10 00 00 00 00 00 00 00
660
660
  - min_normalized_value: 10 00 00 00 00 00 00 00
661
661
  - max_value: FF 7F FF FF FF FF FF FF
662
662
  - epsilon: D0 3C 00 00 00 00 00 00
663
663
  - strict_epsilon: D0 3C 00 00 00 00 00 00
664
- numerals:
664
+ numerals:
665
665
  - "+0": 00 00 00 00 00 00 00 00
666
666
  - "-0": 00 80 00 00 00 00 00 00
667
667
  - "+1": 10 40 00 00 00 00 00 00
@@ -685,8 +685,8 @@ VAX_G:
685
685
  - "2.2204460492503131E-16": D0 3C 00 00 00 00 00 00
686
686
  - "2.2204460492503131E-16": D0 3C 00 00 00 00 00 00
687
687
  base: :bytes
688
- SATURN_X:
689
- parameters:
688
+ SATURN_X:
689
+ parameters:
690
690
  - total_bits: 104
691
691
  - radix: 10
692
692
  - significand_digits: 15
@@ -696,7 +696,7 @@ SATURN_X:
696
696
  - decimal_digits_necessary: 15
697
697
  - decimal_min_exp: -49999
698
698
  - decimal_max_exp: 49999
699
- values:
699
+ values:
700
700
  - Rational(1, 3): 03333333333333339999902955
701
701
  - Rational(1, 10): 01000000000000009999902955
702
702
  - Rational(2, 3): 06666666666666679999902955
@@ -704,13 +704,13 @@ SATURN_X:
704
704
  - Rational(1, 1000): 01000000000000009999702955
705
705
  - Rational(1024, 1): 01024000000000000000302955
706
706
  - Rational(1024, 1): 01024000000000000000302955
707
- special:
707
+ special:
708
708
  - min_value: 01000000000000005000102955
709
709
  - min_normalized_value: 01000000000000005000102955
710
710
  - max_value: 09999999999999994999902955
711
711
  - epsilon: 01000000000000009998602955
712
712
  - strict_epsilon: 05000000000000019998502955
713
- numerals:
713
+ numerals:
714
714
  - "+0": 00000000000000000000002955
715
715
  - "-0": "90000000000000000000002955"
716
716
  - "+1": 01000000000000000000002955
@@ -734,8 +734,8 @@ SATURN_X:
734
734
  - 1E-14: 01000000000000009998602955
735
735
  - "5.00000000000001E-15": 05000000000000019998502955
736
736
  base: 16
737
- SATURN:
738
- parameters:
737
+ SATURN:
738
+ parameters:
739
739
  - total_bits: 84
740
740
  - radix: 10
741
741
  - significand_digits: 12
@@ -745,7 +745,7 @@ SATURN:
745
745
  - decimal_digits_necessary: 12
746
746
  - decimal_min_exp: -499
747
747
  - decimal_max_exp: 499
748
- values:
748
+ values:
749
749
  - Rational(1, 3): 033333333333399902933
750
750
  - Rational(1, 10): 010000000000099902933
751
751
  - Rational(2, 3): 066666666666799902933
@@ -753,13 +753,13 @@ SATURN:
753
753
  - Rational(1, 1000): 010000000000099702933
754
754
  - Rational(1024, 1): 010240000000000302933
755
755
  - Rational(1024, 1): 010240000000000302933
756
- special:
756
+ special:
757
757
  - min_value: 010000000000050102933
758
758
  - min_normalized_value: 010000000000050102933
759
759
  - max_value: 099999999999949902933
760
760
  - epsilon: 010000000000098902933
761
761
  - strict_epsilon: 050000000000198802933
762
- numerals:
762
+ numerals:
763
763
  - "+0": 000000000000000002933
764
764
  - "-0": "900000000000000002933"
765
765
  - "+1": 010000000000000002933
@@ -783,8 +783,8 @@ SATURN:
783
783
  - 1E-11: 010000000000098902933
784
784
  - "5.00000000001E-12": 050000000000198802933
785
785
  base: 16
786
- VAX_H:
787
- parameters:
786
+ VAX_H:
787
+ parameters:
788
788
  - total_bits: 128
789
789
  - radix: 2
790
790
  - significand_digits: 113
@@ -794,7 +794,7 @@ VAX_H:
794
794
  - decimal_digits_necessary: 36
795
795
  - decimal_min_exp: -4931
796
796
  - decimal_max_exp: 4932
797
- values:
797
+ values:
798
798
  - Rational(1, 3): FF 3F 55 55 55 55 55 55 55 55 55 55 55 55 55 55
799
799
  - Rational(1, 10): FD 3F 99 99 99 99 99 99 99 99 99 99 99 99 9A 99
800
800
  - Rational(2, 3): 00 40 55 55 55 55 55 55 55 55 55 55 55 55 55 55
@@ -802,13 +802,13 @@ VAX_H:
802
802
  - Rational(1, 1000): F7 3F 24 06 2F DD 9F 1A 76 BE B4 C8 58 39 62 10
803
803
  - Rational(1024, 1): 0B 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00
804
804
  - Rational(1024, 1): 0B 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00
805
- special:
805
+ special:
806
806
  - min_value: 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
807
807
  - min_normalized_value: 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
808
808
  - max_value: FF 7F FF FF FF FF FF FF FF FF FF FF FF FF FF FF
809
809
  - epsilon: 91 3F 00 00 00 00 00 00 00 00 00 00 00 00 00 00
810
810
  - strict_epsilon: 91 3F 00 00 00 00 00 00 00 00 00 00 00 00 00 00
811
- numerals:
811
+ numerals:
812
812
  - "+0": 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
813
813
  - "-0": 00 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00
814
814
  - "+1": 01 40 00 00 00 00 00 00 00 00 00 00 00 00 00 00
@@ -832,8 +832,8 @@ VAX_H:
832
832
  - "1.92592994438723585305597794258492732E-34": 91 3F 00 00 00 00 00 00 00 00 00 00 00 00 00 00
833
833
  - "1.92592994438723585305597794258492732E-34": 91 3F 00 00 00 00 00 00 00 00 00 00 00 00 00 00
834
834
  base: :bytes
835
- MBF_SINGLE:
836
- parameters:
835
+ MBF_SINGLE:
836
+ parameters:
837
837
  - total_bits: 32
838
838
  - radix: 2
839
839
  - significand_digits: 24
@@ -843,7 +843,7 @@ MBF_SINGLE:
843
843
  - decimal_digits_necessary: 9
844
844
  - decimal_min_exp: -38
845
845
  - decimal_max_exp: 38
846
- values:
846
+ values:
847
847
  - Rational(1, 3): AB AA 2A 7F
848
848
  - Rational(1, 10): CD CC 4C 7D
849
849
  - Rational(2, 3): AB AA 2A 80
@@ -851,13 +851,13 @@ MBF_SINGLE:
851
851
  - Rational(1, 1000): 6F 12 03 77
852
852
  - Rational(1024, 1): 00 00 00 8B
853
853
  - Rational(1024, 1): 00 00 00 8B
854
- special:
854
+ special:
855
855
  - min_value: 00 00 00 01
856
856
  - min_normalized_value: 00 00 00 01
857
857
  - max_value: FF FF 7F FF
858
858
  - epsilon: 00 00 00 6A
859
859
  - strict_epsilon: 00 00 00 6A
860
- numerals:
860
+ numerals:
861
861
  - "+0": 00 00 00 00
862
862
  - "-0": 00 00 80 00
863
863
  - "+1": 00 00 00 81
@@ -881,8 +881,8 @@ MBF_SINGLE:
881
881
  - "1.1920929E-7": 00 00 00 6A
882
882
  - "1.1920929E-7": 00 00 00 6A
883
883
  base: :bytes
884
- HP_CLASSIC:
885
- parameters:
884
+ HP_CLASSIC:
885
+ parameters:
886
886
  - total_bits: 56
887
887
  - radix: 10
888
888
  - significand_digits: 10
@@ -892,7 +892,7 @@ HP_CLASSIC:
892
892
  - decimal_digits_necessary: 10
893
893
  - decimal_min_exp: -99
894
894
  - decimal_max_exp: 99
895
- values:
895
+ values:
896
896
  - Rational(1, 3): 03 33 33 33 33 39 99
897
897
  - Rational(1, 10): 01 00 00 00 00 09 99
898
898
  - Rational(2, 3): 06 66 66 66 66 79 99
@@ -900,13 +900,13 @@ HP_CLASSIC:
900
900
  - Rational(1, 1000): 01 00 00 00 00 09 97
901
901
  - Rational(1024, 1): 01 02 40 00 00 00 03
902
902
  - Rational(1024, 1): 01 02 40 00 00 00 03
903
- special:
903
+ special:
904
904
  - min_value: 01 00 00 00 00 09 01
905
905
  - min_normalized_value: 01 00 00 00 00 09 01
906
906
  - max_value: 09 99 99 99 99 90 99
907
907
  - epsilon: 01 00 00 00 00 09 91
908
908
  - strict_epsilon: 05 00 00 00 00 09 90
909
- numerals:
909
+ numerals:
910
910
  - "+0": 00 00 00 00 00 00 00
911
911
  - "-0": 90 00 00 00 00 00 00
912
912
  - "+1": 01 00 00 00 00 00 00
@@ -930,8 +930,8 @@ HP_CLASSIC:
930
930
  - 1E-9: 01 00 00 00 00 09 91
931
931
  - 5E-10: 05 00 00 00 00 09 90
932
932
  base: :bytes
933
- C51_BCD_LONG_DOUBLE:
934
- parameters:
933
+ C51_BCD_LONG_DOUBLE:
934
+ parameters:
935
935
  - total_bits: 56
936
936
  - radix: 10
937
937
  - significand_digits: 12
@@ -941,7 +941,7 @@ C51_BCD_LONG_DOUBLE:
941
941
  - decimal_digits_necessary: 12
942
942
  - decimal_min_exp: -65
943
943
  - decimal_max_exp: 62
944
- values:
944
+ values:
945
945
  - Rational(1, 3): 40 33 33 33 33 33 33
946
946
  - Rational(1, 10): 40 00 00 00 00 00 10
947
947
  - Rational(2, 3): 40 67 66 66 66 66 66
@@ -949,13 +949,13 @@ C51_BCD_LONG_DOUBLE:
949
949
  - Rational(1, 1000): 3E 00 00 00 00 00 10
950
950
  - Rational(1024, 1): 44 00 00 00 00 24 10
951
951
  - Rational(1024, 1): 44 00 00 00 00 24 10
952
- special:
952
+ special:
953
953
  - min_value: 00 00 00 00 00 00 10
954
954
  - min_normalized_value: 00 00 00 00 00 00 10
955
955
  - max_value: 7F 99 99 99 99 99 99
956
956
  - epsilon: 36 00 00 00 00 00 10
957
957
  - strict_epsilon: 36 00 00 00 00 00 10
958
- numerals:
958
+ numerals:
959
959
  - "+0": 00 00 00 00 00 00 00
960
960
  - "-0": 80 00 00 00 00 00 00
961
961
  - "+1": 41 00 00 00 00 00 10
@@ -979,8 +979,8 @@ C51_BCD_LONG_DOUBLE:
979
979
  - 1E-11: 36 00 00 00 00 00 10
980
980
  - 1E-11: 36 00 00 00 00 00 10
981
981
  base: :bytes
982
- IEEE_DEC128:
983
- parameters:
982
+ IEEE_DEC128:
983
+ parameters:
984
984
  - total_bits: 128
985
985
  - radix: 10
986
986
  - significand_digits: 34
@@ -990,7 +990,7 @@ IEEE_DEC128:
990
990
  - decimal_digits_necessary: 34
991
991
  - decimal_min_exp: -6143
992
992
  - decimal_max_exp: 6144
993
- values:
993
+ values:
994
994
  - Rational(1, 3): 2D FF 9B 36 CD B3 6C DB 36 CD B3 6C DB 36 CD B3
995
995
  - Rational(1, 10): 22 07 C0 00 00 00 00 00 00 00 00 00 00 00 00 01
996
996
  - Rational(2, 3): 39 FF B6 6D 9B 66 D9 B6 6D 9B 66 D9 B6 6D 9B 67
@@ -998,13 +998,13 @@ IEEE_DEC128:
998
998
  - Rational(1, 1000): 22 07 40 00 00 00 00 00 00 00 00 00 00 00 00 01
999
999
  - Rational(1024, 1): 22 08 00 00 00 00 00 00 00 00 00 00 00 00 04 24
1000
1000
  - Rational(1024, 1): 22 08 00 00 00 00 00 00 00 00 00 00 00 00 04 24
1001
- special:
1001
+ special:
1002
1002
  - min_value: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 01
1003
1003
  - min_normalized_value: 04 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1004
1004
  - max_value: 77 FF CF F3 FC FF 3F CF F3 FC FF 3F CF F3 FC FF
1005
1005
  - epsilon: 25 F7 80 00 00 00 00 00 00 00 00 00 00 00 00 00
1006
1006
  - strict_epsilon: 35 F7 40 00 00 00 00 00 00 00 00 00 00 00 00 01
1007
- numerals:
1007
+ numerals:
1008
1008
  - "+0": 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1009
1009
  - "-0": 80 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1010
1010
  - "+1": 22 08 00 00 00 00 00 00 00 00 00 00 00 00 00 01
@@ -1028,8 +1028,8 @@ IEEE_DEC128:
1028
1028
  - 1E-33: 21 FF C0 00 00 00 00 00 00 00 00 00 00 00 00 01
1029
1029
  - 1E-33: 21 FF C0 00 00 00 00 00 00 00 00 00 00 00 00 01
1030
1030
  base: :bytes
1031
- XS256:
1032
- parameters:
1031
+ XS256:
1032
+ parameters:
1033
1033
  - total_bits: 32
1034
1034
  - radix: 2
1035
1035
  - significand_digits: 23
@@ -1039,7 +1039,7 @@ XS256:
1039
1039
  - decimal_digits_necessary: 8
1040
1040
  - decimal_min_exp: -76
1041
1041
  - decimal_max_exp: 77
1042
- values:
1042
+ values:
1043
1043
  - Rational(1, 3): 3F 95 55 55
1044
1044
  - Rational(1, 10): 3F 26 66 66
1045
1045
  - Rational(2, 3): 3F D5 55 55
@@ -1047,13 +1047,13 @@ XS256:
1047
1047
  - Rational(1, 1000): 3D 81 89 37
1048
1048
  - Rational(1024, 1): 42 80 00 00
1049
1049
  - Rational(1024, 1): 42 80 00 00
1050
- special:
1050
+ special:
1051
1051
  - min_value: 00 00 00 01
1052
1052
  - min_normalized_value: 00 00 00 01
1053
1053
  - max_value: 7F FF FF FF
1054
1054
  - epsilon: 3A 80 00 00
1055
1055
  - strict_epsilon: 3A 40 00 00
1056
- numerals:
1056
+ numerals:
1057
1057
  - "+0": 00 00 00 00
1058
1058
  - "-0": 80 00 00 00
1059
1059
  - "+1": 40 00 00 00
@@ -1077,8 +1077,8 @@ XS256:
1077
1077
  - "2.3841858E-7": 3A 80 00 00
1078
1078
  - "1.1920929E-7": 3A 40 00 00
1079
1079
  base: :bytes
1080
- IEEE_EXTENDED:
1081
- parameters:
1080
+ IEEE_EXTENDED:
1081
+ parameters:
1082
1082
  - total_bits: 80
1083
1083
  - radix: 2
1084
1084
  - significand_digits: 64
@@ -1088,7 +1088,7 @@ IEEE_EXTENDED:
1088
1088
  - decimal_digits_necessary: 21
1089
1089
  - decimal_min_exp: -4931
1090
1090
  - decimal_max_exp: 4932
1091
- values:
1091
+ values:
1092
1092
  - Rational(1, 3): AB AA AA AA AA AA AA AA FD 3F
1093
1093
  - Rational(1, 10): CD CC CC CC CC CC CC CC FB 3F
1094
1094
  - Rational(2, 3): AB AA AA AA AA AA AA AA FE 3F
@@ -1096,13 +1096,13 @@ IEEE_EXTENDED:
1096
1096
  - Rational(1, 1000): 3B DF 4F 8D 97 6E 12 83 F5 3F
1097
1097
  - Rational(1024, 1): 00 00 00 00 00 00 00 80 09 40
1098
1098
  - Rational(1024, 1): 00 00 00 00 00 00 00 80 09 40
1099
- special:
1099
+ special:
1100
1100
  - min_value: 01 00 00 00 00 00 00 00 00 00
1101
1101
  - min_normalized_value: 00 00 00 00 00 00 00 80 01 00
1102
1102
  - max_value: FF FF FF FF FF FF FF FF FE 7F
1103
1103
  - epsilon: 00 00 00 00 00 00 00 80 C0 3F
1104
1104
  - strict_epsilon: 01 00 00 00 00 00 00 80 BF 3F
1105
- numerals:
1105
+ numerals:
1106
1106
  - "+0": 00 00 00 00 00 00 00 00 00 00
1107
1107
  - "-0": 00 00 00 00 00 00 00 00 00 80
1108
1108
  - "+1": 00 00 00 00 00 00 00 80 FF 3F
@@ -1126,8 +1126,8 @@ IEEE_EXTENDED:
1126
1126
  - "1.08420217248550443401E-19": 00 00 00 00 00 00 00 80 C0 3F
1127
1127
  - "5.42101086242752217063E-20": 01 00 00 00 00 00 00 80 BF 3F
1128
1128
  base: :bytes
1129
- WANG2200:
1130
- parameters:
1129
+ WANG2200:
1130
+ parameters:
1131
1131
  - total_bits: 64
1132
1132
  - radix: 10
1133
1133
  - significand_digits: 13
@@ -1137,7 +1137,7 @@ WANG2200:
1137
1137
  - decimal_digits_necessary: 13
1138
1138
  - decimal_min_exp: -99
1139
1139
  - decimal_max_exp: 99
1140
- values:
1140
+ values:
1141
1141
  - Rational(1, 3): 33 33 33 33 33 33 03 81
1142
1142
  - Rational(1, 10): 00 00 00 00 00 00 01 81
1143
1143
  - Rational(2, 3): 67 66 66 66 66 66 06 81
@@ -1145,13 +1145,13 @@ WANG2200:
1145
1145
  - Rational(1, 1000): 00 00 00 00 00 00 01 83
1146
1146
  - Rational(1024, 1): 00 00 00 00 40 02 01 03
1147
1147
  - Rational(1024, 1): 00 00 00 00 40 02 01 03
1148
- special:
1148
+ special:
1149
1149
  - min_value: 00 00 00 00 00 00 91 89
1150
1150
  - min_normalized_value: 00 00 00 00 00 00 91 89
1151
1151
  - max_value: 99 99 99 99 99 99 99 09
1152
1152
  - epsilon: 00 00 00 00 00 00 11 82
1153
1153
  - strict_epsilon: 00 00 00 00 00 00 11 82
1154
- numerals:
1154
+ numerals:
1155
1155
  - "+0": 00 00 00 00 00 00 00 00
1156
1156
  - "-0": 00 00 00 00 00 00 00 10
1157
1157
  - "+1": 00 00 00 00 00 00 01 00
@@ -1175,8 +1175,8 @@ WANG2200:
1175
1175
  - 1E-12: 00 00 00 00 00 00 11 82
1176
1176
  - 1E-12: 00 00 00 00 00 00 11 82
1177
1177
  base: :bytes
1178
- CRAY:
1179
- parameters:
1178
+ CRAY:
1179
+ parameters:
1180
1180
  - total_bits: 64
1181
1181
  - radix: 2
1182
1182
  - significand_digits: 48
@@ -1186,7 +1186,7 @@ CRAY:
1186
1186
  - decimal_digits_necessary: 16
1187
1187
  - decimal_min_exp: -2466
1188
1188
  - decimal_max_exp: 2466
1189
- values:
1189
+ values:
1190
1190
  - Rational(1, 3): 3F FF AA AA AA AA AA AB
1191
1191
  - Rational(1, 10): 3F FD CC CC CC CC CC CD
1192
1192
  - Rational(2, 3): 40 00 AA AA AA AA AA AB
@@ -1194,13 +1194,13 @@ CRAY:
1194
1194
  - Rational(1, 1000): 3F F7 83 12 6E 97 8D 50
1195
1195
  - Rational(1024, 1): 40 0B 80 00 00 00 00 00
1196
1196
  - Rational(1024, 1): 40 0B 80 00 00 00 00 00
1197
- special:
1197
+ special:
1198
1198
  - min_value: 20 00 80 00 00 00 00 00
1199
1199
  - min_normalized_value: 20 00 80 00 00 00 00 00
1200
1200
  - max_value: 5F FF FF FF FF FF FF FF
1201
1201
  - epsilon: 3F D2 80 00 00 00 00 00
1202
1202
  - strict_epsilon: 3F D2 80 00 00 00 00 00
1203
- numerals:
1203
+ numerals:
1204
1204
  - "+0": 00 00 00 00 00 00 00 00
1205
1205
  - "-0": 80 00 00 00 00 00 00 00
1206
1206
  - "+1": 40 01 80 00 00 00 00 00
@@ -1224,8 +1224,8 @@ CRAY:
1224
1224
  - "7.105427357601002E-15": 3F D2 80 00 00 00 00 00
1225
1225
  - "7.105427357601002E-15": 3F D2 80 00 00 00 00 00
1226
1226
  base: :bytes
1227
- IBM128:
1228
- parameters:
1227
+ IBM128:
1228
+ parameters:
1229
1229
  - total_bits: 128
1230
1230
  - radix: 16
1231
1231
  - significand_digits: 28
@@ -1235,7 +1235,7 @@ IBM128:
1235
1235
  - decimal_digits_necessary: 35
1236
1236
  - decimal_min_exp: -60
1237
1237
  - decimal_max_exp: 77
1238
- values:
1238
+ values:
1239
1239
  - Rational(1, 3): 40 55 55 55 55 55 55 55 32 55 55 55 55 55 55 55
1240
1240
  - Rational(1, 10): 40 19 99 99 99 99 99 99 32 99 99 99 99 99 99 9A
1241
1241
  - Rational(2, 3): 40 AA AA AA AA AA AA AA 32 AA AA AA AA AA AA AB
@@ -1243,13 +1243,13 @@ IBM128:
1243
1243
  - Rational(1, 1000): 3E 41 89 37 4B C6 A7 EF 30 9D B2 2D 0E 56 04 19
1244
1244
  - Rational(1024, 1): 43 40 00 00 00 00 00 00 35 00 00 00 00 00 00 00
1245
1245
  - Rational(1024, 1): 43 40 00 00 00 00 00 00 35 00 00 00 00 00 00 00
1246
- special:
1246
+ special:
1247
1247
  - min_value: 0E 10 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1248
1248
  - min_normalized_value: 0E 10 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1249
1249
  - max_value: 7F FF FF FF FF FF FF FF 7F FF FF FF FF FF FF FF
1250
1250
  - epsilon: 26 10 00 00 00 00 00 00 18 00 00 00 00 00 00 00
1251
1251
  - strict_epsilon: 26 10 00 00 00 00 00 00 18 00 00 00 00 00 00 00
1252
- numerals:
1252
+ numerals:
1253
1253
  - "+0": 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
1254
1254
  - "-0": 80 00 00 00 00 00 00 00 80 00 00 00 00 00 00 00
1255
1255
  - "+1": 41 10 00 00 00 00 00 00 33 00 00 00 00 00 00 00
@@ -1273,8 +1273,8 @@ IBM128:
1273
1273
  - "3.0814879110195773648895647081358837E-33": 26 10 00 00 00 00 00 00 18 00 00 00 00 00 00 00
1274
1274
  - "3.0814879110195773648895647081358837E-33": 26 10 00 00 00 00 00 00 18 00 00 00 00 00 00 00
1275
1275
  base: :bytes
1276
- IEEE_DEC64:
1277
- parameters:
1276
+ IEEE_DEC64:
1277
+ parameters:
1278
1278
  - total_bits: 64
1279
1279
  - radix: 10
1280
1280
  - significand_digits: 16
@@ -1284,7 +1284,7 @@ IEEE_DEC64:
1284
1284
  - decimal_digits_necessary: 16
1285
1285
  - decimal_min_exp: -383
1286
1286
  - decimal_max_exp: 384
1287
- values:
1287
+ values:
1288
1288
  - Rational(1, 3): 2D F9 B3 6C DB 36 CD B3
1289
1289
  - Rational(1, 10): 22 34 00 00 00 00 00 01
1290
1290
  - Rational(2, 3): 39 FB 66 D9 B6 6D 9B 67
@@ -1292,13 +1292,13 @@ IEEE_DEC64:
1292
1292
  - Rational(1, 1000): 22 2C 00 00 00 00 00 01
1293
1293
  - Rational(1024, 1): 22 38 00 00 00 00 04 24
1294
1294
  - Rational(1024, 1): 22 38 00 00 00 00 04 24
1295
- special:
1295
+ special:
1296
1296
  - min_value: 00 00 00 00 00 00 00 01
1297
1297
  - min_normalized_value: 04 00 00 00 00 00 00 00
1298
1298
  - max_value: 77 FC FF 3F CF F3 FC FF
1299
1299
  - epsilon: 25 C0 00 00 00 00 00 00
1300
1300
  - strict_epsilon: 35 BC 00 00 00 00 00 01
1301
- numerals:
1301
+ numerals:
1302
1302
  - "+0": 00 00 00 00 00 00 00 00
1303
1303
  - "-0": 80 00 00 00 00 00 00 00
1304
1304
  - "+1": 22 38 00 00 00 00 00 01
@@ -1322,8 +1322,8 @@ IEEE_DEC64:
1322
1322
  - 1E-15: 21 FC 00 00 00 00 00 01
1323
1323
  - 1E-15: 21 FC 00 00 00 00 00 01
1324
1324
  base: :bytes
1325
- APPLE:
1326
- parameters:
1325
+ APPLE:
1326
+ parameters:
1327
1327
  - total_bits: 32
1328
1328
  - radix: 2
1329
1329
  - significand_digits: 23
@@ -1333,7 +1333,7 @@ APPLE:
1333
1333
  - decimal_digits_necessary: 8
1334
1334
  - decimal_min_exp: -38
1335
1335
  - decimal_max_exp: 38
1336
- values:
1336
+ values:
1337
1337
  - Rational(1, 3): 7E 55 55 55
1338
1338
  - Rational(1, 10): 7C 66 66 66
1339
1339
  - Rational(2, 3): 7F 55 55 55
@@ -1341,13 +1341,13 @@ APPLE:
1341
1341
  - Rational(1, 1000): 76 41 89 37
1342
1342
  - Rational(1024, 1): 8A 40 00 00
1343
1343
  - Rational(1024, 1): 8A 40 00 00
1344
- special:
1344
+ special:
1345
1345
  - min_value: 00 00 00 01
1346
1346
  - min_normalized_value: 00 40 00 00
1347
1347
  - max_value: FF 7F FF FF
1348
1348
  - epsilon: 6A 40 00 00
1349
1349
  - strict_epsilon: 6A 40 00 00
1350
- numerals:
1350
+ numerals:
1351
1351
  - "+0": 00 00 00 00
1352
1352
  - "-0": 00 80 00 00
1353
1353
  - "+1": 80 40 00 00
@@ -1371,8 +1371,8 @@ APPLE:
1371
1371
  - "2.3841858E-7": 6A 40 00 00
1372
1372
  - "2.3841858E-7": 6A 40 00 00
1373
1373
  base: :bytes
1374
- IEEE_DEC32:
1375
- parameters:
1374
+ IEEE_DEC32:
1375
+ parameters:
1376
1376
  - total_bits: 32
1377
1377
  - radix: 10
1378
1378
  - significand_digits: 7
@@ -1382,7 +1382,7 @@ IEEE_DEC32:
1382
1382
  - decimal_digits_necessary: 7
1383
1383
  - decimal_min_exp: -95
1384
1384
  - decimal_max_exp: 96
1385
- values:
1385
+ values:
1386
1386
  - Rational(1, 3): 2D E6 CD B3
1387
1387
  - Rational(1, 10): 22 40 00 01
1388
1388
  - Rational(2, 3): 39 ED 9B 67
@@ -1390,13 +1390,13 @@ IEEE_DEC32:
1390
1390
  - Rational(1, 1000): 22 20 00 01
1391
1391
  - Rational(1024, 1): 22 50 04 24
1392
1392
  - Rational(1024, 1): 22 50 04 24
1393
- special:
1393
+ special:
1394
1394
  - min_value: 00 00 00 01
1395
1395
  - min_normalized_value: 04 00 00 00
1396
1396
  - max_value: 77 F3 FC FF
1397
1397
  - epsilon: 25 90 00 00
1398
1398
  - strict_epsilon: 35 80 00 01
1399
- numerals:
1399
+ numerals:
1400
1400
  - "+0": 00 00 00 00
1401
1401
  - "-0": 80 00 00 00
1402
1402
  - "+1": 22 50 00 01
@@ -1420,8 +1420,8 @@ IEEE_DEC32:
1420
1420
  - 1E-6: 21 F0 00 01
1421
1421
  - 1E-6: 21 F0 00 01
1422
1422
  base: :bytes
1423
- CDC_SINGLE:
1424
- parameters:
1423
+ CDC_SINGLE:
1424
+ parameters:
1425
1425
  - total_bits: 60
1426
1426
  - radix: 2
1427
1427
  - significand_digits: 48
@@ -1431,7 +1431,7 @@ CDC_SINGLE:
1431
1431
  - decimal_digits_necessary: 16
1432
1432
  - decimal_min_exp: -293
1433
1433
  - decimal_max_exp: 322
1434
- values:
1434
+ values:
1435
1435
  - Rational(1, 3): 3CEAAAAAAAAAAAB
1436
1436
  - Rational(1, 10): 3CCCCCCCCCCCCCD
1437
1437
  - Rational(2, 3): 3CFAAAAAAAAAAAB
@@ -1439,13 +1439,13 @@ CDC_SINGLE:
1439
1439
  - Rational(1, 1000): 3C683126E978D50
1440
1440
  - Rational(1024, 1): 3DA800000000000
1441
1441
  - Rational(1024, 1): 3DA800000000000
1442
- special:
1442
+ special:
1443
1443
  - min_value: 000800000000000
1444
1444
  - min_normalized_value: 000800000000000
1445
1445
  - max_value: 7FFFFFFFFFFFFFF
1446
1446
  - epsilon: 3A1800000000000
1447
1447
  - strict_epsilon: 3A1800000000000
1448
- numerals:
1448
+ numerals:
1449
1449
  - "+0": "000000000000000"
1450
1450
  - "-0": FFFFFFFFFFFFFFF
1451
1451
  - "+1": 3D0800000000000
@@ -1469,8 +1469,8 @@ CDC_SINGLE:
1469
1469
  - "7.105427357601002E-15": 3A1800000000000
1470
1470
  - "7.105427357601002E-15": 3A1800000000000
1471
1471
  base: 16
1472
- UNIVAC_SINGLE:
1473
- parameters:
1472
+ UNIVAC_SINGLE:
1473
+ parameters:
1474
1474
  - total_bits: 36
1475
1475
  - radix: 2
1476
1476
  - significand_digits: 27
@@ -1480,7 +1480,7 @@ UNIVAC_SINGLE:
1480
1480
  - decimal_digits_necessary: 10
1481
1481
  - decimal_min_exp: -38
1482
1482
  - decimal_max_exp: 38
1483
- values:
1483
+ values:
1484
1484
  - Rational(1, 3): 3FD555555
1485
1485
  - Rational(1, 10): 3EE666666
1486
1486
  - Rational(2, 3): "405555555"
@@ -1488,13 +1488,13 @@ UNIVAC_SINGLE:
1488
1488
  - Rational(1, 1000): 3BC189375
1489
1489
  - Rational(1024, 1): 45C000000
1490
1490
  - Rational(1024, 1): 45C000000
1491
- special:
1491
+ special:
1492
1492
  - min_value: "004000000"
1493
1493
  - min_normalized_value: "004000000"
1494
1494
  - max_value: 7FFFFFFFF
1495
1495
  - epsilon: 33C000000
1496
1496
  - strict_epsilon: 33C000000
1497
- numerals:
1497
+ numerals:
1498
1498
  - "+0": "000000000"
1499
1499
  - "-0": FFFFFFFFF
1500
1500
  - "+1": 40C000000
@@ -1518,8 +1518,8 @@ UNIVAC_SINGLE:
1518
1518
  - "1.490116119E-8": 33C000000
1519
1519
  - "1.490116119E-8": 33C000000
1520
1520
  base: 16
1521
- MBF_DOUBLE:
1522
- parameters:
1521
+ MBF_DOUBLE:
1522
+ parameters:
1523
1523
  - total_bits: 64
1524
1524
  - radix: 2
1525
1525
  - significand_digits: 56
@@ -1529,7 +1529,7 @@ MBF_DOUBLE:
1529
1529
  - decimal_digits_necessary: 18
1530
1530
  - decimal_min_exp: -38
1531
1531
  - decimal_max_exp: 38
1532
- values:
1532
+ values:
1533
1533
  - Rational(1, 3): AB AA AA AA AA AA 2A 7F
1534
1534
  - Rational(1, 10): CD CC CC CC CC CC 4C 7D
1535
1535
  - Rational(2, 3): AB AA AA AA AA AA 2A 80
@@ -1537,13 +1537,13 @@ MBF_DOUBLE:
1537
1537
  - Rational(1, 1000): DF 4F 8D 97 6E 12 03 77
1538
1538
  - Rational(1024, 1): 00 00 00 00 00 00 00 8B
1539
1539
  - Rational(1024, 1): 00 00 00 00 00 00 00 8B
1540
- special:
1540
+ special:
1541
1541
  - min_value: 00 00 00 00 00 00 00 01
1542
1542
  - min_normalized_value: 00 00 00 00 00 00 00 01
1543
1543
  - max_value: FF FF FF FF FF FF 7F FF
1544
1544
  - epsilon: 00 00 00 00 00 00 00 4A
1545
1545
  - strict_epsilon: 00 00 00 00 00 00 00 4A
1546
- numerals:
1546
+ numerals:
1547
1547
  - "+0": 00 00 00 00 00 00 00 00
1548
1548
  - "-0": 00 00 00 00 00 00 80 00
1549
1549
  - "+1": 00 00 00 00 00 00 00 81
@@ -1567,8 +1567,8 @@ MBF_DOUBLE:
1567
1567
  - "2.77555756156289135E-17": 00 00 00 00 00 00 00 4A
1568
1568
  - "2.77555756156289135E-17": 00 00 00 00 00 00 00 4A
1569
1569
  base: :bytes
1570
- BORLAND48:
1571
- parameters:
1570
+ BORLAND48:
1571
+ parameters:
1572
1572
  - total_bits: 48
1573
1573
  - radix: 2
1574
1574
  - significand_digits: 40
@@ -1578,7 +1578,7 @@ BORLAND48:
1578
1578
  - decimal_digits_necessary: 14
1579
1579
  - decimal_min_exp: -38
1580
1580
  - decimal_max_exp: 38
1581
- values:
1581
+ values:
1582
1582
  - Rational(1, 3): 7F AB AA AA AA 2A
1583
1583
  - Rational(1, 10): 7D CD CC CC CC 4C
1584
1584
  - Rational(2, 3): 80 AB AA AA AA 2A
@@ -1586,13 +1586,13 @@ BORLAND48:
1586
1586
  - Rational(1, 1000): 77 8D 97 6E 12 03
1587
1587
  - Rational(1024, 1): 8B 00 00 00 00 00
1588
1588
  - Rational(1024, 1): 8B 00 00 00 00 00
1589
- special:
1589
+ special:
1590
1590
  - min_value: 01 00 00 00 00 00
1591
1591
  - min_normalized_value: 01 00 00 00 00 00
1592
1592
  - max_value: FF FF FF FF FF 7F
1593
1593
  - epsilon: 5A 00 00 00 00 00
1594
1594
  - strict_epsilon: 5A 00 00 00 00 00
1595
- numerals:
1595
+ numerals:
1596
1596
  - "+0": 00 00 00 00 00 00
1597
1597
  - "-0": 00 00 00 00 00 80
1598
1598
  - "+1": 81 00 00 00 00 00
@@ -1616,8 +1616,8 @@ BORLAND48:
1616
1616
  - "1.8189894035459E-12": 5A 00 00 00 00 00
1617
1617
  - "1.8189894035459E-12": 5A 00 00 00 00 00
1618
1618
  base: :bytes
1619
- XS128:
1620
- parameters:
1619
+ XS128:
1620
+ parameters:
1621
1621
  - total_bits: 40
1622
1622
  - radix: 2
1623
1623
  - significand_digits: 32
@@ -1627,7 +1627,7 @@ XS128:
1627
1627
  - decimal_digits_necessary: 11
1628
1628
  - decimal_min_exp: -38
1629
1629
  - decimal_max_exp: 38
1630
- values:
1630
+ values:
1631
1631
  - Rational(1, 3): 7F 2A AA AA AB
1632
1632
  - Rational(1, 10): 7D 4C CC CC CD
1633
1633
  - Rational(2, 3): 80 2A AA AA AB
@@ -1635,13 +1635,13 @@ XS128:
1635
1635
  - Rational(1, 1000): 77 03 12 6E 98
1636
1636
  - Rational(1024, 1): 8B 00 00 00 00
1637
1637
  - Rational(1024, 1): 8B 00 00 00 00
1638
- special:
1638
+ special:
1639
1639
  - min_value: 01 00 00 00 00
1640
1640
  - min_normalized_value: 01 00 00 00 00
1641
1641
  - max_value: FF 7F FF FF FF
1642
1642
  - epsilon: 62 00 00 00 00
1643
1643
  - strict_epsilon: 61 00 00 00 00
1644
- numerals:
1644
+ numerals:
1645
1645
  - "+0": 00 00 00 00 00
1646
1646
  - "-0": 00 80 00 00 00
1647
1647
  - "+1": 81 00 00 00 00