dqNextMinus.decTest 8.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126
  1. ------------------------------------------------------------------------
  2. -- dqNextMinus.decTest -- decQuad next that is less [754r nextdown] --
  3. -- Copyright (c) IBM Corporation, 1981, 2008. All rights reserved. --
  4. ------------------------------------------------------------------------
  5. -- Please see the document "General Decimal Arithmetic Testcases" --
  6. -- at http://www2.hursley.ibm.com/decimal for the description of --
  7. -- these testcases. --
  8. -- --
  9. -- These testcases are experimental ('beta' versions), and they --
  10. -- may contain errors. They are offered on an as-is basis. In --
  11. -- particular, achieving the same results as the tests here is not --
  12. -- a guarantee that an implementation complies with any Standard --
  13. -- or specification. The tests are not exhaustive. --
  14. -- --
  15. -- Please send comments, suggestions, and corrections to the author: --
  16. -- Mike Cowlishaw, IBM Fellow --
  17. -- IBM UK, PO Box 31, Birmingham Road, Warwick CV34 5JL, UK --
  18. -- mfc@uk.ibm.com --
  19. ------------------------------------------------------------------------
  20. version: 2.59
  21. -- All operands and results are decQuads.
  22. extended: 1
  23. clamp: 1
  24. precision: 34
  25. maxExponent: 6144
  26. minExponent: -6143
  27. rounding: half_even
  28. dqnextm001 nextminus 0.9999999999999999999999999999999995 -> 0.9999999999999999999999999999999994
  29. dqnextm002 nextminus 0.9999999999999999999999999999999996 -> 0.9999999999999999999999999999999995
  30. dqnextm003 nextminus 0.9999999999999999999999999999999997 -> 0.9999999999999999999999999999999996
  31. dqnextm004 nextminus 0.9999999999999999999999999999999998 -> 0.9999999999999999999999999999999997
  32. dqnextm005 nextminus 0.9999999999999999999999999999999999 -> 0.9999999999999999999999999999999998
  33. dqnextm006 nextminus 1.000000000000000000000000000000000 -> 0.9999999999999999999999999999999999
  34. dqnextm007 nextminus 1.0 -> 0.9999999999999999999999999999999999
  35. dqnextm008 nextminus 1 -> 0.9999999999999999999999999999999999
  36. dqnextm009 nextminus 1.000000000000000000000000000000001 -> 1.000000000000000000000000000000000
  37. dqnextm010 nextminus 1.000000000000000000000000000000002 -> 1.000000000000000000000000000000001
  38. dqnextm011 nextminus 1.000000000000000000000000000000003 -> 1.000000000000000000000000000000002
  39. dqnextm012 nextminus 1.000000000000000000000000000000004 -> 1.000000000000000000000000000000003
  40. dqnextm013 nextminus 1.000000000000000000000000000000005 -> 1.000000000000000000000000000000004
  41. dqnextm014 nextminus 1.000000000000000000000000000000006 -> 1.000000000000000000000000000000005
  42. dqnextm015 nextminus 1.000000000000000000000000000000007 -> 1.000000000000000000000000000000006
  43. dqnextm016 nextminus 1.000000000000000000000000000000008 -> 1.000000000000000000000000000000007
  44. dqnextm017 nextminus 1.000000000000000000000000000000009 -> 1.000000000000000000000000000000008
  45. dqnextm018 nextminus 1.000000000000000000000000000000010 -> 1.000000000000000000000000000000009
  46. dqnextm019 nextminus 1.000000000000000000000000000000011 -> 1.000000000000000000000000000000010
  47. dqnextm020 nextminus 1.000000000000000000000000000000012 -> 1.000000000000000000000000000000011
  48. dqnextm021 nextminus -0.9999999999999999999999999999999995 -> -0.9999999999999999999999999999999996
  49. dqnextm022 nextminus -0.9999999999999999999999999999999996 -> -0.9999999999999999999999999999999997
  50. dqnextm023 nextminus -0.9999999999999999999999999999999997 -> -0.9999999999999999999999999999999998
  51. dqnextm024 nextminus -0.9999999999999999999999999999999998 -> -0.9999999999999999999999999999999999
  52. dqnextm025 nextminus -0.9999999999999999999999999999999999 -> -1.000000000000000000000000000000000
  53. dqnextm026 nextminus -1.000000000000000000000000000000000 -> -1.000000000000000000000000000000001
  54. dqnextm027 nextminus -1.0 -> -1.000000000000000000000000000000001
  55. dqnextm028 nextminus -1 -> -1.000000000000000000000000000000001
  56. dqnextm029 nextminus -1.000000000000000000000000000000001 -> -1.000000000000000000000000000000002
  57. dqnextm030 nextminus -1.000000000000000000000000000000002 -> -1.000000000000000000000000000000003
  58. dqnextm031 nextminus -1.000000000000000000000000000000003 -> -1.000000000000000000000000000000004
  59. dqnextm032 nextminus -1.000000000000000000000000000000004 -> -1.000000000000000000000000000000005
  60. dqnextm033 nextminus -1.000000000000000000000000000000005 -> -1.000000000000000000000000000000006
  61. dqnextm034 nextminus -1.000000000000000000000000000000006 -> -1.000000000000000000000000000000007
  62. dqnextm035 nextminus -1.000000000000000000000000000000007 -> -1.000000000000000000000000000000008
  63. dqnextm036 nextminus -1.000000000000000000000000000000008 -> -1.000000000000000000000000000000009
  64. dqnextm037 nextminus -1.000000000000000000000000000000009 -> -1.000000000000000000000000000000010
  65. dqnextm038 nextminus -1.000000000000000000000000000000010 -> -1.000000000000000000000000000000011
  66. dqnextm039 nextminus -1.000000000000000000000000000000011 -> -1.000000000000000000000000000000012
  67. -- ultra-tiny inputs
  68. dqnextm062 nextminus 1E-6176 -> 0E-6176
  69. dqnextm065 nextminus -1E-6176 -> -2E-6176
  70. -- Zeros
  71. dqnextm100 nextminus -0 -> -1E-6176
  72. dqnextm101 nextminus 0 -> -1E-6176
  73. dqnextm102 nextminus 0.00 -> -1E-6176
  74. dqnextm103 nextminus -0.00 -> -1E-6176
  75. dqnextm104 nextminus 0E-300 -> -1E-6176
  76. dqnextm105 nextminus 0E+300 -> -1E-6176
  77. dqnextm106 nextminus 0E+30000 -> -1E-6176
  78. dqnextm107 nextminus -0E+30000 -> -1E-6176
  79. -- specials
  80. dqnextm150 nextminus Inf -> 9.999999999999999999999999999999999E+6144
  81. dqnextm151 nextminus -Inf -> -Infinity
  82. dqnextm152 nextminus NaN -> NaN
  83. dqnextm153 nextminus sNaN -> NaN Invalid_operation
  84. dqnextm154 nextminus NaN77 -> NaN77
  85. dqnextm155 nextminus sNaN88 -> NaN88 Invalid_operation
  86. dqnextm156 nextminus -NaN -> -NaN
  87. dqnextm157 nextminus -sNaN -> -NaN Invalid_operation
  88. dqnextm158 nextminus -NaN77 -> -NaN77
  89. dqnextm159 nextminus -sNaN88 -> -NaN88 Invalid_operation
  90. -- Nmax, Nmin, Ntiny, subnormals
  91. dqnextm170 nextminus 9.999999999999999999999999999999999E+6144 -> 9.999999999999999999999999999999998E+6144
  92. dqnextm171 nextminus 9.999999999999999999999999999999998E+6144 -> 9.999999999999999999999999999999997E+6144
  93. dqnextm172 nextminus 1E-6143 -> 9.99999999999999999999999999999999E-6144
  94. dqnextm173 nextminus 1.000000000000000000000000000000000E-6143 -> 9.99999999999999999999999999999999E-6144
  95. dqnextm174 nextminus 9E-6176 -> 8E-6176
  96. dqnextm175 nextminus 9.9E-6175 -> 9.8E-6175
  97. dqnextm176 nextminus 9.99999999999999999999999999999E-6147 -> 9.99999999999999999999999999998E-6147
  98. dqnextm177 nextminus 9.99999999999999999999999999999999E-6144 -> 9.99999999999999999999999999999998E-6144
  99. dqnextm178 nextminus 9.99999999999999999999999999999998E-6144 -> 9.99999999999999999999999999999997E-6144
  100. dqnextm179 nextminus 9.99999999999999999999999999999997E-6144 -> 9.99999999999999999999999999999996E-6144
  101. dqnextm180 nextminus 0E-6176 -> -1E-6176
  102. dqnextm181 nextminus 1E-6176 -> 0E-6176
  103. dqnextm182 nextminus 2E-6176 -> 1E-6176
  104. dqnextm183 nextminus -0E-6176 -> -1E-6176
  105. dqnextm184 nextminus -1E-6176 -> -2E-6176
  106. dqnextm185 nextminus -2E-6176 -> -3E-6176
  107. dqnextm186 nextminus -10E-6176 -> -1.1E-6175
  108. dqnextm187 nextminus -100E-6176 -> -1.01E-6174
  109. dqnextm188 nextminus -100000E-6176 -> -1.00001E-6171
  110. dqnextm189 nextminus -1.00000000000000000000000000000E-6143 -> -1.000000000000000000000000000000001E-6143
  111. dqnextm190 nextminus -1.000000000000000000000000000000000E-6143 -> -1.000000000000000000000000000000001E-6143
  112. dqnextm191 nextminus -1E-6143 -> -1.000000000000000000000000000000001E-6143
  113. dqnextm192 nextminus -9.999999999999999999999999999999998E+6144 -> -9.999999999999999999999999999999999E+6144
  114. dqnextm193 nextminus -9.999999999999999999999999999999999E+6144 -> -Infinity
  115. -- Null tests
  116. dqnextm900 nextminus # -> NaN Invalid_operation