@lakutata/math 0.0.0-stage → 3.1.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (1728) hide show
  1. package/LICENSE +23 -0
  2. package/README.md +954 -2
  3. package/README.zh-CN.md +578 -0
  4. package/THIRD_PARTY_NOTICES.md +553 -0
  5. package/binding.gyp +89 -0
  6. package/dist/cjs/exceptions/MathArgumentException.d.ts +11 -0
  7. package/dist/cjs/exceptions/MathArgumentException.js +18 -0
  8. package/dist/cjs/exceptions/MathCancelledException.d.ts +10 -0
  9. package/dist/cjs/exceptions/MathCancelledException.js +17 -0
  10. package/dist/cjs/exceptions/MathDefinitionException.d.ts +11 -0
  11. package/dist/cjs/exceptions/MathDefinitionException.js +18 -0
  12. package/dist/cjs/exceptions/MathDivisionByZeroException.d.ts +10 -0
  13. package/dist/cjs/exceptions/MathDivisionByZeroException.js +17 -0
  14. package/dist/cjs/exceptions/MathDomainException.d.ts +11 -0
  15. package/dist/cjs/exceptions/MathDomainException.js +18 -0
  16. package/dist/cjs/exceptions/MathException.d.ts +19 -0
  17. package/dist/cjs/exceptions/MathException.js +22 -0
  18. package/dist/cjs/exceptions/MathNotSupportedException.d.ts +11 -0
  19. package/dist/cjs/exceptions/MathNotSupportedException.js +18 -0
  20. package/dist/cjs/exceptions/MathSyntaxException.d.ts +11 -0
  21. package/dist/cjs/exceptions/MathSyntaxException.js +18 -0
  22. package/dist/cjs/exceptions/MathTimeoutException.d.ts +10 -0
  23. package/dist/cjs/exceptions/MathTimeoutException.js +17 -0
  24. package/dist/cjs/exceptions/MathUnitException.d.ts +11 -0
  25. package/dist/cjs/exceptions/MathUnitException.js +18 -0
  26. package/dist/cjs/exceptions/MathUnknownFunctionException.d.ts +12 -0
  27. package/dist/cjs/exceptions/MathUnknownFunctionException.js +19 -0
  28. package/dist/cjs/exports/Math.d.ts +28 -0
  29. package/dist/cjs/exports/Math.js +84 -0
  30. package/dist/cjs/lib/Addon.d.ts +5 -0
  31. package/dist/cjs/lib/Addon.js +9 -0
  32. package/dist/cjs/lib/Context.d.ts +90 -0
  33. package/dist/cjs/lib/Context.js +134 -0
  34. package/dist/cjs/lib/Decimal.d.ts +276 -0
  35. package/dist/cjs/lib/Decimal.js +402 -0
  36. package/dist/cjs/lib/Defaults.d.ts +273 -0
  37. package/dist/cjs/lib/Defaults.js +308 -0
  38. package/dist/cjs/lib/Distribution.d.ts +177 -0
  39. package/dist/cjs/lib/Distribution.js +196 -0
  40. package/dist/cjs/lib/Expression.d.ts +791 -0
  41. package/dist/cjs/lib/Expression.js +991 -0
  42. package/dist/cjs/lib/ExpressionMatrix.d.ts +284 -0
  43. package/dist/cjs/lib/ExpressionMatrix.js +412 -0
  44. package/dist/cjs/lib/LinearAlgebra.d.ts +613 -0
  45. package/dist/cjs/lib/LinearAlgebra.js +712 -0
  46. package/dist/cjs/lib/MathScope.d.ts +268 -0
  47. package/dist/cjs/lib/MathScope.js +316 -0
  48. package/dist/cjs/lib/MathSet.d.ts +139 -0
  49. package/dist/cjs/lib/MathSet.js +376 -0
  50. package/dist/cjs/lib/Matrix.d.ts +212 -0
  51. package/dist/cjs/lib/Matrix.js +393 -0
  52. package/dist/cjs/lib/Native.d.ts +80 -0
  53. package/dist/cjs/lib/Native.js +61 -0
  54. package/dist/cjs/lib/NumberTheory.d.ts +356 -0
  55. package/dist/cjs/lib/NumberTheory.js +524 -0
  56. package/dist/cjs/lib/Numeric.d.ts +363 -0
  57. package/dist/cjs/lib/Numeric.js +243 -0
  58. package/dist/cjs/lib/Polynomials.d.ts +140 -0
  59. package/dist/cjs/lib/Polynomials.js +167 -0
  60. package/dist/cjs/lib/SparseMatrix.d.ts +125 -0
  61. package/dist/cjs/lib/SparseMatrix.js +341 -0
  62. package/dist/cjs/lib/Statistics.d.ts +366 -0
  63. package/dist/cjs/lib/Statistics.js +380 -0
  64. package/dist/cjs/lib/Unit.d.ts +342 -0
  65. package/dist/cjs/lib/Unit.js +1027 -0
  66. package/dist/cjs/lib/UnitTable.d.ts +39 -0
  67. package/dist/cjs/lib/UnitTable.js +634 -0
  68. package/dist/cjs/package.json +1 -0
  69. package/dist/esm/exceptions/MathArgumentException.js +14 -0
  70. package/dist/esm/exceptions/MathCancelledException.js +13 -0
  71. package/dist/esm/exceptions/MathDefinitionException.js +14 -0
  72. package/dist/esm/exceptions/MathDivisionByZeroException.js +13 -0
  73. package/dist/esm/exceptions/MathDomainException.js +14 -0
  74. package/dist/esm/exceptions/MathException.js +18 -0
  75. package/dist/esm/exceptions/MathNotSupportedException.js +14 -0
  76. package/dist/esm/exceptions/MathSyntaxException.js +14 -0
  77. package/dist/esm/exceptions/MathTimeoutException.js +13 -0
  78. package/dist/esm/exceptions/MathUnitException.js +14 -0
  79. package/dist/esm/exceptions/MathUnknownFunctionException.js +15 -0
  80. package/dist/esm/exports/Math.js +26 -0
  81. package/dist/esm/lib/Addon.js +10 -0
  82. package/dist/esm/lib/Context.js +128 -0
  83. package/dist/esm/lib/Decimal.js +397 -0
  84. package/dist/esm/lib/Defaults.js +290 -0
  85. package/dist/esm/lib/Distribution.js +191 -0
  86. package/dist/esm/lib/Expression.js +979 -0
  87. package/dist/esm/lib/ExpressionMatrix.js +407 -0
  88. package/dist/esm/lib/LinearAlgebra.js +708 -0
  89. package/dist/esm/lib/MathScope.js +311 -0
  90. package/dist/esm/lib/MathSet.js +370 -0
  91. package/dist/esm/lib/Matrix.js +382 -0
  92. package/dist/esm/lib/Native.js +56 -0
  93. package/dist/esm/lib/NumberTheory.js +520 -0
  94. package/dist/esm/lib/Numeric.js +239 -0
  95. package/dist/esm/lib/Polynomials.js +163 -0
  96. package/dist/esm/lib/SparseMatrix.js +332 -0
  97. package/dist/esm/lib/Statistics.js +376 -0
  98. package/dist/esm/lib/Unit.js +1018 -0
  99. package/dist/esm/lib/UnitTable.js +631 -0
  100. package/dist/types/exceptions/MathArgumentException.d.ts +11 -0
  101. package/dist/types/exceptions/MathCancelledException.d.ts +10 -0
  102. package/dist/types/exceptions/MathDefinitionException.d.ts +11 -0
  103. package/dist/types/exceptions/MathDivisionByZeroException.d.ts +10 -0
  104. package/dist/types/exceptions/MathDomainException.d.ts +11 -0
  105. package/dist/types/exceptions/MathException.d.ts +19 -0
  106. package/dist/types/exceptions/MathNotSupportedException.d.ts +11 -0
  107. package/dist/types/exceptions/MathSyntaxException.d.ts +11 -0
  108. package/dist/types/exceptions/MathTimeoutException.d.ts +10 -0
  109. package/dist/types/exceptions/MathUnitException.d.ts +11 -0
  110. package/dist/types/exceptions/MathUnknownFunctionException.d.ts +12 -0
  111. package/dist/types/exports/Math.d.ts +28 -0
  112. package/dist/types/lib/Addon.d.ts +5 -0
  113. package/dist/types/lib/Context.d.ts +90 -0
  114. package/dist/types/lib/Decimal.d.ts +276 -0
  115. package/dist/types/lib/Defaults.d.ts +273 -0
  116. package/dist/types/lib/Distribution.d.ts +177 -0
  117. package/dist/types/lib/Expression.d.ts +791 -0
  118. package/dist/types/lib/ExpressionMatrix.d.ts +284 -0
  119. package/dist/types/lib/LinearAlgebra.d.ts +613 -0
  120. package/dist/types/lib/MathScope.d.ts +268 -0
  121. package/dist/types/lib/MathSet.d.ts +139 -0
  122. package/dist/types/lib/Matrix.d.ts +212 -0
  123. package/dist/types/lib/Native.d.ts +80 -0
  124. package/dist/types/lib/NumberTheory.d.ts +356 -0
  125. package/dist/types/lib/Numeric.d.ts +363 -0
  126. package/dist/types/lib/Polynomials.d.ts +140 -0
  127. package/dist/types/lib/SparseMatrix.d.ts +125 -0
  128. package/dist/types/lib/Statistics.d.ts +366 -0
  129. package/dist/types/lib/Unit.d.ts +342 -0
  130. package/dist/types/lib/UnitTable.d.ts +39 -0
  131. package/native/addon.cpp +1374 -0
  132. package/native/async/Pool.cpp +133 -0
  133. package/native/async/Pool.h +59 -0
  134. package/native/config/boost_math_policy.h +26 -0
  135. package/native/config/mpdecimal/mpdecimal.h +809 -0
  136. package/native/config/symengine/symengine_config.h +44 -0
  137. package/native/config/symengine/symengine_export.h +19 -0
  138. package/native/core/Errors.cpp +77 -0
  139. package/native/core/Errors.h +72 -0
  140. package/native/core/Handle.cpp +109 -0
  141. package/native/core/Handle.h +72 -0
  142. package/native/core/Scope.cpp +122 -0
  143. package/native/core/Scope.h +36 -0
  144. package/native/functions/Functions.cpp +468 -0
  145. package/native/functions/Functions.h +115 -0
  146. package/native/functions/Gosper.cpp +429 -0
  147. package/native/functions/Gosper.h +20 -0
  148. package/native/functions/SpecialIntegrals.cpp +329 -0
  149. package/native/functions/SpecialIntegrals.h +53 -0
  150. package/native/functions/Summation.cpp +645 -0
  151. package/native/functions/Summation.h +42 -0
  152. package/native/integrals/Integrals.cpp +1428 -0
  153. package/native/integrals/Integrals.h +32 -0
  154. package/native/limits/Gruntz.cpp +1332 -0
  155. package/native/limits/Gruntz.h +24 -0
  156. package/native/linalg/Decompositions.cpp +159 -0
  157. package/native/linalg/Functions.cpp +199 -0
  158. package/native/linalg/Linalg.cpp +123 -0
  159. package/native/linalg/Linalg.h +67 -0
  160. package/native/linalg/LinalgSupport.h +69 -0
  161. package/native/linalg/Sparse.cpp +172 -0
  162. package/native/matrix/Matrices.cpp +766 -0
  163. package/native/matrix/Matrices.h +74 -0
  164. package/native/ntheory/NumberTheory.cpp +754 -0
  165. package/native/ntheory/NumberTheory.h +56 -0
  166. package/native/numeric/Compiled.cpp +93 -0
  167. package/native/numeric/Compiled.h +49 -0
  168. package/native/numeric/Integrate.cpp +718 -0
  169. package/native/numeric/Numeric.h +95 -0
  170. package/native/numeric/ODE.cpp +542 -0
  171. package/native/numeric/Roots.cpp +402 -0
  172. package/native/ops/Decimal.cpp +776 -0
  173. package/native/ops/Decimal.h +182 -0
  174. package/native/ops/DecimalComplex.cpp +738 -0
  175. package/native/ops/DecimalEvaluator.h +79 -0
  176. package/native/ops/DecimalFunctions.cpp +439 -0
  177. package/native/ops/DecimalOperations.cpp +236 -0
  178. package/native/ops/DecimalSpecial.cpp +1028 -0
  179. package/native/ops/DecimalSupport.h +109 -0
  180. package/native/ops/Operations.cpp +969 -0
  181. package/native/ops/Operations.h +120 -0
  182. package/native/ops/Piecewise.cpp +195 -0
  183. package/native/ops/Piecewise.h +40 -0
  184. package/native/parser/Parser.cpp +853 -0
  185. package/native/parser/Parser.h +56 -0
  186. package/native/poly/Convert.cpp +210 -0
  187. package/native/poly/Convert.h +40 -0
  188. package/native/poly/Dense.cpp +1008 -0
  189. package/native/poly/Dense.h +136 -0
  190. package/native/poly/Euclid.cpp +446 -0
  191. package/native/poly/Euclid.h +44 -0
  192. package/native/poly/Factor.cpp +919 -0
  193. package/native/poly/Factor.h +36 -0
  194. package/native/poly/Galois.cpp +439 -0
  195. package/native/poly/Galois.h +86 -0
  196. package/native/poly/Inequalities.cpp +227 -0
  197. package/native/poly/Inequalities.h +21 -0
  198. package/native/poly/Poly.cpp +338 -0
  199. package/native/poly/Poly.h +46 -0
  200. package/native/poly/Rational.cpp +403 -0
  201. package/native/poly/Rational.h +33 -0
  202. package/native/poly/RealRoots.cpp +136 -0
  203. package/native/poly/RealRoots.h +35 -0
  204. package/native/printer/Printer.cpp +973 -0
  205. package/native/printer/Printer.h +23 -0
  206. package/native/simplify/Simplify.cpp +921 -0
  207. package/native/simplify/Simplify.h +21 -0
  208. package/native/stats/Distributions.cpp +392 -0
  209. package/native/stats/Distributions.h +33 -0
  210. package/native/stats/Statistics.cpp +255 -0
  211. package/native/stats/Statistics.h +25 -0
  212. package/package.json +85 -4
  213. package/scripts/sources.mjs +35 -0
  214. package/vendor/PATCHES.md +169 -0
  215. package/vendor/boost/config/README.md +43 -0
  216. package/vendor/boost/config/include/boost/config/abi/borland_prefix.hpp +27 -0
  217. package/vendor/boost/config/include/boost/config/abi/borland_suffix.hpp +12 -0
  218. package/vendor/boost/config/include/boost/config/abi/msvc_prefix.hpp +22 -0
  219. package/vendor/boost/config/include/boost/config/abi/msvc_suffix.hpp +8 -0
  220. package/vendor/boost/config/include/boost/config/abi_prefix.hpp +25 -0
  221. package/vendor/boost/config/include/boost/config/abi_suffix.hpp +25 -0
  222. package/vendor/boost/config/include/boost/config/assert_cxx03.hpp +211 -0
  223. package/vendor/boost/config/include/boost/config/assert_cxx11.hpp +212 -0
  224. package/vendor/boost/config/include/boost/config/assert_cxx14.hpp +47 -0
  225. package/vendor/boost/config/include/boost/config/assert_cxx17.hpp +65 -0
  226. package/vendor/boost/config/include/boost/config/assert_cxx20.hpp +59 -0
  227. package/vendor/boost/config/include/boost/config/assert_cxx23.hpp +41 -0
  228. package/vendor/boost/config/include/boost/config/assert_cxx98.hpp +23 -0
  229. package/vendor/boost/config/include/boost/config/auto_link.hpp +530 -0
  230. package/vendor/boost/config/include/boost/config/compiler/borland.hpp +342 -0
  231. package/vendor/boost/config/include/boost/config/compiler/clang.hpp +370 -0
  232. package/vendor/boost/config/include/boost/config/compiler/clang_version.hpp +98 -0
  233. package/vendor/boost/config/include/boost/config/compiler/codegear.hpp +389 -0
  234. package/vendor/boost/config/include/boost/config/compiler/comeau.hpp +59 -0
  235. package/vendor/boost/config/include/boost/config/compiler/common_edg.hpp +185 -0
  236. package/vendor/boost/config/include/boost/config/compiler/compaq_cxx.hpp +19 -0
  237. package/vendor/boost/config/include/boost/config/compiler/cray.hpp +446 -0
  238. package/vendor/boost/config/include/boost/config/compiler/diab.hpp +26 -0
  239. package/vendor/boost/config/include/boost/config/compiler/digitalmars.hpp +146 -0
  240. package/vendor/boost/config/include/boost/config/compiler/gcc.hpp +386 -0
  241. package/vendor/boost/config/include/boost/config/compiler/gcc_xml.hpp +115 -0
  242. package/vendor/boost/config/include/boost/config/compiler/greenhills.hpp +28 -0
  243. package/vendor/boost/config/include/boost/config/compiler/hp_acc.hpp +153 -0
  244. package/vendor/boost/config/include/boost/config/compiler/intel.hpp +577 -0
  245. package/vendor/boost/config/include/boost/config/compiler/kai.hpp +33 -0
  246. package/vendor/boost/config/include/boost/config/compiler/metrowerks.hpp +201 -0
  247. package/vendor/boost/config/include/boost/config/compiler/mpw.hpp +143 -0
  248. package/vendor/boost/config/include/boost/config/compiler/nvcc.hpp +64 -0
  249. package/vendor/boost/config/include/boost/config/compiler/pathscale.hpp +141 -0
  250. package/vendor/boost/config/include/boost/config/compiler/pgi.hpp +23 -0
  251. package/vendor/boost/config/include/boost/config/compiler/sgi_mipspro.hpp +29 -0
  252. package/vendor/boost/config/include/boost/config/compiler/sunpro_cc.hpp +225 -0
  253. package/vendor/boost/config/include/boost/config/compiler/vacpp.hpp +189 -0
  254. package/vendor/boost/config/include/boost/config/compiler/visualc.hpp +400 -0
  255. package/vendor/boost/config/include/boost/config/compiler/xlcpp.hpp +303 -0
  256. package/vendor/boost/config/include/boost/config/compiler/xlcpp_zos.hpp +174 -0
  257. package/vendor/boost/config/include/boost/config/detail/cxx_composite.hpp +218 -0
  258. package/vendor/boost/config/include/boost/config/detail/posix_features.hpp +95 -0
  259. package/vendor/boost/config/include/boost/config/detail/select_compiler_config.hpp +157 -0
  260. package/vendor/boost/config/include/boost/config/detail/select_platform_config.hpp +147 -0
  261. package/vendor/boost/config/include/boost/config/detail/select_stdlib_config.hpp +121 -0
  262. package/vendor/boost/config/include/boost/config/detail/suffix.hpp +1334 -0
  263. package/vendor/boost/config/include/boost/config/header_deprecated.hpp +26 -0
  264. package/vendor/boost/config/include/boost/config/helper_macros.hpp +37 -0
  265. package/vendor/boost/config/include/boost/config/no_tr1/cmath.hpp +28 -0
  266. package/vendor/boost/config/include/boost/config/no_tr1/complex.hpp +28 -0
  267. package/vendor/boost/config/include/boost/config/no_tr1/functional.hpp +28 -0
  268. package/vendor/boost/config/include/boost/config/no_tr1/memory.hpp +28 -0
  269. package/vendor/boost/config/include/boost/config/no_tr1/utility.hpp +28 -0
  270. package/vendor/boost/config/include/boost/config/platform/aix.hpp +33 -0
  271. package/vendor/boost/config/include/boost/config/platform/amigaos.hpp +15 -0
  272. package/vendor/boost/config/include/boost/config/platform/beos.hpp +26 -0
  273. package/vendor/boost/config/include/boost/config/platform/bsd.hpp +83 -0
  274. package/vendor/boost/config/include/boost/config/platform/cloudabi.hpp +18 -0
  275. package/vendor/boost/config/include/boost/config/platform/cray.hpp +18 -0
  276. package/vendor/boost/config/include/boost/config/platform/cygwin.hpp +71 -0
  277. package/vendor/boost/config/include/boost/config/platform/haiku.hpp +31 -0
  278. package/vendor/boost/config/include/boost/config/platform/hpux.hpp +87 -0
  279. package/vendor/boost/config/include/boost/config/platform/irix.hpp +31 -0
  280. package/vendor/boost/config/include/boost/config/platform/linux.hpp +106 -0
  281. package/vendor/boost/config/include/boost/config/platform/macos.hpp +87 -0
  282. package/vendor/boost/config/include/boost/config/platform/qnxnto.hpp +31 -0
  283. package/vendor/boost/config/include/boost/config/platform/solaris.hpp +31 -0
  284. package/vendor/boost/config/include/boost/config/platform/symbian.hpp +97 -0
  285. package/vendor/boost/config/include/boost/config/platform/vms.hpp +25 -0
  286. package/vendor/boost/config/include/boost/config/platform/vxworks.hpp +422 -0
  287. package/vendor/boost/config/include/boost/config/platform/wasm.hpp +23 -0
  288. package/vendor/boost/config/include/boost/config/platform/win32.hpp +90 -0
  289. package/vendor/boost/config/include/boost/config/platform/zos.hpp +32 -0
  290. package/vendor/boost/config/include/boost/config/pragma_message.hpp +31 -0
  291. package/vendor/boost/config/include/boost/config/requires_threads.hpp +92 -0
  292. package/vendor/boost/config/include/boost/config/stdlib/dinkumware.hpp +324 -0
  293. package/vendor/boost/config/include/boost/config/stdlib/libcomo.hpp +93 -0
  294. package/vendor/boost/config/include/boost/config/stdlib/libcpp.hpp +185 -0
  295. package/vendor/boost/config/include/boost/config/stdlib/libstdcpp3.hpp +482 -0
  296. package/vendor/boost/config/include/boost/config/stdlib/modena.hpp +79 -0
  297. package/vendor/boost/config/include/boost/config/stdlib/msl.hpp +98 -0
  298. package/vendor/boost/config/include/boost/config/stdlib/roguewave.hpp +208 -0
  299. package/vendor/boost/config/include/boost/config/stdlib/sgi.hpp +168 -0
  300. package/vendor/boost/config/include/boost/config/stdlib/stlport.hpp +258 -0
  301. package/vendor/boost/config/include/boost/config/stdlib/vacpp.hpp +74 -0
  302. package/vendor/boost/config/include/boost/config/stdlib/xlcpp_zos.hpp +61 -0
  303. package/vendor/boost/config/include/boost/config/user.hpp +133 -0
  304. package/vendor/boost/config/include/boost/config/warning_disable.hpp +47 -0
  305. package/vendor/boost/config/include/boost/config/workaround.hpp +310 -0
  306. package/vendor/boost/config/include/boost/config.hpp +67 -0
  307. package/vendor/boost/config/include/boost/cstdint.hpp +556 -0
  308. package/vendor/boost/config/include/boost/cxx11_char_types.hpp +70 -0
  309. package/vendor/boost/config/include/boost/detail/workaround.hpp +10 -0
  310. package/vendor/boost/config/include/boost/limits.hpp +146 -0
  311. package/vendor/boost/config/include/boost/static_assert.hpp +179 -0
  312. package/vendor/boost/config/include/boost/version.hpp +32 -0
  313. package/vendor/boost/math/LICENSE +23 -0
  314. package/vendor/boost/math/README.md +184 -0
  315. package/vendor/boost/math/include/boost/cstdfloat.hpp +58 -0
  316. package/vendor/boost/math/include/boost/math/bindings/detail/big_digamma.hpp +297 -0
  317. package/vendor/boost/math/include/boost/math/bindings/detail/big_lanczos.hpp +777 -0
  318. package/vendor/boost/math/include/boost/math/bindings/mpfr.hpp +974 -0
  319. package/vendor/boost/math/include/boost/math/bindings/mpreal.hpp +921 -0
  320. package/vendor/boost/math/include/boost/math/bindings/rr.hpp +876 -0
  321. package/vendor/boost/math/include/boost/math/ccmath/abs.hpp +89 -0
  322. package/vendor/boost/math/include/boost/math/ccmath/ccmath.hpp +45 -0
  323. package/vendor/boost/math/include/boost/math/ccmath/ceil.hpp +78 -0
  324. package/vendor/boost/math/include/boost/math/ccmath/copysign.hpp +81 -0
  325. package/vendor/boost/math/include/boost/math/ccmath/detail/config.hpp +52 -0
  326. package/vendor/boost/math/include/boost/math/ccmath/detail/swap.hpp +21 -0
  327. package/vendor/boost/math/include/boost/math/ccmath/div.hpp +86 -0
  328. package/vendor/boost/math/include/boost/math/ccmath/fabs.hpp +41 -0
  329. package/vendor/boost/math/include/boost/math/ccmath/fdim.hpp +93 -0
  330. package/vendor/boost/math/include/boost/math/ccmath/floor.hpp +131 -0
  331. package/vendor/boost/math/include/boost/math/ccmath/fma.hpp +130 -0
  332. package/vendor/boost/math/include/boost/math/ccmath/fmax.hpp +89 -0
  333. package/vendor/boost/math/include/boost/math/ccmath/fmin.hpp +89 -0
  334. package/vendor/boost/math/include/boost/math/ccmath/fmod.hpp +114 -0
  335. package/vendor/boost/math/include/boost/math/ccmath/fpclassify.hpp +48 -0
  336. package/vendor/boost/math/include/boost/math/ccmath/frexp.hpp +101 -0
  337. package/vendor/boost/math/include/boost/math/ccmath/hypot.hpp +116 -0
  338. package/vendor/boost/math/include/boost/math/ccmath/ilogb.hpp +60 -0
  339. package/vendor/boost/math/include/boost/math/ccmath/isfinite.hpp +53 -0
  340. package/vendor/boost/math/include/boost/math/ccmath/isgreater.hpp +42 -0
  341. package/vendor/boost/math/include/boost/math/ccmath/isgreaterequal.hpp +42 -0
  342. package/vendor/boost/math/include/boost/math/ccmath/isinf.hpp +61 -0
  343. package/vendor/boost/math/include/boost/math/ccmath/isless.hpp +42 -0
  344. package/vendor/boost/math/include/boost/math/ccmath/islessequal.hpp +42 -0
  345. package/vendor/boost/math/include/boost/math/ccmath/isnan.hpp +42 -0
  346. package/vendor/boost/math/include/boost/math/ccmath/isnormal.hpp +47 -0
  347. package/vendor/boost/math/include/boost/math/ccmath/isunordered.hpp +35 -0
  348. package/vendor/boost/math/include/boost/math/ccmath/ldexp.hpp +81 -0
  349. package/vendor/boost/math/include/boost/math/ccmath/logb.hpp +86 -0
  350. package/vendor/boost/math/include/boost/math/ccmath/modf.hpp +79 -0
  351. package/vendor/boost/math/include/boost/math/ccmath/next.hpp +458 -0
  352. package/vendor/boost/math/include/boost/math/ccmath/remainder.hpp +106 -0
  353. package/vendor/boost/math/include/boost/math/ccmath/round.hpp +179 -0
  354. package/vendor/boost/math/include/boost/math/ccmath/scalbln.hpp +60 -0
  355. package/vendor/boost/math/include/boost/math/ccmath/scalbn.hpp +81 -0
  356. package/vendor/boost/math/include/boost/math/ccmath/signbit.hpp +218 -0
  357. package/vendor/boost/math/include/boost/math/ccmath/sqrt.hpp +80 -0
  358. package/vendor/boost/math/include/boost/math/ccmath/trunc.hpp +70 -0
  359. package/vendor/boost/math/include/boost/math/common_factor.hpp +23 -0
  360. package/vendor/boost/math/include/boost/math/common_factor_ct.hpp +34 -0
  361. package/vendor/boost/math/include/boost/math/common_factor_rt.hpp +30 -0
  362. package/vendor/boost/math/include/boost/math/complex/acos.hpp +245 -0
  363. package/vendor/boost/math/include/boost/math/complex/acosh.hpp +34 -0
  364. package/vendor/boost/math/include/boost/math/complex/asin.hpp +252 -0
  365. package/vendor/boost/math/include/boost/math/complex/asinh.hpp +32 -0
  366. package/vendor/boost/math/include/boost/math/complex/atan.hpp +36 -0
  367. package/vendor/boost/math/include/boost/math/complex/atanh.hpp +214 -0
  368. package/vendor/boost/math/include/boost/math/complex/details.hpp +68 -0
  369. package/vendor/boost/math/include/boost/math/complex/fabs.hpp +23 -0
  370. package/vendor/boost/math/include/boost/math/complex.hpp +32 -0
  371. package/vendor/boost/math/include/boost/math/concepts/distributions.hpp +497 -0
  372. package/vendor/boost/math/include/boost/math/concepts/real_concept.hpp +400 -0
  373. package/vendor/boost/math/include/boost/math/concepts/real_type_concept.hpp +119 -0
  374. package/vendor/boost/math/include/boost/math/concepts/std_real_concept.hpp +427 -0
  375. package/vendor/boost/math/include/boost/math/constants/calculate_constants.hpp +1117 -0
  376. package/vendor/boost/math/include/boost/math/constants/constants.hpp +360 -0
  377. package/vendor/boost/math/include/boost/math/constants/info.hpp +169 -0
  378. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_cmath.hpp +1012 -0
  379. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_complex.hpp +38 -0
  380. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_complex_std.hpp +813 -0
  381. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_iostream.hpp +822 -0
  382. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_limits.hpp +87 -0
  383. package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_types.hpp +441 -0
  384. package/vendor/boost/math/include/boost/math/differentiation/autodiff.hpp +2061 -0
  385. package/vendor/boost/math/include/boost/math/differentiation/autodiff_cpp11.hpp +387 -0
  386. package/vendor/boost/math/include/boost/math/differentiation/autodiff_reverse.hpp +811 -0
  387. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_operator_expressions.hpp +276 -0
  388. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_ops_et.hpp +160 -0
  389. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_ops_no_et.hpp +154 -0
  390. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_comparison_operator_overloads.hpp +167 -0
  391. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_erf_overloads.hpp +234 -0
  392. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_expression_template_base.hpp +258 -0
  393. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_helper_functions.hpp +18 -0
  394. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_memory_management.hpp +462 -0
  395. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_et.hpp +275 -0
  396. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_expressions.hpp +852 -0
  397. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_no_et.hpp +266 -0
  398. package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_utilities.hpp +51 -0
  399. package/vendor/boost/math/include/boost/math/differentiation/finite_difference.hpp +266 -0
  400. package/vendor/boost/math/include/boost/math/differentiation/lanczos_smoothing.hpp +591 -0
  401. package/vendor/boost/math/include/boost/math/distributions/arcsine.hpp +593 -0
  402. package/vendor/boost/math/include/boost/math/distributions/bernoulli.hpp +349 -0
  403. package/vendor/boost/math/include/boost/math/distributions/beta.hpp +584 -0
  404. package/vendor/boost/math/include/boost/math/distributions/binomial.hpp +729 -0
  405. package/vendor/boost/math/include/boost/math/distributions/cauchy.hpp +379 -0
  406. package/vendor/boost/math/include/boost/math/distributions/chi_squared.hpp +345 -0
  407. package/vendor/boost/math/include/boost/math/distributions/complement.hpp +198 -0
  408. package/vendor/boost/math/include/boost/math/distributions/detail/common_error_handling.hpp +228 -0
  409. package/vendor/boost/math/include/boost/math/distributions/detail/derived_accessors.hpp +190 -0
  410. package/vendor/boost/math/include/boost/math/distributions/detail/generic_mode.hpp +145 -0
  411. package/vendor/boost/math/include/boost/math/distributions/detail/generic_quantile.hpp +100 -0
  412. package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_cdf.hpp +101 -0
  413. package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_pdf.hpp +490 -0
  414. package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_quantile.hpp +245 -0
  415. package/vendor/boost/math/include/boost/math/distributions/detail/inv_discrete_quantile.hpp +583 -0
  416. package/vendor/boost/math/include/boost/math/distributions/empirical_cumulative_distribution_function.hpp +73 -0
  417. package/vendor/boost/math/include/boost/math/distributions/exponential.hpp +352 -0
  418. package/vendor/boost/math/include/boost/math/distributions/extreme_value.hpp +388 -0
  419. package/vendor/boost/math/include/boost/math/distributions/find_location.hpp +141 -0
  420. package/vendor/boost/math/include/boost/math/distributions/find_scale.hpp +200 -0
  421. package/vendor/boost/math/include/boost/math/distributions/fisher_f.hpp +393 -0
  422. package/vendor/boost/math/include/boost/math/distributions/fwd.hpp +171 -0
  423. package/vendor/boost/math/include/boost/math/distributions/gamma.hpp +396 -0
  424. package/vendor/boost/math/include/boost/math/distributions/geometric.hpp +571 -0
  425. package/vendor/boost/math/include/boost/math/distributions/holtsmark.hpp +2518 -0
  426. package/vendor/boost/math/include/boost/math/distributions/hyperexponential.hpp +641 -0
  427. package/vendor/boost/math/include/boost/math/distributions/hypergeometric.hpp +313 -0
  428. package/vendor/boost/math/include/boost/math/distributions/inverse_chi_squared.hpp +398 -0
  429. package/vendor/boost/math/include/boost/math/distributions/inverse_gamma.hpp +504 -0
  430. package/vendor/boost/math/include/boost/math/distributions/inverse_gaussian.hpp +566 -0
  431. package/vendor/boost/math/include/boost/math/distributions/kolmogorov_smirnov.hpp +511 -0
  432. package/vendor/boost/math/include/boost/math/distributions/landau.hpp +4642 -0
  433. package/vendor/boost/math/include/boost/math/distributions/laplace.hpp +494 -0
  434. package/vendor/boost/math/include/boost/math/distributions/logistic.hpp +377 -0
  435. package/vendor/boost/math/include/boost/math/distributions/lognormal.hpp +361 -0
  436. package/vendor/boost/math/include/boost/math/distributions/mapairy.hpp +4220 -0
  437. package/vendor/boost/math/include/boost/math/distributions/negative_binomial.hpp +609 -0
  438. package/vendor/boost/math/include/boost/math/distributions/non_central_beta.hpp +981 -0
  439. package/vendor/boost/math/include/boost/math/distributions/non_central_chi_squared.hpp +998 -0
  440. package/vendor/boost/math/include/boost/math/distributions/non_central_f.hpp +712 -0
  441. package/vendor/boost/math/include/boost/math/distributions/non_central_t.hpp +1324 -0
  442. package/vendor/boost/math/include/boost/math/distributions/normal.hpp +368 -0
  443. package/vendor/boost/math/include/boost/math/distributions/pareto.hpp +508 -0
  444. package/vendor/boost/math/include/boost/math/distributions/poisson.hpp +563 -0
  445. package/vendor/boost/math/include/boost/math/distributions/rayleigh.hpp +381 -0
  446. package/vendor/boost/math/include/boost/math/distributions/saspoint5.hpp +2796 -0
  447. package/vendor/boost/math/include/boost/math/distributions/skew_normal.hpp +760 -0
  448. package/vendor/boost/math/include/boost/math/distributions/students_t.hpp +721 -0
  449. package/vendor/boost/math/include/boost/math/distributions/triangular.hpp +548 -0
  450. package/vendor/boost/math/include/boost/math/distributions/uniform.hpp +398 -0
  451. package/vendor/boost/math/include/boost/math/distributions/weibull.hpp +487 -0
  452. package/vendor/boost/math/include/boost/math/distributions.hpp +58 -0
  453. package/vendor/boost/math/include/boost/math/filters/daubechies.hpp +99 -0
  454. package/vendor/boost/math/include/boost/math/interpolators/barycentric_rational.hpp +99 -0
  455. package/vendor/boost/math/include/boost/math/interpolators/bezier_polynomial.hpp +60 -0
  456. package/vendor/boost/math/include/boost/math/interpolators/bilinear_uniform.hpp +54 -0
  457. package/vendor/boost/math/include/boost/math/interpolators/cardinal_cubic_b_spline.hpp +87 -0
  458. package/vendor/boost/math/include/boost/math/interpolators/cardinal_quadratic_b_spline.hpp +57 -0
  459. package/vendor/boost/math/include/boost/math/interpolators/cardinal_quintic_b_spline.hpp +62 -0
  460. package/vendor/boost/math/include/boost/math/interpolators/cardinal_trigonometric.hpp +58 -0
  461. package/vendor/boost/math/include/boost/math/interpolators/catmull_rom.hpp +310 -0
  462. package/vendor/boost/math/include/boost/math/interpolators/cubic_b_spline.hpp +90 -0
  463. package/vendor/boost/math/include/boost/math/interpolators/cubic_hermite.hpp +142 -0
  464. package/vendor/boost/math/include/boost/math/interpolators/detail/barycentric_rational_detail.hpp +215 -0
  465. package/vendor/boost/math/include/boost/math/interpolators/detail/bezier_polynomial_detail.hpp +167 -0
  466. package/vendor/boost/math/include/boost/math/interpolators/detail/bilinear_uniform_detail.hpp +137 -0
  467. package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_cubic_b_spline_detail.hpp +331 -0
  468. package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_quadratic_b_spline_detail.hpp +208 -0
  469. package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_quintic_b_spline_detail.hpp +241 -0
  470. package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_trigonometric_detail.hpp +684 -0
  471. package/vendor/boost/math/include/boost/math/interpolators/detail/cubic_b_spline_detail.hpp +330 -0
  472. package/vendor/boost/math/include/boost/math/interpolators/detail/cubic_hermite_detail.hpp +439 -0
  473. package/vendor/boost/math/include/boost/math/interpolators/detail/quintic_hermite_detail.hpp +586 -0
  474. package/vendor/boost/math/include/boost/math/interpolators/detail/septic_hermite_detail.hpp +653 -0
  475. package/vendor/boost/math/include/boost/math/interpolators/detail/vector_barycentric_rational_detail.hpp +196 -0
  476. package/vendor/boost/math/include/boost/math/interpolators/detail/whittaker_shannon_detail.hpp +128 -0
  477. package/vendor/boost/math/include/boost/math/interpolators/makima.hpp +178 -0
  478. package/vendor/boost/math/include/boost/math/interpolators/pchip.hpp +136 -0
  479. package/vendor/boost/math/include/boost/math/interpolators/quintic_hermite.hpp +143 -0
  480. package/vendor/boost/math/include/boost/math/interpolators/septic_hermite.hpp +147 -0
  481. package/vendor/boost/math/include/boost/math/interpolators/vector_barycentric_rational.hpp +82 -0
  482. package/vendor/boost/math/include/boost/math/interpolators/whittaker_shannon.hpp +47 -0
  483. package/vendor/boost/math/include/boost/math/octonion.hpp +4254 -0
  484. package/vendor/boost/math/include/boost/math/optimization/cma_es.hpp +392 -0
  485. package/vendor/boost/math/include/boost/math/optimization/detail/common.hpp +200 -0
  486. package/vendor/boost/math/include/boost/math/optimization/detail/differentiable_opt_utilties.hpp +157 -0
  487. package/vendor/boost/math/include/boost/math/optimization/detail/gradient_opt_base.hpp +92 -0
  488. package/vendor/boost/math/include/boost/math/optimization/detail/line_search_policies.hpp +206 -0
  489. package/vendor/boost/math/include/boost/math/optimization/detail/rdiff_optimization_policies.hpp +134 -0
  490. package/vendor/boost/math/include/boost/math/optimization/differential_evolution.hpp +236 -0
  491. package/vendor/boost/math/include/boost/math/optimization/gradient_descent.hpp +202 -0
  492. package/vendor/boost/math/include/boost/math/optimization/gradient_optimizers.hpp +18 -0
  493. package/vendor/boost/math/include/boost/math/optimization/jso.hpp +465 -0
  494. package/vendor/boost/math/include/boost/math/optimization/lbfgs.hpp +382 -0
  495. package/vendor/boost/math/include/boost/math/optimization/minimizer.hpp +336 -0
  496. package/vendor/boost/math/include/boost/math/optimization/nesterov.hpp +208 -0
  497. package/vendor/boost/math/include/boost/math/optimization/random_search.hpp +145 -0
  498. package/vendor/boost/math/include/boost/math/policies/error_handling.hpp +1062 -0
  499. package/vendor/boost/math/include/boost/math/policies/policy.hpp +1034 -0
  500. package/vendor/boost/math/include/boost/math/quadrature/detail/exp_sinh_detail.hpp +2002 -0
  501. package/vendor/boost/math/include/boost/math/quadrature/detail/ooura_fourier_integrals_detail.hpp +692 -0
  502. package/vendor/boost/math/include/boost/math/quadrature/detail/sinh_sinh_detail.hpp +1353 -0
  503. package/vendor/boost/math/include/boost/math/quadrature/detail/tanh_sinh_detail.hpp +879 -0
  504. package/vendor/boost/math/include/boost/math/quadrature/exp_sinh.hpp +180 -0
  505. package/vendor/boost/math/include/boost/math/quadrature/gauss.hpp +904 -0
  506. package/vendor/boost/math/include/boost/math/quadrature/gauss_kronrod.hpp +1317 -0
  507. package/vendor/boost/math/include/boost/math/quadrature/naive_monte_carlo.hpp +469 -0
  508. package/vendor/boost/math/include/boost/math/quadrature/ooura_fourier_integrals.hpp +68 -0
  509. package/vendor/boost/math/include/boost/math/quadrature/sinh_sinh.hpp +72 -0
  510. package/vendor/boost/math/include/boost/math/quadrature/tanh_sinh.hpp +289 -0
  511. package/vendor/boost/math/include/boost/math/quadrature/trapezoidal.hpp +125 -0
  512. package/vendor/boost/math/include/boost/math/quadrature/wavelet_transforms.hpp +47 -0
  513. package/vendor/boost/math/include/boost/math/quaternion.hpp +1190 -0
  514. package/vendor/boost/math/include/boost/math/special_functions/acosh.hpp +102 -0
  515. package/vendor/boost/math/include/boost/math/special_functions/airy.hpp +475 -0
  516. package/vendor/boost/math/include/boost/math/special_functions/asinh.hpp +110 -0
  517. package/vendor/boost/math/include/boost/math/special_functions/atanh.hpp +116 -0
  518. package/vendor/boost/math/include/boost/math/special_functions/bernoulli.hpp +149 -0
  519. package/vendor/boost/math/include/boost/math/special_functions/bessel.hpp +795 -0
  520. package/vendor/boost/math/include/boost/math/special_functions/bessel_iterators.hpp +187 -0
  521. package/vendor/boost/math/include/boost/math/special_functions/bessel_prime.hpp +343 -0
  522. package/vendor/boost/math/include/boost/math/special_functions/beta.hpp +1870 -0
  523. package/vendor/boost/math/include/boost/math/special_functions/binomial.hpp +87 -0
  524. package/vendor/boost/math/include/boost/math/special_functions/cardinal_b_spline.hpp +218 -0
  525. package/vendor/boost/math/include/boost/math/special_functions/cbrt.hpp +215 -0
  526. package/vendor/boost/math/include/boost/math/special_functions/chebyshev.hpp +314 -0
  527. package/vendor/boost/math/include/boost/math/special_functions/chebyshev_transform.hpp +237 -0
  528. package/vendor/boost/math/include/boost/math/special_functions/cos_pi.hpp +128 -0
  529. package/vendor/boost/math/include/boost/math/special_functions/daubechies_scaling.hpp +491 -0
  530. package/vendor/boost/math/include/boost/math/special_functions/daubechies_wavelet.hpp +266 -0
  531. package/vendor/boost/math/include/boost/math/special_functions/detail/airy_ai_bi_zero.hpp +222 -0
  532. package/vendor/boost/math/include/boost/math/special_functions/detail/bernoulli_details.hpp +629 -0
  533. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_derivatives_linear.hpp +107 -0
  534. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_i0.hpp +550 -0
  535. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_i1.hpp +556 -0
  536. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_ik.hpp +447 -0
  537. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_j0.hpp +192 -0
  538. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_j1.hpp +179 -0
  539. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jn.hpp +127 -0
  540. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy.hpp +603 -0
  541. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_asym.hpp +230 -0
  542. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_derivatives_asym.hpp +141 -0
  543. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_derivatives_series.hpp +219 -0
  544. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_series.hpp +267 -0
  545. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_zero.hpp +643 -0
  546. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_k0.hpp +485 -0
  547. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_k1.hpp +526 -0
  548. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_kn.hpp +91 -0
  549. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_y0.hpp +205 -0
  550. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_y1.hpp +183 -0
  551. package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_yn.hpp +113 -0
  552. package/vendor/boost/math/include/boost/math/special_functions/detail/daubechies_scaling_integer_grid.hpp +244 -0
  553. package/vendor/boost/math/include/boost/math/special_functions/detail/erf_inv.hpp +559 -0
  554. package/vendor/boost/math/include/boost/math/special_functions/detail/fp_traits.hpp +562 -0
  555. package/vendor/boost/math/include/boost/math/special_functions/detail/gamma_inva.hpp +241 -0
  556. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_0F1_bessel.hpp +46 -0
  557. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_addition_theorems_on_z.hpp +293 -0
  558. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_bessel.hpp +768 -0
  559. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_by_ratios.hpp +678 -0
  560. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_cf.hpp +50 -0
  561. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_large_a.hpp +35 -0
  562. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_large_abz.hpp +492 -0
  563. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_negative_b_regions.hpp +521 -0
  564. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_recurrence.hpp +522 -0
  565. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_scaled_series.hpp +60 -0
  566. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_small_a_negative_b_by_ratio.hpp +70 -0
  567. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_asym.hpp +179 -0
  568. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_cf.hpp +228 -0
  569. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_pFq_checked_series.hpp +687 -0
  570. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_pade.hpp +131 -0
  571. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_rational.hpp +167 -0
  572. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_separated_series.hpp +50 -0
  573. package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_series.hpp +434 -0
  574. package/vendor/boost/math/include/boost/math/special_functions/detail/ibeta_inv_ab.hpp +331 -0
  575. package/vendor/boost/math/include/boost/math/special_functions/detail/ibeta_inverse.hpp +1122 -0
  576. package/vendor/boost/math/include/boost/math/special_functions/detail/iconv.hpp +43 -0
  577. package/vendor/boost/math/include/boost/math/special_functions/detail/igamma_inverse.hpp +587 -0
  578. package/vendor/boost/math/include/boost/math/special_functions/detail/igamma_large.hpp +823 -0
  579. package/vendor/boost/math/include/boost/math/special_functions/detail/lambert_w_lookup_table.ipp +162 -0
  580. package/vendor/boost/math/include/boost/math/special_functions/detail/lanczos_sse2.hpp +238 -0
  581. package/vendor/boost/math/include/boost/math/special_functions/detail/lgamma_small.hpp +569 -0
  582. package/vendor/boost/math/include/boost/math/special_functions/detail/polygamma.hpp +538 -0
  583. package/vendor/boost/math/include/boost/math/special_functions/detail/round_fwd.hpp +87 -0
  584. package/vendor/boost/math/include/boost/math/special_functions/detail/t_distribution_inv.hpp +567 -0
  585. package/vendor/boost/math/include/boost/math/special_functions/detail/unchecked_bernoulli.hpp +1305 -0
  586. package/vendor/boost/math/include/boost/math/special_functions/detail/unchecked_factorial.hpp +1727 -0
  587. package/vendor/boost/math/include/boost/math/special_functions/digamma.hpp +631 -0
  588. package/vendor/boost/math/include/boost/math/special_functions/ellint_1.hpp +815 -0
  589. package/vendor/boost/math/include/boost/math/special_functions/ellint_2.hpp +756 -0
  590. package/vendor/boost/math/include/boost/math/special_functions/ellint_3.hpp +374 -0
  591. package/vendor/boost/math/include/boost/math/special_functions/ellint_d.hpp +183 -0
  592. package/vendor/boost/math/include/boost/math/special_functions/ellint_rc.hpp +112 -0
  593. package/vendor/boost/math/include/boost/math/special_functions/ellint_rd.hpp +207 -0
  594. package/vendor/boost/math/include/boost/math/special_functions/ellint_rf.hpp +169 -0
  595. package/vendor/boost/math/include/boost/math/special_functions/ellint_rg.hpp +130 -0
  596. package/vendor/boost/math/include/boost/math/special_functions/ellint_rj.hpp +299 -0
  597. package/vendor/boost/math/include/boost/math/special_functions/erf.hpp +1334 -0
  598. package/vendor/boost/math/include/boost/math/special_functions/expint.hpp +1614 -0
  599. package/vendor/boost/math/include/boost/math/special_functions/expm1.hpp +416 -0
  600. package/vendor/boost/math/include/boost/math/special_functions/factorials.hpp +276 -0
  601. package/vendor/boost/math/include/boost/math/special_functions/fibonacci.hpp +92 -0
  602. package/vendor/boost/math/include/boost/math/special_functions/fourier_transform_daubechies.hpp +248 -0
  603. package/vendor/boost/math/include/boost/math/special_functions/fpclassify.hpp +797 -0
  604. package/vendor/boost/math/include/boost/math/special_functions/gamma.hpp +2628 -0
  605. package/vendor/boost/math/include/boost/math/special_functions/gegenbauer.hpp +84 -0
  606. package/vendor/boost/math/include/boost/math/special_functions/hankel.hpp +186 -0
  607. package/vendor/boost/math/include/boost/math/special_functions/hermite.hpp +79 -0
  608. package/vendor/boost/math/include/boost/math/special_functions/heuman_lambda.hpp +97 -0
  609. package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_0F1.hpp +116 -0
  610. package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_1F0.hpp +69 -0
  611. package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_1F1.hpp +822 -0
  612. package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_2F0.hpp +163 -0
  613. package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_pFq.hpp +205 -0
  614. package/vendor/boost/math/include/boost/math/special_functions/hypot.hpp +148 -0
  615. package/vendor/boost/math/include/boost/math/special_functions/jacobi.hpp +69 -0
  616. package/vendor/boost/math/include/boost/math/special_functions/jacobi_elliptic.hpp +319 -0
  617. package/vendor/boost/math/include/boost/math/special_functions/jacobi_theta.hpp +802 -0
  618. package/vendor/boost/math/include/boost/math/special_functions/jacobi_zeta.hpp +83 -0
  619. package/vendor/boost/math/include/boost/math/special_functions/laguerre.hpp +139 -0
  620. package/vendor/boost/math/include/boost/math/special_functions/lambert_w.hpp +2171 -0
  621. package/vendor/boost/math/include/boost/math/special_functions/lanczos.hpp +2760 -0
  622. package/vendor/boost/math/include/boost/math/special_functions/legendre.hpp +380 -0
  623. package/vendor/boost/math/include/boost/math/special_functions/legendre_stieltjes.hpp +234 -0
  624. package/vendor/boost/math/include/boost/math/special_functions/log1p.hpp +417 -0
  625. package/vendor/boost/math/include/boost/math/special_functions/logaddexp.hpp +41 -0
  626. package/vendor/boost/math/include/boost/math/special_functions/logistic_sigmoid.hpp +46 -0
  627. package/vendor/boost/math/include/boost/math/special_functions/logit.hpp +56 -0
  628. package/vendor/boost/math/include/boost/math/special_functions/logsumexp.hpp +60 -0
  629. package/vendor/boost/math/include/boost/math/special_functions/math_fwd.hpp +1927 -0
  630. package/vendor/boost/math/include/boost/math/special_functions/modf.hpp +74 -0
  631. package/vendor/boost/math/include/boost/math/special_functions/next.hpp +886 -0
  632. package/vendor/boost/math/include/boost/math/special_functions/nonfinite_num_facets.hpp +588 -0
  633. package/vendor/boost/math/include/boost/math/special_functions/owens_t.hpp +1067 -0
  634. package/vendor/boost/math/include/boost/math/special_functions/polygamma.hpp +83 -0
  635. package/vendor/boost/math/include/boost/math/special_functions/pow.hpp +144 -0
  636. package/vendor/boost/math/include/boost/math/special_functions/powm1.hpp +101 -0
  637. package/vendor/boost/math/include/boost/math/special_functions/prime.hpp +2433 -0
  638. package/vendor/boost/math/include/boost/math/special_functions/relative_difference.hpp +134 -0
  639. package/vendor/boost/math/include/boost/math/special_functions/round.hpp +353 -0
  640. package/vendor/boost/math/include/boost/math/special_functions/rsqrt.hpp +52 -0
  641. package/vendor/boost/math/include/boost/math/special_functions/sign.hpp +241 -0
  642. package/vendor/boost/math/include/boost/math/special_functions/sin_pi.hpp +135 -0
  643. package/vendor/boost/math/include/boost/math/special_functions/sinc.hpp +123 -0
  644. package/vendor/boost/math/include/boost/math/special_functions/sinhc.hpp +142 -0
  645. package/vendor/boost/math/include/boost/math/special_functions/spherical_harmonic.hpp +205 -0
  646. package/vendor/boost/math/include/boost/math/special_functions/sqrt1pm1.hpp +49 -0
  647. package/vendor/boost/math/include/boost/math/special_functions/trigamma.hpp +448 -0
  648. package/vendor/boost/math/include/boost/math/special_functions/trunc.hpp +385 -0
  649. package/vendor/boost/math/include/boost/math/special_functions/ulp.hpp +102 -0
  650. package/vendor/boost/math/include/boost/math/special_functions/zeta.hpp +1081 -0
  651. package/vendor/boost/math/include/boost/math/special_functions.hpp +86 -0
  652. package/vendor/boost/math/include/boost/math/statistics/anderson_darling.hpp +112 -0
  653. package/vendor/boost/math/include/boost/math/statistics/bivariate_statistics.hpp +470 -0
  654. package/vendor/boost/math/include/boost/math/statistics/chatterjee_correlation.hpp +159 -0
  655. package/vendor/boost/math/include/boost/math/statistics/detail/rank.hpp +140 -0
  656. package/vendor/boost/math/include/boost/math/statistics/detail/single_pass.hpp +401 -0
  657. package/vendor/boost/math/include/boost/math/statistics/linear_regression.hpp +133 -0
  658. package/vendor/boost/math/include/boost/math/statistics/ljung_box.hpp +70 -0
  659. package/vendor/boost/math/include/boost/math/statistics/runs_test.hpp +121 -0
  660. package/vendor/boost/math/include/boost/math/statistics/signal_statistics.hpp +350 -0
  661. package/vendor/boost/math/include/boost/math/statistics/t_test.hpp +275 -0
  662. package/vendor/boost/math/include/boost/math/statistics/univariate_statistics.hpp +1184 -0
  663. package/vendor/boost/math/include/boost/math/statistics/z_test.hpp +161 -0
  664. package/vendor/boost/math/include/boost/math/tools/agm.hpp +47 -0
  665. package/vendor/boost/math/include/boost/math/tools/array.hpp +41 -0
  666. package/vendor/boost/math/include/boost/math/tools/assert.hpp +49 -0
  667. package/vendor/boost/math/include/boost/math/tools/atomic.hpp +50 -0
  668. package/vendor/boost/math/include/boost/math/tools/big_constant.hpp +110 -0
  669. package/vendor/boost/math/include/boost/math/tools/bivariate_statistics.hpp +96 -0
  670. package/vendor/boost/math/include/boost/math/tools/centered_continued_fraction.hpp +173 -0
  671. package/vendor/boost/math/include/boost/math/tools/cohen_acceleration.hpp +51 -0
  672. package/vendor/boost/math/include/boost/math/tools/color_maps.hpp +1943 -0
  673. package/vendor/boost/math/include/boost/math/tools/complex.hpp +115 -0
  674. package/vendor/boost/math/include/boost/math/tools/concepts.hpp +24 -0
  675. package/vendor/boost/math/include/boost/math/tools/condition_numbers.hpp +144 -0
  676. package/vendor/boost/math/include/boost/math/tools/config.hpp +856 -0
  677. package/vendor/boost/math/include/boost/math/tools/convert_from_string.hpp +85 -0
  678. package/vendor/boost/math/include/boost/math/tools/cstdint.hpp +107 -0
  679. package/vendor/boost/math/include/boost/math/tools/cubic_roots.hpp +198 -0
  680. package/vendor/boost/math/include/boost/math/tools/cxx03_warn.hpp +95 -0
  681. package/vendor/boost/math/include/boost/math/tools/detail/is_const_iterable.hpp +38 -0
  682. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_10.hpp +84 -0
  683. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_11.hpp +90 -0
  684. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_12.hpp +96 -0
  685. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_13.hpp +102 -0
  686. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_14.hpp +108 -0
  687. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_15.hpp +114 -0
  688. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_16.hpp +120 -0
  689. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_17.hpp +126 -0
  690. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_18.hpp +132 -0
  691. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_19.hpp +138 -0
  692. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_2.hpp +36 -0
  693. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_20.hpp +144 -0
  694. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_3.hpp +42 -0
  695. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_4.hpp +48 -0
  696. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_5.hpp +54 -0
  697. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_6.hpp +60 -0
  698. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_7.hpp +66 -0
  699. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_8.hpp +72 -0
  700. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_9.hpp +78 -0
  701. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_10.hpp +90 -0
  702. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_11.hpp +97 -0
  703. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_12.hpp +104 -0
  704. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_13.hpp +111 -0
  705. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_14.hpp +118 -0
  706. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_15.hpp +125 -0
  707. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_16.hpp +132 -0
  708. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_17.hpp +139 -0
  709. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_18.hpp +146 -0
  710. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_19.hpp +153 -0
  711. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_2.hpp +48 -0
  712. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_20.hpp +160 -0
  713. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_3.hpp +48 -0
  714. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_4.hpp +48 -0
  715. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_5.hpp +55 -0
  716. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_6.hpp +62 -0
  717. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_7.hpp +69 -0
  718. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_8.hpp +76 -0
  719. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_9.hpp +83 -0
  720. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_10.hpp +156 -0
  721. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_11.hpp +181 -0
  722. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_12.hpp +208 -0
  723. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_13.hpp +237 -0
  724. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_14.hpp +268 -0
  725. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_15.hpp +301 -0
  726. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_16.hpp +336 -0
  727. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_17.hpp +373 -0
  728. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_18.hpp +412 -0
  729. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_19.hpp +453 -0
  730. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_2.hpp +48 -0
  731. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_20.hpp +496 -0
  732. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_3.hpp +48 -0
  733. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_4.hpp +48 -0
  734. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_5.hpp +61 -0
  735. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_6.hpp +76 -0
  736. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_7.hpp +93 -0
  737. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_8.hpp +112 -0
  738. package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_9.hpp +133 -0
  739. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_10.hpp +138 -0
  740. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_11.hpp +150 -0
  741. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_12.hpp +162 -0
  742. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_13.hpp +174 -0
  743. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_14.hpp +186 -0
  744. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_15.hpp +198 -0
  745. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_16.hpp +210 -0
  746. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_17.hpp +222 -0
  747. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_18.hpp +234 -0
  748. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_19.hpp +246 -0
  749. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_2.hpp +42 -0
  750. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_20.hpp +258 -0
  751. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_3.hpp +54 -0
  752. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_4.hpp +66 -0
  753. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_5.hpp +78 -0
  754. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_6.hpp +90 -0
  755. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_7.hpp +102 -0
  756. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_8.hpp +114 -0
  757. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_9.hpp +126 -0
  758. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_10.hpp +144 -0
  759. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_11.hpp +160 -0
  760. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_12.hpp +176 -0
  761. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_13.hpp +192 -0
  762. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_14.hpp +208 -0
  763. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_15.hpp +224 -0
  764. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_16.hpp +240 -0
  765. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_17.hpp +256 -0
  766. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_18.hpp +272 -0
  767. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_19.hpp +288 -0
  768. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_2.hpp +48 -0
  769. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_20.hpp +304 -0
  770. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_3.hpp +48 -0
  771. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_4.hpp +48 -0
  772. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_5.hpp +64 -0
  773. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_6.hpp +80 -0
  774. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_7.hpp +96 -0
  775. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_8.hpp +112 -0
  776. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_9.hpp +128 -0
  777. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_10.hpp +396 -0
  778. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_11.hpp +482 -0
  779. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_12.hpp +576 -0
  780. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_13.hpp +678 -0
  781. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_14.hpp +788 -0
  782. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_15.hpp +906 -0
  783. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_16.hpp +1032 -0
  784. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_17.hpp +1166 -0
  785. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_18.hpp +1308 -0
  786. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_19.hpp +1458 -0
  787. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_2.hpp +48 -0
  788. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_20.hpp +1616 -0
  789. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_3.hpp +48 -0
  790. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_4.hpp +48 -0
  791. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_5.hpp +86 -0
  792. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_6.hpp +132 -0
  793. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_7.hpp +186 -0
  794. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_8.hpp +248 -0
  795. package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_9.hpp +318 -0
  796. package/vendor/boost/math/include/boost/math/tools/engel_expansion.hpp +124 -0
  797. package/vendor/boost/math/include/boost/math/tools/estrin.hpp +72 -0
  798. package/vendor/boost/math/include/boost/math/tools/fraction.hpp +354 -0
  799. package/vendor/boost/math/include/boost/math/tools/header_deprecated.hpp +27 -0
  800. package/vendor/boost/math/include/boost/math/tools/is_constant_evaluated.hpp +51 -0
  801. package/vendor/boost/math/include/boost/math/tools/is_detected.hpp +56 -0
  802. package/vendor/boost/math/include/boost/math/tools/is_standalone.hpp +18 -0
  803. package/vendor/boost/math/include/boost/math/tools/luroth_expansion.hpp +147 -0
  804. package/vendor/boost/math/include/boost/math/tools/minima.hpp +164 -0
  805. package/vendor/boost/math/include/boost/math/tools/mp.hpp +423 -0
  806. package/vendor/boost/math/include/boost/math/tools/norms.hpp +638 -0
  807. package/vendor/boost/math/include/boost/math/tools/nothrow.hpp +27 -0
  808. package/vendor/boost/math/include/boost/math/tools/numeric_limits.hpp +888 -0
  809. package/vendor/boost/math/include/boost/math/tools/numerical_differentiation.hpp +12 -0
  810. package/vendor/boost/math/include/boost/math/tools/polynomial.hpp +862 -0
  811. package/vendor/boost/math/include/boost/math/tools/polynomial_gcd.hpp +268 -0
  812. package/vendor/boost/math/include/boost/math/tools/precision.hpp +418 -0
  813. package/vendor/boost/math/include/boost/math/tools/promotion.hpp +135 -0
  814. package/vendor/boost/math/include/boost/math/tools/quartic_roots.hpp +157 -0
  815. package/vendor/boost/math/include/boost/math/tools/random_vector.hpp +101 -0
  816. package/vendor/boost/math/include/boost/math/tools/rational.hpp +346 -0
  817. package/vendor/boost/math/include/boost/math/tools/real_cast.hpp +31 -0
  818. package/vendor/boost/math/include/boost/math/tools/recurrence.hpp +330 -0
  819. package/vendor/boost/math/include/boost/math/tools/roots.hpp +1072 -0
  820. package/vendor/boost/math/include/boost/math/tools/series.hpp +221 -0
  821. package/vendor/boost/math/include/boost/math/tools/signal_statistics.hpp +353 -0
  822. package/vendor/boost/math/include/boost/math/tools/simple_continued_fraction.hpp +177 -0
  823. package/vendor/boost/math/include/boost/math/tools/stats.hpp +87 -0
  824. package/vendor/boost/math/include/boost/math/tools/test_value.hpp +143 -0
  825. package/vendor/boost/math/include/boost/math/tools/throw_exception.hpp +43 -0
  826. package/vendor/boost/math/include/boost/math/tools/toms748_solve.hpp +636 -0
  827. package/vendor/boost/math/include/boost/math/tools/traits.hpp +140 -0
  828. package/vendor/boost/math/include/boost/math/tools/tuple.hpp +88 -0
  829. package/vendor/boost/math/include/boost/math/tools/type_traits.hpp +489 -0
  830. package/vendor/boost/math/include/boost/math/tools/ulps_plot.hpp +598 -0
  831. package/vendor/boost/math/include/boost/math/tools/univariate_statistics.hpp +437 -0
  832. package/vendor/boost/math/include/boost/math/tools/user.hpp +105 -0
  833. package/vendor/boost/math/include/boost/math/tools/utility.hpp +69 -0
  834. package/vendor/boost/math/include/boost/math/tools/workaround.hpp +42 -0
  835. package/vendor/boost/math/include/boost/math/tr1.hpp +1121 -0
  836. package/vendor/boost/math/include/boost/math/tr1_c_macros.ipp +810 -0
  837. package/vendor/boost/math/include/boost/math_fwd.hpp +42 -0
  838. package/vendor/boost/multiprecision/LICENSE +23 -0
  839. package/vendor/boost/multiprecision/README.md +168 -0
  840. package/vendor/boost/multiprecision/include/boost/config/abi/borland_prefix.hpp +27 -0
  841. package/vendor/boost/multiprecision/include/boost/config/abi/borland_suffix.hpp +12 -0
  842. package/vendor/boost/multiprecision/include/boost/config/abi/msvc_prefix.hpp +22 -0
  843. package/vendor/boost/multiprecision/include/boost/config/abi/msvc_suffix.hpp +8 -0
  844. package/vendor/boost/multiprecision/include/boost/config/abi_prefix.hpp +25 -0
  845. package/vendor/boost/multiprecision/include/boost/config/abi_suffix.hpp +25 -0
  846. package/vendor/boost/multiprecision/include/boost/config/assert_cxx03.hpp +211 -0
  847. package/vendor/boost/multiprecision/include/boost/config/assert_cxx11.hpp +212 -0
  848. package/vendor/boost/multiprecision/include/boost/config/assert_cxx14.hpp +47 -0
  849. package/vendor/boost/multiprecision/include/boost/config/assert_cxx17.hpp +65 -0
  850. package/vendor/boost/multiprecision/include/boost/config/assert_cxx20.hpp +59 -0
  851. package/vendor/boost/multiprecision/include/boost/config/assert_cxx23.hpp +41 -0
  852. package/vendor/boost/multiprecision/include/boost/config/assert_cxx98.hpp +23 -0
  853. package/vendor/boost/multiprecision/include/boost/config/auto_link.hpp +530 -0
  854. package/vendor/boost/multiprecision/include/boost/config/compiler/borland.hpp +342 -0
  855. package/vendor/boost/multiprecision/include/boost/config/compiler/clang.hpp +370 -0
  856. package/vendor/boost/multiprecision/include/boost/config/compiler/clang_version.hpp +98 -0
  857. package/vendor/boost/multiprecision/include/boost/config/compiler/codegear.hpp +389 -0
  858. package/vendor/boost/multiprecision/include/boost/config/compiler/comeau.hpp +59 -0
  859. package/vendor/boost/multiprecision/include/boost/config/compiler/common_edg.hpp +185 -0
  860. package/vendor/boost/multiprecision/include/boost/config/compiler/compaq_cxx.hpp +19 -0
  861. package/vendor/boost/multiprecision/include/boost/config/compiler/cray.hpp +446 -0
  862. package/vendor/boost/multiprecision/include/boost/config/compiler/diab.hpp +26 -0
  863. package/vendor/boost/multiprecision/include/boost/config/compiler/digitalmars.hpp +146 -0
  864. package/vendor/boost/multiprecision/include/boost/config/compiler/gcc.hpp +386 -0
  865. package/vendor/boost/multiprecision/include/boost/config/compiler/gcc_xml.hpp +115 -0
  866. package/vendor/boost/multiprecision/include/boost/config/compiler/greenhills.hpp +28 -0
  867. package/vendor/boost/multiprecision/include/boost/config/compiler/hp_acc.hpp +153 -0
  868. package/vendor/boost/multiprecision/include/boost/config/compiler/intel.hpp +577 -0
  869. package/vendor/boost/multiprecision/include/boost/config/compiler/kai.hpp +33 -0
  870. package/vendor/boost/multiprecision/include/boost/config/compiler/metrowerks.hpp +201 -0
  871. package/vendor/boost/multiprecision/include/boost/config/compiler/mpw.hpp +143 -0
  872. package/vendor/boost/multiprecision/include/boost/config/compiler/nvcc.hpp +64 -0
  873. package/vendor/boost/multiprecision/include/boost/config/compiler/pathscale.hpp +141 -0
  874. package/vendor/boost/multiprecision/include/boost/config/compiler/pgi.hpp +23 -0
  875. package/vendor/boost/multiprecision/include/boost/config/compiler/sgi_mipspro.hpp +29 -0
  876. package/vendor/boost/multiprecision/include/boost/config/compiler/sunpro_cc.hpp +225 -0
  877. package/vendor/boost/multiprecision/include/boost/config/compiler/vacpp.hpp +189 -0
  878. package/vendor/boost/multiprecision/include/boost/config/compiler/visualc.hpp +400 -0
  879. package/vendor/boost/multiprecision/include/boost/config/compiler/xlcpp.hpp +303 -0
  880. package/vendor/boost/multiprecision/include/boost/config/compiler/xlcpp_zos.hpp +174 -0
  881. package/vendor/boost/multiprecision/include/boost/config/detail/cxx_composite.hpp +218 -0
  882. package/vendor/boost/multiprecision/include/boost/config/detail/posix_features.hpp +95 -0
  883. package/vendor/boost/multiprecision/include/boost/config/detail/select_compiler_config.hpp +157 -0
  884. package/vendor/boost/multiprecision/include/boost/config/detail/select_platform_config.hpp +147 -0
  885. package/vendor/boost/multiprecision/include/boost/config/detail/select_stdlib_config.hpp +121 -0
  886. package/vendor/boost/multiprecision/include/boost/config/detail/suffix.hpp +1334 -0
  887. package/vendor/boost/multiprecision/include/boost/config/header_deprecated.hpp +26 -0
  888. package/vendor/boost/multiprecision/include/boost/config/helper_macros.hpp +37 -0
  889. package/vendor/boost/multiprecision/include/boost/config/no_tr1/cmath.hpp +28 -0
  890. package/vendor/boost/multiprecision/include/boost/config/no_tr1/complex.hpp +28 -0
  891. package/vendor/boost/multiprecision/include/boost/config/no_tr1/functional.hpp +28 -0
  892. package/vendor/boost/multiprecision/include/boost/config/no_tr1/memory.hpp +28 -0
  893. package/vendor/boost/multiprecision/include/boost/config/no_tr1/utility.hpp +28 -0
  894. package/vendor/boost/multiprecision/include/boost/config/platform/aix.hpp +33 -0
  895. package/vendor/boost/multiprecision/include/boost/config/platform/amigaos.hpp +15 -0
  896. package/vendor/boost/multiprecision/include/boost/config/platform/beos.hpp +26 -0
  897. package/vendor/boost/multiprecision/include/boost/config/platform/bsd.hpp +83 -0
  898. package/vendor/boost/multiprecision/include/boost/config/platform/cloudabi.hpp +18 -0
  899. package/vendor/boost/multiprecision/include/boost/config/platform/cray.hpp +18 -0
  900. package/vendor/boost/multiprecision/include/boost/config/platform/cygwin.hpp +71 -0
  901. package/vendor/boost/multiprecision/include/boost/config/platform/haiku.hpp +31 -0
  902. package/vendor/boost/multiprecision/include/boost/config/platform/hpux.hpp +87 -0
  903. package/vendor/boost/multiprecision/include/boost/config/platform/irix.hpp +31 -0
  904. package/vendor/boost/multiprecision/include/boost/config/platform/linux.hpp +106 -0
  905. package/vendor/boost/multiprecision/include/boost/config/platform/macos.hpp +87 -0
  906. package/vendor/boost/multiprecision/include/boost/config/platform/qnxnto.hpp +31 -0
  907. package/vendor/boost/multiprecision/include/boost/config/platform/solaris.hpp +31 -0
  908. package/vendor/boost/multiprecision/include/boost/config/platform/symbian.hpp +97 -0
  909. package/vendor/boost/multiprecision/include/boost/config/platform/vms.hpp +25 -0
  910. package/vendor/boost/multiprecision/include/boost/config/platform/vxworks.hpp +422 -0
  911. package/vendor/boost/multiprecision/include/boost/config/platform/wasm.hpp +23 -0
  912. package/vendor/boost/multiprecision/include/boost/config/platform/win32.hpp +90 -0
  913. package/vendor/boost/multiprecision/include/boost/config/platform/zos.hpp +32 -0
  914. package/vendor/boost/multiprecision/include/boost/config/pragma_message.hpp +31 -0
  915. package/vendor/boost/multiprecision/include/boost/config/requires_threads.hpp +92 -0
  916. package/vendor/boost/multiprecision/include/boost/config/stdlib/dinkumware.hpp +324 -0
  917. package/vendor/boost/multiprecision/include/boost/config/stdlib/libcomo.hpp +93 -0
  918. package/vendor/boost/multiprecision/include/boost/config/stdlib/libcpp.hpp +185 -0
  919. package/vendor/boost/multiprecision/include/boost/config/stdlib/libstdcpp3.hpp +482 -0
  920. package/vendor/boost/multiprecision/include/boost/config/stdlib/modena.hpp +79 -0
  921. package/vendor/boost/multiprecision/include/boost/config/stdlib/msl.hpp +98 -0
  922. package/vendor/boost/multiprecision/include/boost/config/stdlib/roguewave.hpp +208 -0
  923. package/vendor/boost/multiprecision/include/boost/config/stdlib/sgi.hpp +168 -0
  924. package/vendor/boost/multiprecision/include/boost/config/stdlib/stlport.hpp +258 -0
  925. package/vendor/boost/multiprecision/include/boost/config/stdlib/vacpp.hpp +74 -0
  926. package/vendor/boost/multiprecision/include/boost/config/stdlib/xlcpp_zos.hpp +61 -0
  927. package/vendor/boost/multiprecision/include/boost/config/user.hpp +133 -0
  928. package/vendor/boost/multiprecision/include/boost/config/warning_disable.hpp +47 -0
  929. package/vendor/boost/multiprecision/include/boost/config/workaround.hpp +310 -0
  930. package/vendor/boost/multiprecision/include/boost/config.hpp +67 -0
  931. package/vendor/boost/multiprecision/include/boost/cstdint.hpp +556 -0
  932. package/vendor/boost/multiprecision/include/boost/cxx11_char_types.hpp +70 -0
  933. package/vendor/boost/multiprecision/include/boost/detail/workaround.hpp +10 -0
  934. package/vendor/boost/multiprecision/include/boost/limits.hpp +146 -0
  935. package/vendor/boost/multiprecision/include/boost/multiprecision/complex128.hpp +24 -0
  936. package/vendor/boost/multiprecision/include/boost/multiprecision/complex_adaptor.hpp +1049 -0
  937. package/vendor/boost/multiprecision/include/boost/multiprecision/concepts/mp_number_archetypes.hpp +257 -0
  938. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float/io.hpp +700 -0
  939. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float/transcendental.hpp +157 -0
  940. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float.hpp +2374 -0
  941. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_complex.hpp +12 -0
  942. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_dec_float.hpp +3807 -0
  943. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail.hpp +177 -0
  944. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath.hpp +25 -0
  945. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fabs.hpp +27 -0
  946. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_floor.hpp +116 -0
  947. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fma.hpp +65 -0
  948. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fpclassify.hpp +52 -0
  949. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_frexp.hpp +93 -0
  950. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_isinf.hpp +24 -0
  951. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_isnan.hpp +21 -0
  952. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_ldexp.hpp +71 -0
  953. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_limits.hpp +218 -0
  954. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_log.hpp +172 -0
  955. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_sqrt.hpp +57 -0
  956. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_constants.hpp +80 -0
  957. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_double_fp.hpp +2690 -0
  958. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/add.hpp +368 -0
  959. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/add_unsigned.hpp +387 -0
  960. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/bitwise.hpp +896 -0
  961. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/checked.hpp +178 -0
  962. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/comparison.hpp +374 -0
  963. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/cpp_int_config.hpp +161 -0
  964. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/divide.hpp +703 -0
  965. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/import_export.hpp +248 -0
  966. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/intel_intrinsics.hpp +138 -0
  967. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/limits.hpp +292 -0
  968. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/literals.hpp +296 -0
  969. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/misc.hpp +1462 -0
  970. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/multiply.hpp +848 -0
  971. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/serialize.hpp +209 -0
  972. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/value_pack.hpp +42 -0
  973. package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int.hpp +2360 -0
  974. package/vendor/boost/multiprecision/include/boost/multiprecision/debug_adaptor.hpp +760 -0
  975. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/assert.hpp +29 -0
  976. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/atomic.hpp +62 -0
  977. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/bitscan.hpp +317 -0
  978. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/check_cpp11_config.hpp +64 -0
  979. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/constexpr.hpp +88 -0
  980. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/default_ops.hpp +4077 -0
  981. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/digits.hpp +49 -0
  982. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/dynamic_array.hpp +44 -0
  983. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/empty_value.hpp +87 -0
  984. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/endian.hpp +35 -0
  985. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/et_ops.hpp +1831 -0
  986. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/float128_functions.hpp +95 -0
  987. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/float_string_cvt.hpp +333 -0
  988. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/fpclassify.hpp +101 -0
  989. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/constants.hpp +289 -0
  990. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/pow.hpp +941 -0
  991. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/trig.hpp +1064 -0
  992. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/trunc.hpp +82 -0
  993. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/generic_interconvert.hpp +687 -0
  994. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/hash.hpp +56 -0
  995. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/integer_ops.hpp +474 -0
  996. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/itos.hpp +39 -0
  997. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/min_max.hpp +106 -0
  998. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/no_et_ops.hpp +661 -0
  999. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/no_exceptions_support.hpp +55 -0
  1000. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/number_base.hpp +1656 -0
  1001. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/number_compare.hpp +848 -0
  1002. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/precision.hpp +313 -0
  1003. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/rebind.hpp +19 -0
  1004. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/standalone_config.hpp +165 -0
  1005. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/static_array.hpp +42 -0
  1006. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/string_helpers.hpp +48 -0
  1007. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/tables.hpp +80 -0
  1008. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/ublas_interop.hpp +75 -0
  1009. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/uniform_int_distribution.hpp +212 -0
  1010. package/vendor/boost/multiprecision/include/boost/multiprecision/detail/utype_helper.hpp +374 -0
  1011. package/vendor/boost/multiprecision/include/boost/multiprecision/eigen.hpp +248 -0
  1012. package/vendor/boost/multiprecision/include/boost/multiprecision/float128.hpp +960 -0
  1013. package/vendor/boost/multiprecision/include/boost/multiprecision/fwd.hpp +268 -0
  1014. package/vendor/boost/multiprecision/include/boost/multiprecision/gmp.hpp +4100 -0
  1015. package/vendor/boost/multiprecision/include/boost/multiprecision/integer.hpp +363 -0
  1016. package/vendor/boost/multiprecision/include/boost/multiprecision/logged_adaptor.hpp +834 -0
  1017. package/vendor/boost/multiprecision/include/boost/multiprecision/miller_rabin.hpp +221 -0
  1018. package/vendor/boost/multiprecision/include/boost/multiprecision/mpc.hpp +1721 -0
  1019. package/vendor/boost/multiprecision/include/boost/multiprecision/mpfi.hpp +2579 -0
  1020. package/vendor/boost/multiprecision/include/boost/multiprecision/mpfr.hpp +3668 -0
  1021. package/vendor/boost/multiprecision/include/boost/multiprecision/number.hpp +2491 -0
  1022. package/vendor/boost/multiprecision/include/boost/multiprecision/random.hpp +23 -0
  1023. package/vendor/boost/multiprecision/include/boost/multiprecision/rational_adaptor.hpp +1289 -0
  1024. package/vendor/boost/multiprecision/include/boost/multiprecision/tommath.hpp +1044 -0
  1025. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/explicit_conversion.hpp +67 -0
  1026. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/extract_exponent_type.hpp +28 -0
  1027. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_backend.hpp +91 -0
  1028. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_byte_container.hpp +51 -0
  1029. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_complex.hpp +22 -0
  1030. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_convertible_arithmetic.hpp +51 -0
  1031. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_restricted_conversion.hpp +47 -0
  1032. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_variable_precision.hpp +25 -0
  1033. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/max_digits10.hpp +79 -0
  1034. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/std_integer_traits.hpp +95 -0
  1035. package/vendor/boost/multiprecision/include/boost/multiprecision/traits/transcendental_reduction_type.hpp +21 -0
  1036. package/vendor/boost/multiprecision/include/boost/static_assert.hpp +179 -0
  1037. package/vendor/boost/multiprecision/include/boost/version.hpp +32 -0
  1038. package/vendor/eigen/COPYING.APACHE +203 -0
  1039. package/vendor/eigen/COPYING.BSD +26 -0
  1040. package/vendor/eigen/COPYING.MPL2 +373 -0
  1041. package/vendor/eigen/COPYING.README +6 -0
  1042. package/vendor/eigen/Eigen/AccelerateSupport +52 -0
  1043. package/vendor/eigen/Eigen/Cholesky +43 -0
  1044. package/vendor/eigen/Eigen/CholmodSupport +48 -0
  1045. package/vendor/eigen/Eigen/Core +451 -0
  1046. package/vendor/eigen/Eigen/Dense +7 -0
  1047. package/vendor/eigen/Eigen/Eigen +2 -0
  1048. package/vendor/eigen/Eigen/Eigenvalues +63 -0
  1049. package/vendor/eigen/Eigen/Geometry +59 -0
  1050. package/vendor/eigen/Eigen/Householder +31 -0
  1051. package/vendor/eigen/Eigen/IterativeLinearSolvers +52 -0
  1052. package/vendor/eigen/Eigen/Jacobi +33 -0
  1053. package/vendor/eigen/Eigen/KLUSupport +43 -0
  1054. package/vendor/eigen/Eigen/LU +46 -0
  1055. package/vendor/eigen/Eigen/MetisSupport +35 -0
  1056. package/vendor/eigen/Eigen/OrderingMethods +73 -0
  1057. package/vendor/eigen/Eigen/PaStiXSupport +51 -0
  1058. package/vendor/eigen/Eigen/PardisoSupport +38 -0
  1059. package/vendor/eigen/Eigen/QR +48 -0
  1060. package/vendor/eigen/Eigen/QtAlignedMalloc +32 -0
  1061. package/vendor/eigen/Eigen/SPQRSupport +41 -0
  1062. package/vendor/eigen/Eigen/SVD +56 -0
  1063. package/vendor/eigen/Eigen/Sparse +33 -0
  1064. package/vendor/eigen/Eigen/SparseCholesky +40 -0
  1065. package/vendor/eigen/Eigen/SparseCore +70 -0
  1066. package/vendor/eigen/Eigen/SparseLU +50 -0
  1067. package/vendor/eigen/Eigen/SparseQR +38 -0
  1068. package/vendor/eigen/Eigen/StdDeque +30 -0
  1069. package/vendor/eigen/Eigen/StdList +29 -0
  1070. package/vendor/eigen/Eigen/StdVector +30 -0
  1071. package/vendor/eigen/Eigen/SuperLUSupport +70 -0
  1072. package/vendor/eigen/Eigen/ThreadPool +80 -0
  1073. package/vendor/eigen/Eigen/UmfPackSupport +42 -0
  1074. package/vendor/eigen/Eigen/Version +14 -0
  1075. package/vendor/eigen/Eigen/src/AccelerateSupport/AccelerateSupport.h +423 -0
  1076. package/vendor/eigen/Eigen/src/AccelerateSupport/InternalHeaderCheck.h +3 -0
  1077. package/vendor/eigen/Eigen/src/Cholesky/InternalHeaderCheck.h +3 -0
  1078. package/vendor/eigen/Eigen/src/Cholesky/LDLT.h +649 -0
  1079. package/vendor/eigen/Eigen/src/Cholesky/LLT.h +514 -0
  1080. package/vendor/eigen/Eigen/src/Cholesky/LLT_LAPACKE.h +124 -0
  1081. package/vendor/eigen/Eigen/src/CholmodSupport/CholmodSupport.h +738 -0
  1082. package/vendor/eigen/Eigen/src/CholmodSupport/InternalHeaderCheck.h +3 -0
  1083. package/vendor/eigen/Eigen/src/Core/ArithmeticSequence.h +239 -0
  1084. package/vendor/eigen/Eigen/src/Core/Array.h +376 -0
  1085. package/vendor/eigen/Eigen/src/Core/ArrayBase.h +213 -0
  1086. package/vendor/eigen/Eigen/src/Core/ArrayWrapper.h +165 -0
  1087. package/vendor/eigen/Eigen/src/Core/Assign.h +80 -0
  1088. package/vendor/eigen/Eigen/src/Core/AssignEvaluator.h +1057 -0
  1089. package/vendor/eigen/Eigen/src/Core/Assign_MKL.h +183 -0
  1090. package/vendor/eigen/Eigen/src/Core/BandMatrix.h +338 -0
  1091. package/vendor/eigen/Eigen/src/Core/Block.h +429 -0
  1092. package/vendor/eigen/Eigen/src/Core/CommaInitializer.h +149 -0
  1093. package/vendor/eigen/Eigen/src/Core/ConditionEstimator.h +173 -0
  1094. package/vendor/eigen/Eigen/src/Core/CoreEvaluators.h +2018 -0
  1095. package/vendor/eigen/Eigen/src/Core/CoreIterators.h +141 -0
  1096. package/vendor/eigen/Eigen/src/Core/CwiseBinaryOp.h +166 -0
  1097. package/vendor/eigen/Eigen/src/Core/CwiseNullaryOp.h +975 -0
  1098. package/vendor/eigen/Eigen/src/Core/CwiseTernaryOp.h +171 -0
  1099. package/vendor/eigen/Eigen/src/Core/CwiseUnaryOp.h +91 -0
  1100. package/vendor/eigen/Eigen/src/Core/CwiseUnaryView.h +167 -0
  1101. package/vendor/eigen/Eigen/src/Core/DenseBase.h +673 -0
  1102. package/vendor/eigen/Eigen/src/Core/DenseCoeffsBase.h +568 -0
  1103. package/vendor/eigen/Eigen/src/Core/DenseStorage.h +573 -0
  1104. package/vendor/eigen/Eigen/src/Core/DeviceWrapper.h +153 -0
  1105. package/vendor/eigen/Eigen/src/Core/Diagonal.h +219 -0
  1106. package/vendor/eigen/Eigen/src/Core/DiagonalMatrix.h +420 -0
  1107. package/vendor/eigen/Eigen/src/Core/DiagonalProduct.h +30 -0
  1108. package/vendor/eigen/Eigen/src/Core/Dot.h +268 -0
  1109. package/vendor/eigen/Eigen/src/Core/EigenBase.h +149 -0
  1110. package/vendor/eigen/Eigen/src/Core/Fill.h +138 -0
  1111. package/vendor/eigen/Eigen/src/Core/FindCoeff.h +464 -0
  1112. package/vendor/eigen/Eigen/src/Core/ForceAlignedAccess.h +127 -0
  1113. package/vendor/eigen/Eigen/src/Core/Fuzzy.h +132 -0
  1114. package/vendor/eigen/Eigen/src/Core/GeneralProduct.h +519 -0
  1115. package/vendor/eigen/Eigen/src/Core/GenericPacketMath.h +1702 -0
  1116. package/vendor/eigen/Eigen/src/Core/GlobalFunctions.h +230 -0
  1117. package/vendor/eigen/Eigen/src/Core/IO.h +233 -0
  1118. package/vendor/eigen/Eigen/src/Core/IndexedView.h +321 -0
  1119. package/vendor/eigen/Eigen/src/Core/InnerProduct.h +260 -0
  1120. package/vendor/eigen/Eigen/src/Core/InternalHeaderCheck.h +3 -0
  1121. package/vendor/eigen/Eigen/src/Core/Inverse.h +108 -0
  1122. package/vendor/eigen/Eigen/src/Core/Map.h +153 -0
  1123. package/vendor/eigen/Eigen/src/Core/MapBase.h +283 -0
  1124. package/vendor/eigen/Eigen/src/Core/MathFunctions.h +2103 -0
  1125. package/vendor/eigen/Eigen/src/Core/MathFunctionsImpl.h +263 -0
  1126. package/vendor/eigen/Eigen/src/Core/Matrix.h +534 -0
  1127. package/vendor/eigen/Eigen/src/Core/MatrixBase.h +545 -0
  1128. package/vendor/eigen/Eigen/src/Core/NestByValue.h +91 -0
  1129. package/vendor/eigen/Eigen/src/Core/NoAlias.h +102 -0
  1130. package/vendor/eigen/Eigen/src/Core/NumTraits.h +335 -0
  1131. package/vendor/eigen/Eigen/src/Core/PartialReduxEvaluator.h +253 -0
  1132. package/vendor/eigen/Eigen/src/Core/PermutationMatrix.h +555 -0
  1133. package/vendor/eigen/Eigen/src/Core/PlainObjectBase.h +1014 -0
  1134. package/vendor/eigen/Eigen/src/Core/Product.h +307 -0
  1135. package/vendor/eigen/Eigen/src/Core/ProductEvaluators.h +1287 -0
  1136. package/vendor/eigen/Eigen/src/Core/Random.h +207 -0
  1137. package/vendor/eigen/Eigen/src/Core/RandomImpl.h +262 -0
  1138. package/vendor/eigen/Eigen/src/Core/RealView.h +250 -0
  1139. package/vendor/eigen/Eigen/src/Core/Redux.h +535 -0
  1140. package/vendor/eigen/Eigen/src/Core/Ref.h +383 -0
  1141. package/vendor/eigen/Eigen/src/Core/Replicate.h +130 -0
  1142. package/vendor/eigen/Eigen/src/Core/Reshaped.h +398 -0
  1143. package/vendor/eigen/Eigen/src/Core/ReturnByValue.h +111 -0
  1144. package/vendor/eigen/Eigen/src/Core/Reverse.h +202 -0
  1145. package/vendor/eigen/Eigen/src/Core/Select.h +92 -0
  1146. package/vendor/eigen/Eigen/src/Core/SelfAdjointView.h +329 -0
  1147. package/vendor/eigen/Eigen/src/Core/SelfCwiseBinaryOp.h +50 -0
  1148. package/vendor/eigen/Eigen/src/Core/SkewSymmetricMatrix3.h +382 -0
  1149. package/vendor/eigen/Eigen/src/Core/Solve.h +174 -0
  1150. package/vendor/eigen/Eigen/src/Core/SolveTriangular.h +237 -0
  1151. package/vendor/eigen/Eigen/src/Core/SolverBase.h +167 -0
  1152. package/vendor/eigen/Eigen/src/Core/StableNorm.h +217 -0
  1153. package/vendor/eigen/Eigen/src/Core/StlIterators.h +619 -0
  1154. package/vendor/eigen/Eigen/src/Core/Stride.h +114 -0
  1155. package/vendor/eigen/Eigen/src/Core/Swap.h +99 -0
  1156. package/vendor/eigen/Eigen/src/Core/Transpose.h +427 -0
  1157. package/vendor/eigen/Eigen/src/Core/Transpositions.h +323 -0
  1158. package/vendor/eigen/Eigen/src/Core/TriangularMatrix.h +900 -0
  1159. package/vendor/eigen/Eigen/src/Core/VectorBlock.h +83 -0
  1160. package/vendor/eigen/Eigen/src/Core/VectorwiseOp.h +733 -0
  1161. package/vendor/eigen/Eigen/src/Core/Visitor.h +537 -0
  1162. package/vendor/eigen/Eigen/src/Core/arch/AVX/Complex.h +565 -0
  1163. package/vendor/eigen/Eigen/src/Core/arch/AVX/MathFunctions.h +130 -0
  1164. package/vendor/eigen/Eigen/src/Core/arch/AVX/PacketMath.h +3081 -0
  1165. package/vendor/eigen/Eigen/src/Core/arch/AVX/Reductions.h +353 -0
  1166. package/vendor/eigen/Eigen/src/Core/arch/AVX/TypeCasting.h +308 -0
  1167. package/vendor/eigen/Eigen/src/Core/arch/AVX512/Complex.h +472 -0
  1168. package/vendor/eigen/Eigen/src/Core/arch/AVX512/GemmKernel.h +1245 -0
  1169. package/vendor/eigen/Eigen/src/Core/arch/AVX512/MathFunctions.h +141 -0
  1170. package/vendor/eigen/Eigen/src/Core/arch/AVX512/MathFunctionsFP16.h +75 -0
  1171. package/vendor/eigen/Eigen/src/Core/arch/AVX512/PacketMath.h +3146 -0
  1172. package/vendor/eigen/Eigen/src/Core/arch/AVX512/PacketMathFP16.h +1413 -0
  1173. package/vendor/eigen/Eigen/src/Core/arch/AVX512/Reductions.h +297 -0
  1174. package/vendor/eigen/Eigen/src/Core/arch/AVX512/TrsmKernel.h +1167 -0
  1175. package/vendor/eigen/Eigen/src/Core/arch/AVX512/TrsmUnrolls.inc +1219 -0
  1176. package/vendor/eigen/Eigen/src/Core/arch/AVX512/TypeCasting.h +277 -0
  1177. package/vendor/eigen/Eigen/src/Core/arch/AVX512/TypeCastingFP16.h +130 -0
  1178. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/Complex.h +653 -0
  1179. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MathFunctions.h +81 -0
  1180. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProduct.h +3686 -0
  1181. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductCommon.h +205 -0
  1182. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductMMA.h +901 -0
  1183. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductMMAbfloat16.h +742 -0
  1184. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixVectorProduct.inc +2818 -0
  1185. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/PacketMath.h +3729 -0
  1186. package/vendor/eigen/Eigen/src/Core/arch/AltiVec/TypeCasting.h +153 -0
  1187. package/vendor/eigen/Eigen/src/Core/arch/Default/BFloat16.h +866 -0
  1188. package/vendor/eigen/Eigen/src/Core/arch/Default/ConjHelper.h +128 -0
  1189. package/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h +2634 -0
  1190. package/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctionsFwd.h +227 -0
  1191. package/vendor/eigen/Eigen/src/Core/arch/Default/Half.h +1091 -0
  1192. package/vendor/eigen/Eigen/src/Core/arch/Default/Settings.h +47 -0
  1193. package/vendor/eigen/Eigen/src/Core/arch/GPU/Complex.h +244 -0
  1194. package/vendor/eigen/Eigen/src/Core/arch/GPU/MathFunctions.h +104 -0
  1195. package/vendor/eigen/Eigen/src/Core/arch/GPU/PacketMath.h +1712 -0
  1196. package/vendor/eigen/Eigen/src/Core/arch/GPU/Tuple.h +268 -0
  1197. package/vendor/eigen/Eigen/src/Core/arch/GPU/TypeCasting.h +77 -0
  1198. package/vendor/eigen/Eigen/src/Core/arch/HIP/hcc/math_constants.h +23 -0
  1199. package/vendor/eigen/Eigen/src/Core/arch/HVX/PacketMath.h +1088 -0
  1200. package/vendor/eigen/Eigen/src/Core/arch/LSX/Complex.h +520 -0
  1201. package/vendor/eigen/Eigen/src/Core/arch/LSX/GeneralBlockPanelKernel.h +23 -0
  1202. package/vendor/eigen/Eigen/src/Core/arch/LSX/MathFunctions.h +43 -0
  1203. package/vendor/eigen/Eigen/src/Core/arch/LSX/PacketMath.h +2866 -0
  1204. package/vendor/eigen/Eigen/src/Core/arch/LSX/TypeCasting.h +526 -0
  1205. package/vendor/eigen/Eigen/src/Core/arch/MSA/Complex.h +620 -0
  1206. package/vendor/eigen/Eigen/src/Core/arch/MSA/MathFunctions.h +379 -0
  1207. package/vendor/eigen/Eigen/src/Core/arch/MSA/PacketMath.h +1237 -0
  1208. package/vendor/eigen/Eigen/src/Core/arch/NEON/Complex.h +732 -0
  1209. package/vendor/eigen/Eigen/src/Core/arch/NEON/GeneralBlockPanelKernel.h +243 -0
  1210. package/vendor/eigen/Eigen/src/Core/arch/NEON/MathFunctions.h +68 -0
  1211. package/vendor/eigen/Eigen/src/Core/arch/NEON/PacketMath.h +6096 -0
  1212. package/vendor/eigen/Eigen/src/Core/arch/NEON/TypeCasting.h +1642 -0
  1213. package/vendor/eigen/Eigen/src/Core/arch/NEON/UnaryFunctors.h +57 -0
  1214. package/vendor/eigen/Eigen/src/Core/arch/SSE/Complex.h +503 -0
  1215. package/vendor/eigen/Eigen/src/Core/arch/SSE/MathFunctions.h +88 -0
  1216. package/vendor/eigen/Eigen/src/Core/arch/SSE/PacketMath.h +2384 -0
  1217. package/vendor/eigen/Eigen/src/Core/arch/SSE/Reductions.h +324 -0
  1218. package/vendor/eigen/Eigen/src/Core/arch/SSE/TypeCasting.h +230 -0
  1219. package/vendor/eigen/Eigen/src/Core/arch/SVE/MathFunctions.h +48 -0
  1220. package/vendor/eigen/Eigen/src/Core/arch/SVE/PacketMath.h +674 -0
  1221. package/vendor/eigen/Eigen/src/Core/arch/SVE/TypeCasting.h +52 -0
  1222. package/vendor/eigen/Eigen/src/Core/arch/SYCL/InteropHeaders.h +227 -0
  1223. package/vendor/eigen/Eigen/src/Core/arch/SYCL/MathFunctions.h +303 -0
  1224. package/vendor/eigen/Eigen/src/Core/arch/SYCL/PacketMath.h +576 -0
  1225. package/vendor/eigen/Eigen/src/Core/arch/SYCL/TypeCasting.h +83 -0
  1226. package/vendor/eigen/Eigen/src/Core/arch/ZVector/Complex.h +570 -0
  1227. package/vendor/eigen/Eigen/src/Core/arch/ZVector/MathFunctions.h +244 -0
  1228. package/vendor/eigen/Eigen/src/Core/arch/ZVector/PacketMath.h +1413 -0
  1229. package/vendor/eigen/Eigen/src/Core/functors/AssignmentFunctors.h +174 -0
  1230. package/vendor/eigen/Eigen/src/Core/functors/BinaryFunctors.h +747 -0
  1231. package/vendor/eigen/Eigen/src/Core/functors/NullaryFunctors.h +274 -0
  1232. package/vendor/eigen/Eigen/src/Core/functors/StlFunctors.h +149 -0
  1233. package/vendor/eigen/Eigen/src/Core/functors/TernaryFunctors.h +52 -0
  1234. package/vendor/eigen/Eigen/src/Core/functors/UnaryFunctors.h +1420 -0
  1235. package/vendor/eigen/Eigen/src/Core/products/GeneralBlockPanelKernel.h +3153 -0
  1236. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix.h +459 -0
  1237. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h +330 -0
  1238. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h +148 -0
  1239. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix_BLAS.h +205 -0
  1240. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixVector.h +473 -0
  1241. package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixVector_BLAS.h +139 -0
  1242. package/vendor/eigen/Eigen/src/Core/products/Parallelizer.h +282 -0
  1243. package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix.h +483 -0
  1244. package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix_BLAS.h +277 -0
  1245. package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixVector.h +253 -0
  1246. package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixVector_BLAS.h +115 -0
  1247. package/vendor/eigen/Eigen/src/Core/products/SelfadjointProduct.h +133 -0
  1248. package/vendor/eigen/Eigen/src/Core/products/SelfadjointRank2Update.h +95 -0
  1249. package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix.h +397 -0
  1250. package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix_BLAS.h +325 -0
  1251. package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixVector.h +347 -0
  1252. package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixVector_BLAS.h +275 -0
  1253. package/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix.h +388 -0
  1254. package/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix_BLAS.h +166 -0
  1255. package/vendor/eigen/Eigen/src/Core/products/TriangularSolverVector.h +122 -0
  1256. package/vendor/eigen/Eigen/src/Core/util/Assert.h +158 -0
  1257. package/vendor/eigen/Eigen/src/Core/util/BlasUtil.h +622 -0
  1258. package/vendor/eigen/Eigen/src/Core/util/ConfigureVectorization.h +543 -0
  1259. package/vendor/eigen/Eigen/src/Core/util/Constants.h +598 -0
  1260. package/vendor/eigen/Eigen/src/Core/util/DisableStupidWarnings.h +146 -0
  1261. package/vendor/eigen/Eigen/src/Core/util/EmulateArray.h +270 -0
  1262. package/vendor/eigen/Eigen/src/Core/util/ForwardDeclarations.h +524 -0
  1263. package/vendor/eigen/Eigen/src/Core/util/GpuHipCudaDefines.inc +101 -0
  1264. package/vendor/eigen/Eigen/src/Core/util/GpuHipCudaUndefines.inc +45 -0
  1265. package/vendor/eigen/Eigen/src/Core/util/IndexedViewHelper.h +487 -0
  1266. package/vendor/eigen/Eigen/src/Core/util/IntegralConstant.h +279 -0
  1267. package/vendor/eigen/Eigen/src/Core/util/MKL_support.h +139 -0
  1268. package/vendor/eigen/Eigen/src/Core/util/Macros.h +1346 -0
  1269. package/vendor/eigen/Eigen/src/Core/util/MaxSizeVector.h +139 -0
  1270. package/vendor/eigen/Eigen/src/Core/util/Memory.h +1385 -0
  1271. package/vendor/eigen/Eigen/src/Core/util/Meta.h +760 -0
  1272. package/vendor/eigen/Eigen/src/Core/util/MoreMeta.h +638 -0
  1273. package/vendor/eigen/Eigen/src/Core/util/ReenableStupidWarnings.h +44 -0
  1274. package/vendor/eigen/Eigen/src/Core/util/ReshapedHelper.h +51 -0
  1275. package/vendor/eigen/Eigen/src/Core/util/Serializer.h +209 -0
  1276. package/vendor/eigen/Eigen/src/Core/util/StaticAssert.h +105 -0
  1277. package/vendor/eigen/Eigen/src/Core/util/SymbolicIndex.h +445 -0
  1278. package/vendor/eigen/Eigen/src/Core/util/XprHelper.h +1093 -0
  1279. package/vendor/eigen/Eigen/src/Eigenvalues/ComplexEigenSolver.h +315 -0
  1280. package/vendor/eigen/Eigen/src/Eigenvalues/ComplexSchur.h +442 -0
  1281. package/vendor/eigen/Eigen/src/Eigenvalues/ComplexSchur_LAPACKE.h +95 -0
  1282. package/vendor/eigen/Eigen/src/Eigenvalues/EigenSolver.h +579 -0
  1283. package/vendor/eigen/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h +402 -0
  1284. package/vendor/eigen/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h +212 -0
  1285. package/vendor/eigen/Eigen/src/Eigenvalues/HessenbergDecomposition.h +356 -0
  1286. package/vendor/eigen/Eigen/src/Eigenvalues/InternalHeaderCheck.h +3 -0
  1287. package/vendor/eigen/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h +142 -0
  1288. package/vendor/eigen/Eigen/src/Eigenvalues/RealQZ.h +587 -0
  1289. package/vendor/eigen/Eigen/src/Eigenvalues/RealSchur.h +519 -0
  1290. package/vendor/eigen/Eigen/src/Eigenvalues/RealSchur_LAPACKE.h +83 -0
  1291. package/vendor/eigen/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h +850 -0
  1292. package/vendor/eigen/Eigen/src/Eigenvalues/SelfAdjointEigenSolver_LAPACKE.h +90 -0
  1293. package/vendor/eigen/Eigen/src/Eigenvalues/Tridiagonalization.h +529 -0
  1294. package/vendor/eigen/Eigen/src/Geometry/AlignedBox.h +485 -0
  1295. package/vendor/eigen/Eigen/src/Geometry/AngleAxis.h +245 -0
  1296. package/vendor/eigen/Eigen/src/Geometry/EulerAngles.h +203 -0
  1297. package/vendor/eigen/Eigen/src/Geometry/Homogeneous.h +453 -0
  1298. package/vendor/eigen/Eigen/src/Geometry/Hyperplane.h +273 -0
  1299. package/vendor/eigen/Eigen/src/Geometry/InternalHeaderCheck.h +3 -0
  1300. package/vendor/eigen/Eigen/src/Geometry/OrthoMethods.h +257 -0
  1301. package/vendor/eigen/Eigen/src/Geometry/ParametrizedLine.h +232 -0
  1302. package/vendor/eigen/Eigen/src/Geometry/Quaternion.h +930 -0
  1303. package/vendor/eigen/Eigen/src/Geometry/Rotation2D.h +201 -0
  1304. package/vendor/eigen/Eigen/src/Geometry/RotationBase.h +209 -0
  1305. package/vendor/eigen/Eigen/src/Geometry/Scaling.h +195 -0
  1306. package/vendor/eigen/Eigen/src/Geometry/Transform.h +1485 -0
  1307. package/vendor/eigen/Eigen/src/Geometry/Translation.h +204 -0
  1308. package/vendor/eigen/Eigen/src/Geometry/Umeyama.h +161 -0
  1309. package/vendor/eigen/Eigen/src/Geometry/arch/Geometry_SIMD.h +154 -0
  1310. package/vendor/eigen/Eigen/src/Householder/BlockHouseholder.h +115 -0
  1311. package/vendor/eigen/Eigen/src/Householder/Householder.h +154 -0
  1312. package/vendor/eigen/Eigen/src/Householder/HouseholderSequence.h +504 -0
  1313. package/vendor/eigen/Eigen/src/Householder/InternalHeaderCheck.h +3 -0
  1314. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/BasicPreconditioners.h +213 -0
  1315. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h +220 -0
  1316. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/ConjugateGradient.h +217 -0
  1317. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteCholesky.h +402 -0
  1318. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteLUT.h +449 -0
  1319. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/InternalHeaderCheck.h +3 -0
  1320. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IterativeSolverBase.h +395 -0
  1321. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/LeastSquareConjugateGradient.h +193 -0
  1322. package/vendor/eigen/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h +111 -0
  1323. package/vendor/eigen/Eigen/src/Jacobi/InternalHeaderCheck.h +3 -0
  1324. package/vendor/eigen/Eigen/src/Jacobi/Jacobi.h +427 -0
  1325. package/vendor/eigen/Eigen/src/KLUSupport/InternalHeaderCheck.h +3 -0
  1326. package/vendor/eigen/Eigen/src/KLUSupport/KLUSupport.h +339 -0
  1327. package/vendor/eigen/Eigen/src/LU/Determinant.h +98 -0
  1328. package/vendor/eigen/Eigen/src/LU/FullPivLU.h +826 -0
  1329. package/vendor/eigen/Eigen/src/LU/InternalHeaderCheck.h +3 -0
  1330. package/vendor/eigen/Eigen/src/LU/InverseImpl.h +353 -0
  1331. package/vendor/eigen/Eigen/src/LU/PartialPivLU.h +586 -0
  1332. package/vendor/eigen/Eigen/src/LU/PartialPivLU_LAPACKE.h +97 -0
  1333. package/vendor/eigen/Eigen/src/LU/arch/InverseSize4.h +353 -0
  1334. package/vendor/eigen/Eigen/src/MetisSupport/InternalHeaderCheck.h +3 -0
  1335. package/vendor/eigen/Eigen/src/MetisSupport/MetisSupport.h +125 -0
  1336. package/vendor/eigen/Eigen/src/OrderingMethods/Amd.h +413 -0
  1337. package/vendor/eigen/Eigen/src/OrderingMethods/Eigen_Colamd.h +1690 -0
  1338. package/vendor/eigen/Eigen/src/OrderingMethods/InternalHeaderCheck.h +3 -0
  1339. package/vendor/eigen/Eigen/src/OrderingMethods/Ordering.h +146 -0
  1340. package/vendor/eigen/Eigen/src/PaStiXSupport/InternalHeaderCheck.h +3 -0
  1341. package/vendor/eigen/Eigen/src/PaStiXSupport/PaStiXSupport.h +632 -0
  1342. package/vendor/eigen/Eigen/src/PardisoSupport/InternalHeaderCheck.h +3 -0
  1343. package/vendor/eigen/Eigen/src/PardisoSupport/PardisoSupport.h +500 -0
  1344. package/vendor/eigen/Eigen/src/QR/ColPivHouseholderQR.h +674 -0
  1345. package/vendor/eigen/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h +161 -0
  1346. package/vendor/eigen/Eigen/src/QR/CompleteOrthogonalDecomposition.h +648 -0
  1347. package/vendor/eigen/Eigen/src/QR/FullPivHouseholderQR.h +733 -0
  1348. package/vendor/eigen/Eigen/src/QR/HouseholderQR.h +543 -0
  1349. package/vendor/eigen/Eigen/src/QR/HouseholderQR_LAPACKE.h +77 -0
  1350. package/vendor/eigen/Eigen/src/QR/InternalHeaderCheck.h +3 -0
  1351. package/vendor/eigen/Eigen/src/SPQRSupport/InternalHeaderCheck.h +3 -0
  1352. package/vendor/eigen/Eigen/src/SPQRSupport/SuiteSparseQRSupport.h +315 -0
  1353. package/vendor/eigen/Eigen/src/SVD/BDCSVD.h +1470 -0
  1354. package/vendor/eigen/Eigen/src/SVD/BDCSVD_LAPACKE.h +174 -0
  1355. package/vendor/eigen/Eigen/src/SVD/InternalHeaderCheck.h +3 -0
  1356. package/vendor/eigen/Eigen/src/SVD/JacobiSVD.h +846 -0
  1357. package/vendor/eigen/Eigen/src/SVD/JacobiSVD_LAPACKE.h +127 -0
  1358. package/vendor/eigen/Eigen/src/SVD/SVDBase.h +436 -0
  1359. package/vendor/eigen/Eigen/src/SVD/UpperBidiagonalization.h +379 -0
  1360. package/vendor/eigen/Eigen/src/SparseCholesky/InternalHeaderCheck.h +3 -0
  1361. package/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky.h +868 -0
  1362. package/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky_impl.h +388 -0
  1363. package/vendor/eigen/Eigen/src/SparseCore/AmbiVector.h +329 -0
  1364. package/vendor/eigen/Eigen/src/SparseCore/CompressedStorage.h +206 -0
  1365. package/vendor/eigen/Eigen/src/SparseCore/ConservativeSparseSparseProduct.h +308 -0
  1366. package/vendor/eigen/Eigen/src/SparseCore/InternalHeaderCheck.h +3 -0
  1367. package/vendor/eigen/Eigen/src/SparseCore/SparseAssign.h +279 -0
  1368. package/vendor/eigen/Eigen/src/SparseCore/SparseBlock.h +534 -0
  1369. package/vendor/eigen/Eigen/src/SparseCore/SparseColEtree.h +194 -0
  1370. package/vendor/eigen/Eigen/src/SparseCore/SparseCompressedBase.h +592 -0
  1371. package/vendor/eigen/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +938 -0
  1372. package/vendor/eigen/Eigen/src/SparseCore/SparseCwiseUnaryOp.h +142 -0
  1373. package/vendor/eigen/Eigen/src/SparseCore/SparseDenseProduct.h +314 -0
  1374. package/vendor/eigen/Eigen/src/SparseCore/SparseDiagonalProduct.h +138 -0
  1375. package/vendor/eigen/Eigen/src/SparseCore/SparseDot.h +100 -0
  1376. package/vendor/eigen/Eigen/src/SparseCore/SparseFuzzy.h +31 -0
  1377. package/vendor/eigen/Eigen/src/SparseCore/SparseMap.h +295 -0
  1378. package/vendor/eigen/Eigen/src/SparseCore/SparseMatrix.h +1876 -0
  1379. package/vendor/eigen/Eigen/src/SparseCore/SparseMatrixBase.h +451 -0
  1380. package/vendor/eigen/Eigen/src/SparseCore/SparsePermutation.h +249 -0
  1381. package/vendor/eigen/Eigen/src/SparseCore/SparseProduct.h +178 -0
  1382. package/vendor/eigen/Eigen/src/SparseCore/SparseRedux.h +47 -0
  1383. package/vendor/eigen/Eigen/src/SparseCore/SparseRef.h +370 -0
  1384. package/vendor/eigen/Eigen/src/SparseCore/SparseSelfAdjointView.h +613 -0
  1385. package/vendor/eigen/Eigen/src/SparseCore/SparseSolverBase.h +115 -0
  1386. package/vendor/eigen/Eigen/src/SparseCore/SparseSparseProductWithPruning.h +184 -0
  1387. package/vendor/eigen/Eigen/src/SparseCore/SparseTranspose.h +83 -0
  1388. package/vendor/eigen/Eigen/src/SparseCore/SparseTriangularView.h +177 -0
  1389. package/vendor/eigen/Eigen/src/SparseCore/SparseUtil.h +209 -0
  1390. package/vendor/eigen/Eigen/src/SparseCore/SparseVector.h +532 -0
  1391. package/vendor/eigen/Eigen/src/SparseCore/SparseView.h +225 -0
  1392. package/vendor/eigen/Eigen/src/SparseCore/TriangularSolver.h +274 -0
  1393. package/vendor/eigen/Eigen/src/SparseLU/InternalHeaderCheck.h +3 -0
  1394. package/vendor/eigen/Eigen/src/SparseLU/SparseLU.h +969 -0
  1395. package/vendor/eigen/Eigen/src/SparseLU/SparseLUImpl.h +79 -0
  1396. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Memory.h +210 -0
  1397. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Structs.h +113 -0
  1398. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_SupernodalMatrix.h +319 -0
  1399. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Utils.h +75 -0
  1400. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_column_bmod.h +177 -0
  1401. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_column_dfs.h +168 -0
  1402. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_copy_to_ucol.h +106 -0
  1403. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_heap_relax_snode.h +114 -0
  1404. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_kernel_bmod.h +133 -0
  1405. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_panel_bmod.h +215 -0
  1406. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_panel_dfs.h +235 -0
  1407. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_pivotL.h +136 -0
  1408. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_pruneL.h +130 -0
  1409. package/vendor/eigen/Eigen/src/SparseLU/SparseLU_relax_snode.h +81 -0
  1410. package/vendor/eigen/Eigen/src/SparseQR/InternalHeaderCheck.h +3 -0
  1411. package/vendor/eigen/Eigen/src/SparseQR/SparseQR.h +706 -0
  1412. package/vendor/eigen/Eigen/src/StlSupport/StdDeque.h +51 -0
  1413. package/vendor/eigen/Eigen/src/StlSupport/StdList.h +50 -0
  1414. package/vendor/eigen/Eigen/src/StlSupport/StdVector.h +51 -0
  1415. package/vendor/eigen/Eigen/src/StlSupport/details.h +82 -0
  1416. package/vendor/eigen/Eigen/src/SuperLUSupport/InternalHeaderCheck.h +3 -0
  1417. package/vendor/eigen/Eigen/src/SuperLUSupport/SuperLUSupport.h +929 -0
  1418. package/vendor/eigen/Eigen/src/ThreadPool/Barrier.h +70 -0
  1419. package/vendor/eigen/Eigen/src/ThreadPool/CoreThreadPoolDevice.h +336 -0
  1420. package/vendor/eigen/Eigen/src/ThreadPool/EventCount.h +241 -0
  1421. package/vendor/eigen/Eigen/src/ThreadPool/ForkJoin.h +140 -0
  1422. package/vendor/eigen/Eigen/src/ThreadPool/InternalHeaderCheck.h +4 -0
  1423. package/vendor/eigen/Eigen/src/ThreadPool/NonBlockingThreadPool.h +587 -0
  1424. package/vendor/eigen/Eigen/src/ThreadPool/RunQueue.h +230 -0
  1425. package/vendor/eigen/Eigen/src/ThreadPool/ThreadCancel.h +21 -0
  1426. package/vendor/eigen/Eigen/src/ThreadPool/ThreadEnvironment.h +43 -0
  1427. package/vendor/eigen/Eigen/src/ThreadPool/ThreadLocal.h +289 -0
  1428. package/vendor/eigen/Eigen/src/ThreadPool/ThreadPoolInterface.h +50 -0
  1429. package/vendor/eigen/Eigen/src/ThreadPool/ThreadYield.h +16 -0
  1430. package/vendor/eigen/Eigen/src/UmfPackSupport/InternalHeaderCheck.h +3 -0
  1431. package/vendor/eigen/Eigen/src/UmfPackSupport/UmfPackSupport.h +606 -0
  1432. package/vendor/eigen/Eigen/src/misc/Image.h +80 -0
  1433. package/vendor/eigen/Eigen/src/misc/InternalHeaderCheck.h +3 -0
  1434. package/vendor/eigen/Eigen/src/misc/Kernel.h +77 -0
  1435. package/vendor/eigen/Eigen/src/misc/RealSvd2x2.h +53 -0
  1436. package/vendor/eigen/Eigen/src/misc/blas.h +97 -0
  1437. package/vendor/eigen/Eigen/src/misc/lapacke.h +10085 -0
  1438. package/vendor/eigen/Eigen/src/misc/lapacke_helpers.h +163 -0
  1439. package/vendor/eigen/Eigen/src/misc/lapacke_mangling.h +16 -0
  1440. package/vendor/eigen/Eigen/src/plugins/ArrayCwiseBinaryOps.inc +344 -0
  1441. package/vendor/eigen/Eigen/src/plugins/ArrayCwiseUnaryOps.inc +544 -0
  1442. package/vendor/eigen/Eigen/src/plugins/BlockMethods.inc +1370 -0
  1443. package/vendor/eigen/Eigen/src/plugins/CommonCwiseBinaryOps.inc +116 -0
  1444. package/vendor/eigen/Eigen/src/plugins/CommonCwiseUnaryOps.inc +167 -0
  1445. package/vendor/eigen/Eigen/src/plugins/IndexedViewMethods.inc +192 -0
  1446. package/vendor/eigen/Eigen/src/plugins/InternalHeaderCheck.inc +3 -0
  1447. package/vendor/eigen/Eigen/src/plugins/MatrixCwiseBinaryOps.inc +331 -0
  1448. package/vendor/eigen/Eigen/src/plugins/MatrixCwiseUnaryOps.inc +118 -0
  1449. package/vendor/eigen/Eigen/src/plugins/ReshapedMethods.inc +133 -0
  1450. package/vendor/eigen/README.md +5 -0
  1451. package/vendor/mpdecimal/COPYRIGHT.txt +23 -0
  1452. package/vendor/mpdecimal/README.txt +53 -0
  1453. package/vendor/mpdecimal/libmpdec/.objs/README.txt +8 -0
  1454. package/vendor/mpdecimal/libmpdec/.objs/symbols32.exp +343 -0
  1455. package/vendor/mpdecimal/libmpdec/.objs/symbols64.exp +347 -0
  1456. package/vendor/mpdecimal/libmpdec/.pc/libmpdec.pc.in +11 -0
  1457. package/vendor/mpdecimal/libmpdec/.profile/train.sh +35 -0
  1458. package/vendor/mpdecimal/libmpdec/README.txt +84 -0
  1459. package/vendor/mpdecimal/libmpdec/basearith.c +649 -0
  1460. package/vendor/mpdecimal/libmpdec/basearith.h +217 -0
  1461. package/vendor/mpdecimal/libmpdec/bits.h +188 -0
  1462. package/vendor/mpdecimal/libmpdec/constants.c +129 -0
  1463. package/vendor/mpdecimal/libmpdec/constants.h +88 -0
  1464. package/vendor/mpdecimal/libmpdec/context.c +285 -0
  1465. package/vendor/mpdecimal/libmpdec/convolute.c +172 -0
  1466. package/vendor/mpdecimal/libmpdec/convolute.h +48 -0
  1467. package/vendor/mpdecimal/libmpdec/crt.c +178 -0
  1468. package/vendor/mpdecimal/libmpdec/crt.h +45 -0
  1469. package/vendor/mpdecimal/libmpdec/difradix2.c +171 -0
  1470. package/vendor/mpdecimal/libmpdec/difradix2.h +46 -0
  1471. package/vendor/mpdecimal/libmpdec/fnt.c +77 -0
  1472. package/vendor/mpdecimal/libmpdec/fnt.h +46 -0
  1473. package/vendor/mpdecimal/libmpdec/fourstep.c +242 -0
  1474. package/vendor/mpdecimal/libmpdec/fourstep.h +46 -0
  1475. package/vendor/mpdecimal/libmpdec/io.c +1610 -0
  1476. package/vendor/mpdecimal/libmpdec/io.h +61 -0
  1477. package/vendor/mpdecimal/libmpdec/mpalloc.c +347 -0
  1478. package/vendor/mpdecimal/libmpdec/mpalloc.h +53 -0
  1479. package/vendor/mpdecimal/libmpdec/mpdecimal.c +9155 -0
  1480. package/vendor/mpdecimal/libmpdec/mpdecimal.h.in +804 -0
  1481. package/vendor/mpdecimal/libmpdec/mpsignal.c +966 -0
  1482. package/vendor/mpdecimal/libmpdec/numbertheory.c +129 -0
  1483. package/vendor/mpdecimal/libmpdec/numbertheory.h +75 -0
  1484. package/vendor/mpdecimal/libmpdec/sixstep.c +212 -0
  1485. package/vendor/mpdecimal/libmpdec/sixstep.h +46 -0
  1486. package/vendor/mpdecimal/libmpdec/transpose.c +275 -0
  1487. package/vendor/mpdecimal/libmpdec/transpose.h +60 -0
  1488. package/vendor/mpdecimal/libmpdec/typearith.h +661 -0
  1489. package/vendor/mpdecimal/libmpdec/umodarith.h +645 -0
  1490. package/vendor/symengine/AUTHORS +101 -0
  1491. package/vendor/symengine/LICENSE +254 -0
  1492. package/vendor/symengine/README.md +199 -0
  1493. package/vendor/symengine/symengine/add.cpp +508 -0
  1494. package/vendor/symengine/symengine/add.h +187 -0
  1495. package/vendor/symengine/symengine/as_real_imag.cpp +289 -0
  1496. package/vendor/symengine/symengine/assumptions.cpp +202 -0
  1497. package/vendor/symengine/symengine/assumptions.h +47 -0
  1498. package/vendor/symengine/symengine/basic-inl.h +152 -0
  1499. package/vendor/symengine/symengine/basic-methods.inc +9 -0
  1500. package/vendor/symengine/symengine/basic.cpp +110 -0
  1501. package/vendor/symengine/symengine/basic.h +356 -0
  1502. package/vendor/symengine/symengine/complex.cpp +198 -0
  1503. package/vendor/symengine/symengine/complex.h +396 -0
  1504. package/vendor/symengine/symengine/complex_double.cpp +72 -0
  1505. package/vendor/symengine/symengine/complex_double.h +570 -0
  1506. package/vendor/symengine/symengine/complex_mpc.h +406 -0
  1507. package/vendor/symengine/symengine/constants.cpp +130 -0
  1508. package/vendor/symengine/symengine/constants.h +81 -0
  1509. package/vendor/symengine/symengine/cse.cpp +556 -0
  1510. package/vendor/symengine/symengine/cwrapper.h +949 -0
  1511. package/vendor/symengine/symengine/dense_matrix.cpp +2100 -0
  1512. package/vendor/symengine/symengine/derivative.cpp +841 -0
  1513. package/vendor/symengine/symengine/derivative.h +137 -0
  1514. package/vendor/symengine/symengine/dict.cpp +125 -0
  1515. package/vendor/symengine/symengine/dict.h +333 -0
  1516. package/vendor/symengine/symengine/diophantine.cpp +139 -0
  1517. package/vendor/symengine/symengine/diophantine.h +20 -0
  1518. package/vendor/symengine/symengine/eval.cpp +109 -0
  1519. package/vendor/symengine/symengine/eval.h +40 -0
  1520. package/vendor/symengine/symengine/eval_arb.h +31 -0
  1521. package/vendor/symengine/symengine/eval_double.cpp +959 -0
  1522. package/vendor/symengine/symengine/eval_double.h +28 -0
  1523. package/vendor/symengine/symengine/eval_mpc.h +29 -0
  1524. package/vendor/symengine/symengine/eval_mpfr.h +26 -0
  1525. package/vendor/symengine/symengine/expand.cpp +379 -0
  1526. package/vendor/symengine/symengine/expression.cpp +24 -0
  1527. package/vendor/symengine/symengine/expression.h +375 -0
  1528. package/vendor/symengine/symengine/fields.cpp +861 -0
  1529. package/vendor/symengine/symengine/fields.h +647 -0
  1530. package/vendor/symengine/symengine/finitediff.cpp +70 -0
  1531. package/vendor/symengine/symengine/finitediff.h +21 -0
  1532. package/vendor/symengine/symengine/flint_wrapper.h +1010 -0
  1533. package/vendor/symengine/symengine/functions.cpp +3913 -0
  1534. package/vendor/symengine/symengine/functions.h +1321 -0
  1535. package/vendor/symengine/symengine/infinity.cpp +537 -0
  1536. package/vendor/symengine/symengine/infinity.h +118 -0
  1537. package/vendor/symengine/symengine/integer.cpp +153 -0
  1538. package/vendor/symengine/symengine/integer.h +227 -0
  1539. package/vendor/symengine/symengine/interruption.cpp +9 -0
  1540. package/vendor/symengine/symengine/interruption.h +19 -0
  1541. package/vendor/symengine/symengine/lambda_double.h +918 -0
  1542. package/vendor/symengine/symengine/limits.h +35 -0
  1543. package/vendor/symengine/symengine/llvm_double.h +201 -0
  1544. package/vendor/symengine/symengine/logic.cpp +812 -0
  1545. package/vendor/symengine/symengine/logic.h +281 -0
  1546. package/vendor/symengine/symengine/matrices/conjugate_matrix.cpp +139 -0
  1547. package/vendor/symengine/symengine/matrices/conjugate_matrix.h +39 -0
  1548. package/vendor/symengine/symengine/matrices/diagonal_matrix.cpp +79 -0
  1549. package/vendor/symengine/symengine/matrices/diagonal_matrix.h +52 -0
  1550. package/vendor/symengine/symengine/matrices/hadamard_product.cpp +151 -0
  1551. package/vendor/symengine/symengine/matrices/hadamard_product.h +42 -0
  1552. package/vendor/symengine/symengine/matrices/identity_matrix.cpp +63 -0
  1553. package/vendor/symengine/symengine/matrices/identity_matrix.h +40 -0
  1554. package/vendor/symengine/symengine/matrices/immutable_dense_matrix.cpp +143 -0
  1555. package/vendor/symengine/symengine/matrices/immutable_dense_matrix.h +65 -0
  1556. package/vendor/symengine/symengine/matrices/is_diagonal.cpp +115 -0
  1557. package/vendor/symengine/symengine/matrices/is_lower.cpp +110 -0
  1558. package/vendor/symengine/symengine/matrices/is_real.cpp +78 -0
  1559. package/vendor/symengine/symengine/matrices/is_square.cpp +85 -0
  1560. package/vendor/symengine/symengine/matrices/is_symmetric.cpp +112 -0
  1561. package/vendor/symengine/symengine/matrices/is_toeplitz.cpp +104 -0
  1562. package/vendor/symengine/symengine/matrices/is_upper.cpp +108 -0
  1563. package/vendor/symengine/symengine/matrices/is_zero.cpp +81 -0
  1564. package/vendor/symengine/symengine/matrices/matrix_add.cpp +176 -0
  1565. package/vendor/symengine/symengine/matrices/matrix_add.h +42 -0
  1566. package/vendor/symengine/symengine/matrices/matrix_expr.h +19 -0
  1567. package/vendor/symengine/symengine/matrices/matrix_mul.cpp +258 -0
  1568. package/vendor/symengine/symengine/matrices/matrix_mul.h +55 -0
  1569. package/vendor/symengine/symengine/matrices/matrix_symbol.cpp +34 -0
  1570. package/vendor/symengine/symengine/matrices/matrix_symbol.h +41 -0
  1571. package/vendor/symengine/symengine/matrices/size.cpp +121 -0
  1572. package/vendor/symengine/symengine/matrices/size.h +15 -0
  1573. package/vendor/symengine/symengine/matrices/trace.cpp +112 -0
  1574. package/vendor/symengine/symengine/matrices/trace.h +31 -0
  1575. package/vendor/symengine/symengine/matrices/transpose.cpp +126 -0
  1576. package/vendor/symengine/symengine/matrices/transpose.h +39 -0
  1577. package/vendor/symengine/symengine/matrices/zero_matrix.cpp +94 -0
  1578. package/vendor/symengine/symengine/matrices/zero_matrix.h +47 -0
  1579. package/vendor/symengine/symengine/matrix.cpp +33 -0
  1580. package/vendor/symengine/symengine/matrix.h +675 -0
  1581. package/vendor/symengine/symengine/matrix_expressions.h +51 -0
  1582. package/vendor/symengine/symengine/monomials.cpp +33 -0
  1583. package/vendor/symengine/symengine/monomials.h +20 -0
  1584. package/vendor/symengine/symengine/mp_boost.cpp +635 -0
  1585. package/vendor/symengine/symengine/mp_class.h +1286 -0
  1586. package/vendor/symengine/symengine/mp_wrapper.h +510 -0
  1587. package/vendor/symengine/symengine/mul.cpp +629 -0
  1588. package/vendor/symengine/symengine/mul.h +146 -0
  1589. package/vendor/symengine/symengine/nan.cpp +234 -0
  1590. package/vendor/symengine/symengine/nan.h +82 -0
  1591. package/vendor/symengine/symengine/ntheory.cpp +1700 -0
  1592. package/vendor/symengine/symengine/ntheory.h +213 -0
  1593. package/vendor/symengine/symengine/ntheory_funcs.cpp +189 -0
  1594. package/vendor/symengine/symengine/ntheory_funcs.h +78 -0
  1595. package/vendor/symengine/symengine/number.cpp +36 -0
  1596. package/vendor/symengine/symengine/number.h +256 -0
  1597. package/vendor/symengine/symengine/numer_denom.cpp +149 -0
  1598. package/vendor/symengine/symengine/parser/parser.cpp +367 -0
  1599. package/vendor/symengine/symengine/parser/parser.h +56 -0
  1600. package/vendor/symengine/symengine/parser/parser.tab.cc +1495 -0
  1601. package/vendor/symengine/symengine/parser/parser.tab.hh +1410 -0
  1602. package/vendor/symengine/symengine/parser/parser_old.cpp +688 -0
  1603. package/vendor/symengine/symengine/parser/tokenizer.cpp +435 -0
  1604. package/vendor/symengine/symengine/parser/tokenizer.h +35 -0
  1605. package/vendor/symengine/symengine/parser.h +25 -0
  1606. package/vendor/symengine/symengine/polys/basic_conversions.cpp +178 -0
  1607. package/vendor/symengine/symengine/polys/basic_conversions.h +575 -0
  1608. package/vendor/symengine/symengine/polys/cancel.h +39 -0
  1609. package/vendor/symengine/symengine/polys/msymenginepoly.cpp +130 -0
  1610. package/vendor/symengine/symengine/polys/msymenginepoly.h +536 -0
  1611. package/vendor/symengine/symengine/polys/uexprpoly.cpp +90 -0
  1612. package/vendor/symengine/symengine/polys/uexprpoly.h +205 -0
  1613. package/vendor/symengine/symengine/polys/uintpoly.cpp +62 -0
  1614. package/vendor/symengine/symengine/polys/uintpoly.h +134 -0
  1615. package/vendor/symengine/symengine/polys/uintpoly_flint.h +228 -0
  1616. package/vendor/symengine/symengine/polys/uintpoly_piranha.h +373 -0
  1617. package/vendor/symengine/symengine/polys/upolybase.h +769 -0
  1618. package/vendor/symengine/symengine/polys/uratpoly.cpp +59 -0
  1619. package/vendor/symengine/symengine/polys/uratpoly.h +58 -0
  1620. package/vendor/symengine/symengine/polys/usymenginepoly.h +139 -0
  1621. package/vendor/symengine/symengine/pow.cpp +303 -0
  1622. package/vendor/symengine/symengine/pow.h +76 -0
  1623. package/vendor/symengine/symengine/prime_sieve.cpp +143 -0
  1624. package/vendor/symengine/symengine/prime_sieve.h +64 -0
  1625. package/vendor/symengine/symengine/printers/codegen.cpp +716 -0
  1626. package/vendor/symengine/symengine/printers/codegen.h +168 -0
  1627. package/vendor/symengine/symengine/printers/latex.cpp +630 -0
  1628. package/vendor/symengine/symengine/printers/latex.h +76 -0
  1629. package/vendor/symengine/symengine/printers/mathml.cpp +358 -0
  1630. package/vendor/symengine/symengine/printers/mathml.h +62 -0
  1631. package/vendor/symengine/symengine/printers/stringbox.cpp +276 -0
  1632. package/vendor/symengine/symengine/printers/stringbox.h +60 -0
  1633. package/vendor/symengine/symengine/printers/strprinter.cpp +1212 -0
  1634. package/vendor/symengine/symengine/printers/strprinter.h +217 -0
  1635. package/vendor/symengine/symengine/printers/unicode.cpp +730 -0
  1636. package/vendor/symengine/symengine/printers/unicode.h +84 -0
  1637. package/vendor/symengine/symengine/printers.h +46 -0
  1638. package/vendor/symengine/symengine/rational.cpp +365 -0
  1639. package/vendor/symengine/symengine/rational.h +341 -0
  1640. package/vendor/symengine/symengine/real_double.cpp +388 -0
  1641. package/vendor/symengine/symengine/real_double.h +492 -0
  1642. package/vendor/symengine/symengine/real_mpfr.h +379 -0
  1643. package/vendor/symengine/symengine/refine.cpp +213 -0
  1644. package/vendor/symengine/symengine/refine.h +43 -0
  1645. package/vendor/symengine/symengine/rewrite.cpp +235 -0
  1646. package/vendor/symengine/symengine/rings.cpp +107 -0
  1647. package/vendor/symengine/symengine/rings.h +24 -0
  1648. package/vendor/symengine/symengine/serialize-cereal.h +964 -0
  1649. package/vendor/symengine/symengine/series.cpp +85 -0
  1650. package/vendor/symengine/symengine/series.h +727 -0
  1651. package/vendor/symengine/symengine/series_flint.h +214 -0
  1652. package/vendor/symengine/symengine/series_generic.cpp +247 -0
  1653. package/vendor/symengine/symengine/series_generic.h +86 -0
  1654. package/vendor/symengine/symengine/series_piranha.h +95 -0
  1655. package/vendor/symengine/symengine/series_visitor.h +357 -0
  1656. package/vendor/symengine/symengine/set_funcs.cpp +296 -0
  1657. package/vendor/symengine/symengine/sets.cpp +1854 -0
  1658. package/vendor/symengine/symengine/sets.h +696 -0
  1659. package/vendor/symengine/symengine/simplify.cpp +62 -0
  1660. package/vendor/symengine/symengine/simplify.h +34 -0
  1661. package/vendor/symengine/symengine/solve.cpp +665 -0
  1662. package/vendor/symengine/symengine/solve.h +117 -0
  1663. package/vendor/symengine/symengine/sparse_matrix.cpp +776 -0
  1664. package/vendor/symengine/symengine/special_boost.cpp +85 -0
  1665. package/vendor/symengine/symengine/special_double.h +570 -0
  1666. package/vendor/symengine/symengine/subs.h +579 -0
  1667. package/vendor/symengine/symengine/symbol.cpp +88 -0
  1668. package/vendor/symengine/symengine/symbol.h +116 -0
  1669. package/vendor/symengine/symengine/symengine_assert.h +50 -0
  1670. package/vendor/symengine/symengine/symengine_casts.h +139 -0
  1671. package/vendor/symengine/symengine/symengine_exception.h +101 -0
  1672. package/vendor/symengine/symengine/symengine_rcp.cpp +21 -0
  1673. package/vendor/symengine/symengine/symengine_rcp.h +384 -0
  1674. package/vendor/symengine/symengine/test_visitors.cpp +1083 -0
  1675. package/vendor/symengine/symengine/test_visitors.h +466 -0
  1676. package/vendor/symengine/symengine/tribool.h +85 -0
  1677. package/vendor/symengine/symengine/tuple.cpp +47 -0
  1678. package/vendor/symengine/symengine/tuple.h +32 -0
  1679. package/vendor/symengine/symengine/type_codes.inc +139 -0
  1680. package/vendor/symengine/symengine/utilities/cereal/LICENSE +24 -0
  1681. package/vendor/symengine/symengine/utilities/cereal/include/cereal/access.hpp +351 -0
  1682. package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/adapters.hpp +163 -0
  1683. package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/binary.hpp +169 -0
  1684. package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/json.hpp +1024 -0
  1685. package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/portable_binary.hpp +334 -0
  1686. package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/xml.hpp +956 -0
  1687. package/vendor/symengine/symengine/utilities/cereal/include/cereal/cereal.hpp +1120 -0
  1688. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/helpers.hpp +422 -0
  1689. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/polymorphic_impl.hpp +825 -0
  1690. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/polymorphic_impl_fwd.hpp +65 -0
  1691. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/static_object.hpp +128 -0
  1692. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/traits.hpp +1411 -0
  1693. package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/util.hpp +84 -0
  1694. package/vendor/symengine/symengine/utilities/cereal/include/cereal/macros.hpp +156 -0
  1695. package/vendor/symengine/symengine/utilities/cereal/include/cereal/specialize.hpp +139 -0
  1696. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/array.hpp +79 -0
  1697. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/atomic.hpp +55 -0
  1698. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/base_class.hpp +203 -0
  1699. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/bitset.hpp +176 -0
  1700. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/boost_variant.hpp +164 -0
  1701. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/chrono.hpp +72 -0
  1702. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/common.hpp +129 -0
  1703. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/complex.hpp +56 -0
  1704. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/concepts/pair_associative_container.hpp +73 -0
  1705. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/deque.hpp +62 -0
  1706. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/forward_list.hpp +68 -0
  1707. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/functional.hpp +43 -0
  1708. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/list.hpp +62 -0
  1709. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/map.hpp +36 -0
  1710. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/memory.hpp +425 -0
  1711. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/optional.hpp +65 -0
  1712. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/polymorphic.hpp +483 -0
  1713. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/queue.hpp +132 -0
  1714. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/set.hpp +103 -0
  1715. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/stack.hpp +76 -0
  1716. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/string.hpp +61 -0
  1717. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/tuple.hpp +123 -0
  1718. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/unordered_map.hpp +36 -0
  1719. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/unordered_set.hpp +99 -0
  1720. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/utility.hpp +47 -0
  1721. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/valarray.hpp +89 -0
  1722. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/variant.hpp +108 -0
  1723. package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/vector.hpp +112 -0
  1724. package/vendor/symengine/symengine/utilities/cereal/include/cereal/version.hpp +52 -0
  1725. package/vendor/symengine/symengine/utilities/fast_float/include/fast_float/fast_float.h +3720 -0
  1726. package/vendor/symengine/symengine/utilities/stream_fmt.h +25 -0
  1727. package/vendor/symengine/symengine/visitor.cpp +348 -0
  1728. package/vendor/symengine/symengine/visitor.h +425 -0
@@ -0,0 +1,3720 @@
1
+ // fast_float by Daniel Lemire
2
+ // fast_float by João Paulo Magalhaes
3
+ //
4
+ //
5
+ // with contributions from Eugene Golushkov
6
+ // with contributions from Maksim Kita
7
+ // with contributions from Marcin Wojdyr
8
+ // with contributions from Neal Richardson
9
+ // with contributions from Tim Paine
10
+ // with contributions from Fabio Pellacini
11
+ // with contributions from Lénárd Szolnoki
12
+ // with contributions from Jan Pharago
13
+ // with contributions from Maya Warrier
14
+ // with contributions from Taha Khokhar
15
+ //
16
+ //
17
+ // Licensed under the Apache License, Version 2.0, or the
18
+ // MIT License or the Boost License. This file may not be copied,
19
+ // modified, or distributed except according to those terms.
20
+ //
21
+ // MIT License Notice
22
+ //
23
+ // MIT License
24
+ //
25
+ // Copyright (c) 2021 The fast_float authors
26
+ //
27
+ // Permission is hereby granted, free of charge, to any
28
+ // person obtaining a copy of this software and associated
29
+ // documentation files (the "Software"), to deal in the
30
+ // Software without restriction, including without
31
+ // limitation the rights to use, copy, modify, merge,
32
+ // publish, distribute, sublicense, and/or sell copies of
33
+ // the Software, and to permit persons to whom the Software
34
+ // is furnished to do so, subject to the following
35
+ // conditions:
36
+ //
37
+ // The above copyright notice and this permission notice
38
+ // shall be included in all copies or substantial portions
39
+ // of the Software.
40
+ //
41
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
42
+ // ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
43
+ // TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
44
+ // PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
45
+ // SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
46
+ // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
47
+ // OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
48
+ // IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
49
+ // DEALINGS IN THE SOFTWARE.
50
+ //
51
+ // Apache License (Version 2.0) Notice
52
+ //
53
+ // Copyright 2021 The fast_float authors
54
+ // Licensed under the Apache License, Version 2.0 (the "License");
55
+ // you may not use this file except in compliance with the License.
56
+ // You may obtain a copy of the License at
57
+ //
58
+ // http://www.apache.org/licenses/LICENSE-2.0
59
+ //
60
+ // Unless required by applicable law or agreed to in writing, software
61
+ // distributed under the License is distributed on an "AS IS" BASIS,
62
+ // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
63
+ // See the License for the specific language governing permissions and
64
+ //
65
+ // BOOST License Notice
66
+ //
67
+ // Boost Software License - Version 1.0 - August 17th, 2003
68
+ //
69
+ // Permission is hereby granted, free of charge, to any person or organization
70
+ // obtaining a copy of the software and accompanying documentation covered by
71
+ // this license (the "Software") to use, reproduce, display, distribute,
72
+ // execute, and transmit the Software, and to prepare derivative works of the
73
+ // Software, and to permit third-parties to whom the Software is furnished to
74
+ // do so, all subject to the following:
75
+ //
76
+ // The copyright notices in the Software and this entire statement, including
77
+ // the above license grant, this restriction and the following disclaimer,
78
+ // must be included in all copies of the Software, in whole or in part, and
79
+ // all derivative works of the Software, unless such copies or derivative
80
+ // works are solely in the form of machine-executable object code generated by
81
+ // a source language processor.
82
+ //
83
+ // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
84
+ // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
85
+ // FITNESS FOR A PARTICULAR PURPOSE, TITLE AND NON-INFRINGEMENT. IN NO EVENT
86
+ // SHALL THE COPYRIGHT HOLDERS OR ANYONE DISTRIBUTING THE SOFTWARE BE LIABLE
87
+ // FOR ANY DAMAGES OR OTHER LIABILITY, WHETHER IN CONTRACT, TORT OR OTHERWISE,
88
+ // ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
89
+ // DEALINGS IN THE SOFTWARE.
90
+ //
91
+
92
+ #ifndef FASTFLOAT_CONSTEXPR_FEATURE_DETECT_H
93
+ #define FASTFLOAT_CONSTEXPR_FEATURE_DETECT_H
94
+
95
+ #ifdef __has_include
96
+ #if __has_include(<version>)
97
+ #include <version>
98
+ #endif
99
+ #endif
100
+
101
+ // Testing for https://wg21.link/N3652, adopted in C++14
102
+ #if __cpp_constexpr >= 201304
103
+ #define FASTFLOAT_CONSTEXPR14 constexpr
104
+ #else
105
+ #define FASTFLOAT_CONSTEXPR14
106
+ #endif
107
+
108
+ #if defined(__cpp_lib_bit_cast) && __cpp_lib_bit_cast >= 201806L
109
+ #define FASTFLOAT_HAS_BIT_CAST 1
110
+ #else
111
+ #define FASTFLOAT_HAS_BIT_CAST 0
112
+ #endif
113
+
114
+ #if defined(__cpp_lib_is_constant_evaluated) && __cpp_lib_is_constant_evaluated >= 201811L
115
+ #define FASTFLOAT_HAS_IS_CONSTANT_EVALUATED 1
116
+ #else
117
+ #define FASTFLOAT_HAS_IS_CONSTANT_EVALUATED 0
118
+ #endif
119
+
120
+ // Testing for relevant C++20 constexpr library features
121
+ #if FASTFLOAT_HAS_IS_CONSTANT_EVALUATED \
122
+ && FASTFLOAT_HAS_BIT_CAST \
123
+ && __cpp_lib_constexpr_algorithms >= 201806L /*For std::copy and std::fill*/
124
+ #define FASTFLOAT_CONSTEXPR20 constexpr
125
+ #define FASTFLOAT_IS_CONSTEXPR 1
126
+ #else
127
+ #define FASTFLOAT_CONSTEXPR20
128
+ #define FASTFLOAT_IS_CONSTEXPR 0
129
+ #endif
130
+
131
+ #endif // FASTFLOAT_CONSTEXPR_FEATURE_DETECT_H
132
+
133
+ #ifndef FASTFLOAT_FLOAT_COMMON_H
134
+ #define FASTFLOAT_FLOAT_COMMON_H
135
+
136
+ #include <cfloat>
137
+ #include <cstdint>
138
+ #include <cassert>
139
+ #include <cstring>
140
+ #include <type_traits>
141
+ #include <system_error>
142
+ #ifdef __has_include
143
+ #if __has_include(<stdfloat>)
144
+ #include <stdfloat>
145
+ #endif
146
+ #endif
147
+
148
+ namespace fast_float {
149
+
150
+ #define FASTFLOAT_JSONFMT (1 << 5)
151
+ #define FASTFLOAT_FORTRANFMT (1 << 6)
152
+
153
+ enum chars_format {
154
+ scientific = 1 << 0,
155
+ fixed = 1 << 2,
156
+ hex = 1 << 3,
157
+ no_infnan = 1 << 4,
158
+ // RFC 8259: https://datatracker.ietf.org/doc/html/rfc8259#section-6
159
+ json = FASTFLOAT_JSONFMT | fixed | scientific | no_infnan,
160
+ // Extension of RFC 8259 where, e.g., "inf" and "nan" are allowed.
161
+ json_or_infnan = FASTFLOAT_JSONFMT | fixed | scientific,
162
+ fortran = FASTFLOAT_FORTRANFMT | fixed | scientific,
163
+ general = fixed | scientific
164
+ };
165
+
166
+ template <typename UC>
167
+ struct from_chars_result_t {
168
+ UC const* ptr;
169
+ std::errc ec;
170
+ };
171
+ using from_chars_result = from_chars_result_t<char>;
172
+
173
+ template <typename UC>
174
+ struct parse_options_t {
175
+ constexpr explicit parse_options_t(chars_format fmt = chars_format::general,
176
+ UC dot = UC('.'))
177
+ : format(fmt), decimal_point(dot) {}
178
+
179
+ /** Which number formats are accepted */
180
+ chars_format format;
181
+ /** The character used as decimal point */
182
+ UC decimal_point;
183
+ };
184
+ using parse_options = parse_options_t<char>;
185
+
186
+ }
187
+
188
+ #if FASTFLOAT_HAS_BIT_CAST
189
+ #include <bit>
190
+ #endif
191
+
192
+ #if (defined(__x86_64) || defined(__x86_64__) || defined(_M_X64) \
193
+ || defined(__amd64) || defined(__aarch64__) || defined(_M_ARM64) \
194
+ || defined(__MINGW64__) \
195
+ || defined(__s390x__) \
196
+ || (defined(__ppc64__) || defined(__PPC64__) || defined(__ppc64le__) || defined(__PPC64LE__)) \
197
+ || defined(__loongarch64) )
198
+ #define FASTFLOAT_64BIT 1
199
+ #elif (defined(__i386) || defined(__i386__) || defined(_M_IX86) \
200
+ || defined(__arm__) || defined(_M_ARM) || defined(__ppc__) \
201
+ || defined(__MINGW32__) || defined(__EMSCRIPTEN__))
202
+ #define FASTFLOAT_32BIT 1
203
+ #else
204
+ // Need to check incrementally, since SIZE_MAX is a size_t, avoid overflow.
205
+ // We can never tell the register width, but the SIZE_MAX is a good approximation.
206
+ // UINTPTR_MAX and INTPTR_MAX are optional, so avoid them for max portability.
207
+ #if SIZE_MAX == 0xffff
208
+ #error Unknown platform (16-bit, unsupported)
209
+ #elif SIZE_MAX == 0xffffffff
210
+ #define FASTFLOAT_32BIT 1
211
+ #elif SIZE_MAX == 0xffffffffffffffff
212
+ #define FASTFLOAT_64BIT 1
213
+ #else
214
+ #error Unknown platform (not 32-bit, not 64-bit?)
215
+ #endif
216
+ #endif
217
+
218
+ #if ((defined(_WIN32) || defined(_WIN64)) && !defined(__clang__))
219
+ #include <intrin.h>
220
+ #endif
221
+
222
+ #if defined(_MSC_VER) && !defined(__clang__)
223
+ #define FASTFLOAT_VISUAL_STUDIO 1
224
+ #endif
225
+
226
+ #if defined __BYTE_ORDER__ && defined __ORDER_BIG_ENDIAN__
227
+ #define FASTFLOAT_IS_BIG_ENDIAN (__BYTE_ORDER__ == __ORDER_BIG_ENDIAN__)
228
+ #elif defined _WIN32
229
+ #define FASTFLOAT_IS_BIG_ENDIAN 0
230
+ #else
231
+ #if defined(__APPLE__) || defined(__FreeBSD__)
232
+ #include <machine/endian.h>
233
+ #elif defined(sun) || defined(__sun)
234
+ #include <sys/byteorder.h>
235
+ #elif defined(__MVS__)
236
+ #include <sys/endian.h>
237
+ #else
238
+ #ifdef __has_include
239
+ #if __has_include(<endian.h>)
240
+ #include <endian.h>
241
+ #endif //__has_include(<endian.h>)
242
+ #endif //__has_include
243
+ #endif
244
+ #
245
+ #ifndef __BYTE_ORDER__
246
+ // safe choice
247
+ #define FASTFLOAT_IS_BIG_ENDIAN 0
248
+ #endif
249
+ #
250
+ #ifndef __ORDER_LITTLE_ENDIAN__
251
+ // safe choice
252
+ #define FASTFLOAT_IS_BIG_ENDIAN 0
253
+ #endif
254
+ #
255
+ #if __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__
256
+ #define FASTFLOAT_IS_BIG_ENDIAN 0
257
+ #else
258
+ #define FASTFLOAT_IS_BIG_ENDIAN 1
259
+ #endif
260
+ #endif
261
+
262
+ #if defined(__SSE2__) || \
263
+ (defined(FASTFLOAT_VISUAL_STUDIO) && \
264
+ (defined(_M_AMD64) || defined(_M_X64) || (defined(_M_IX86_FP) && _M_IX86_FP == 2)))
265
+ #define FASTFLOAT_SSE2 1
266
+ #endif
267
+
268
+ #if defined(__aarch64__) || defined(_M_ARM64)
269
+ #define FASTFLOAT_NEON 1
270
+ #endif
271
+
272
+ #if defined(FASTFLOAT_SSE2) || defined(FASTFLOAT_NEON)
273
+ #define FASTFLOAT_HAS_SIMD 1
274
+ #endif
275
+
276
+ #if defined(__GNUC__)
277
+ // disable -Wcast-align=strict (GCC only)
278
+ #define FASTFLOAT_SIMD_DISABLE_WARNINGS \
279
+ _Pragma("GCC diagnostic push") \
280
+ _Pragma("GCC diagnostic ignored \"-Wcast-align\"")
281
+ #else
282
+ #define FASTFLOAT_SIMD_DISABLE_WARNINGS
283
+ #endif
284
+
285
+ #if defined(__GNUC__)
286
+ #define FASTFLOAT_SIMD_RESTORE_WARNINGS \
287
+ _Pragma("GCC diagnostic pop")
288
+ #else
289
+ #define FASTFLOAT_SIMD_RESTORE_WARNINGS
290
+ #endif
291
+
292
+
293
+
294
+ #ifdef FASTFLOAT_VISUAL_STUDIO
295
+ #define fastfloat_really_inline __forceinline
296
+ #else
297
+ #define fastfloat_really_inline inline __attribute__((always_inline))
298
+ #endif
299
+
300
+ #ifndef FASTFLOAT_ASSERT
301
+ #define FASTFLOAT_ASSERT(x) { ((void)(x)); }
302
+ #endif
303
+
304
+ #ifndef FASTFLOAT_DEBUG_ASSERT
305
+ #define FASTFLOAT_DEBUG_ASSERT(x) { ((void)(x)); }
306
+ #endif
307
+
308
+ // rust style `try!()` macro, or `?` operator
309
+ #define FASTFLOAT_TRY(x) { if (!(x)) return false; }
310
+
311
+ #define FASTFLOAT_ENABLE_IF(...) typename std::enable_if<(__VA_ARGS__), int>::type
312
+
313
+
314
+ namespace fast_float {
315
+
316
+ fastfloat_really_inline constexpr bool cpp20_and_in_constexpr() {
317
+ #if FASTFLOAT_HAS_IS_CONSTANT_EVALUATED
318
+ return std::is_constant_evaluated();
319
+ #else
320
+ return false;
321
+ #endif
322
+ }
323
+
324
+ template <typename T>
325
+ fastfloat_really_inline constexpr bool is_supported_float_type() {
326
+ return std::is_same<T, float>::value || std::is_same<T, double>::value
327
+ #if __STDCPP_FLOAT32_T__
328
+ || std::is_same<T, std::float32_t>::value
329
+ #endif
330
+ #if __STDCPP_FLOAT64_T__
331
+ || std::is_same<T, std::float64_t>::value
332
+ #endif
333
+ ;
334
+ }
335
+
336
+ template <typename UC>
337
+ fastfloat_really_inline constexpr bool is_supported_char_type() {
338
+ return
339
+ std::is_same<UC, char>::value ||
340
+ std::is_same<UC, wchar_t>::value ||
341
+ std::is_same<UC, char16_t>::value ||
342
+ std::is_same<UC, char32_t>::value;
343
+ }
344
+
345
+ // Compares two ASCII strings in a case insensitive manner.
346
+ template <typename UC>
347
+ inline FASTFLOAT_CONSTEXPR14 bool
348
+ fastfloat_strncasecmp(UC const * input1, UC const * input2, size_t length) {
349
+ char running_diff{0};
350
+ for (size_t i = 0; i < length; ++i) {
351
+ running_diff |= (char(input1[i]) ^ char(input2[i]));
352
+ }
353
+ return (running_diff == 0) || (running_diff == 32);
354
+ }
355
+
356
+ #ifndef FLT_EVAL_METHOD
357
+ #error "FLT_EVAL_METHOD should be defined, please include cfloat."
358
+ #endif
359
+
360
+ // a pointer and a length to a contiguous block of memory
361
+ template <typename T>
362
+ struct span {
363
+ const T* ptr;
364
+ size_t length;
365
+ constexpr span(const T* _ptr, size_t _length) : ptr(_ptr), length(_length) {}
366
+ constexpr span() : ptr(nullptr), length(0) {}
367
+
368
+ constexpr size_t len() const noexcept {
369
+ return length;
370
+ }
371
+
372
+ FASTFLOAT_CONSTEXPR14 const T& operator[](size_t index) const noexcept {
373
+ FASTFLOAT_DEBUG_ASSERT(index < length);
374
+ return ptr[index];
375
+ }
376
+ };
377
+
378
+ struct value128 {
379
+ uint64_t low;
380
+ uint64_t high;
381
+ constexpr value128(uint64_t _low, uint64_t _high) : low(_low), high(_high) {}
382
+ constexpr value128() : low(0), high(0) {}
383
+ };
384
+
385
+ /* Helper C++14 constexpr generic implementation of leading_zeroes */
386
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
387
+ int leading_zeroes_generic(uint64_t input_num, int last_bit = 0) {
388
+ if(input_num & uint64_t(0xffffffff00000000)) { input_num >>= 32; last_bit |= 32; }
389
+ if(input_num & uint64_t( 0xffff0000)) { input_num >>= 16; last_bit |= 16; }
390
+ if(input_num & uint64_t( 0xff00)) { input_num >>= 8; last_bit |= 8; }
391
+ if(input_num & uint64_t( 0xf0)) { input_num >>= 4; last_bit |= 4; }
392
+ if(input_num & uint64_t( 0xc)) { input_num >>= 2; last_bit |= 2; }
393
+ if(input_num & uint64_t( 0x2)) { /* input_num >>= 1; */ last_bit |= 1; }
394
+ return 63 - last_bit;
395
+ }
396
+
397
+ /* result might be undefined when input_num is zero */
398
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
399
+ int leading_zeroes(uint64_t input_num) {
400
+ assert(input_num > 0);
401
+ if (cpp20_and_in_constexpr()) {
402
+ return leading_zeroes_generic(input_num);
403
+ }
404
+ #ifdef FASTFLOAT_VISUAL_STUDIO
405
+ #if defined(_M_X64) || defined(_M_ARM64)
406
+ unsigned long leading_zero = 0;
407
+ // Search the mask data from most significant bit (MSB)
408
+ // to least significant bit (LSB) for a set bit (1).
409
+ _BitScanReverse64(&leading_zero, input_num);
410
+ return (int)(63 - leading_zero);
411
+ #else
412
+ return leading_zeroes_generic(input_num);
413
+ #endif
414
+ #else
415
+ return __builtin_clzll(input_num);
416
+ #endif
417
+ }
418
+
419
+ // slow emulation routine for 32-bit
420
+ fastfloat_really_inline constexpr uint64_t emulu(uint32_t x, uint32_t y) {
421
+ return x * (uint64_t)y;
422
+ }
423
+
424
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
425
+ uint64_t umul128_generic(uint64_t ab, uint64_t cd, uint64_t *hi) {
426
+ uint64_t ad = emulu((uint32_t)(ab >> 32), (uint32_t)cd);
427
+ uint64_t bd = emulu((uint32_t)ab, (uint32_t)cd);
428
+ uint64_t adbc = ad + emulu((uint32_t)ab, (uint32_t)(cd >> 32));
429
+ uint64_t adbc_carry = (uint64_t)(adbc < ad);
430
+ uint64_t lo = bd + (adbc << 32);
431
+ *hi = emulu((uint32_t)(ab >> 32), (uint32_t)(cd >> 32)) + (adbc >> 32) +
432
+ (adbc_carry << 32) + (uint64_t)(lo < bd);
433
+ return lo;
434
+ }
435
+
436
+ #ifdef FASTFLOAT_32BIT
437
+
438
+ // slow emulation routine for 32-bit
439
+ #if !defined(__MINGW64__)
440
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
441
+ uint64_t _umul128(uint64_t ab, uint64_t cd, uint64_t *hi) {
442
+ return umul128_generic(ab, cd, hi);
443
+ }
444
+ #endif // !__MINGW64__
445
+
446
+ #endif // FASTFLOAT_32BIT
447
+
448
+
449
+ // compute 64-bit a*b
450
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
451
+ value128 full_multiplication(uint64_t a, uint64_t b) {
452
+ if (cpp20_and_in_constexpr()) {
453
+ value128 answer;
454
+ answer.low = umul128_generic(a, b, &answer.high);
455
+ return answer;
456
+ }
457
+ value128 answer;
458
+ #if defined(_M_ARM64) && !defined(__MINGW32__)
459
+ // ARM64 has native support for 64-bit multiplications, no need to emulate
460
+ // But MinGW on ARM64 doesn't have native support for 64-bit multiplications
461
+ answer.high = __umulh(a, b);
462
+ answer.low = a * b;
463
+ #elif defined(FASTFLOAT_32BIT) || (defined(_WIN64) && !defined(__clang__))
464
+ answer.low = _umul128(a, b, &answer.high); // _umul128 not available on ARM64
465
+ #elif defined(FASTFLOAT_64BIT)
466
+ __uint128_t r = ((__uint128_t)a) * b;
467
+ answer.low = uint64_t(r);
468
+ answer.high = uint64_t(r >> 64);
469
+ #else
470
+ answer.low = umul128_generic(a, b, &answer.high);
471
+ #endif
472
+ return answer;
473
+ }
474
+
475
+ struct adjusted_mantissa {
476
+ uint64_t mantissa{0};
477
+ int32_t power2{0}; // a negative value indicates an invalid result
478
+ adjusted_mantissa() = default;
479
+ constexpr bool operator==(const adjusted_mantissa &o) const {
480
+ return mantissa == o.mantissa && power2 == o.power2;
481
+ }
482
+ constexpr bool operator!=(const adjusted_mantissa &o) const {
483
+ return mantissa != o.mantissa || power2 != o.power2;
484
+ }
485
+ };
486
+
487
+ // Bias so we can get the real exponent with an invalid adjusted_mantissa.
488
+ constexpr static int32_t invalid_am_bias = -0x8000;
489
+
490
+ // used for binary_format_lookup_tables<T>::max_mantissa
491
+ constexpr uint64_t constant_55555 = 5 * 5 * 5 * 5 * 5;
492
+
493
+ template <typename T, typename U = void>
494
+ struct binary_format_lookup_tables;
495
+
496
+ template <typename T> struct binary_format : binary_format_lookup_tables<T> {
497
+ using equiv_uint = typename std::conditional<sizeof(T) == 4, uint32_t, uint64_t>::type;
498
+
499
+ static inline constexpr int mantissa_explicit_bits();
500
+ static inline constexpr int minimum_exponent();
501
+ static inline constexpr int infinite_power();
502
+ static inline constexpr int sign_index();
503
+ static inline constexpr int min_exponent_fast_path(); // used when fegetround() == FE_TONEAREST
504
+ static inline constexpr int max_exponent_fast_path();
505
+ static inline constexpr int max_exponent_round_to_even();
506
+ static inline constexpr int min_exponent_round_to_even();
507
+ static inline constexpr uint64_t max_mantissa_fast_path(int64_t power);
508
+ static inline constexpr uint64_t max_mantissa_fast_path(); // used when fegetround() == FE_TONEAREST
509
+ static inline constexpr int largest_power_of_ten();
510
+ static inline constexpr int smallest_power_of_ten();
511
+ static inline constexpr T exact_power_of_ten(int64_t power);
512
+ static inline constexpr size_t max_digits();
513
+ static inline constexpr equiv_uint exponent_mask();
514
+ static inline constexpr equiv_uint mantissa_mask();
515
+ static inline constexpr equiv_uint hidden_bit_mask();
516
+ };
517
+
518
+ template <typename U>
519
+ struct binary_format_lookup_tables<double, U> {
520
+ static constexpr double powers_of_ten[] = {
521
+ 1e0, 1e1, 1e2, 1e3, 1e4, 1e5, 1e6, 1e7, 1e8, 1e9, 1e10, 1e11,
522
+ 1e12, 1e13, 1e14, 1e15, 1e16, 1e17, 1e18, 1e19, 1e20, 1e21, 1e22};
523
+
524
+ // Largest integer value v so that (5**index * v) <= 1<<53.
525
+ // 0x10000000000000 == 1 << 53
526
+ static constexpr uint64_t max_mantissa[] = {
527
+ 0x10000000000000,
528
+ 0x10000000000000 / 5,
529
+ 0x10000000000000 / (5 * 5),
530
+ 0x10000000000000 / (5 * 5 * 5),
531
+ 0x10000000000000 / (5 * 5 * 5 * 5),
532
+ 0x10000000000000 / (constant_55555),
533
+ 0x10000000000000 / (constant_55555 * 5),
534
+ 0x10000000000000 / (constant_55555 * 5 * 5),
535
+ 0x10000000000000 / (constant_55555 * 5 * 5 * 5),
536
+ 0x10000000000000 / (constant_55555 * 5 * 5 * 5 * 5),
537
+ 0x10000000000000 / (constant_55555 * constant_55555),
538
+ 0x10000000000000 / (constant_55555 * constant_55555 * 5),
539
+ 0x10000000000000 / (constant_55555 * constant_55555 * 5 * 5),
540
+ 0x10000000000000 / (constant_55555 * constant_55555 * 5 * 5 * 5),
541
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555),
542
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * 5),
543
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * 5 * 5),
544
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * 5 * 5 * 5),
545
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * 5 * 5 * 5 * 5),
546
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * constant_55555),
547
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * constant_55555 * 5),
548
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * constant_55555 * 5 * 5),
549
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * constant_55555 * 5 * 5 * 5),
550
+ 0x10000000000000 / (constant_55555 * constant_55555 * constant_55555 * constant_55555 * 5 * 5 * 5 * 5)};
551
+ };
552
+
553
+ template <typename U>
554
+ constexpr double binary_format_lookup_tables<double, U>::powers_of_ten[];
555
+
556
+ template <typename U>
557
+ constexpr uint64_t binary_format_lookup_tables<double, U>::max_mantissa[];
558
+
559
+ template <typename U>
560
+ struct binary_format_lookup_tables<float, U> {
561
+ static constexpr float powers_of_ten[] = {1e0f, 1e1f, 1e2f, 1e3f, 1e4f, 1e5f,
562
+ 1e6f, 1e7f, 1e8f, 1e9f, 1e10f};
563
+
564
+ // Largest integer value v so that (5**index * v) <= 1<<24.
565
+ // 0x1000000 == 1<<24
566
+ static constexpr uint64_t max_mantissa[] = {
567
+ 0x1000000,
568
+ 0x1000000 / 5,
569
+ 0x1000000 / (5 * 5),
570
+ 0x1000000 / (5 * 5 * 5),
571
+ 0x1000000 / (5 * 5 * 5 * 5),
572
+ 0x1000000 / (constant_55555),
573
+ 0x1000000 / (constant_55555 * 5),
574
+ 0x1000000 / (constant_55555 * 5 * 5),
575
+ 0x1000000 / (constant_55555 * 5 * 5 * 5),
576
+ 0x1000000 / (constant_55555 * 5 * 5 * 5 * 5),
577
+ 0x1000000 / (constant_55555 * constant_55555),
578
+ 0x1000000 / (constant_55555 * constant_55555 * 5)};
579
+ };
580
+
581
+ template <typename U>
582
+ constexpr float binary_format_lookup_tables<float, U>::powers_of_ten[];
583
+
584
+ template <typename U>
585
+ constexpr uint64_t binary_format_lookup_tables<float, U>::max_mantissa[];
586
+
587
+ template <> inline constexpr int binary_format<double>::min_exponent_fast_path() {
588
+ #if (FLT_EVAL_METHOD != 1) && (FLT_EVAL_METHOD != 0)
589
+ return 0;
590
+ #else
591
+ return -22;
592
+ #endif
593
+ }
594
+
595
+ template <> inline constexpr int binary_format<float>::min_exponent_fast_path() {
596
+ #if (FLT_EVAL_METHOD != 1) && (FLT_EVAL_METHOD != 0)
597
+ return 0;
598
+ #else
599
+ return -10;
600
+ #endif
601
+ }
602
+
603
+ template <> inline constexpr int binary_format<double>::mantissa_explicit_bits() {
604
+ return 52;
605
+ }
606
+ template <> inline constexpr int binary_format<float>::mantissa_explicit_bits() {
607
+ return 23;
608
+ }
609
+
610
+ template <> inline constexpr int binary_format<double>::max_exponent_round_to_even() {
611
+ return 23;
612
+ }
613
+
614
+ template <> inline constexpr int binary_format<float>::max_exponent_round_to_even() {
615
+ return 10;
616
+ }
617
+
618
+ template <> inline constexpr int binary_format<double>::min_exponent_round_to_even() {
619
+ return -4;
620
+ }
621
+
622
+ template <> inline constexpr int binary_format<float>::min_exponent_round_to_even() {
623
+ return -17;
624
+ }
625
+
626
+ template <> inline constexpr int binary_format<double>::minimum_exponent() {
627
+ return -1023;
628
+ }
629
+ template <> inline constexpr int binary_format<float>::minimum_exponent() {
630
+ return -127;
631
+ }
632
+
633
+ template <> inline constexpr int binary_format<double>::infinite_power() {
634
+ return 0x7FF;
635
+ }
636
+ template <> inline constexpr int binary_format<float>::infinite_power() {
637
+ return 0xFF;
638
+ }
639
+
640
+ template <> inline constexpr int binary_format<double>::sign_index() { return 63; }
641
+ template <> inline constexpr int binary_format<float>::sign_index() { return 31; }
642
+
643
+ template <> inline constexpr int binary_format<double>::max_exponent_fast_path() {
644
+ return 22;
645
+ }
646
+ template <> inline constexpr int binary_format<float>::max_exponent_fast_path() {
647
+ return 10;
648
+ }
649
+
650
+ template <> inline constexpr uint64_t binary_format<double>::max_mantissa_fast_path() {
651
+ return uint64_t(2) << mantissa_explicit_bits();
652
+ }
653
+ template <> inline constexpr uint64_t binary_format<double>::max_mantissa_fast_path(int64_t power) {
654
+ // caller is responsible to ensure that
655
+ // power >= 0 && power <= 22
656
+ //
657
+ // Work around clang bug https://godbolt.org/z/zedh7rrhc
658
+ return (void)max_mantissa[0], max_mantissa[power];
659
+ }
660
+ template <> inline constexpr uint64_t binary_format<float>::max_mantissa_fast_path() {
661
+ return uint64_t(2) << mantissa_explicit_bits();
662
+ }
663
+ template <> inline constexpr uint64_t binary_format<float>::max_mantissa_fast_path(int64_t power) {
664
+ // caller is responsible to ensure that
665
+ // power >= 0 && power <= 10
666
+ //
667
+ // Work around clang bug https://godbolt.org/z/zedh7rrhc
668
+ return (void)max_mantissa[0], max_mantissa[power];
669
+ }
670
+
671
+ template <>
672
+ inline constexpr double binary_format<double>::exact_power_of_ten(int64_t power) {
673
+ // Work around clang bug https://godbolt.org/z/zedh7rrhc
674
+ return (void)powers_of_ten[0], powers_of_ten[power];
675
+ }
676
+ template <>
677
+ inline constexpr float binary_format<float>::exact_power_of_ten(int64_t power) {
678
+ // Work around clang bug https://godbolt.org/z/zedh7rrhc
679
+ return (void)powers_of_ten[0], powers_of_ten[power];
680
+ }
681
+
682
+
683
+ template <>
684
+ inline constexpr int binary_format<double>::largest_power_of_ten() {
685
+ return 308;
686
+ }
687
+ template <>
688
+ inline constexpr int binary_format<float>::largest_power_of_ten() {
689
+ return 38;
690
+ }
691
+
692
+ template <>
693
+ inline constexpr int binary_format<double>::smallest_power_of_ten() {
694
+ return -342;
695
+ }
696
+ template <>
697
+ inline constexpr int binary_format<float>::smallest_power_of_ten() {
698
+ return -65;
699
+ }
700
+
701
+ template <> inline constexpr size_t binary_format<double>::max_digits() {
702
+ return 769;
703
+ }
704
+ template <> inline constexpr size_t binary_format<float>::max_digits() {
705
+ return 114;
706
+ }
707
+
708
+ template <> inline constexpr binary_format<float>::equiv_uint
709
+ binary_format<float>::exponent_mask() {
710
+ return 0x7F800000;
711
+ }
712
+ template <> inline constexpr binary_format<double>::equiv_uint
713
+ binary_format<double>::exponent_mask() {
714
+ return 0x7FF0000000000000;
715
+ }
716
+
717
+ template <> inline constexpr binary_format<float>::equiv_uint
718
+ binary_format<float>::mantissa_mask() {
719
+ return 0x007FFFFF;
720
+ }
721
+ template <> inline constexpr binary_format<double>::equiv_uint
722
+ binary_format<double>::mantissa_mask() {
723
+ return 0x000FFFFFFFFFFFFF;
724
+ }
725
+
726
+ template <> inline constexpr binary_format<float>::equiv_uint
727
+ binary_format<float>::hidden_bit_mask() {
728
+ return 0x00800000;
729
+ }
730
+ template <> inline constexpr binary_format<double>::equiv_uint
731
+ binary_format<double>::hidden_bit_mask() {
732
+ return 0x0010000000000000;
733
+ }
734
+
735
+ template<typename T>
736
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
737
+ void to_float(bool negative, adjusted_mantissa am, T &value) {
738
+ using fastfloat_uint = typename binary_format<T>::equiv_uint;
739
+ fastfloat_uint word = (fastfloat_uint)am.mantissa;
740
+ word |= fastfloat_uint(am.power2) << binary_format<T>::mantissa_explicit_bits();
741
+ word |= fastfloat_uint(negative) << binary_format<T>::sign_index();
742
+ #if FASTFLOAT_HAS_BIT_CAST
743
+ value = std::bit_cast<T>(word);
744
+ #else
745
+ ::memcpy(&value, &word, sizeof(T));
746
+ #endif
747
+ }
748
+
749
+ #ifdef FASTFLOAT_SKIP_WHITE_SPACE // disabled by default
750
+ template <typename = void>
751
+ struct space_lut {
752
+ static constexpr bool value[] = {
753
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
754
+ 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
755
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
756
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
757
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
758
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
759
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
760
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
761
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
762
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
763
+ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
764
+ };
765
+
766
+ template <typename T>
767
+ constexpr bool space_lut<T>::value[];
768
+
769
+ inline constexpr bool is_space(uint8_t c) { return space_lut<>::value[c]; }
770
+ #endif
771
+
772
+ template<typename UC>
773
+ static constexpr uint64_t int_cmp_zeros()
774
+ {
775
+ static_assert((sizeof(UC) == 1) || (sizeof(UC) == 2) || (sizeof(UC) == 4), "Unsupported character size");
776
+ return (sizeof(UC) == 1) ? 0x3030303030303030 : (sizeof(UC) == 2) ? (uint64_t(UC('0')) << 48 | uint64_t(UC('0')) << 32 | uint64_t(UC('0')) << 16 | UC('0')) : (uint64_t(UC('0')) << 32 | UC('0'));
777
+ }
778
+ template<typename UC>
779
+ static constexpr int int_cmp_len()
780
+ {
781
+ return sizeof(uint64_t) / sizeof(UC);
782
+ }
783
+ template<typename UC>
784
+ static constexpr UC const * str_const_nan()
785
+ {
786
+ return nullptr;
787
+ }
788
+ template<>
789
+ constexpr char const * str_const_nan<char>()
790
+ {
791
+ return "nan";
792
+ }
793
+ template<>
794
+ constexpr wchar_t const * str_const_nan<wchar_t>()
795
+ {
796
+ return L"nan";
797
+ }
798
+ template<>
799
+ constexpr char16_t const * str_const_nan<char16_t>()
800
+ {
801
+ return u"nan";
802
+ }
803
+ template<>
804
+ constexpr char32_t const * str_const_nan<char32_t>()
805
+ {
806
+ return U"nan";
807
+ }
808
+ template<typename UC>
809
+ static constexpr UC const * str_const_inf()
810
+ {
811
+ return nullptr;
812
+ }
813
+ template<>
814
+ constexpr char const * str_const_inf<char>()
815
+ {
816
+ return "infinity";
817
+ }
818
+ template<>
819
+ constexpr wchar_t const * str_const_inf<wchar_t>()
820
+ {
821
+ return L"infinity";
822
+ }
823
+ template<>
824
+ constexpr char16_t const * str_const_inf<char16_t>()
825
+ {
826
+ return u"infinity";
827
+ }
828
+ template<>
829
+ constexpr char32_t const * str_const_inf<char32_t>()
830
+ {
831
+ return U"infinity";
832
+ }
833
+
834
+
835
+ template <typename = void>
836
+ struct int_luts {
837
+ static constexpr uint8_t chdigit[] = {
838
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
839
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
840
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
841
+ 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 255, 255, 255, 255, 255, 255,
842
+ 255, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
843
+ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 255, 255, 255, 255, 255,
844
+ 255, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24,
845
+ 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 255, 255, 255, 255, 255,
846
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
847
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
848
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
849
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
850
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
851
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
852
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255,
853
+ 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255, 255
854
+ };
855
+
856
+ static constexpr size_t maxdigits_u64[] = {
857
+ 64, 41, 32, 28, 25, 23, 22, 21,
858
+ 20, 19, 18, 18, 17, 17, 16, 16,
859
+ 16, 16, 15, 15, 15, 15, 14, 14,
860
+ 14, 14, 14, 14, 14, 13, 13, 13,
861
+ 13, 13, 13
862
+ };
863
+
864
+ static constexpr uint64_t min_safe_u64[] = {
865
+ 9223372036854775808ull, 12157665459056928801ull, 4611686018427387904, 7450580596923828125, 4738381338321616896,
866
+ 3909821048582988049, 9223372036854775808ull, 12157665459056928801ull, 10000000000000000000ull, 5559917313492231481,
867
+ 2218611106740436992, 8650415919381337933, 2177953337809371136, 6568408355712890625, 1152921504606846976,
868
+ 2862423051509815793, 6746640616477458432, 15181127029874798299ull, 1638400000000000000, 3243919932521508681,
869
+ 6221821273427820544, 11592836324538749809ull, 876488338465357824, 1490116119384765625, 2481152873203736576,
870
+ 4052555153018976267, 6502111422497947648, 10260628712958602189ull, 15943230000000000000ull, 787662783788549761,
871
+ 1152921504606846976, 1667889514952984961, 2386420683693101056, 3379220508056640625, 4738381338321616896
872
+ };
873
+ };
874
+
875
+ template <typename T>
876
+ constexpr uint8_t int_luts<T>::chdigit[];
877
+
878
+ template <typename T>
879
+ constexpr size_t int_luts<T>::maxdigits_u64[];
880
+
881
+ template <typename T>
882
+ constexpr uint64_t int_luts<T>::min_safe_u64[];
883
+
884
+ template <typename UC>
885
+ fastfloat_really_inline
886
+ constexpr uint8_t ch_to_digit(UC c) { return int_luts<>::chdigit[static_cast<unsigned char>(c)]; }
887
+
888
+ fastfloat_really_inline
889
+ constexpr size_t max_digits_u64(int base) { return int_luts<>::maxdigits_u64[base - 2]; }
890
+
891
+ // If a u64 is exactly max_digits_u64() in length, this is
892
+ // the value below which it has definitely overflowed.
893
+ fastfloat_really_inline
894
+ constexpr uint64_t min_safe_u64(int base) { return int_luts<>::min_safe_u64[base - 2]; }
895
+
896
+ } // namespace fast_float
897
+
898
+ #endif
899
+
900
+
901
+ #ifndef FASTFLOAT_FAST_FLOAT_H
902
+ #define FASTFLOAT_FAST_FLOAT_H
903
+
904
+
905
+ namespace fast_float {
906
+ /**
907
+ * This function parses the character sequence [first,last) for a number. It parses floating-point numbers expecting
908
+ * a locale-indepent format equivalent to what is used by std::strtod in the default ("C") locale.
909
+ * The resulting floating-point value is the closest floating-point values (using either float or double),
910
+ * using the "round to even" convention for values that would otherwise fall right in-between two values.
911
+ * That is, we provide exact parsing according to the IEEE standard.
912
+ *
913
+ * Given a successful parse, the pointer (`ptr`) in the returned value is set to point right after the
914
+ * parsed number, and the `value` referenced is set to the parsed value. In case of error, the returned
915
+ * `ec` contains a representative error, otherwise the default (`std::errc()`) value is stored.
916
+ *
917
+ * The implementation does not throw and does not allocate memory (e.g., with `new` or `malloc`).
918
+ *
919
+ * Like the C++17 standard, the `fast_float::from_chars` functions take an optional last argument of
920
+ * the type `fast_float::chars_format`. It is a bitset value: we check whether
921
+ * `fmt & fast_float::chars_format::fixed` and `fmt & fast_float::chars_format::scientific` are set
922
+ * to determine whether we allow the fixed point and scientific notation respectively.
923
+ * The default is `fast_float::chars_format::general` which allows both `fixed` and `scientific`.
924
+ */
925
+ template<typename T, typename UC = char, typename = FASTFLOAT_ENABLE_IF(is_supported_float_type<T>())>
926
+ FASTFLOAT_CONSTEXPR20
927
+ from_chars_result_t<UC> from_chars(UC const * first, UC const * last,
928
+ T &value, chars_format fmt = chars_format::general) noexcept;
929
+
930
+ /**
931
+ * Like from_chars, but accepts an `options` argument to govern number parsing.
932
+ */
933
+ template<typename T, typename UC = char>
934
+ FASTFLOAT_CONSTEXPR20
935
+ from_chars_result_t<UC> from_chars_advanced(UC const * first, UC const * last,
936
+ T &value, parse_options_t<UC> options) noexcept;
937
+ /**
938
+ * from_chars for integer types.
939
+ */
940
+ template <typename T, typename UC = char, typename = FASTFLOAT_ENABLE_IF(!is_supported_float_type<T>())>
941
+ FASTFLOAT_CONSTEXPR20
942
+ from_chars_result_t<UC> from_chars(UC const * first, UC const * last, T& value, int base = 10) noexcept;
943
+
944
+ } // namespace fast_float
945
+ #endif // FASTFLOAT_FAST_FLOAT_H
946
+
947
+ #ifndef FASTFLOAT_ASCII_NUMBER_H
948
+ #define FASTFLOAT_ASCII_NUMBER_H
949
+
950
+ #include <cctype>
951
+ #include <cstdint>
952
+ #include <cstring>
953
+ #include <iterator>
954
+ #include <limits>
955
+ #include <type_traits>
956
+
957
+
958
+ #ifdef FASTFLOAT_SSE2
959
+ #include <emmintrin.h>
960
+ #endif
961
+
962
+ #ifdef FASTFLOAT_NEON
963
+ #include <arm_neon.h>
964
+ #endif
965
+
966
+ namespace fast_float {
967
+
968
+ template <typename UC>
969
+ fastfloat_really_inline constexpr bool has_simd_opt() {
970
+ #ifdef FASTFLOAT_HAS_SIMD
971
+ return std::is_same<UC, char16_t>::value;
972
+ #else
973
+ return false;
974
+ #endif
975
+ }
976
+
977
+ // Next function can be micro-optimized, but compilers are entirely
978
+ // able to optimize it well.
979
+ template <typename UC>
980
+ fastfloat_really_inline constexpr bool is_integer(UC c) noexcept {
981
+ return !(c > UC('9') || c < UC('0'));
982
+ }
983
+
984
+ fastfloat_really_inline constexpr uint64_t byteswap(uint64_t val) {
985
+ return (val & 0xFF00000000000000) >> 56
986
+ | (val & 0x00FF000000000000) >> 40
987
+ | (val & 0x0000FF0000000000) >> 24
988
+ | (val & 0x000000FF00000000) >> 8
989
+ | (val & 0x00000000FF000000) << 8
990
+ | (val & 0x0000000000FF0000) << 24
991
+ | (val & 0x000000000000FF00) << 40
992
+ | (val & 0x00000000000000FF) << 56;
993
+ }
994
+
995
+ // Read 8 UC into a u64. Truncates UC if not char.
996
+ template <typename UC>
997
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
998
+ uint64_t read8_to_u64(const UC *chars) {
999
+ if (cpp20_and_in_constexpr() || !std::is_same<UC, char>::value) {
1000
+ uint64_t val = 0;
1001
+ for(int i = 0; i < 8; ++i) {
1002
+ val |= uint64_t(uint8_t(*chars)) << (i*8);
1003
+ ++chars;
1004
+ }
1005
+ return val;
1006
+ }
1007
+ uint64_t val;
1008
+ ::memcpy(&val, chars, sizeof(uint64_t));
1009
+ #if FASTFLOAT_IS_BIG_ENDIAN == 1
1010
+ // Need to read as-if the number was in little-endian order.
1011
+ val = byteswap(val);
1012
+ #endif
1013
+ return val;
1014
+ }
1015
+
1016
+ #ifdef FASTFLOAT_SSE2
1017
+
1018
+ fastfloat_really_inline
1019
+ uint64_t simd_read8_to_u64(const __m128i data) {
1020
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1021
+ const __m128i packed = _mm_packus_epi16(data, data);
1022
+ #ifdef FASTFLOAT_64BIT
1023
+ return uint64_t(_mm_cvtsi128_si64(packed));
1024
+ #else
1025
+ uint64_t value;
1026
+ // Visual Studio + older versions of GCC don't support _mm_storeu_si64
1027
+ _mm_storel_epi64(reinterpret_cast<__m128i*>(&value), packed);
1028
+ return value;
1029
+ #endif
1030
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1031
+ }
1032
+
1033
+ fastfloat_really_inline
1034
+ uint64_t simd_read8_to_u64(const char16_t* chars) {
1035
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1036
+ return simd_read8_to_u64(_mm_loadu_si128(reinterpret_cast<const __m128i*>(chars)));
1037
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1038
+ }
1039
+
1040
+ #elif defined(FASTFLOAT_NEON)
1041
+
1042
+
1043
+ fastfloat_really_inline
1044
+ uint64_t simd_read8_to_u64(const uint16x8_t data) {
1045
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1046
+ uint8x8_t utf8_packed = vmovn_u16(data);
1047
+ return vget_lane_u64(vreinterpret_u64_u8(utf8_packed), 0);
1048
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1049
+ }
1050
+
1051
+ fastfloat_really_inline
1052
+ uint64_t simd_read8_to_u64(const char16_t* chars) {
1053
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1054
+ return simd_read8_to_u64(vld1q_u16(reinterpret_cast<const uint16_t*>(chars)));
1055
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1056
+ }
1057
+
1058
+ #endif // FASTFLOAT_SSE2
1059
+
1060
+ // MSVC SFINAE is broken pre-VS2017
1061
+ #if defined(_MSC_VER) && _MSC_VER <= 1900
1062
+ template <typename UC>
1063
+ #else
1064
+ template <typename UC, FASTFLOAT_ENABLE_IF(!has_simd_opt<UC>()) = 0>
1065
+ #endif
1066
+ // dummy for compile
1067
+ uint64_t simd_read8_to_u64(UC const*) {
1068
+ return 0;
1069
+ }
1070
+
1071
+
1072
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1073
+ void write_u64(uint8_t *chars, uint64_t val) {
1074
+ if (cpp20_and_in_constexpr()) {
1075
+ for(int i = 0; i < 8; ++i) {
1076
+ *chars = uint8_t(val);
1077
+ val >>= 8;
1078
+ ++chars;
1079
+ }
1080
+ return;
1081
+ }
1082
+ #if FASTFLOAT_IS_BIG_ENDIAN == 1
1083
+ // Need to read as-if the number was in little-endian order.
1084
+ val = byteswap(val);
1085
+ #endif
1086
+ ::memcpy(chars, &val, sizeof(uint64_t));
1087
+ }
1088
+
1089
+ // credit @aqrit
1090
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
1091
+ uint32_t parse_eight_digits_unrolled(uint64_t val) {
1092
+ const uint64_t mask = 0x000000FF000000FF;
1093
+ const uint64_t mul1 = 0x000F424000000064; // 100 + (1000000ULL << 32)
1094
+ const uint64_t mul2 = 0x0000271000000001; // 1 + (10000ULL << 32)
1095
+ val -= 0x3030303030303030;
1096
+ val = (val * 10) + (val >> 8); // val = (val * 2561) >> 8;
1097
+ val = (((val & mask) * mul1) + (((val >> 16) & mask) * mul2)) >> 32;
1098
+ return uint32_t(val);
1099
+ }
1100
+
1101
+
1102
+ // Call this if chars are definitely 8 digits.
1103
+ template <typename UC>
1104
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1105
+ uint32_t parse_eight_digits_unrolled(UC const * chars) noexcept {
1106
+ if (cpp20_and_in_constexpr() || !has_simd_opt<UC>()) {
1107
+ return parse_eight_digits_unrolled(read8_to_u64(chars)); // truncation okay
1108
+ }
1109
+ return parse_eight_digits_unrolled(simd_read8_to_u64(chars));
1110
+ }
1111
+
1112
+
1113
+ // credit @aqrit
1114
+ fastfloat_really_inline constexpr bool is_made_of_eight_digits_fast(uint64_t val) noexcept {
1115
+ return !((((val + 0x4646464646464646) | (val - 0x3030303030303030)) &
1116
+ 0x8080808080808080));
1117
+ }
1118
+
1119
+
1120
+ #ifdef FASTFLOAT_HAS_SIMD
1121
+
1122
+ // Call this if chars might not be 8 digits.
1123
+ // Using this style (instead of is_made_of_eight_digits_fast() then parse_eight_digits_unrolled())
1124
+ // ensures we don't load SIMD registers twice.
1125
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1126
+ bool simd_parse_if_eight_digits_unrolled(const char16_t* chars, uint64_t& i) noexcept {
1127
+ if (cpp20_and_in_constexpr()) {
1128
+ return false;
1129
+ }
1130
+ #ifdef FASTFLOAT_SSE2
1131
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1132
+ const __m128i data = _mm_loadu_si128(reinterpret_cast<const __m128i*>(chars));
1133
+
1134
+ // (x - '0') <= 9
1135
+ // http://0x80.pl/articles/simd-parsing-int-sequences.html
1136
+ const __m128i t0 = _mm_add_epi16(data, _mm_set1_epi16(32720));
1137
+ const __m128i t1 = _mm_cmpgt_epi16(t0, _mm_set1_epi16(-32759));
1138
+
1139
+ if (_mm_movemask_epi8(t1) == 0) {
1140
+ i = i * 100000000 + parse_eight_digits_unrolled(simd_read8_to_u64(data));
1141
+ return true;
1142
+ }
1143
+ else return false;
1144
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1145
+ #elif defined(FASTFLOAT_NEON)
1146
+ FASTFLOAT_SIMD_DISABLE_WARNINGS
1147
+ const uint16x8_t data = vld1q_u16(reinterpret_cast<const uint16_t*>(chars));
1148
+
1149
+ // (x - '0') <= 9
1150
+ // http://0x80.pl/articles/simd-parsing-int-sequences.html
1151
+ const uint16x8_t t0 = vsubq_u16(data, vmovq_n_u16('0'));
1152
+ const uint16x8_t mask = vcltq_u16(t0, vmovq_n_u16('9' - '0' + 1));
1153
+
1154
+ if (vminvq_u16(mask) == 0xFFFF) {
1155
+ i = i * 100000000 + parse_eight_digits_unrolled(simd_read8_to_u64(data));
1156
+ return true;
1157
+ }
1158
+ else return false;
1159
+ FASTFLOAT_SIMD_RESTORE_WARNINGS
1160
+ #else
1161
+ (void)chars; (void)i;
1162
+ return false;
1163
+ #endif // FASTFLOAT_SSE2
1164
+ }
1165
+
1166
+ #endif // FASTFLOAT_HAS_SIMD
1167
+
1168
+ // MSVC SFINAE is broken pre-VS2017
1169
+ #if defined(_MSC_VER) && _MSC_VER <= 1900
1170
+ template <typename UC>
1171
+ #else
1172
+ template <typename UC, FASTFLOAT_ENABLE_IF(!has_simd_opt<UC>()) = 0>
1173
+ #endif
1174
+ // dummy for compile
1175
+ bool simd_parse_if_eight_digits_unrolled(UC const*, uint64_t&) {
1176
+ return 0;
1177
+ }
1178
+
1179
+
1180
+ template <typename UC, FASTFLOAT_ENABLE_IF(!std::is_same<UC, char>::value) = 0>
1181
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1182
+ void loop_parse_if_eight_digits(const UC*& p, const UC* const pend, uint64_t& i) {
1183
+ if (!has_simd_opt<UC>()) {
1184
+ return;
1185
+ }
1186
+ while ((std::distance(p, pend) >= 8) && simd_parse_if_eight_digits_unrolled(p, i)) { // in rare cases, this will overflow, but that's ok
1187
+ p += 8;
1188
+ }
1189
+ }
1190
+
1191
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1192
+ void loop_parse_if_eight_digits(const char*& p, const char* const pend, uint64_t& i) {
1193
+ // optimizes better than parse_if_eight_digits_unrolled() for UC = char.
1194
+ while ((std::distance(p, pend) >= 8) && is_made_of_eight_digits_fast(read8_to_u64(p))) {
1195
+ i = i * 100000000 + parse_eight_digits_unrolled(read8_to_u64(p)); // in rare cases, this will overflow, but that's ok
1196
+ p += 8;
1197
+ }
1198
+ }
1199
+
1200
+ template <typename UC>
1201
+ struct parsed_number_string_t {
1202
+ int64_t exponent{0};
1203
+ uint64_t mantissa{0};
1204
+ UC const * lastmatch{nullptr};
1205
+ bool negative{false};
1206
+ bool valid{false};
1207
+ bool too_many_digits{false};
1208
+ // contains the range of the significant digits
1209
+ span<const UC> integer{}; // non-nullable
1210
+ span<const UC> fraction{}; // nullable
1211
+ };
1212
+
1213
+ using byte_span = span<const char>;
1214
+ using parsed_number_string = parsed_number_string_t<char>;
1215
+
1216
+ // Assuming that you use no more than 19 digits, this will
1217
+ // parse an ASCII string.
1218
+ template <typename UC>
1219
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1220
+ parsed_number_string_t<UC> parse_number_string(UC const *p, UC const * pend, parse_options_t<UC> options) noexcept {
1221
+ chars_format const fmt = options.format;
1222
+ UC const decimal_point = options.decimal_point;
1223
+
1224
+ parsed_number_string_t<UC> answer;
1225
+ answer.valid = false;
1226
+ answer.too_many_digits = false;
1227
+ answer.negative = (*p == UC('-'));
1228
+ #ifdef FASTFLOAT_ALLOWS_LEADING_PLUS // disabled by default
1229
+ if ((*p == UC('-')) || (!(fmt & FASTFLOAT_JSONFMT) && *p == UC('+'))) {
1230
+ #else
1231
+ if (*p == UC('-')) { // C++17 20.19.3.(7.1) explicitly forbids '+' sign here
1232
+ #endif
1233
+ ++p;
1234
+ if (p == pend) {
1235
+ return answer;
1236
+ }
1237
+ if (fmt & FASTFLOAT_JSONFMT) {
1238
+ if (!is_integer(*p)) { // a sign must be followed by an integer
1239
+ return answer;
1240
+ }
1241
+ } else {
1242
+ if (!is_integer(*p) && (*p != decimal_point)) { // a sign must be followed by an integer or the dot
1243
+ return answer;
1244
+ }
1245
+ }
1246
+ }
1247
+ UC const * const start_digits = p;
1248
+
1249
+ uint64_t i = 0; // an unsigned int avoids signed overflows (which are bad)
1250
+
1251
+ while ((p != pend) && is_integer(*p)) {
1252
+ // a multiplication by 10 is cheaper than an arbitrary integer
1253
+ // multiplication
1254
+ i = 10 * i +
1255
+ uint64_t(*p - UC('0')); // might overflow, we will handle the overflow later
1256
+ ++p;
1257
+ }
1258
+ UC const * const end_of_integer_part = p;
1259
+ int64_t digit_count = int64_t(end_of_integer_part - start_digits);
1260
+ answer.integer = span<const UC>(start_digits, size_t(digit_count));
1261
+ if (fmt & FASTFLOAT_JSONFMT) {
1262
+ // at least 1 digit in integer part, without leading zeros
1263
+ if (digit_count == 0 || (start_digits[0] == UC('0') && digit_count > 1)) {
1264
+ return answer;
1265
+ }
1266
+ }
1267
+
1268
+ int64_t exponent = 0;
1269
+ const bool has_decimal_point = (p != pend) && (*p == decimal_point);
1270
+ if (has_decimal_point) {
1271
+ ++p;
1272
+ UC const * before = p;
1273
+ // can occur at most twice without overflowing, but let it occur more, since
1274
+ // for integers with many digits, digit parsing is the primary bottleneck.
1275
+ loop_parse_if_eight_digits(p, pend, i);
1276
+
1277
+ while ((p != pend) && is_integer(*p)) {
1278
+ uint8_t digit = uint8_t(*p - UC('0'));
1279
+ ++p;
1280
+ i = i * 10 + digit; // in rare cases, this will overflow, but that's ok
1281
+ }
1282
+ exponent = before - p;
1283
+ answer.fraction = span<const UC>(before, size_t(p - before));
1284
+ digit_count -= exponent;
1285
+ }
1286
+ if (fmt & FASTFLOAT_JSONFMT) {
1287
+ // at least 1 digit in fractional part
1288
+ if (has_decimal_point && exponent == 0) {
1289
+ return answer;
1290
+ }
1291
+ }
1292
+ else if (digit_count == 0) { // we must have encountered at least one integer!
1293
+ return answer;
1294
+ }
1295
+ int64_t exp_number = 0; // explicit exponential part
1296
+ if ( ((fmt & chars_format::scientific) &&
1297
+ (p != pend) &&
1298
+ ((UC('e') == *p) || (UC('E') == *p)))
1299
+ ||
1300
+ ((fmt & FASTFLOAT_FORTRANFMT) &&
1301
+ (p != pend) &&
1302
+ ((UC('+') == *p) || (UC('-') == *p) || (UC('d') == *p) || (UC('D') == *p)))) {
1303
+ UC const * location_of_e = p;
1304
+ if ((UC('e') == *p) || (UC('E') == *p) || (UC('d') == *p) || (UC('D') == *p)) {
1305
+ ++p;
1306
+ }
1307
+ bool neg_exp = false;
1308
+ if ((p != pend) && (UC('-') == *p)) {
1309
+ neg_exp = true;
1310
+ ++p;
1311
+ } else if ((p != pend) && (UC('+') == *p)) { // '+' on exponent is allowed by C++17 20.19.3.(7.1)
1312
+ ++p;
1313
+ }
1314
+ if ((p == pend) || !is_integer(*p)) {
1315
+ if(!(fmt & chars_format::fixed)) {
1316
+ // We are in error.
1317
+ return answer;
1318
+ }
1319
+ // Otherwise, we will be ignoring the 'e'.
1320
+ p = location_of_e;
1321
+ } else {
1322
+ while ((p != pend) && is_integer(*p)) {
1323
+ uint8_t digit = uint8_t(*p - UC('0'));
1324
+ if (exp_number < 0x10000000) {
1325
+ exp_number = 10 * exp_number + digit;
1326
+ }
1327
+ ++p;
1328
+ }
1329
+ if(neg_exp) { exp_number = - exp_number; }
1330
+ exponent += exp_number;
1331
+ }
1332
+ } else {
1333
+ // If it scientific and not fixed, we have to bail out.
1334
+ if((fmt & chars_format::scientific) && !(fmt & chars_format::fixed)) { return answer; }
1335
+ }
1336
+ answer.lastmatch = p;
1337
+ answer.valid = true;
1338
+
1339
+ // If we frequently had to deal with long strings of digits,
1340
+ // we could extend our code by using a 128-bit integer instead
1341
+ // of a 64-bit integer. However, this is uncommon.
1342
+ //
1343
+ // We can deal with up to 19 digits.
1344
+ if (digit_count > 19) { // this is uncommon
1345
+ // It is possible that the integer had an overflow.
1346
+ // We have to handle the case where we have 0.0000somenumber.
1347
+ // We need to be mindful of the case where we only have zeroes...
1348
+ // E.g., 0.000000000...000.
1349
+ UC const * start = start_digits;
1350
+ while ((start != pend) && (*start == UC('0') || *start == decimal_point)) {
1351
+ if(*start == UC('0')) { digit_count --; }
1352
+ start++;
1353
+ }
1354
+
1355
+ if (digit_count > 19) {
1356
+ answer.too_many_digits = true;
1357
+ // Let us start again, this time, avoiding overflows.
1358
+ // We don't need to check if is_integer, since we use the
1359
+ // pre-tokenized spans from above.
1360
+ i = 0;
1361
+ p = answer.integer.ptr;
1362
+ UC const* int_end = p + answer.integer.len();
1363
+ const uint64_t minimal_nineteen_digit_integer{ 1000000000000000000 };
1364
+ while ((i < minimal_nineteen_digit_integer) && (p != int_end)) {
1365
+ i = i * 10 + uint64_t(*p - UC('0'));
1366
+ ++p;
1367
+ }
1368
+ if (i >= minimal_nineteen_digit_integer) { // We have a big integers
1369
+ exponent = end_of_integer_part - p + exp_number;
1370
+ }
1371
+ else { // We have a value with a fractional component.
1372
+ p = answer.fraction.ptr;
1373
+ UC const* frac_end = p + answer.fraction.len();
1374
+ while ((i < minimal_nineteen_digit_integer) && (p != frac_end)) {
1375
+ i = i * 10 + uint64_t(*p - UC('0'));
1376
+ ++p;
1377
+ }
1378
+ exponent = answer.fraction.ptr - p + exp_number;
1379
+ }
1380
+ // We have now corrected both exponent and i, to a truncated value
1381
+ }
1382
+ }
1383
+ answer.exponent = exponent;
1384
+ answer.mantissa = i;
1385
+ return answer;
1386
+ }
1387
+
1388
+ template <typename T, typename UC>
1389
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
1390
+ from_chars_result_t<UC> parse_int_string(UC const* p, UC const* pend, T& value, int base) {
1391
+ from_chars_result_t<UC> answer;
1392
+
1393
+ UC const* const first = p;
1394
+
1395
+ bool negative = (*p == UC('-'));
1396
+ if (!std::is_signed<T>::value && negative) {
1397
+ answer.ec = std::errc::invalid_argument;
1398
+ answer.ptr = first;
1399
+ return answer;
1400
+ }
1401
+ #ifdef FASTFLOAT_ALLOWS_LEADING_PLUS // disabled by default
1402
+ if ((*p == UC('-')) || (*p == UC('+'))) {
1403
+ #else
1404
+ if (*p == UC('-')) {
1405
+ #endif
1406
+ ++p;
1407
+ }
1408
+
1409
+ UC const* const start_num = p;
1410
+
1411
+ while (p!= pend && *p == UC('0')) {
1412
+ ++p;
1413
+ }
1414
+
1415
+ const bool has_leading_zeros = p > start_num;
1416
+
1417
+ UC const* const start_digits = p;
1418
+
1419
+ uint64_t i = 0;
1420
+ if (base == 10) {
1421
+ loop_parse_if_eight_digits(p, pend, i); // use SIMD if possible
1422
+ }
1423
+ while (p != pend) {
1424
+ uint8_t digit = ch_to_digit(*p);
1425
+ if (digit >= base) {
1426
+ break;
1427
+ }
1428
+ i = uint64_t(base) * i + digit; // might overflow, check this later
1429
+ p++;
1430
+ }
1431
+
1432
+ size_t digit_count = size_t(p - start_digits);
1433
+
1434
+ if (digit_count == 0) {
1435
+ if (has_leading_zeros) {
1436
+ value = 0;
1437
+ answer.ec = std::errc();
1438
+ answer.ptr = p;
1439
+ }
1440
+ else {
1441
+ answer.ec = std::errc::invalid_argument;
1442
+ answer.ptr = first;
1443
+ }
1444
+ return answer;
1445
+ }
1446
+
1447
+ answer.ptr = p;
1448
+
1449
+ // check u64 overflow
1450
+ size_t max_digits = max_digits_u64(base);
1451
+ if (digit_count > max_digits) {
1452
+ answer.ec = std::errc::result_out_of_range;
1453
+ return answer;
1454
+ }
1455
+ // this check can be eliminated for all other types, but they will all require a max_digits(base) equivalent
1456
+ if (digit_count == max_digits && i < min_safe_u64(base)) {
1457
+ answer.ec = std::errc::result_out_of_range;
1458
+ return answer;
1459
+ }
1460
+
1461
+ // check other types overflow
1462
+ if (!std::is_same<T, uint64_t>::value) {
1463
+ if (i > uint64_t(std::numeric_limits<T>::max()) + uint64_t(negative)) {
1464
+ answer.ec = std::errc::result_out_of_range;
1465
+ return answer;
1466
+ }
1467
+ }
1468
+
1469
+ if (negative) {
1470
+ #ifdef FASTFLOAT_VISUAL_STUDIO
1471
+ #pragma warning(push)
1472
+ #pragma warning(disable: 4146)
1473
+ #endif
1474
+ // this weird workaround is required because:
1475
+ // - converting unsigned to signed when its value is greater than signed max is UB pre-C++23.
1476
+ // - reinterpret_casting (~i + 1) would work, but it is not constexpr
1477
+ // this is always optimized into a neg instruction (note: T is an integer type)
1478
+ value = T(-std::numeric_limits<T>::max() - T(i - uint64_t(std::numeric_limits<T>::max())));
1479
+ #ifdef FASTFLOAT_VISUAL_STUDIO
1480
+ #pragma warning(pop)
1481
+ #endif
1482
+ }
1483
+ else { value = T(i); }
1484
+
1485
+ answer.ec = std::errc();
1486
+ return answer;
1487
+ }
1488
+
1489
+ } // namespace fast_float
1490
+
1491
+ #endif
1492
+
1493
+ #ifndef FASTFLOAT_FAST_TABLE_H
1494
+ #define FASTFLOAT_FAST_TABLE_H
1495
+
1496
+ #include <cstdint>
1497
+
1498
+ namespace fast_float {
1499
+
1500
+ /**
1501
+ * When mapping numbers from decimal to binary,
1502
+ * we go from w * 10^q to m * 2^p but we have
1503
+ * 10^q = 5^q * 2^q, so effectively
1504
+ * we are trying to match
1505
+ * w * 2^q * 5^q to m * 2^p. Thus the powers of two
1506
+ * are not a concern since they can be represented
1507
+ * exactly using the binary notation, only the powers of five
1508
+ * affect the binary significand.
1509
+ */
1510
+
1511
+ /**
1512
+ * The smallest non-zero float (binary64) is 2^-1074.
1513
+ * We take as input numbers of the form w x 10^q where w < 2^64.
1514
+ * We have that w * 10^-343 < 2^(64-344) 5^-343 < 2^-1076.
1515
+ * However, we have that
1516
+ * (2^64-1) * 10^-342 = (2^64-1) * 2^-342 * 5^-342 > 2^-1074.
1517
+ * Thus it is possible for a number of the form w * 10^-342 where
1518
+ * w is a 64-bit value to be a non-zero floating-point number.
1519
+ *********
1520
+ * Any number of form w * 10^309 where w>= 1 is going to be
1521
+ * infinite in binary64 so we never need to worry about powers
1522
+ * of 5 greater than 308.
1523
+ */
1524
+ template <class unused = void>
1525
+ struct powers_template {
1526
+
1527
+ constexpr static int smallest_power_of_five = binary_format<double>::smallest_power_of_ten();
1528
+ constexpr static int largest_power_of_five = binary_format<double>::largest_power_of_ten();
1529
+ constexpr static int number_of_entries = 2 * (largest_power_of_five - smallest_power_of_five + 1);
1530
+ // Powers of five from 5^-342 all the way to 5^308 rounded toward one.
1531
+ constexpr static uint64_t power_of_five_128[number_of_entries] = {
1532
+ 0xeef453d6923bd65a,0x113faa2906a13b3f,
1533
+ 0x9558b4661b6565f8,0x4ac7ca59a424c507,
1534
+ 0xbaaee17fa23ebf76,0x5d79bcf00d2df649,
1535
+ 0xe95a99df8ace6f53,0xf4d82c2c107973dc,
1536
+ 0x91d8a02bb6c10594,0x79071b9b8a4be869,
1537
+ 0xb64ec836a47146f9,0x9748e2826cdee284,
1538
+ 0xe3e27a444d8d98b7,0xfd1b1b2308169b25,
1539
+ 0x8e6d8c6ab0787f72,0xfe30f0f5e50e20f7,
1540
+ 0xb208ef855c969f4f,0xbdbd2d335e51a935,
1541
+ 0xde8b2b66b3bc4723,0xad2c788035e61382,
1542
+ 0x8b16fb203055ac76,0x4c3bcb5021afcc31,
1543
+ 0xaddcb9e83c6b1793,0xdf4abe242a1bbf3d,
1544
+ 0xd953e8624b85dd78,0xd71d6dad34a2af0d,
1545
+ 0x87d4713d6f33aa6b,0x8672648c40e5ad68,
1546
+ 0xa9c98d8ccb009506,0x680efdaf511f18c2,
1547
+ 0xd43bf0effdc0ba48,0x212bd1b2566def2,
1548
+ 0x84a57695fe98746d,0x14bb630f7604b57,
1549
+ 0xa5ced43b7e3e9188,0x419ea3bd35385e2d,
1550
+ 0xcf42894a5dce35ea,0x52064cac828675b9,
1551
+ 0x818995ce7aa0e1b2,0x7343efebd1940993,
1552
+ 0xa1ebfb4219491a1f,0x1014ebe6c5f90bf8,
1553
+ 0xca66fa129f9b60a6,0xd41a26e077774ef6,
1554
+ 0xfd00b897478238d0,0x8920b098955522b4,
1555
+ 0x9e20735e8cb16382,0x55b46e5f5d5535b0,
1556
+ 0xc5a890362fddbc62,0xeb2189f734aa831d,
1557
+ 0xf712b443bbd52b7b,0xa5e9ec7501d523e4,
1558
+ 0x9a6bb0aa55653b2d,0x47b233c92125366e,
1559
+ 0xc1069cd4eabe89f8,0x999ec0bb696e840a,
1560
+ 0xf148440a256e2c76,0xc00670ea43ca250d,
1561
+ 0x96cd2a865764dbca,0x380406926a5e5728,
1562
+ 0xbc807527ed3e12bc,0xc605083704f5ecf2,
1563
+ 0xeba09271e88d976b,0xf7864a44c633682e,
1564
+ 0x93445b8731587ea3,0x7ab3ee6afbe0211d,
1565
+ 0xb8157268fdae9e4c,0x5960ea05bad82964,
1566
+ 0xe61acf033d1a45df,0x6fb92487298e33bd,
1567
+ 0x8fd0c16206306bab,0xa5d3b6d479f8e056,
1568
+ 0xb3c4f1ba87bc8696,0x8f48a4899877186c,
1569
+ 0xe0b62e2929aba83c,0x331acdabfe94de87,
1570
+ 0x8c71dcd9ba0b4925,0x9ff0c08b7f1d0b14,
1571
+ 0xaf8e5410288e1b6f,0x7ecf0ae5ee44dd9,
1572
+ 0xdb71e91432b1a24a,0xc9e82cd9f69d6150,
1573
+ 0x892731ac9faf056e,0xbe311c083a225cd2,
1574
+ 0xab70fe17c79ac6ca,0x6dbd630a48aaf406,
1575
+ 0xd64d3d9db981787d,0x92cbbccdad5b108,
1576
+ 0x85f0468293f0eb4e,0x25bbf56008c58ea5,
1577
+ 0xa76c582338ed2621,0xaf2af2b80af6f24e,
1578
+ 0xd1476e2c07286faa,0x1af5af660db4aee1,
1579
+ 0x82cca4db847945ca,0x50d98d9fc890ed4d,
1580
+ 0xa37fce126597973c,0xe50ff107bab528a0,
1581
+ 0xcc5fc196fefd7d0c,0x1e53ed49a96272c8,
1582
+ 0xff77b1fcbebcdc4f,0x25e8e89c13bb0f7a,
1583
+ 0x9faacf3df73609b1,0x77b191618c54e9ac,
1584
+ 0xc795830d75038c1d,0xd59df5b9ef6a2417,
1585
+ 0xf97ae3d0d2446f25,0x4b0573286b44ad1d,
1586
+ 0x9becce62836ac577,0x4ee367f9430aec32,
1587
+ 0xc2e801fb244576d5,0x229c41f793cda73f,
1588
+ 0xf3a20279ed56d48a,0x6b43527578c1110f,
1589
+ 0x9845418c345644d6,0x830a13896b78aaa9,
1590
+ 0xbe5691ef416bd60c,0x23cc986bc656d553,
1591
+ 0xedec366b11c6cb8f,0x2cbfbe86b7ec8aa8,
1592
+ 0x94b3a202eb1c3f39,0x7bf7d71432f3d6a9,
1593
+ 0xb9e08a83a5e34f07,0xdaf5ccd93fb0cc53,
1594
+ 0xe858ad248f5c22c9,0xd1b3400f8f9cff68,
1595
+ 0x91376c36d99995be,0x23100809b9c21fa1,
1596
+ 0xb58547448ffffb2d,0xabd40a0c2832a78a,
1597
+ 0xe2e69915b3fff9f9,0x16c90c8f323f516c,
1598
+ 0x8dd01fad907ffc3b,0xae3da7d97f6792e3,
1599
+ 0xb1442798f49ffb4a,0x99cd11cfdf41779c,
1600
+ 0xdd95317f31c7fa1d,0x40405643d711d583,
1601
+ 0x8a7d3eef7f1cfc52,0x482835ea666b2572,
1602
+ 0xad1c8eab5ee43b66,0xda3243650005eecf,
1603
+ 0xd863b256369d4a40,0x90bed43e40076a82,
1604
+ 0x873e4f75e2224e68,0x5a7744a6e804a291,
1605
+ 0xa90de3535aaae202,0x711515d0a205cb36,
1606
+ 0xd3515c2831559a83,0xd5a5b44ca873e03,
1607
+ 0x8412d9991ed58091,0xe858790afe9486c2,
1608
+ 0xa5178fff668ae0b6,0x626e974dbe39a872,
1609
+ 0xce5d73ff402d98e3,0xfb0a3d212dc8128f,
1610
+ 0x80fa687f881c7f8e,0x7ce66634bc9d0b99,
1611
+ 0xa139029f6a239f72,0x1c1fffc1ebc44e80,
1612
+ 0xc987434744ac874e,0xa327ffb266b56220,
1613
+ 0xfbe9141915d7a922,0x4bf1ff9f0062baa8,
1614
+ 0x9d71ac8fada6c9b5,0x6f773fc3603db4a9,
1615
+ 0xc4ce17b399107c22,0xcb550fb4384d21d3,
1616
+ 0xf6019da07f549b2b,0x7e2a53a146606a48,
1617
+ 0x99c102844f94e0fb,0x2eda7444cbfc426d,
1618
+ 0xc0314325637a1939,0xfa911155fefb5308,
1619
+ 0xf03d93eebc589f88,0x793555ab7eba27ca,
1620
+ 0x96267c7535b763b5,0x4bc1558b2f3458de,
1621
+ 0xbbb01b9283253ca2,0x9eb1aaedfb016f16,
1622
+ 0xea9c227723ee8bcb,0x465e15a979c1cadc,
1623
+ 0x92a1958a7675175f,0xbfacd89ec191ec9,
1624
+ 0xb749faed14125d36,0xcef980ec671f667b,
1625
+ 0xe51c79a85916f484,0x82b7e12780e7401a,
1626
+ 0x8f31cc0937ae58d2,0xd1b2ecb8b0908810,
1627
+ 0xb2fe3f0b8599ef07,0x861fa7e6dcb4aa15,
1628
+ 0xdfbdcece67006ac9,0x67a791e093e1d49a,
1629
+ 0x8bd6a141006042bd,0xe0c8bb2c5c6d24e0,
1630
+ 0xaecc49914078536d,0x58fae9f773886e18,
1631
+ 0xda7f5bf590966848,0xaf39a475506a899e,
1632
+ 0x888f99797a5e012d,0x6d8406c952429603,
1633
+ 0xaab37fd7d8f58178,0xc8e5087ba6d33b83,
1634
+ 0xd5605fcdcf32e1d6,0xfb1e4a9a90880a64,
1635
+ 0x855c3be0a17fcd26,0x5cf2eea09a55067f,
1636
+ 0xa6b34ad8c9dfc06f,0xf42faa48c0ea481e,
1637
+ 0xd0601d8efc57b08b,0xf13b94daf124da26,
1638
+ 0x823c12795db6ce57,0x76c53d08d6b70858,
1639
+ 0xa2cb1717b52481ed,0x54768c4b0c64ca6e,
1640
+ 0xcb7ddcdda26da268,0xa9942f5dcf7dfd09,
1641
+ 0xfe5d54150b090b02,0xd3f93b35435d7c4c,
1642
+ 0x9efa548d26e5a6e1,0xc47bc5014a1a6daf,
1643
+ 0xc6b8e9b0709f109a,0x359ab6419ca1091b,
1644
+ 0xf867241c8cc6d4c0,0xc30163d203c94b62,
1645
+ 0x9b407691d7fc44f8,0x79e0de63425dcf1d,
1646
+ 0xc21094364dfb5636,0x985915fc12f542e4,
1647
+ 0xf294b943e17a2bc4,0x3e6f5b7b17b2939d,
1648
+ 0x979cf3ca6cec5b5a,0xa705992ceecf9c42,
1649
+ 0xbd8430bd08277231,0x50c6ff782a838353,
1650
+ 0xece53cec4a314ebd,0xa4f8bf5635246428,
1651
+ 0x940f4613ae5ed136,0x871b7795e136be99,
1652
+ 0xb913179899f68584,0x28e2557b59846e3f,
1653
+ 0xe757dd7ec07426e5,0x331aeada2fe589cf,
1654
+ 0x9096ea6f3848984f,0x3ff0d2c85def7621,
1655
+ 0xb4bca50b065abe63,0xfed077a756b53a9,
1656
+ 0xe1ebce4dc7f16dfb,0xd3e8495912c62894,
1657
+ 0x8d3360f09cf6e4bd,0x64712dd7abbbd95c,
1658
+ 0xb080392cc4349dec,0xbd8d794d96aacfb3,
1659
+ 0xdca04777f541c567,0xecf0d7a0fc5583a0,
1660
+ 0x89e42caaf9491b60,0xf41686c49db57244,
1661
+ 0xac5d37d5b79b6239,0x311c2875c522ced5,
1662
+ 0xd77485cb25823ac7,0x7d633293366b828b,
1663
+ 0x86a8d39ef77164bc,0xae5dff9c02033197,
1664
+ 0xa8530886b54dbdeb,0xd9f57f830283fdfc,
1665
+ 0xd267caa862a12d66,0xd072df63c324fd7b,
1666
+ 0x8380dea93da4bc60,0x4247cb9e59f71e6d,
1667
+ 0xa46116538d0deb78,0x52d9be85f074e608,
1668
+ 0xcd795be870516656,0x67902e276c921f8b,
1669
+ 0x806bd9714632dff6,0xba1cd8a3db53b6,
1670
+ 0xa086cfcd97bf97f3,0x80e8a40eccd228a4,
1671
+ 0xc8a883c0fdaf7df0,0x6122cd128006b2cd,
1672
+ 0xfad2a4b13d1b5d6c,0x796b805720085f81,
1673
+ 0x9cc3a6eec6311a63,0xcbe3303674053bb0,
1674
+ 0xc3f490aa77bd60fc,0xbedbfc4411068a9c,
1675
+ 0xf4f1b4d515acb93b,0xee92fb5515482d44,
1676
+ 0x991711052d8bf3c5,0x751bdd152d4d1c4a,
1677
+ 0xbf5cd54678eef0b6,0xd262d45a78a0635d,
1678
+ 0xef340a98172aace4,0x86fb897116c87c34,
1679
+ 0x9580869f0e7aac0e,0xd45d35e6ae3d4da0,
1680
+ 0xbae0a846d2195712,0x8974836059cca109,
1681
+ 0xe998d258869facd7,0x2bd1a438703fc94b,
1682
+ 0x91ff83775423cc06,0x7b6306a34627ddcf,
1683
+ 0xb67f6455292cbf08,0x1a3bc84c17b1d542,
1684
+ 0xe41f3d6a7377eeca,0x20caba5f1d9e4a93,
1685
+ 0x8e938662882af53e,0x547eb47b7282ee9c,
1686
+ 0xb23867fb2a35b28d,0xe99e619a4f23aa43,
1687
+ 0xdec681f9f4c31f31,0x6405fa00e2ec94d4,
1688
+ 0x8b3c113c38f9f37e,0xde83bc408dd3dd04,
1689
+ 0xae0b158b4738705e,0x9624ab50b148d445,
1690
+ 0xd98ddaee19068c76,0x3badd624dd9b0957,
1691
+ 0x87f8a8d4cfa417c9,0xe54ca5d70a80e5d6,
1692
+ 0xa9f6d30a038d1dbc,0x5e9fcf4ccd211f4c,
1693
+ 0xd47487cc8470652b,0x7647c3200069671f,
1694
+ 0x84c8d4dfd2c63f3b,0x29ecd9f40041e073,
1695
+ 0xa5fb0a17c777cf09,0xf468107100525890,
1696
+ 0xcf79cc9db955c2cc,0x7182148d4066eeb4,
1697
+ 0x81ac1fe293d599bf,0xc6f14cd848405530,
1698
+ 0xa21727db38cb002f,0xb8ada00e5a506a7c,
1699
+ 0xca9cf1d206fdc03b,0xa6d90811f0e4851c,
1700
+ 0xfd442e4688bd304a,0x908f4a166d1da663,
1701
+ 0x9e4a9cec15763e2e,0x9a598e4e043287fe,
1702
+ 0xc5dd44271ad3cdba,0x40eff1e1853f29fd,
1703
+ 0xf7549530e188c128,0xd12bee59e68ef47c,
1704
+ 0x9a94dd3e8cf578b9,0x82bb74f8301958ce,
1705
+ 0xc13a148e3032d6e7,0xe36a52363c1faf01,
1706
+ 0xf18899b1bc3f8ca1,0xdc44e6c3cb279ac1,
1707
+ 0x96f5600f15a7b7e5,0x29ab103a5ef8c0b9,
1708
+ 0xbcb2b812db11a5de,0x7415d448f6b6f0e7,
1709
+ 0xebdf661791d60f56,0x111b495b3464ad21,
1710
+ 0x936b9fcebb25c995,0xcab10dd900beec34,
1711
+ 0xb84687c269ef3bfb,0x3d5d514f40eea742,
1712
+ 0xe65829b3046b0afa,0xcb4a5a3112a5112,
1713
+ 0x8ff71a0fe2c2e6dc,0x47f0e785eaba72ab,
1714
+ 0xb3f4e093db73a093,0x59ed216765690f56,
1715
+ 0xe0f218b8d25088b8,0x306869c13ec3532c,
1716
+ 0x8c974f7383725573,0x1e414218c73a13fb,
1717
+ 0xafbd2350644eeacf,0xe5d1929ef90898fa,
1718
+ 0xdbac6c247d62a583,0xdf45f746b74abf39,
1719
+ 0x894bc396ce5da772,0x6b8bba8c328eb783,
1720
+ 0xab9eb47c81f5114f,0x66ea92f3f326564,
1721
+ 0xd686619ba27255a2,0xc80a537b0efefebd,
1722
+ 0x8613fd0145877585,0xbd06742ce95f5f36,
1723
+ 0xa798fc4196e952e7,0x2c48113823b73704,
1724
+ 0xd17f3b51fca3a7a0,0xf75a15862ca504c5,
1725
+ 0x82ef85133de648c4,0x9a984d73dbe722fb,
1726
+ 0xa3ab66580d5fdaf5,0xc13e60d0d2e0ebba,
1727
+ 0xcc963fee10b7d1b3,0x318df905079926a8,
1728
+ 0xffbbcfe994e5c61f,0xfdf17746497f7052,
1729
+ 0x9fd561f1fd0f9bd3,0xfeb6ea8bedefa633,
1730
+ 0xc7caba6e7c5382c8,0xfe64a52ee96b8fc0,
1731
+ 0xf9bd690a1b68637b,0x3dfdce7aa3c673b0,
1732
+ 0x9c1661a651213e2d,0x6bea10ca65c084e,
1733
+ 0xc31bfa0fe5698db8,0x486e494fcff30a62,
1734
+ 0xf3e2f893dec3f126,0x5a89dba3c3efccfa,
1735
+ 0x986ddb5c6b3a76b7,0xf89629465a75e01c,
1736
+ 0xbe89523386091465,0xf6bbb397f1135823,
1737
+ 0xee2ba6c0678b597f,0x746aa07ded582e2c,
1738
+ 0x94db483840b717ef,0xa8c2a44eb4571cdc,
1739
+ 0xba121a4650e4ddeb,0x92f34d62616ce413,
1740
+ 0xe896a0d7e51e1566,0x77b020baf9c81d17,
1741
+ 0x915e2486ef32cd60,0xace1474dc1d122e,
1742
+ 0xb5b5ada8aaff80b8,0xd819992132456ba,
1743
+ 0xe3231912d5bf60e6,0x10e1fff697ed6c69,
1744
+ 0x8df5efabc5979c8f,0xca8d3ffa1ef463c1,
1745
+ 0xb1736b96b6fd83b3,0xbd308ff8a6b17cb2,
1746
+ 0xddd0467c64bce4a0,0xac7cb3f6d05ddbde,
1747
+ 0x8aa22c0dbef60ee4,0x6bcdf07a423aa96b,
1748
+ 0xad4ab7112eb3929d,0x86c16c98d2c953c6,
1749
+ 0xd89d64d57a607744,0xe871c7bf077ba8b7,
1750
+ 0x87625f056c7c4a8b,0x11471cd764ad4972,
1751
+ 0xa93af6c6c79b5d2d,0xd598e40d3dd89bcf,
1752
+ 0xd389b47879823479,0x4aff1d108d4ec2c3,
1753
+ 0x843610cb4bf160cb,0xcedf722a585139ba,
1754
+ 0xa54394fe1eedb8fe,0xc2974eb4ee658828,
1755
+ 0xce947a3da6a9273e,0x733d226229feea32,
1756
+ 0x811ccc668829b887,0x806357d5a3f525f,
1757
+ 0xa163ff802a3426a8,0xca07c2dcb0cf26f7,
1758
+ 0xc9bcff6034c13052,0xfc89b393dd02f0b5,
1759
+ 0xfc2c3f3841f17c67,0xbbac2078d443ace2,
1760
+ 0x9d9ba7832936edc0,0xd54b944b84aa4c0d,
1761
+ 0xc5029163f384a931,0xa9e795e65d4df11,
1762
+ 0xf64335bcf065d37d,0x4d4617b5ff4a16d5,
1763
+ 0x99ea0196163fa42e,0x504bced1bf8e4e45,
1764
+ 0xc06481fb9bcf8d39,0xe45ec2862f71e1d6,
1765
+ 0xf07da27a82c37088,0x5d767327bb4e5a4c,
1766
+ 0x964e858c91ba2655,0x3a6a07f8d510f86f,
1767
+ 0xbbe226efb628afea,0x890489f70a55368b,
1768
+ 0xeadab0aba3b2dbe5,0x2b45ac74ccea842e,
1769
+ 0x92c8ae6b464fc96f,0x3b0b8bc90012929d,
1770
+ 0xb77ada0617e3bbcb,0x9ce6ebb40173744,
1771
+ 0xe55990879ddcaabd,0xcc420a6a101d0515,
1772
+ 0x8f57fa54c2a9eab6,0x9fa946824a12232d,
1773
+ 0xb32df8e9f3546564,0x47939822dc96abf9,
1774
+ 0xdff9772470297ebd,0x59787e2b93bc56f7,
1775
+ 0x8bfbea76c619ef36,0x57eb4edb3c55b65a,
1776
+ 0xaefae51477a06b03,0xede622920b6b23f1,
1777
+ 0xdab99e59958885c4,0xe95fab368e45eced,
1778
+ 0x88b402f7fd75539b,0x11dbcb0218ebb414,
1779
+ 0xaae103b5fcd2a881,0xd652bdc29f26a119,
1780
+ 0xd59944a37c0752a2,0x4be76d3346f0495f,
1781
+ 0x857fcae62d8493a5,0x6f70a4400c562ddb,
1782
+ 0xa6dfbd9fb8e5b88e,0xcb4ccd500f6bb952,
1783
+ 0xd097ad07a71f26b2,0x7e2000a41346a7a7,
1784
+ 0x825ecc24c873782f,0x8ed400668c0c28c8,
1785
+ 0xa2f67f2dfa90563b,0x728900802f0f32fa,
1786
+ 0xcbb41ef979346bca,0x4f2b40a03ad2ffb9,
1787
+ 0xfea126b7d78186bc,0xe2f610c84987bfa8,
1788
+ 0x9f24b832e6b0f436,0xdd9ca7d2df4d7c9,
1789
+ 0xc6ede63fa05d3143,0x91503d1c79720dbb,
1790
+ 0xf8a95fcf88747d94,0x75a44c6397ce912a,
1791
+ 0x9b69dbe1b548ce7c,0xc986afbe3ee11aba,
1792
+ 0xc24452da229b021b,0xfbe85badce996168,
1793
+ 0xf2d56790ab41c2a2,0xfae27299423fb9c3,
1794
+ 0x97c560ba6b0919a5,0xdccd879fc967d41a,
1795
+ 0xbdb6b8e905cb600f,0x5400e987bbc1c920,
1796
+ 0xed246723473e3813,0x290123e9aab23b68,
1797
+ 0x9436c0760c86e30b,0xf9a0b6720aaf6521,
1798
+ 0xb94470938fa89bce,0xf808e40e8d5b3e69,
1799
+ 0xe7958cb87392c2c2,0xb60b1d1230b20e04,
1800
+ 0x90bd77f3483bb9b9,0xb1c6f22b5e6f48c2,
1801
+ 0xb4ecd5f01a4aa828,0x1e38aeb6360b1af3,
1802
+ 0xe2280b6c20dd5232,0x25c6da63c38de1b0,
1803
+ 0x8d590723948a535f,0x579c487e5a38ad0e,
1804
+ 0xb0af48ec79ace837,0x2d835a9df0c6d851,
1805
+ 0xdcdb1b2798182244,0xf8e431456cf88e65,
1806
+ 0x8a08f0f8bf0f156b,0x1b8e9ecb641b58ff,
1807
+ 0xac8b2d36eed2dac5,0xe272467e3d222f3f,
1808
+ 0xd7adf884aa879177,0x5b0ed81dcc6abb0f,
1809
+ 0x86ccbb52ea94baea,0x98e947129fc2b4e9,
1810
+ 0xa87fea27a539e9a5,0x3f2398d747b36224,
1811
+ 0xd29fe4b18e88640e,0x8eec7f0d19a03aad,
1812
+ 0x83a3eeeef9153e89,0x1953cf68300424ac,
1813
+ 0xa48ceaaab75a8e2b,0x5fa8c3423c052dd7,
1814
+ 0xcdb02555653131b6,0x3792f412cb06794d,
1815
+ 0x808e17555f3ebf11,0xe2bbd88bbee40bd0,
1816
+ 0xa0b19d2ab70e6ed6,0x5b6aceaeae9d0ec4,
1817
+ 0xc8de047564d20a8b,0xf245825a5a445275,
1818
+ 0xfb158592be068d2e,0xeed6e2f0f0d56712,
1819
+ 0x9ced737bb6c4183d,0x55464dd69685606b,
1820
+ 0xc428d05aa4751e4c,0xaa97e14c3c26b886,
1821
+ 0xf53304714d9265df,0xd53dd99f4b3066a8,
1822
+ 0x993fe2c6d07b7fab,0xe546a8038efe4029,
1823
+ 0xbf8fdb78849a5f96,0xde98520472bdd033,
1824
+ 0xef73d256a5c0f77c,0x963e66858f6d4440,
1825
+ 0x95a8637627989aad,0xdde7001379a44aa8,
1826
+ 0xbb127c53b17ec159,0x5560c018580d5d52,
1827
+ 0xe9d71b689dde71af,0xaab8f01e6e10b4a6,
1828
+ 0x9226712162ab070d,0xcab3961304ca70e8,
1829
+ 0xb6b00d69bb55c8d1,0x3d607b97c5fd0d22,
1830
+ 0xe45c10c42a2b3b05,0x8cb89a7db77c506a,
1831
+ 0x8eb98a7a9a5b04e3,0x77f3608e92adb242,
1832
+ 0xb267ed1940f1c61c,0x55f038b237591ed3,
1833
+ 0xdf01e85f912e37a3,0x6b6c46dec52f6688,
1834
+ 0x8b61313bbabce2c6,0x2323ac4b3b3da015,
1835
+ 0xae397d8aa96c1b77,0xabec975e0a0d081a,
1836
+ 0xd9c7dced53c72255,0x96e7bd358c904a21,
1837
+ 0x881cea14545c7575,0x7e50d64177da2e54,
1838
+ 0xaa242499697392d2,0xdde50bd1d5d0b9e9,
1839
+ 0xd4ad2dbfc3d07787,0x955e4ec64b44e864,
1840
+ 0x84ec3c97da624ab4,0xbd5af13bef0b113e,
1841
+ 0xa6274bbdd0fadd61,0xecb1ad8aeacdd58e,
1842
+ 0xcfb11ead453994ba,0x67de18eda5814af2,
1843
+ 0x81ceb32c4b43fcf4,0x80eacf948770ced7,
1844
+ 0xa2425ff75e14fc31,0xa1258379a94d028d,
1845
+ 0xcad2f7f5359a3b3e,0x96ee45813a04330,
1846
+ 0xfd87b5f28300ca0d,0x8bca9d6e188853fc,
1847
+ 0x9e74d1b791e07e48,0x775ea264cf55347e,
1848
+ 0xc612062576589dda,0x95364afe032a819e,
1849
+ 0xf79687aed3eec551,0x3a83ddbd83f52205,
1850
+ 0x9abe14cd44753b52,0xc4926a9672793543,
1851
+ 0xc16d9a0095928a27,0x75b7053c0f178294,
1852
+ 0xf1c90080baf72cb1,0x5324c68b12dd6339,
1853
+ 0x971da05074da7bee,0xd3f6fc16ebca5e04,
1854
+ 0xbce5086492111aea,0x88f4bb1ca6bcf585,
1855
+ 0xec1e4a7db69561a5,0x2b31e9e3d06c32e6,
1856
+ 0x9392ee8e921d5d07,0x3aff322e62439fd0,
1857
+ 0xb877aa3236a4b449,0x9befeb9fad487c3,
1858
+ 0xe69594bec44de15b,0x4c2ebe687989a9b4,
1859
+ 0x901d7cf73ab0acd9,0xf9d37014bf60a11,
1860
+ 0xb424dc35095cd80f,0x538484c19ef38c95,
1861
+ 0xe12e13424bb40e13,0x2865a5f206b06fba,
1862
+ 0x8cbccc096f5088cb,0xf93f87b7442e45d4,
1863
+ 0xafebff0bcb24aafe,0xf78f69a51539d749,
1864
+ 0xdbe6fecebdedd5be,0xb573440e5a884d1c,
1865
+ 0x89705f4136b4a597,0x31680a88f8953031,
1866
+ 0xabcc77118461cefc,0xfdc20d2b36ba7c3e,
1867
+ 0xd6bf94d5e57a42bc,0x3d32907604691b4d,
1868
+ 0x8637bd05af6c69b5,0xa63f9a49c2c1b110,
1869
+ 0xa7c5ac471b478423,0xfcf80dc33721d54,
1870
+ 0xd1b71758e219652b,0xd3c36113404ea4a9,
1871
+ 0x83126e978d4fdf3b,0x645a1cac083126ea,
1872
+ 0xa3d70a3d70a3d70a,0x3d70a3d70a3d70a4,
1873
+ 0xcccccccccccccccc,0xcccccccccccccccd,
1874
+ 0x8000000000000000,0x0,
1875
+ 0xa000000000000000,0x0,
1876
+ 0xc800000000000000,0x0,
1877
+ 0xfa00000000000000,0x0,
1878
+ 0x9c40000000000000,0x0,
1879
+ 0xc350000000000000,0x0,
1880
+ 0xf424000000000000,0x0,
1881
+ 0x9896800000000000,0x0,
1882
+ 0xbebc200000000000,0x0,
1883
+ 0xee6b280000000000,0x0,
1884
+ 0x9502f90000000000,0x0,
1885
+ 0xba43b74000000000,0x0,
1886
+ 0xe8d4a51000000000,0x0,
1887
+ 0x9184e72a00000000,0x0,
1888
+ 0xb5e620f480000000,0x0,
1889
+ 0xe35fa931a0000000,0x0,
1890
+ 0x8e1bc9bf04000000,0x0,
1891
+ 0xb1a2bc2ec5000000,0x0,
1892
+ 0xde0b6b3a76400000,0x0,
1893
+ 0x8ac7230489e80000,0x0,
1894
+ 0xad78ebc5ac620000,0x0,
1895
+ 0xd8d726b7177a8000,0x0,
1896
+ 0x878678326eac9000,0x0,
1897
+ 0xa968163f0a57b400,0x0,
1898
+ 0xd3c21bcecceda100,0x0,
1899
+ 0x84595161401484a0,0x0,
1900
+ 0xa56fa5b99019a5c8,0x0,
1901
+ 0xcecb8f27f4200f3a,0x0,
1902
+ 0x813f3978f8940984,0x4000000000000000,
1903
+ 0xa18f07d736b90be5,0x5000000000000000,
1904
+ 0xc9f2c9cd04674ede,0xa400000000000000,
1905
+ 0xfc6f7c4045812296,0x4d00000000000000,
1906
+ 0x9dc5ada82b70b59d,0xf020000000000000,
1907
+ 0xc5371912364ce305,0x6c28000000000000,
1908
+ 0xf684df56c3e01bc6,0xc732000000000000,
1909
+ 0x9a130b963a6c115c,0x3c7f400000000000,
1910
+ 0xc097ce7bc90715b3,0x4b9f100000000000,
1911
+ 0xf0bdc21abb48db20,0x1e86d40000000000,
1912
+ 0x96769950b50d88f4,0x1314448000000000,
1913
+ 0xbc143fa4e250eb31,0x17d955a000000000,
1914
+ 0xeb194f8e1ae525fd,0x5dcfab0800000000,
1915
+ 0x92efd1b8d0cf37be,0x5aa1cae500000000,
1916
+ 0xb7abc627050305ad,0xf14a3d9e40000000,
1917
+ 0xe596b7b0c643c719,0x6d9ccd05d0000000,
1918
+ 0x8f7e32ce7bea5c6f,0xe4820023a2000000,
1919
+ 0xb35dbf821ae4f38b,0xdda2802c8a800000,
1920
+ 0xe0352f62a19e306e,0xd50b2037ad200000,
1921
+ 0x8c213d9da502de45,0x4526f422cc340000,
1922
+ 0xaf298d050e4395d6,0x9670b12b7f410000,
1923
+ 0xdaf3f04651d47b4c,0x3c0cdd765f114000,
1924
+ 0x88d8762bf324cd0f,0xa5880a69fb6ac800,
1925
+ 0xab0e93b6efee0053,0x8eea0d047a457a00,
1926
+ 0xd5d238a4abe98068,0x72a4904598d6d880,
1927
+ 0x85a36366eb71f041,0x47a6da2b7f864750,
1928
+ 0xa70c3c40a64e6c51,0x999090b65f67d924,
1929
+ 0xd0cf4b50cfe20765,0xfff4b4e3f741cf6d,
1930
+ 0x82818f1281ed449f,0xbff8f10e7a8921a4,
1931
+ 0xa321f2d7226895c7,0xaff72d52192b6a0d,
1932
+ 0xcbea6f8ceb02bb39,0x9bf4f8a69f764490,
1933
+ 0xfee50b7025c36a08,0x2f236d04753d5b4,
1934
+ 0x9f4f2726179a2245,0x1d762422c946590,
1935
+ 0xc722f0ef9d80aad6,0x424d3ad2b7b97ef5,
1936
+ 0xf8ebad2b84e0d58b,0xd2e0898765a7deb2,
1937
+ 0x9b934c3b330c8577,0x63cc55f49f88eb2f,
1938
+ 0xc2781f49ffcfa6d5,0x3cbf6b71c76b25fb,
1939
+ 0xf316271c7fc3908a,0x8bef464e3945ef7a,
1940
+ 0x97edd871cfda3a56,0x97758bf0e3cbb5ac,
1941
+ 0xbde94e8e43d0c8ec,0x3d52eeed1cbea317,
1942
+ 0xed63a231d4c4fb27,0x4ca7aaa863ee4bdd,
1943
+ 0x945e455f24fb1cf8,0x8fe8caa93e74ef6a,
1944
+ 0xb975d6b6ee39e436,0xb3e2fd538e122b44,
1945
+ 0xe7d34c64a9c85d44,0x60dbbca87196b616,
1946
+ 0x90e40fbeea1d3a4a,0xbc8955e946fe31cd,
1947
+ 0xb51d13aea4a488dd,0x6babab6398bdbe41,
1948
+ 0xe264589a4dcdab14,0xc696963c7eed2dd1,
1949
+ 0x8d7eb76070a08aec,0xfc1e1de5cf543ca2,
1950
+ 0xb0de65388cc8ada8,0x3b25a55f43294bcb,
1951
+ 0xdd15fe86affad912,0x49ef0eb713f39ebe,
1952
+ 0x8a2dbf142dfcc7ab,0x6e3569326c784337,
1953
+ 0xacb92ed9397bf996,0x49c2c37f07965404,
1954
+ 0xd7e77a8f87daf7fb,0xdc33745ec97be906,
1955
+ 0x86f0ac99b4e8dafd,0x69a028bb3ded71a3,
1956
+ 0xa8acd7c0222311bc,0xc40832ea0d68ce0c,
1957
+ 0xd2d80db02aabd62b,0xf50a3fa490c30190,
1958
+ 0x83c7088e1aab65db,0x792667c6da79e0fa,
1959
+ 0xa4b8cab1a1563f52,0x577001b891185938,
1960
+ 0xcde6fd5e09abcf26,0xed4c0226b55e6f86,
1961
+ 0x80b05e5ac60b6178,0x544f8158315b05b4,
1962
+ 0xa0dc75f1778e39d6,0x696361ae3db1c721,
1963
+ 0xc913936dd571c84c,0x3bc3a19cd1e38e9,
1964
+ 0xfb5878494ace3a5f,0x4ab48a04065c723,
1965
+ 0x9d174b2dcec0e47b,0x62eb0d64283f9c76,
1966
+ 0xc45d1df942711d9a,0x3ba5d0bd324f8394,
1967
+ 0xf5746577930d6500,0xca8f44ec7ee36479,
1968
+ 0x9968bf6abbe85f20,0x7e998b13cf4e1ecb,
1969
+ 0xbfc2ef456ae276e8,0x9e3fedd8c321a67e,
1970
+ 0xefb3ab16c59b14a2,0xc5cfe94ef3ea101e,
1971
+ 0x95d04aee3b80ece5,0xbba1f1d158724a12,
1972
+ 0xbb445da9ca61281f,0x2a8a6e45ae8edc97,
1973
+ 0xea1575143cf97226,0xf52d09d71a3293bd,
1974
+ 0x924d692ca61be758,0x593c2626705f9c56,
1975
+ 0xb6e0c377cfa2e12e,0x6f8b2fb00c77836c,
1976
+ 0xe498f455c38b997a,0xb6dfb9c0f956447,
1977
+ 0x8edf98b59a373fec,0x4724bd4189bd5eac,
1978
+ 0xb2977ee300c50fe7,0x58edec91ec2cb657,
1979
+ 0xdf3d5e9bc0f653e1,0x2f2967b66737e3ed,
1980
+ 0x8b865b215899f46c,0xbd79e0d20082ee74,
1981
+ 0xae67f1e9aec07187,0xecd8590680a3aa11,
1982
+ 0xda01ee641a708de9,0xe80e6f4820cc9495,
1983
+ 0x884134fe908658b2,0x3109058d147fdcdd,
1984
+ 0xaa51823e34a7eede,0xbd4b46f0599fd415,
1985
+ 0xd4e5e2cdc1d1ea96,0x6c9e18ac7007c91a,
1986
+ 0x850fadc09923329e,0x3e2cf6bc604ddb0,
1987
+ 0xa6539930bf6bff45,0x84db8346b786151c,
1988
+ 0xcfe87f7cef46ff16,0xe612641865679a63,
1989
+ 0x81f14fae158c5f6e,0x4fcb7e8f3f60c07e,
1990
+ 0xa26da3999aef7749,0xe3be5e330f38f09d,
1991
+ 0xcb090c8001ab551c,0x5cadf5bfd3072cc5,
1992
+ 0xfdcb4fa002162a63,0x73d9732fc7c8f7f6,
1993
+ 0x9e9f11c4014dda7e,0x2867e7fddcdd9afa,
1994
+ 0xc646d63501a1511d,0xb281e1fd541501b8,
1995
+ 0xf7d88bc24209a565,0x1f225a7ca91a4226,
1996
+ 0x9ae757596946075f,0x3375788de9b06958,
1997
+ 0xc1a12d2fc3978937,0x52d6b1641c83ae,
1998
+ 0xf209787bb47d6b84,0xc0678c5dbd23a49a,
1999
+ 0x9745eb4d50ce6332,0xf840b7ba963646e0,
2000
+ 0xbd176620a501fbff,0xb650e5a93bc3d898,
2001
+ 0xec5d3fa8ce427aff,0xa3e51f138ab4cebe,
2002
+ 0x93ba47c980e98cdf,0xc66f336c36b10137,
2003
+ 0xb8a8d9bbe123f017,0xb80b0047445d4184,
2004
+ 0xe6d3102ad96cec1d,0xa60dc059157491e5,
2005
+ 0x9043ea1ac7e41392,0x87c89837ad68db2f,
2006
+ 0xb454e4a179dd1877,0x29babe4598c311fb,
2007
+ 0xe16a1dc9d8545e94,0xf4296dd6fef3d67a,
2008
+ 0x8ce2529e2734bb1d,0x1899e4a65f58660c,
2009
+ 0xb01ae745b101e9e4,0x5ec05dcff72e7f8f,
2010
+ 0xdc21a1171d42645d,0x76707543f4fa1f73,
2011
+ 0x899504ae72497eba,0x6a06494a791c53a8,
2012
+ 0xabfa45da0edbde69,0x487db9d17636892,
2013
+ 0xd6f8d7509292d603,0x45a9d2845d3c42b6,
2014
+ 0x865b86925b9bc5c2,0xb8a2392ba45a9b2,
2015
+ 0xa7f26836f282b732,0x8e6cac7768d7141e,
2016
+ 0xd1ef0244af2364ff,0x3207d795430cd926,
2017
+ 0x8335616aed761f1f,0x7f44e6bd49e807b8,
2018
+ 0xa402b9c5a8d3a6e7,0x5f16206c9c6209a6,
2019
+ 0xcd036837130890a1,0x36dba887c37a8c0f,
2020
+ 0x802221226be55a64,0xc2494954da2c9789,
2021
+ 0xa02aa96b06deb0fd,0xf2db9baa10b7bd6c,
2022
+ 0xc83553c5c8965d3d,0x6f92829494e5acc7,
2023
+ 0xfa42a8b73abbf48c,0xcb772339ba1f17f9,
2024
+ 0x9c69a97284b578d7,0xff2a760414536efb,
2025
+ 0xc38413cf25e2d70d,0xfef5138519684aba,
2026
+ 0xf46518c2ef5b8cd1,0x7eb258665fc25d69,
2027
+ 0x98bf2f79d5993802,0xef2f773ffbd97a61,
2028
+ 0xbeeefb584aff8603,0xaafb550ffacfd8fa,
2029
+ 0xeeaaba2e5dbf6784,0x95ba2a53f983cf38,
2030
+ 0x952ab45cfa97a0b2,0xdd945a747bf26183,
2031
+ 0xba756174393d88df,0x94f971119aeef9e4,
2032
+ 0xe912b9d1478ceb17,0x7a37cd5601aab85d,
2033
+ 0x91abb422ccb812ee,0xac62e055c10ab33a,
2034
+ 0xb616a12b7fe617aa,0x577b986b314d6009,
2035
+ 0xe39c49765fdf9d94,0xed5a7e85fda0b80b,
2036
+ 0x8e41ade9fbebc27d,0x14588f13be847307,
2037
+ 0xb1d219647ae6b31c,0x596eb2d8ae258fc8,
2038
+ 0xde469fbd99a05fe3,0x6fca5f8ed9aef3bb,
2039
+ 0x8aec23d680043bee,0x25de7bb9480d5854,
2040
+ 0xada72ccc20054ae9,0xaf561aa79a10ae6a,
2041
+ 0xd910f7ff28069da4,0x1b2ba1518094da04,
2042
+ 0x87aa9aff79042286,0x90fb44d2f05d0842,
2043
+ 0xa99541bf57452b28,0x353a1607ac744a53,
2044
+ 0xd3fa922f2d1675f2,0x42889b8997915ce8,
2045
+ 0x847c9b5d7c2e09b7,0x69956135febada11,
2046
+ 0xa59bc234db398c25,0x43fab9837e699095,
2047
+ 0xcf02b2c21207ef2e,0x94f967e45e03f4bb,
2048
+ 0x8161afb94b44f57d,0x1d1be0eebac278f5,
2049
+ 0xa1ba1ba79e1632dc,0x6462d92a69731732,
2050
+ 0xca28a291859bbf93,0x7d7b8f7503cfdcfe,
2051
+ 0xfcb2cb35e702af78,0x5cda735244c3d43e,
2052
+ 0x9defbf01b061adab,0x3a0888136afa64a7,
2053
+ 0xc56baec21c7a1916,0x88aaa1845b8fdd0,
2054
+ 0xf6c69a72a3989f5b,0x8aad549e57273d45,
2055
+ 0x9a3c2087a63f6399,0x36ac54e2f678864b,
2056
+ 0xc0cb28a98fcf3c7f,0x84576a1bb416a7dd,
2057
+ 0xf0fdf2d3f3c30b9f,0x656d44a2a11c51d5,
2058
+ 0x969eb7c47859e743,0x9f644ae5a4b1b325,
2059
+ 0xbc4665b596706114,0x873d5d9f0dde1fee,
2060
+ 0xeb57ff22fc0c7959,0xa90cb506d155a7ea,
2061
+ 0x9316ff75dd87cbd8,0x9a7f12442d588f2,
2062
+ 0xb7dcbf5354e9bece,0xc11ed6d538aeb2f,
2063
+ 0xe5d3ef282a242e81,0x8f1668c8a86da5fa,
2064
+ 0x8fa475791a569d10,0xf96e017d694487bc,
2065
+ 0xb38d92d760ec4455,0x37c981dcc395a9ac,
2066
+ 0xe070f78d3927556a,0x85bbe253f47b1417,
2067
+ 0x8c469ab843b89562,0x93956d7478ccec8e,
2068
+ 0xaf58416654a6babb,0x387ac8d1970027b2,
2069
+ 0xdb2e51bfe9d0696a,0x6997b05fcc0319e,
2070
+ 0x88fcf317f22241e2,0x441fece3bdf81f03,
2071
+ 0xab3c2fddeeaad25a,0xd527e81cad7626c3,
2072
+ 0xd60b3bd56a5586f1,0x8a71e223d8d3b074,
2073
+ 0x85c7056562757456,0xf6872d5667844e49,
2074
+ 0xa738c6bebb12d16c,0xb428f8ac016561db,
2075
+ 0xd106f86e69d785c7,0xe13336d701beba52,
2076
+ 0x82a45b450226b39c,0xecc0024661173473,
2077
+ 0xa34d721642b06084,0x27f002d7f95d0190,
2078
+ 0xcc20ce9bd35c78a5,0x31ec038df7b441f4,
2079
+ 0xff290242c83396ce,0x7e67047175a15271,
2080
+ 0x9f79a169bd203e41,0xf0062c6e984d386,
2081
+ 0xc75809c42c684dd1,0x52c07b78a3e60868,
2082
+ 0xf92e0c3537826145,0xa7709a56ccdf8a82,
2083
+ 0x9bbcc7a142b17ccb,0x88a66076400bb691,
2084
+ 0xc2abf989935ddbfe,0x6acff893d00ea435,
2085
+ 0xf356f7ebf83552fe,0x583f6b8c4124d43,
2086
+ 0x98165af37b2153de,0xc3727a337a8b704a,
2087
+ 0xbe1bf1b059e9a8d6,0x744f18c0592e4c5c,
2088
+ 0xeda2ee1c7064130c,0x1162def06f79df73,
2089
+ 0x9485d4d1c63e8be7,0x8addcb5645ac2ba8,
2090
+ 0xb9a74a0637ce2ee1,0x6d953e2bd7173692,
2091
+ 0xe8111c87c5c1ba99,0xc8fa8db6ccdd0437,
2092
+ 0x910ab1d4db9914a0,0x1d9c9892400a22a2,
2093
+ 0xb54d5e4a127f59c8,0x2503beb6d00cab4b,
2094
+ 0xe2a0b5dc971f303a,0x2e44ae64840fd61d,
2095
+ 0x8da471a9de737e24,0x5ceaecfed289e5d2,
2096
+ 0xb10d8e1456105dad,0x7425a83e872c5f47,
2097
+ 0xdd50f1996b947518,0xd12f124e28f77719,
2098
+ 0x8a5296ffe33cc92f,0x82bd6b70d99aaa6f,
2099
+ 0xace73cbfdc0bfb7b,0x636cc64d1001550b,
2100
+ 0xd8210befd30efa5a,0x3c47f7e05401aa4e,
2101
+ 0x8714a775e3e95c78,0x65acfaec34810a71,
2102
+ 0xa8d9d1535ce3b396,0x7f1839a741a14d0d,
2103
+ 0xd31045a8341ca07c,0x1ede48111209a050,
2104
+ 0x83ea2b892091e44d,0x934aed0aab460432,
2105
+ 0xa4e4b66b68b65d60,0xf81da84d5617853f,
2106
+ 0xce1de40642e3f4b9,0x36251260ab9d668e,
2107
+ 0x80d2ae83e9ce78f3,0xc1d72b7c6b426019,
2108
+ 0xa1075a24e4421730,0xb24cf65b8612f81f,
2109
+ 0xc94930ae1d529cfc,0xdee033f26797b627,
2110
+ 0xfb9b7cd9a4a7443c,0x169840ef017da3b1,
2111
+ 0x9d412e0806e88aa5,0x8e1f289560ee864e,
2112
+ 0xc491798a08a2ad4e,0xf1a6f2bab92a27e2,
2113
+ 0xf5b5d7ec8acb58a2,0xae10af696774b1db,
2114
+ 0x9991a6f3d6bf1765,0xacca6da1e0a8ef29,
2115
+ 0xbff610b0cc6edd3f,0x17fd090a58d32af3,
2116
+ 0xeff394dcff8a948e,0xddfc4b4cef07f5b0,
2117
+ 0x95f83d0a1fb69cd9,0x4abdaf101564f98e,
2118
+ 0xbb764c4ca7a4440f,0x9d6d1ad41abe37f1,
2119
+ 0xea53df5fd18d5513,0x84c86189216dc5ed,
2120
+ 0x92746b9be2f8552c,0x32fd3cf5b4e49bb4,
2121
+ 0xb7118682dbb66a77,0x3fbc8c33221dc2a1,
2122
+ 0xe4d5e82392a40515,0xfabaf3feaa5334a,
2123
+ 0x8f05b1163ba6832d,0x29cb4d87f2a7400e,
2124
+ 0xb2c71d5bca9023f8,0x743e20e9ef511012,
2125
+ 0xdf78e4b2bd342cf6,0x914da9246b255416,
2126
+ 0x8bab8eefb6409c1a,0x1ad089b6c2f7548e,
2127
+ 0xae9672aba3d0c320,0xa184ac2473b529b1,
2128
+ 0xda3c0f568cc4f3e8,0xc9e5d72d90a2741e,
2129
+ 0x8865899617fb1871,0x7e2fa67c7a658892,
2130
+ 0xaa7eebfb9df9de8d,0xddbb901b98feeab7,
2131
+ 0xd51ea6fa85785631,0x552a74227f3ea565,
2132
+ 0x8533285c936b35de,0xd53a88958f87275f,
2133
+ 0xa67ff273b8460356,0x8a892abaf368f137,
2134
+ 0xd01fef10a657842c,0x2d2b7569b0432d85,
2135
+ 0x8213f56a67f6b29b,0x9c3b29620e29fc73,
2136
+ 0xa298f2c501f45f42,0x8349f3ba91b47b8f,
2137
+ 0xcb3f2f7642717713,0x241c70a936219a73,
2138
+ 0xfe0efb53d30dd4d7,0xed238cd383aa0110,
2139
+ 0x9ec95d1463e8a506,0xf4363804324a40aa,
2140
+ 0xc67bb4597ce2ce48,0xb143c6053edcd0d5,
2141
+ 0xf81aa16fdc1b81da,0xdd94b7868e94050a,
2142
+ 0x9b10a4e5e9913128,0xca7cf2b4191c8326,
2143
+ 0xc1d4ce1f63f57d72,0xfd1c2f611f63a3f0,
2144
+ 0xf24a01a73cf2dccf,0xbc633b39673c8cec,
2145
+ 0x976e41088617ca01,0xd5be0503e085d813,
2146
+ 0xbd49d14aa79dbc82,0x4b2d8644d8a74e18,
2147
+ 0xec9c459d51852ba2,0xddf8e7d60ed1219e,
2148
+ 0x93e1ab8252f33b45,0xcabb90e5c942b503,
2149
+ 0xb8da1662e7b00a17,0x3d6a751f3b936243,
2150
+ 0xe7109bfba19c0c9d,0xcc512670a783ad4,
2151
+ 0x906a617d450187e2,0x27fb2b80668b24c5,
2152
+ 0xb484f9dc9641e9da,0xb1f9f660802dedf6,
2153
+ 0xe1a63853bbd26451,0x5e7873f8a0396973,
2154
+ 0x8d07e33455637eb2,0xdb0b487b6423e1e8,
2155
+ 0xb049dc016abc5e5f,0x91ce1a9a3d2cda62,
2156
+ 0xdc5c5301c56b75f7,0x7641a140cc7810fb,
2157
+ 0x89b9b3e11b6329ba,0xa9e904c87fcb0a9d,
2158
+ 0xac2820d9623bf429,0x546345fa9fbdcd44,
2159
+ 0xd732290fbacaf133,0xa97c177947ad4095,
2160
+ 0x867f59a9d4bed6c0,0x49ed8eabcccc485d,
2161
+ 0xa81f301449ee8c70,0x5c68f256bfff5a74,
2162
+ 0xd226fc195c6a2f8c,0x73832eec6fff3111,
2163
+ 0x83585d8fd9c25db7,0xc831fd53c5ff7eab,
2164
+ 0xa42e74f3d032f525,0xba3e7ca8b77f5e55,
2165
+ 0xcd3a1230c43fb26f,0x28ce1bd2e55f35eb,
2166
+ 0x80444b5e7aa7cf85,0x7980d163cf5b81b3,
2167
+ 0xa0555e361951c366,0xd7e105bcc332621f,
2168
+ 0xc86ab5c39fa63440,0x8dd9472bf3fefaa7,
2169
+ 0xfa856334878fc150,0xb14f98f6f0feb951,
2170
+ 0x9c935e00d4b9d8d2,0x6ed1bf9a569f33d3,
2171
+ 0xc3b8358109e84f07,0xa862f80ec4700c8,
2172
+ 0xf4a642e14c6262c8,0xcd27bb612758c0fa,
2173
+ 0x98e7e9cccfbd7dbd,0x8038d51cb897789c,
2174
+ 0xbf21e44003acdd2c,0xe0470a63e6bd56c3,
2175
+ 0xeeea5d5004981478,0x1858ccfce06cac74,
2176
+ 0x95527a5202df0ccb,0xf37801e0c43ebc8,
2177
+ 0xbaa718e68396cffd,0xd30560258f54e6ba,
2178
+ 0xe950df20247c83fd,0x47c6b82ef32a2069,
2179
+ 0x91d28b7416cdd27e,0x4cdc331d57fa5441,
2180
+ 0xb6472e511c81471d,0xe0133fe4adf8e952,
2181
+ 0xe3d8f9e563a198e5,0x58180fddd97723a6,
2182
+ 0x8e679c2f5e44ff8f,0x570f09eaa7ea7648,};
2183
+ };
2184
+
2185
+ template <class unused>
2186
+ constexpr uint64_t powers_template<unused>::power_of_five_128[number_of_entries];
2187
+
2188
+ using powers = powers_template<>;
2189
+
2190
+ } // namespace fast_float
2191
+
2192
+ #endif
2193
+
2194
+ #ifndef FASTFLOAT_DECIMAL_TO_BINARY_H
2195
+ #define FASTFLOAT_DECIMAL_TO_BINARY_H
2196
+
2197
+ #include <cfloat>
2198
+ #include <cinttypes>
2199
+ #include <cmath>
2200
+ #include <cstdint>
2201
+ #include <cstdlib>
2202
+ #include <cstring>
2203
+
2204
+ namespace fast_float {
2205
+
2206
+ // This will compute or rather approximate w * 5**q and return a pair of 64-bit words approximating
2207
+ // the result, with the "high" part corresponding to the most significant bits and the
2208
+ // low part corresponding to the least significant bits.
2209
+ //
2210
+ template <int bit_precision>
2211
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2212
+ value128 compute_product_approximation(int64_t q, uint64_t w) {
2213
+ const int index = 2 * int(q - powers::smallest_power_of_five);
2214
+ // For small values of q, e.g., q in [0,27], the answer is always exact because
2215
+ // The line value128 firstproduct = full_multiplication(w, power_of_five_128[index]);
2216
+ // gives the exact answer.
2217
+ value128 firstproduct = full_multiplication(w, powers::power_of_five_128[index]);
2218
+ static_assert((bit_precision >= 0) && (bit_precision <= 64), " precision should be in (0,64]");
2219
+ constexpr uint64_t precision_mask = (bit_precision < 64) ?
2220
+ (uint64_t(0xFFFFFFFFFFFFFFFF) >> bit_precision)
2221
+ : uint64_t(0xFFFFFFFFFFFFFFFF);
2222
+ if((firstproduct.high & precision_mask) == precision_mask) { // could further guard with (lower + w < lower)
2223
+ // regarding the second product, we only need secondproduct.high, but our expectation is that the compiler will optimize this extra work away if needed.
2224
+ value128 secondproduct = full_multiplication(w, powers::power_of_five_128[index + 1]);
2225
+ firstproduct.low += secondproduct.high;
2226
+ if(secondproduct.high > firstproduct.low) {
2227
+ firstproduct.high++;
2228
+ }
2229
+ }
2230
+ return firstproduct;
2231
+ }
2232
+
2233
+ namespace detail {
2234
+ /**
2235
+ * For q in (0,350), we have that
2236
+ * f = (((152170 + 65536) * q ) >> 16);
2237
+ * is equal to
2238
+ * floor(p) + q
2239
+ * where
2240
+ * p = log(5**q)/log(2) = q * log(5)/log(2)
2241
+ *
2242
+ * For negative values of q in (-400,0), we have that
2243
+ * f = (((152170 + 65536) * q ) >> 16);
2244
+ * is equal to
2245
+ * -ceil(p) + q
2246
+ * where
2247
+ * p = log(5**-q)/log(2) = -q * log(5)/log(2)
2248
+ */
2249
+ constexpr fastfloat_really_inline int32_t power(int32_t q) noexcept {
2250
+ return (((152170 + 65536) * q) >> 16) + 63;
2251
+ }
2252
+ } // namespace detail
2253
+
2254
+ // create an adjusted mantissa, biased by the invalid power2
2255
+ // for significant digits already multiplied by 10 ** q.
2256
+ template <typename binary>
2257
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
2258
+ adjusted_mantissa compute_error_scaled(int64_t q, uint64_t w, int lz) noexcept {
2259
+ int hilz = int(w >> 63) ^ 1;
2260
+ adjusted_mantissa answer;
2261
+ answer.mantissa = w << hilz;
2262
+ int bias = binary::mantissa_explicit_bits() - binary::minimum_exponent();
2263
+ answer.power2 = int32_t(detail::power(int32_t(q)) + bias - hilz - lz - 62 + invalid_am_bias);
2264
+ return answer;
2265
+ }
2266
+
2267
+ // w * 10 ** q, without rounding the representation up.
2268
+ // the power2 in the exponent will be adjusted by invalid_am_bias.
2269
+ template <typename binary>
2270
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2271
+ adjusted_mantissa compute_error(int64_t q, uint64_t w) noexcept {
2272
+ int lz = leading_zeroes(w);
2273
+ w <<= lz;
2274
+ value128 product = compute_product_approximation<binary::mantissa_explicit_bits() + 3>(q, w);
2275
+ return compute_error_scaled<binary>(q, product.high, lz);
2276
+ }
2277
+
2278
+ // w * 10 ** q
2279
+ // The returned value should be a valid ieee64 number that simply need to be packed.
2280
+ // However, in some very rare cases, the computation will fail. In such cases, we
2281
+ // return an adjusted_mantissa with a negative power of 2: the caller should recompute
2282
+ // in such cases.
2283
+ template <typename binary>
2284
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2285
+ adjusted_mantissa compute_float(int64_t q, uint64_t w) noexcept {
2286
+ adjusted_mantissa answer;
2287
+ if ((w == 0) || (q < binary::smallest_power_of_ten())) {
2288
+ answer.power2 = 0;
2289
+ answer.mantissa = 0;
2290
+ // result should be zero
2291
+ return answer;
2292
+ }
2293
+ if (q > binary::largest_power_of_ten()) {
2294
+ // we want to get infinity:
2295
+ answer.power2 = binary::infinite_power();
2296
+ answer.mantissa = 0;
2297
+ return answer;
2298
+ }
2299
+ // At this point in time q is in [powers::smallest_power_of_five, powers::largest_power_of_five].
2300
+
2301
+ // We want the most significant bit of i to be 1. Shift if needed.
2302
+ int lz = leading_zeroes(w);
2303
+ w <<= lz;
2304
+
2305
+ // The required precision is binary::mantissa_explicit_bits() + 3 because
2306
+ // 1. We need the implicit bit
2307
+ // 2. We need an extra bit for rounding purposes
2308
+ // 3. We might lose a bit due to the "upperbit" routine (result too small, requiring a shift)
2309
+
2310
+ value128 product = compute_product_approximation<binary::mantissa_explicit_bits() + 3>(q, w);
2311
+ // The computed 'product' is always sufficient.
2312
+ // Mathematical proof:
2313
+ // Noble Mushtak and Daniel Lemire, Fast Number Parsing Without Fallback (to appear)
2314
+ // See script/mushtak_lemire.py
2315
+
2316
+ // The "compute_product_approximation" function can be slightly slower than a branchless approach:
2317
+ // value128 product = compute_product(q, w);
2318
+ // but in practice, we can win big with the compute_product_approximation if its additional branch
2319
+ // is easily predicted. Which is best is data specific.
2320
+ int upperbit = int(product.high >> 63);
2321
+
2322
+ answer.mantissa = product.high >> (upperbit + 64 - binary::mantissa_explicit_bits() - 3);
2323
+
2324
+ answer.power2 = int32_t(detail::power(int32_t(q)) + upperbit - lz - binary::minimum_exponent());
2325
+ if (answer.power2 <= 0) { // we have a subnormal?
2326
+ // Here have that answer.power2 <= 0 so -answer.power2 >= 0
2327
+ if(-answer.power2 + 1 >= 64) { // if we have more than 64 bits below the minimum exponent, you have a zero for sure.
2328
+ answer.power2 = 0;
2329
+ answer.mantissa = 0;
2330
+ // result should be zero
2331
+ return answer;
2332
+ }
2333
+ // next line is safe because -answer.power2 + 1 < 64
2334
+ answer.mantissa >>= -answer.power2 + 1;
2335
+ // Thankfully, we can't have both "round-to-even" and subnormals because
2336
+ // "round-to-even" only occurs for powers close to 0.
2337
+ answer.mantissa += (answer.mantissa & 1); // round up
2338
+ answer.mantissa >>= 1;
2339
+ // There is a weird scenario where we don't have a subnormal but just.
2340
+ // Suppose we start with 2.2250738585072013e-308, we end up
2341
+ // with 0x3fffffffffffff x 2^-1023-53 which is technically subnormal
2342
+ // whereas 0x40000000000000 x 2^-1023-53 is normal. Now, we need to round
2343
+ // up 0x3fffffffffffff x 2^-1023-53 and once we do, we are no longer
2344
+ // subnormal, but we can only know this after rounding.
2345
+ // So we only declare a subnormal if we are smaller than the threshold.
2346
+ answer.power2 = (answer.mantissa < (uint64_t(1) << binary::mantissa_explicit_bits())) ? 0 : 1;
2347
+ return answer;
2348
+ }
2349
+
2350
+ // usually, we round *up*, but if we fall right in between and and we have an
2351
+ // even basis, we need to round down
2352
+ // We are only concerned with the cases where 5**q fits in single 64-bit word.
2353
+ if ((product.low <= 1) && (q >= binary::min_exponent_round_to_even()) && (q <= binary::max_exponent_round_to_even()) &&
2354
+ ((answer.mantissa & 3) == 1) ) { // we may fall between two floats!
2355
+ // To be in-between two floats we need that in doing
2356
+ // answer.mantissa = product.high >> (upperbit + 64 - binary::mantissa_explicit_bits() - 3);
2357
+ // ... we dropped out only zeroes. But if this happened, then we can go back!!!
2358
+ if((answer.mantissa << (upperbit + 64 - binary::mantissa_explicit_bits() - 3)) == product.high) {
2359
+ answer.mantissa &= ~uint64_t(1); // flip it so that we do not round up
2360
+ }
2361
+ }
2362
+
2363
+ answer.mantissa += (answer.mantissa & 1); // round up
2364
+ answer.mantissa >>= 1;
2365
+ if (answer.mantissa >= (uint64_t(2) << binary::mantissa_explicit_bits())) {
2366
+ answer.mantissa = (uint64_t(1) << binary::mantissa_explicit_bits());
2367
+ answer.power2++; // undo previous addition
2368
+ }
2369
+
2370
+ answer.mantissa &= ~(uint64_t(1) << binary::mantissa_explicit_bits());
2371
+ if (answer.power2 >= binary::infinite_power()) { // infinity
2372
+ answer.power2 = binary::infinite_power();
2373
+ answer.mantissa = 0;
2374
+ }
2375
+ return answer;
2376
+ }
2377
+
2378
+ } // namespace fast_float
2379
+
2380
+ #endif
2381
+
2382
+ #ifndef FASTFLOAT_BIGINT_H
2383
+ #define FASTFLOAT_BIGINT_H
2384
+
2385
+ #include <algorithm>
2386
+ #include <cstdint>
2387
+ #include <climits>
2388
+ #include <cstring>
2389
+
2390
+
2391
+ namespace fast_float {
2392
+
2393
+ // the limb width: we want efficient multiplication of double the bits in
2394
+ // limb, or for 64-bit limbs, at least 64-bit multiplication where we can
2395
+ // extract the high and low parts efficiently. this is every 64-bit
2396
+ // architecture except for sparc, which emulates 128-bit multiplication.
2397
+ // we might have platforms where `CHAR_BIT` is not 8, so let's avoid
2398
+ // doing `8 * sizeof(limb)`.
2399
+ #if defined(FASTFLOAT_64BIT) && !defined(__sparc)
2400
+ #define FASTFLOAT_64BIT_LIMB 1
2401
+ typedef uint64_t limb;
2402
+ constexpr size_t limb_bits = 64;
2403
+ #else
2404
+ #define FASTFLOAT_32BIT_LIMB
2405
+ typedef uint32_t limb;
2406
+ constexpr size_t limb_bits = 32;
2407
+ #endif
2408
+
2409
+ typedef span<limb> limb_span;
2410
+
2411
+ // number of bits in a bigint. this needs to be at least the number
2412
+ // of bits required to store the largest bigint, which is
2413
+ // `log2(10**(digits + max_exp))`, or `log2(10**(767 + 342))`, or
2414
+ // ~3600 bits, so we round to 4000.
2415
+ constexpr size_t bigint_bits = 4000;
2416
+ constexpr size_t bigint_limbs = bigint_bits / limb_bits;
2417
+
2418
+ // vector-like type that is allocated on the stack. the entire
2419
+ // buffer is pre-allocated, and only the length changes.
2420
+ template <uint16_t size>
2421
+ struct stackvec {
2422
+ limb data[size];
2423
+ // we never need more than 150 limbs
2424
+ uint16_t length{0};
2425
+
2426
+ stackvec() = default;
2427
+ stackvec(const stackvec &) = delete;
2428
+ stackvec &operator=(const stackvec &) = delete;
2429
+ stackvec(stackvec &&) = delete;
2430
+ stackvec &operator=(stackvec &&other) = delete;
2431
+
2432
+ // create stack vector from existing limb span.
2433
+ FASTFLOAT_CONSTEXPR20 stackvec(limb_span s) {
2434
+ FASTFLOAT_ASSERT(try_extend(s));
2435
+ }
2436
+
2437
+ FASTFLOAT_CONSTEXPR14 limb& operator[](size_t index) noexcept {
2438
+ FASTFLOAT_DEBUG_ASSERT(index < length);
2439
+ return data[index];
2440
+ }
2441
+ FASTFLOAT_CONSTEXPR14 const limb& operator[](size_t index) const noexcept {
2442
+ FASTFLOAT_DEBUG_ASSERT(index < length);
2443
+ return data[index];
2444
+ }
2445
+ // index from the end of the container
2446
+ FASTFLOAT_CONSTEXPR14 const limb& rindex(size_t index) const noexcept {
2447
+ FASTFLOAT_DEBUG_ASSERT(index < length);
2448
+ size_t rindex = length - index - 1;
2449
+ return data[rindex];
2450
+ }
2451
+
2452
+ // set the length, without bounds checking.
2453
+ FASTFLOAT_CONSTEXPR14 void set_len(size_t len) noexcept {
2454
+ length = uint16_t(len);
2455
+ }
2456
+ constexpr size_t len() const noexcept {
2457
+ return length;
2458
+ }
2459
+ constexpr bool is_empty() const noexcept {
2460
+ return length == 0;
2461
+ }
2462
+ constexpr size_t capacity() const noexcept {
2463
+ return size;
2464
+ }
2465
+ // append item to vector, without bounds checking
2466
+ FASTFLOAT_CONSTEXPR14 void push_unchecked(limb value) noexcept {
2467
+ data[length] = value;
2468
+ length++;
2469
+ }
2470
+ // append item to vector, returning if item was added
2471
+ FASTFLOAT_CONSTEXPR14 bool try_push(limb value) noexcept {
2472
+ if (len() < capacity()) {
2473
+ push_unchecked(value);
2474
+ return true;
2475
+ } else {
2476
+ return false;
2477
+ }
2478
+ }
2479
+ // add items to the vector, from a span, without bounds checking
2480
+ FASTFLOAT_CONSTEXPR20 void extend_unchecked(limb_span s) noexcept {
2481
+ limb* ptr = data + length;
2482
+ std::copy_n(s.ptr, s.len(), ptr);
2483
+ set_len(len() + s.len());
2484
+ }
2485
+ // try to add items to the vector, returning if items were added
2486
+ FASTFLOAT_CONSTEXPR20 bool try_extend(limb_span s) noexcept {
2487
+ if (len() + s.len() <= capacity()) {
2488
+ extend_unchecked(s);
2489
+ return true;
2490
+ } else {
2491
+ return false;
2492
+ }
2493
+ }
2494
+ // resize the vector, without bounds checking
2495
+ // if the new size is longer than the vector, assign value to each
2496
+ // appended item.
2497
+ FASTFLOAT_CONSTEXPR20
2498
+ void resize_unchecked(size_t new_len, limb value) noexcept {
2499
+ if (new_len > len()) {
2500
+ size_t count = new_len - len();
2501
+ limb* first = data + len();
2502
+ limb* last = first + count;
2503
+ ::std::fill(first, last, value);
2504
+ set_len(new_len);
2505
+ } else {
2506
+ set_len(new_len);
2507
+ }
2508
+ }
2509
+ // try to resize the vector, returning if the vector was resized.
2510
+ FASTFLOAT_CONSTEXPR20 bool try_resize(size_t new_len, limb value) noexcept {
2511
+ if (new_len > capacity()) {
2512
+ return false;
2513
+ } else {
2514
+ resize_unchecked(new_len, value);
2515
+ return true;
2516
+ }
2517
+ }
2518
+ // check if any limbs are non-zero after the given index.
2519
+ // this needs to be done in reverse order, since the index
2520
+ // is relative to the most significant limbs.
2521
+ FASTFLOAT_CONSTEXPR14 bool nonzero(size_t index) const noexcept {
2522
+ while (index < len()) {
2523
+ if (rindex(index) != 0) {
2524
+ return true;
2525
+ }
2526
+ index++;
2527
+ }
2528
+ return false;
2529
+ }
2530
+ // normalize the big integer, so most-significant zero limbs are removed.
2531
+ FASTFLOAT_CONSTEXPR14 void normalize() noexcept {
2532
+ while (len() > 0 && rindex(0) == 0) {
2533
+ length--;
2534
+ }
2535
+ }
2536
+ };
2537
+
2538
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
2539
+ uint64_t empty_hi64(bool& truncated) noexcept {
2540
+ truncated = false;
2541
+ return 0;
2542
+ }
2543
+
2544
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2545
+ uint64_t uint64_hi64(uint64_t r0, bool& truncated) noexcept {
2546
+ truncated = false;
2547
+ int shl = leading_zeroes(r0);
2548
+ return r0 << shl;
2549
+ }
2550
+
2551
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2552
+ uint64_t uint64_hi64(uint64_t r0, uint64_t r1, bool& truncated) noexcept {
2553
+ int shl = leading_zeroes(r0);
2554
+ if (shl == 0) {
2555
+ truncated = r1 != 0;
2556
+ return r0;
2557
+ } else {
2558
+ int shr = 64 - shl;
2559
+ truncated = (r1 << shl) != 0;
2560
+ return (r0 << shl) | (r1 >> shr);
2561
+ }
2562
+ }
2563
+
2564
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2565
+ uint64_t uint32_hi64(uint32_t r0, bool& truncated) noexcept {
2566
+ return uint64_hi64(r0, truncated);
2567
+ }
2568
+
2569
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2570
+ uint64_t uint32_hi64(uint32_t r0, uint32_t r1, bool& truncated) noexcept {
2571
+ uint64_t x0 = r0;
2572
+ uint64_t x1 = r1;
2573
+ return uint64_hi64((x0 << 32) | x1, truncated);
2574
+ }
2575
+
2576
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2577
+ uint64_t uint32_hi64(uint32_t r0, uint32_t r1, uint32_t r2, bool& truncated) noexcept {
2578
+ uint64_t x0 = r0;
2579
+ uint64_t x1 = r1;
2580
+ uint64_t x2 = r2;
2581
+ return uint64_hi64(x0, (x1 << 32) | x2, truncated);
2582
+ }
2583
+
2584
+ // add two small integers, checking for overflow.
2585
+ // we want an efficient operation. for msvc, where
2586
+ // we don't have built-in intrinsics, this is still
2587
+ // pretty fast.
2588
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2589
+ limb scalar_add(limb x, limb y, bool& overflow) noexcept {
2590
+ limb z;
2591
+ // gcc and clang
2592
+ #if defined(__has_builtin)
2593
+ #if __has_builtin(__builtin_add_overflow)
2594
+ if (!cpp20_and_in_constexpr()) {
2595
+ overflow = __builtin_add_overflow(x, y, &z);
2596
+ return z;
2597
+ }
2598
+ #endif
2599
+ #endif
2600
+
2601
+ // generic, this still optimizes correctly on MSVC.
2602
+ z = x + y;
2603
+ overflow = z < x;
2604
+ return z;
2605
+ }
2606
+
2607
+ // multiply two small integers, getting both the high and low bits.
2608
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2609
+ limb scalar_mul(limb x, limb y, limb& carry) noexcept {
2610
+ #ifdef FASTFLOAT_64BIT_LIMB
2611
+ #if defined(__SIZEOF_INT128__)
2612
+ // GCC and clang both define it as an extension.
2613
+ __uint128_t z = __uint128_t(x) * __uint128_t(y) + __uint128_t(carry);
2614
+ carry = limb(z >> limb_bits);
2615
+ return limb(z);
2616
+ #else
2617
+ // fallback, no native 128-bit integer multiplication with carry.
2618
+ // on msvc, this optimizes identically, somehow.
2619
+ value128 z = full_multiplication(x, y);
2620
+ bool overflow;
2621
+ z.low = scalar_add(z.low, carry, overflow);
2622
+ z.high += uint64_t(overflow); // cannot overflow
2623
+ carry = z.high;
2624
+ return z.low;
2625
+ #endif
2626
+ #else
2627
+ uint64_t z = uint64_t(x) * uint64_t(y) + uint64_t(carry);
2628
+ carry = limb(z >> limb_bits);
2629
+ return limb(z);
2630
+ #endif
2631
+ }
2632
+
2633
+ // add scalar value to bigint starting from offset.
2634
+ // used in grade school multiplication
2635
+ template <uint16_t size>
2636
+ inline FASTFLOAT_CONSTEXPR20
2637
+ bool small_add_from(stackvec<size>& vec, limb y, size_t start) noexcept {
2638
+ size_t index = start;
2639
+ limb carry = y;
2640
+ bool overflow;
2641
+ while (carry != 0 && index < vec.len()) {
2642
+ vec[index] = scalar_add(vec[index], carry, overflow);
2643
+ carry = limb(overflow);
2644
+ index += 1;
2645
+ }
2646
+ if (carry != 0) {
2647
+ FASTFLOAT_TRY(vec.try_push(carry));
2648
+ }
2649
+ return true;
2650
+ }
2651
+
2652
+ // add scalar value to bigint.
2653
+ template <uint16_t size>
2654
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2655
+ bool small_add(stackvec<size>& vec, limb y) noexcept {
2656
+ return small_add_from(vec, y, 0);
2657
+ }
2658
+
2659
+ // multiply bigint by scalar value.
2660
+ template <uint16_t size>
2661
+ inline FASTFLOAT_CONSTEXPR20
2662
+ bool small_mul(stackvec<size>& vec, limb y) noexcept {
2663
+ limb carry = 0;
2664
+ for (size_t index = 0; index < vec.len(); index++) {
2665
+ vec[index] = scalar_mul(vec[index], y, carry);
2666
+ }
2667
+ if (carry != 0) {
2668
+ FASTFLOAT_TRY(vec.try_push(carry));
2669
+ }
2670
+ return true;
2671
+ }
2672
+
2673
+ // add bigint to bigint starting from index.
2674
+ // used in grade school multiplication
2675
+ template <uint16_t size>
2676
+ FASTFLOAT_CONSTEXPR20
2677
+ bool large_add_from(stackvec<size>& x, limb_span y, size_t start) noexcept {
2678
+ // the effective x buffer is from `xstart..x.len()`, so exit early
2679
+ // if we can't get that current range.
2680
+ if (x.len() < start || y.len() > x.len() - start) {
2681
+ FASTFLOAT_TRY(x.try_resize(y.len() + start, 0));
2682
+ }
2683
+
2684
+ bool carry = false;
2685
+ for (size_t index = 0; index < y.len(); index++) {
2686
+ limb xi = x[index + start];
2687
+ limb yi = y[index];
2688
+ bool c1 = false;
2689
+ bool c2 = false;
2690
+ xi = scalar_add(xi, yi, c1);
2691
+ if (carry) {
2692
+ xi = scalar_add(xi, 1, c2);
2693
+ }
2694
+ x[index + start] = xi;
2695
+ carry = c1 | c2;
2696
+ }
2697
+
2698
+ // handle overflow
2699
+ if (carry) {
2700
+ FASTFLOAT_TRY(small_add_from(x, 1, y.len() + start));
2701
+ }
2702
+ return true;
2703
+ }
2704
+
2705
+ // add bigint to bigint.
2706
+ template <uint16_t size>
2707
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
2708
+ bool large_add_from(stackvec<size>& x, limb_span y) noexcept {
2709
+ return large_add_from(x, y, 0);
2710
+ }
2711
+
2712
+ // grade-school multiplication algorithm
2713
+ template <uint16_t size>
2714
+ FASTFLOAT_CONSTEXPR20
2715
+ bool long_mul(stackvec<size>& x, limb_span y) noexcept {
2716
+ limb_span xs = limb_span(x.data, x.len());
2717
+ stackvec<size> z(xs);
2718
+ limb_span zs = limb_span(z.data, z.len());
2719
+
2720
+ if (y.len() != 0) {
2721
+ limb y0 = y[0];
2722
+ FASTFLOAT_TRY(small_mul(x, y0));
2723
+ for (size_t index = 1; index < y.len(); index++) {
2724
+ limb yi = y[index];
2725
+ stackvec<size> zi;
2726
+ if (yi != 0) {
2727
+ // re-use the same buffer throughout
2728
+ zi.set_len(0);
2729
+ FASTFLOAT_TRY(zi.try_extend(zs));
2730
+ FASTFLOAT_TRY(small_mul(zi, yi));
2731
+ limb_span zis = limb_span(zi.data, zi.len());
2732
+ FASTFLOAT_TRY(large_add_from(x, zis, index));
2733
+ }
2734
+ }
2735
+ }
2736
+
2737
+ x.normalize();
2738
+ return true;
2739
+ }
2740
+
2741
+ // grade-school multiplication algorithm
2742
+ template <uint16_t size>
2743
+ FASTFLOAT_CONSTEXPR20
2744
+ bool large_mul(stackvec<size>& x, limb_span y) noexcept {
2745
+ if (y.len() == 1) {
2746
+ FASTFLOAT_TRY(small_mul(x, y[0]));
2747
+ } else {
2748
+ FASTFLOAT_TRY(long_mul(x, y));
2749
+ }
2750
+ return true;
2751
+ }
2752
+
2753
+ template <typename = void>
2754
+ struct pow5_tables {
2755
+ static constexpr uint32_t large_step = 135;
2756
+ static constexpr uint64_t small_power_of_5[] = {
2757
+ 1UL, 5UL, 25UL, 125UL, 625UL, 3125UL, 15625UL, 78125UL, 390625UL,
2758
+ 1953125UL, 9765625UL, 48828125UL, 244140625UL, 1220703125UL,
2759
+ 6103515625UL, 30517578125UL, 152587890625UL, 762939453125UL,
2760
+ 3814697265625UL, 19073486328125UL, 95367431640625UL, 476837158203125UL,
2761
+ 2384185791015625UL, 11920928955078125UL, 59604644775390625UL,
2762
+ 298023223876953125UL, 1490116119384765625UL, 7450580596923828125UL,
2763
+ };
2764
+ #ifdef FASTFLOAT_64BIT_LIMB
2765
+ constexpr static limb large_power_of_5[] = {
2766
+ 1414648277510068013UL, 9180637584431281687UL, 4539964771860779200UL,
2767
+ 10482974169319127550UL, 198276706040285095UL};
2768
+ #else
2769
+ constexpr static limb large_power_of_5[] = {
2770
+ 4279965485U, 329373468U, 4020270615U, 2137533757U, 4287402176U,
2771
+ 1057042919U, 1071430142U, 2440757623U, 381945767U, 46164893U};
2772
+ #endif
2773
+ };
2774
+
2775
+ template <typename T>
2776
+ constexpr uint32_t pow5_tables<T>::large_step;
2777
+
2778
+ template <typename T>
2779
+ constexpr uint64_t pow5_tables<T>::small_power_of_5[];
2780
+
2781
+ template <typename T>
2782
+ constexpr limb pow5_tables<T>::large_power_of_5[];
2783
+
2784
+ // big integer type. implements a small subset of big integer
2785
+ // arithmetic, using simple algorithms since asymptotically
2786
+ // faster algorithms are slower for a small number of limbs.
2787
+ // all operations assume the big-integer is normalized.
2788
+ struct bigint : pow5_tables<> {
2789
+ // storage of the limbs, in little-endian order.
2790
+ stackvec<bigint_limbs> vec;
2791
+
2792
+ FASTFLOAT_CONSTEXPR20 bigint(): vec() {}
2793
+ bigint(const bigint &) = delete;
2794
+ bigint &operator=(const bigint &) = delete;
2795
+ bigint(bigint &&) = delete;
2796
+ bigint &operator=(bigint &&other) = delete;
2797
+
2798
+ FASTFLOAT_CONSTEXPR20 bigint(uint64_t value): vec() {
2799
+ #ifdef FASTFLOAT_64BIT_LIMB
2800
+ vec.push_unchecked(value);
2801
+ #else
2802
+ vec.push_unchecked(uint32_t(value));
2803
+ vec.push_unchecked(uint32_t(value >> 32));
2804
+ #endif
2805
+ vec.normalize();
2806
+ }
2807
+
2808
+ // get the high 64 bits from the vector, and if bits were truncated.
2809
+ // this is to get the significant digits for the float.
2810
+ FASTFLOAT_CONSTEXPR20 uint64_t hi64(bool& truncated) const noexcept {
2811
+ #ifdef FASTFLOAT_64BIT_LIMB
2812
+ if (vec.len() == 0) {
2813
+ return empty_hi64(truncated);
2814
+ } else if (vec.len() == 1) {
2815
+ return uint64_hi64(vec.rindex(0), truncated);
2816
+ } else {
2817
+ uint64_t result = uint64_hi64(vec.rindex(0), vec.rindex(1), truncated);
2818
+ truncated |= vec.nonzero(2);
2819
+ return result;
2820
+ }
2821
+ #else
2822
+ if (vec.len() == 0) {
2823
+ return empty_hi64(truncated);
2824
+ } else if (vec.len() == 1) {
2825
+ return uint32_hi64(vec.rindex(0), truncated);
2826
+ } else if (vec.len() == 2) {
2827
+ return uint32_hi64(vec.rindex(0), vec.rindex(1), truncated);
2828
+ } else {
2829
+ uint64_t result = uint32_hi64(vec.rindex(0), vec.rindex(1), vec.rindex(2), truncated);
2830
+ truncated |= vec.nonzero(3);
2831
+ return result;
2832
+ }
2833
+ #endif
2834
+ }
2835
+
2836
+ // compare two big integers, returning the large value.
2837
+ // assumes both are normalized. if the return value is
2838
+ // negative, other is larger, if the return value is
2839
+ // positive, this is larger, otherwise they are equal.
2840
+ // the limbs are stored in little-endian order, so we
2841
+ // must compare the limbs in ever order.
2842
+ FASTFLOAT_CONSTEXPR20 int compare(const bigint& other) const noexcept {
2843
+ if (vec.len() > other.vec.len()) {
2844
+ return 1;
2845
+ } else if (vec.len() < other.vec.len()) {
2846
+ return -1;
2847
+ } else {
2848
+ for (size_t index = vec.len(); index > 0; index--) {
2849
+ limb xi = vec[index - 1];
2850
+ limb yi = other.vec[index - 1];
2851
+ if (xi > yi) {
2852
+ return 1;
2853
+ } else if (xi < yi) {
2854
+ return -1;
2855
+ }
2856
+ }
2857
+ return 0;
2858
+ }
2859
+ }
2860
+
2861
+ // shift left each limb n bits, carrying over to the new limb
2862
+ // returns true if we were able to shift all the digits.
2863
+ FASTFLOAT_CONSTEXPR20 bool shl_bits(size_t n) noexcept {
2864
+ // Internally, for each item, we shift left by n, and add the previous
2865
+ // right shifted limb-bits.
2866
+ // For example, we transform (for u8) shifted left 2, to:
2867
+ // b10100100 b01000010
2868
+ // b10 b10010001 b00001000
2869
+ FASTFLOAT_DEBUG_ASSERT(n != 0);
2870
+ FASTFLOAT_DEBUG_ASSERT(n < sizeof(limb) * 8);
2871
+
2872
+ size_t shl = n;
2873
+ size_t shr = limb_bits - shl;
2874
+ limb prev = 0;
2875
+ for (size_t index = 0; index < vec.len(); index++) {
2876
+ limb xi = vec[index];
2877
+ vec[index] = (xi << shl) | (prev >> shr);
2878
+ prev = xi;
2879
+ }
2880
+
2881
+ limb carry = prev >> shr;
2882
+ if (carry != 0) {
2883
+ return vec.try_push(carry);
2884
+ }
2885
+ return true;
2886
+ }
2887
+
2888
+ // move the limbs left by `n` limbs.
2889
+ FASTFLOAT_CONSTEXPR20 bool shl_limbs(size_t n) noexcept {
2890
+ FASTFLOAT_DEBUG_ASSERT(n != 0);
2891
+ if (n + vec.len() > vec.capacity()) {
2892
+ return false;
2893
+ } else if (!vec.is_empty()) {
2894
+ // move limbs
2895
+ limb* dst = vec.data + n;
2896
+ const limb* src = vec.data;
2897
+ std::copy_backward(src, src + vec.len(), dst + vec.len());
2898
+ // fill in empty limbs
2899
+ limb* first = vec.data;
2900
+ limb* last = first + n;
2901
+ ::std::fill(first, last, 0);
2902
+ vec.set_len(n + vec.len());
2903
+ return true;
2904
+ } else {
2905
+ return true;
2906
+ }
2907
+ }
2908
+
2909
+ // move the limbs left by `n` bits.
2910
+ FASTFLOAT_CONSTEXPR20 bool shl(size_t n) noexcept {
2911
+ size_t rem = n % limb_bits;
2912
+ size_t div = n / limb_bits;
2913
+ if (rem != 0) {
2914
+ FASTFLOAT_TRY(shl_bits(rem));
2915
+ }
2916
+ if (div != 0) {
2917
+ FASTFLOAT_TRY(shl_limbs(div));
2918
+ }
2919
+ return true;
2920
+ }
2921
+
2922
+ // get the number of leading zeros in the bigint.
2923
+ FASTFLOAT_CONSTEXPR20 int ctlz() const noexcept {
2924
+ if (vec.is_empty()) {
2925
+ return 0;
2926
+ } else {
2927
+ #ifdef FASTFLOAT_64BIT_LIMB
2928
+ return leading_zeroes(vec.rindex(0));
2929
+ #else
2930
+ // no use defining a specialized leading_zeroes for a 32-bit type.
2931
+ uint64_t r0 = vec.rindex(0);
2932
+ return leading_zeroes(r0 << 32);
2933
+ #endif
2934
+ }
2935
+ }
2936
+
2937
+ // get the number of bits in the bigint.
2938
+ FASTFLOAT_CONSTEXPR20 int bit_length() const noexcept {
2939
+ int lz = ctlz();
2940
+ return int(limb_bits * vec.len()) - lz;
2941
+ }
2942
+
2943
+ FASTFLOAT_CONSTEXPR20 bool mul(limb y) noexcept {
2944
+ return small_mul(vec, y);
2945
+ }
2946
+
2947
+ FASTFLOAT_CONSTEXPR20 bool add(limb y) noexcept {
2948
+ return small_add(vec, y);
2949
+ }
2950
+
2951
+ // multiply as if by 2 raised to a power.
2952
+ FASTFLOAT_CONSTEXPR20 bool pow2(uint32_t exp) noexcept {
2953
+ return shl(exp);
2954
+ }
2955
+
2956
+ // multiply as if by 5 raised to a power.
2957
+ FASTFLOAT_CONSTEXPR20 bool pow5(uint32_t exp) noexcept {
2958
+ // multiply by a power of 5
2959
+ size_t large_length = sizeof(large_power_of_5) / sizeof(limb);
2960
+ limb_span large = limb_span(large_power_of_5, large_length);
2961
+ while (exp >= large_step) {
2962
+ FASTFLOAT_TRY(large_mul(vec, large));
2963
+ exp -= large_step;
2964
+ }
2965
+ #ifdef FASTFLOAT_64BIT_LIMB
2966
+ uint32_t small_step = 27;
2967
+ limb max_native = 7450580596923828125UL;
2968
+ #else
2969
+ uint32_t small_step = 13;
2970
+ limb max_native = 1220703125U;
2971
+ #endif
2972
+ while (exp >= small_step) {
2973
+ FASTFLOAT_TRY(small_mul(vec, max_native));
2974
+ exp -= small_step;
2975
+ }
2976
+ if (exp != 0) {
2977
+ // Work around clang bug https://godbolt.org/z/zedh7rrhc
2978
+ // This is similar to https://github.com/llvm/llvm-project/issues/47746,
2979
+ // except the workaround described there don't work here
2980
+ FASTFLOAT_TRY(
2981
+ small_mul(vec, limb(((void)small_power_of_5[0], small_power_of_5[exp])))
2982
+ );
2983
+ }
2984
+
2985
+ return true;
2986
+ }
2987
+
2988
+ // multiply as if by 10 raised to a power.
2989
+ FASTFLOAT_CONSTEXPR20 bool pow10(uint32_t exp) noexcept {
2990
+ FASTFLOAT_TRY(pow5(exp));
2991
+ return pow2(exp);
2992
+ }
2993
+ };
2994
+
2995
+ } // namespace fast_float
2996
+
2997
+ #endif
2998
+
2999
+ #ifndef FASTFLOAT_DIGIT_COMPARISON_H
3000
+ #define FASTFLOAT_DIGIT_COMPARISON_H
3001
+
3002
+ #include <algorithm>
3003
+ #include <cstdint>
3004
+ #include <cstring>
3005
+ #include <iterator>
3006
+
3007
+
3008
+ namespace fast_float {
3009
+
3010
+ // 1e0 to 1e19
3011
+ constexpr static uint64_t powers_of_ten_uint64[] = {
3012
+ 1UL, 10UL, 100UL, 1000UL, 10000UL, 100000UL, 1000000UL, 10000000UL, 100000000UL,
3013
+ 1000000000UL, 10000000000UL, 100000000000UL, 1000000000000UL, 10000000000000UL,
3014
+ 100000000000000UL, 1000000000000000UL, 10000000000000000UL, 100000000000000000UL,
3015
+ 1000000000000000000UL, 10000000000000000000UL};
3016
+
3017
+ // calculate the exponent, in scientific notation, of the number.
3018
+ // this algorithm is not even close to optimized, but it has no practical
3019
+ // effect on performance: in order to have a faster algorithm, we'd need
3020
+ // to slow down performance for faster algorithms, and this is still fast.
3021
+ template <typename UC>
3022
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
3023
+ int32_t scientific_exponent(parsed_number_string_t<UC> & num) noexcept {
3024
+ uint64_t mantissa = num.mantissa;
3025
+ int32_t exponent = int32_t(num.exponent);
3026
+ while (mantissa >= 10000) {
3027
+ mantissa /= 10000;
3028
+ exponent += 4;
3029
+ }
3030
+ while (mantissa >= 100) {
3031
+ mantissa /= 100;
3032
+ exponent += 2;
3033
+ }
3034
+ while (mantissa >= 10) {
3035
+ mantissa /= 10;
3036
+ exponent += 1;
3037
+ }
3038
+ return exponent;
3039
+ }
3040
+
3041
+ // this converts a native floating-point number to an extended-precision float.
3042
+ template <typename T>
3043
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3044
+ adjusted_mantissa to_extended(T value) noexcept {
3045
+ using equiv_uint = typename binary_format<T>::equiv_uint;
3046
+ constexpr equiv_uint exponent_mask = binary_format<T>::exponent_mask();
3047
+ constexpr equiv_uint mantissa_mask = binary_format<T>::mantissa_mask();
3048
+ constexpr equiv_uint hidden_bit_mask = binary_format<T>::hidden_bit_mask();
3049
+
3050
+ adjusted_mantissa am;
3051
+ int32_t bias = binary_format<T>::mantissa_explicit_bits() - binary_format<T>::minimum_exponent();
3052
+ equiv_uint bits;
3053
+ #if FASTFLOAT_HAS_BIT_CAST
3054
+ bits = std::bit_cast<equiv_uint>(value);
3055
+ #else
3056
+ ::memcpy(&bits, &value, sizeof(T));
3057
+ #endif
3058
+ if ((bits & exponent_mask) == 0) {
3059
+ // denormal
3060
+ am.power2 = 1 - bias;
3061
+ am.mantissa = bits & mantissa_mask;
3062
+ } else {
3063
+ // normal
3064
+ am.power2 = int32_t((bits & exponent_mask) >> binary_format<T>::mantissa_explicit_bits());
3065
+ am.power2 -= bias;
3066
+ am.mantissa = (bits & mantissa_mask) | hidden_bit_mask;
3067
+ }
3068
+
3069
+ return am;
3070
+ }
3071
+
3072
+ // get the extended precision value of the halfway point between b and b+u.
3073
+ // we are given a native float that represents b, so we need to adjust it
3074
+ // halfway between b and b+u.
3075
+ template <typename T>
3076
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3077
+ adjusted_mantissa to_extended_halfway(T value) noexcept {
3078
+ adjusted_mantissa am = to_extended(value);
3079
+ am.mantissa <<= 1;
3080
+ am.mantissa += 1;
3081
+ am.power2 -= 1;
3082
+ return am;
3083
+ }
3084
+
3085
+ // round an extended-precision float to the nearest machine float.
3086
+ template <typename T, typename callback>
3087
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
3088
+ void round(adjusted_mantissa& am, callback cb) noexcept {
3089
+ int32_t mantissa_shift = 64 - binary_format<T>::mantissa_explicit_bits() - 1;
3090
+ if (-am.power2 >= mantissa_shift) {
3091
+ // have a denormal float
3092
+ int32_t shift = -am.power2 + 1;
3093
+ cb(am, std::min<int32_t>(shift, 64));
3094
+ // check for round-up: if rounding-nearest carried us to the hidden bit.
3095
+ am.power2 = (am.mantissa < (uint64_t(1) << binary_format<T>::mantissa_explicit_bits())) ? 0 : 1;
3096
+ return;
3097
+ }
3098
+
3099
+ // have a normal float, use the default shift.
3100
+ cb(am, mantissa_shift);
3101
+
3102
+ // check for carry
3103
+ if (am.mantissa >= (uint64_t(2) << binary_format<T>::mantissa_explicit_bits())) {
3104
+ am.mantissa = (uint64_t(1) << binary_format<T>::mantissa_explicit_bits());
3105
+ am.power2++;
3106
+ }
3107
+
3108
+ // check for infinite: we could have carried to an infinite power
3109
+ am.mantissa &= ~(uint64_t(1) << binary_format<T>::mantissa_explicit_bits());
3110
+ if (am.power2 >= binary_format<T>::infinite_power()) {
3111
+ am.power2 = binary_format<T>::infinite_power();
3112
+ am.mantissa = 0;
3113
+ }
3114
+ }
3115
+
3116
+ template <typename callback>
3117
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
3118
+ void round_nearest_tie_even(adjusted_mantissa& am, int32_t shift, callback cb) noexcept {
3119
+ const uint64_t mask
3120
+ = (shift == 64)
3121
+ ? UINT64_MAX
3122
+ : (uint64_t(1) << shift) - 1;
3123
+ const uint64_t halfway
3124
+ = (shift == 0)
3125
+ ? 0
3126
+ : uint64_t(1) << (shift - 1);
3127
+ uint64_t truncated_bits = am.mantissa & mask;
3128
+ bool is_above = truncated_bits > halfway;
3129
+ bool is_halfway = truncated_bits == halfway;
3130
+
3131
+ // shift digits into position
3132
+ if (shift == 64) {
3133
+ am.mantissa = 0;
3134
+ } else {
3135
+ am.mantissa >>= shift;
3136
+ }
3137
+ am.power2 += shift;
3138
+
3139
+ bool is_odd = (am.mantissa & 1) == 1;
3140
+ am.mantissa += uint64_t(cb(is_odd, is_halfway, is_above));
3141
+ }
3142
+
3143
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
3144
+ void round_down(adjusted_mantissa& am, int32_t shift) noexcept {
3145
+ if (shift == 64) {
3146
+ am.mantissa = 0;
3147
+ } else {
3148
+ am.mantissa >>= shift;
3149
+ }
3150
+ am.power2 += shift;
3151
+ }
3152
+ template <typename UC>
3153
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3154
+ void skip_zeros(UC const * & first, UC const * last) noexcept {
3155
+ uint64_t val;
3156
+ while (!cpp20_and_in_constexpr() && std::distance(first, last) >= int_cmp_len<UC>()) {
3157
+ ::memcpy(&val, first, sizeof(uint64_t));
3158
+ if (val != int_cmp_zeros<UC>()) {
3159
+ break;
3160
+ }
3161
+ first += int_cmp_len<UC>();
3162
+ }
3163
+ while (first != last) {
3164
+ if (*first != UC('0')) {
3165
+ break;
3166
+ }
3167
+ first++;
3168
+ }
3169
+ }
3170
+
3171
+ // determine if any non-zero digits were truncated.
3172
+ // all characters must be valid digits.
3173
+ template <typename UC>
3174
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3175
+ bool is_truncated(UC const * first, UC const * last) noexcept {
3176
+ // do 8-bit optimizations, can just compare to 8 literal 0s.
3177
+ uint64_t val;
3178
+ while (!cpp20_and_in_constexpr() && std::distance(first, last) >= int_cmp_len<UC>()) {
3179
+ ::memcpy(&val, first, sizeof(uint64_t));
3180
+ if (val != int_cmp_zeros<UC>()) {
3181
+ return true;
3182
+ }
3183
+ first += int_cmp_len<UC>();
3184
+ }
3185
+ while (first != last) {
3186
+ if (*first != UC('0')) {
3187
+ return true;
3188
+ }
3189
+ ++first;
3190
+ }
3191
+ return false;
3192
+ }
3193
+ template <typename UC>
3194
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3195
+ bool is_truncated(span<const UC> s) noexcept {
3196
+ return is_truncated(s.ptr, s.ptr + s.len());
3197
+ }
3198
+
3199
+
3200
+ template <typename UC>
3201
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3202
+ void parse_eight_digits(const UC*& p, limb& value, size_t& counter, size_t& count) noexcept {
3203
+ value = value * 100000000 + parse_eight_digits_unrolled(p);
3204
+ p += 8;
3205
+ counter += 8;
3206
+ count += 8;
3207
+ }
3208
+
3209
+ template <typename UC>
3210
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR14
3211
+ void parse_one_digit(UC const *& p, limb& value, size_t& counter, size_t& count) noexcept {
3212
+ value = value * 10 + limb(*p - UC('0'));
3213
+ p++;
3214
+ counter++;
3215
+ count++;
3216
+ }
3217
+
3218
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3219
+ void add_native(bigint& big, limb power, limb value) noexcept {
3220
+ big.mul(power);
3221
+ big.add(value);
3222
+ }
3223
+
3224
+ fastfloat_really_inline FASTFLOAT_CONSTEXPR20
3225
+ void round_up_bigint(bigint& big, size_t& count) noexcept {
3226
+ // need to round-up the digits, but need to avoid rounding
3227
+ // ....9999 to ...10000, which could cause a false halfway point.
3228
+ add_native(big, 10, 1);
3229
+ count++;
3230
+ }
3231
+
3232
+ // parse the significant digits into a big integer
3233
+ template <typename UC>
3234
+ inline FASTFLOAT_CONSTEXPR20
3235
+ void parse_mantissa(bigint& result, parsed_number_string_t<UC>& num, size_t max_digits, size_t& digits) noexcept {
3236
+ // try to minimize the number of big integer and scalar multiplication.
3237
+ // therefore, try to parse 8 digits at a time, and multiply by the largest
3238
+ // scalar value (9 or 19 digits) for each step.
3239
+ size_t counter = 0;
3240
+ digits = 0;
3241
+ limb value = 0;
3242
+ #ifdef FASTFLOAT_64BIT_LIMB
3243
+ size_t step = 19;
3244
+ #else
3245
+ size_t step = 9;
3246
+ #endif
3247
+
3248
+ // process all integer digits.
3249
+ UC const * p = num.integer.ptr;
3250
+ UC const * pend = p + num.integer.len();
3251
+ skip_zeros(p, pend);
3252
+ // process all digits, in increments of step per loop
3253
+ while (p != pend) {
3254
+ while ((std::distance(p, pend) >= 8) && (step - counter >= 8) && (max_digits - digits >= 8)) {
3255
+ parse_eight_digits(p, value, counter, digits);
3256
+ }
3257
+ while (counter < step && p != pend && digits < max_digits) {
3258
+ parse_one_digit(p, value, counter, digits);
3259
+ }
3260
+ if (digits == max_digits) {
3261
+ // add the temporary value, then check if we've truncated any digits
3262
+ add_native(result, limb(powers_of_ten_uint64[counter]), value);
3263
+ bool truncated = is_truncated(p, pend);
3264
+ if (num.fraction.ptr != nullptr) {
3265
+ truncated |= is_truncated(num.fraction);
3266
+ }
3267
+ if (truncated) {
3268
+ round_up_bigint(result, digits);
3269
+ }
3270
+ return;
3271
+ } else {
3272
+ add_native(result, limb(powers_of_ten_uint64[counter]), value);
3273
+ counter = 0;
3274
+ value = 0;
3275
+ }
3276
+ }
3277
+
3278
+ // add our fraction digits, if they're available.
3279
+ if (num.fraction.ptr != nullptr) {
3280
+ p = num.fraction.ptr;
3281
+ pend = p + num.fraction.len();
3282
+ if (digits == 0) {
3283
+ skip_zeros(p, pend);
3284
+ }
3285
+ // process all digits, in increments of step per loop
3286
+ while (p != pend) {
3287
+ while ((std::distance(p, pend) >= 8) && (step - counter >= 8) && (max_digits - digits >= 8)) {
3288
+ parse_eight_digits(p, value, counter, digits);
3289
+ }
3290
+ while (counter < step && p != pend && digits < max_digits) {
3291
+ parse_one_digit(p, value, counter, digits);
3292
+ }
3293
+ if (digits == max_digits) {
3294
+ // add the temporary value, then check if we've truncated any digits
3295
+ add_native(result, limb(powers_of_ten_uint64[counter]), value);
3296
+ bool truncated = is_truncated(p, pend);
3297
+ if (truncated) {
3298
+ round_up_bigint(result, digits);
3299
+ }
3300
+ return;
3301
+ } else {
3302
+ add_native(result, limb(powers_of_ten_uint64[counter]), value);
3303
+ counter = 0;
3304
+ value = 0;
3305
+ }
3306
+ }
3307
+ }
3308
+
3309
+ if (counter != 0) {
3310
+ add_native(result, limb(powers_of_ten_uint64[counter]), value);
3311
+ }
3312
+ }
3313
+
3314
+ template <typename T>
3315
+ inline FASTFLOAT_CONSTEXPR20
3316
+ adjusted_mantissa positive_digit_comp(bigint& bigmant, int32_t exponent) noexcept {
3317
+ FASTFLOAT_ASSERT(bigmant.pow10(uint32_t(exponent)));
3318
+ adjusted_mantissa answer;
3319
+ bool truncated;
3320
+ answer.mantissa = bigmant.hi64(truncated);
3321
+ int bias = binary_format<T>::mantissa_explicit_bits() - binary_format<T>::minimum_exponent();
3322
+ answer.power2 = bigmant.bit_length() - 64 + bias;
3323
+
3324
+ round<T>(answer, [truncated](adjusted_mantissa& a, int32_t shift) {
3325
+ round_nearest_tie_even(a, shift, [truncated](bool is_odd, bool is_halfway, bool is_above) -> bool {
3326
+ return is_above || (is_halfway && truncated) || (is_odd && is_halfway);
3327
+ });
3328
+ });
3329
+
3330
+ return answer;
3331
+ }
3332
+
3333
+ // the scaling here is quite simple: we have, for the real digits `m * 10^e`,
3334
+ // and for the theoretical digits `n * 2^f`. Since `e` is always negative,
3335
+ // to scale them identically, we do `n * 2^f * 5^-f`, so we now have `m * 2^e`.
3336
+ // we then need to scale by `2^(f- e)`, and then the two significant digits
3337
+ // are of the same magnitude.
3338
+ template <typename T>
3339
+ inline FASTFLOAT_CONSTEXPR20
3340
+ adjusted_mantissa negative_digit_comp(bigint& bigmant, adjusted_mantissa am, int32_t exponent) noexcept {
3341
+ bigint& real_digits = bigmant;
3342
+ int32_t real_exp = exponent;
3343
+
3344
+ // get the value of `b`, rounded down, and get a bigint representation of b+h
3345
+ adjusted_mantissa am_b = am;
3346
+ // gcc7 buf: use a lambda to remove the noexcept qualifier bug with -Wnoexcept-type.
3347
+ round<T>(am_b, [](adjusted_mantissa&a, int32_t shift) { round_down(a, shift); });
3348
+ T b;
3349
+ to_float(false, am_b, b);
3350
+ adjusted_mantissa theor = to_extended_halfway(b);
3351
+ bigint theor_digits(theor.mantissa);
3352
+ int32_t theor_exp = theor.power2;
3353
+
3354
+ // scale real digits and theor digits to be same power.
3355
+ int32_t pow2_exp = theor_exp - real_exp;
3356
+ uint32_t pow5_exp = uint32_t(-real_exp);
3357
+ if (pow5_exp != 0) {
3358
+ FASTFLOAT_ASSERT(theor_digits.pow5(pow5_exp));
3359
+ }
3360
+ if (pow2_exp > 0) {
3361
+ FASTFLOAT_ASSERT(theor_digits.pow2(uint32_t(pow2_exp)));
3362
+ } else if (pow2_exp < 0) {
3363
+ FASTFLOAT_ASSERT(real_digits.pow2(uint32_t(-pow2_exp)));
3364
+ }
3365
+
3366
+ // compare digits, and use it to director rounding
3367
+ int ord = real_digits.compare(theor_digits);
3368
+ adjusted_mantissa answer = am;
3369
+ round<T>(answer, [ord](adjusted_mantissa& a, int32_t shift) {
3370
+ round_nearest_tie_even(a, shift, [ord](bool is_odd, bool _, bool __) -> bool {
3371
+ (void)_; // not needed, since we've done our comparison
3372
+ (void)__; // not needed, since we've done our comparison
3373
+ if (ord > 0) {
3374
+ return true;
3375
+ } else if (ord < 0) {
3376
+ return false;
3377
+ } else {
3378
+ return is_odd;
3379
+ }
3380
+ });
3381
+ });
3382
+
3383
+ return answer;
3384
+ }
3385
+
3386
+ // parse the significant digits as a big integer to unambiguously round the
3387
+ // the significant digits. here, we are trying to determine how to round
3388
+ // an extended float representation close to `b+h`, halfway between `b`
3389
+ // (the float rounded-down) and `b+u`, the next positive float. this
3390
+ // algorithm is always correct, and uses one of two approaches. when
3391
+ // the exponent is positive relative to the significant digits (such as
3392
+ // 1234), we create a big-integer representation, get the high 64-bits,
3393
+ // determine if any lower bits are truncated, and use that to direct
3394
+ // rounding. in case of a negative exponent relative to the significant
3395
+ // digits (such as 1.2345), we create a theoretical representation of
3396
+ // `b` as a big-integer type, scaled to the same binary exponent as
3397
+ // the actual digits. we then compare the big integer representations
3398
+ // of both, and use that to direct rounding.
3399
+ template <typename T, typename UC>
3400
+ inline FASTFLOAT_CONSTEXPR20
3401
+ adjusted_mantissa digit_comp(parsed_number_string_t<UC>& num, adjusted_mantissa am) noexcept {
3402
+ // remove the invalid exponent bias
3403
+ am.power2 -= invalid_am_bias;
3404
+
3405
+ int32_t sci_exp = scientific_exponent(num);
3406
+ size_t max_digits = binary_format<T>::max_digits();
3407
+ size_t digits = 0;
3408
+ bigint bigmant;
3409
+ parse_mantissa(bigmant, num, max_digits, digits);
3410
+ // can't underflow, since digits is at most max_digits.
3411
+ int32_t exponent = sci_exp + 1 - int32_t(digits);
3412
+ if (exponent >= 0) {
3413
+ return positive_digit_comp<T>(bigmant, exponent);
3414
+ } else {
3415
+ return negative_digit_comp<T>(bigmant, am, exponent);
3416
+ }
3417
+ }
3418
+
3419
+ } // namespace fast_float
3420
+
3421
+ #endif
3422
+
3423
+ #ifndef FASTFLOAT_PARSE_NUMBER_H
3424
+ #define FASTFLOAT_PARSE_NUMBER_H
3425
+
3426
+
3427
+ #include <cmath>
3428
+ #include <cstring>
3429
+ #include <limits>
3430
+ #include <system_error>
3431
+ namespace fast_float {
3432
+
3433
+
3434
+ namespace detail {
3435
+ /**
3436
+ * Special case +inf, -inf, nan, infinity, -infinity.
3437
+ * The case comparisons could be made much faster given that we know that the
3438
+ * strings a null-free and fixed.
3439
+ **/
3440
+ template <typename T, typename UC>
3441
+ from_chars_result_t<UC> FASTFLOAT_CONSTEXPR14
3442
+ parse_infnan(UC const * first, UC const * last, T &value) noexcept {
3443
+ from_chars_result_t<UC> answer{};
3444
+ answer.ptr = first;
3445
+ answer.ec = std::errc(); // be optimistic
3446
+ bool minusSign = false;
3447
+ if (*first == UC('-')) { // assume first < last, so dereference without checks; C++17 20.19.3.(7.1) explicitly forbids '+' here
3448
+ minusSign = true;
3449
+ ++first;
3450
+ }
3451
+ #ifdef FASTFLOAT_ALLOWS_LEADING_PLUS // disabled by default
3452
+ if (*first == UC('+')) {
3453
+ ++first;
3454
+ }
3455
+ #endif
3456
+ if (last - first >= 3) {
3457
+ if (fastfloat_strncasecmp(first, str_const_nan<UC>(), 3)) {
3458
+ answer.ptr = (first += 3);
3459
+ value = minusSign ? -std::numeric_limits<T>::quiet_NaN() : std::numeric_limits<T>::quiet_NaN();
3460
+ // Check for possible nan(n-char-seq-opt), C++17 20.19.3.7, C11 7.20.1.3.3. At least MSVC produces nan(ind) and nan(snan).
3461
+ if(first != last && *first == UC('(')) {
3462
+ for(UC const * ptr = first + 1; ptr != last; ++ptr) {
3463
+ if (*ptr == UC(')')) {
3464
+ answer.ptr = ptr + 1; // valid nan(n-char-seq-opt)
3465
+ break;
3466
+ }
3467
+ else if(!((UC('a') <= *ptr && *ptr <= UC('z')) || (UC('A') <= *ptr && *ptr <= UC('Z')) || (UC('0') <= *ptr && *ptr <= UC('9')) || *ptr == UC('_')))
3468
+ break; // forbidden char, not nan(n-char-seq-opt)
3469
+ }
3470
+ }
3471
+ return answer;
3472
+ }
3473
+ if (fastfloat_strncasecmp(first, str_const_inf<UC>(), 3)) {
3474
+ if ((last - first >= 8) && fastfloat_strncasecmp(first + 3, str_const_inf<UC>() + 3, 5)) {
3475
+ answer.ptr = first + 8;
3476
+ } else {
3477
+ answer.ptr = first + 3;
3478
+ }
3479
+ value = minusSign ? -std::numeric_limits<T>::infinity() : std::numeric_limits<T>::infinity();
3480
+ return answer;
3481
+ }
3482
+ }
3483
+ answer.ec = std::errc::invalid_argument;
3484
+ return answer;
3485
+ }
3486
+
3487
+ /**
3488
+ * Returns true if the floating-pointing rounding mode is to 'nearest'.
3489
+ * It is the default on most system. This function is meant to be inexpensive.
3490
+ * Credit : @mwalcott3
3491
+ */
3492
+ fastfloat_really_inline bool rounds_to_nearest() noexcept {
3493
+ // https://lemire.me/blog/2020/06/26/gcc-not-nearest/
3494
+ #if (FLT_EVAL_METHOD != 1) && (FLT_EVAL_METHOD != 0)
3495
+ return false;
3496
+ #endif
3497
+ // See
3498
+ // A fast function to check your floating-point rounding mode
3499
+ // https://lemire.me/blog/2022/11/16/a-fast-function-to-check-your-floating-point-rounding-mode/
3500
+ //
3501
+ // This function is meant to be equivalent to :
3502
+ // prior: #include <cfenv>
3503
+ // return fegetround() == FE_TONEAREST;
3504
+ // However, it is expected to be much faster than the fegetround()
3505
+ // function call.
3506
+ //
3507
+ // The volatile keywoard prevents the compiler from computing the function
3508
+ // at compile-time.
3509
+ // There might be other ways to prevent compile-time optimizations (e.g., asm).
3510
+ // The value does not need to be std::numeric_limits<float>::min(), any small
3511
+ // value so that 1 + x should round to 1 would do (after accounting for excess
3512
+ // precision, as in 387 instructions).
3513
+ static volatile float fmin = std::numeric_limits<float>::min();
3514
+ float fmini = fmin; // we copy it so that it gets loaded at most once.
3515
+ //
3516
+ // Explanation:
3517
+ // Only when fegetround() == FE_TONEAREST do we have that
3518
+ // fmin + 1.0f == 1.0f - fmin.
3519
+ //
3520
+ // FE_UPWARD:
3521
+ // fmin + 1.0f > 1
3522
+ // 1.0f - fmin == 1
3523
+ //
3524
+ // FE_DOWNWARD or FE_TOWARDZERO:
3525
+ // fmin + 1.0f == 1
3526
+ // 1.0f - fmin < 1
3527
+ //
3528
+ // Note: This may fail to be accurate if fast-math has been
3529
+ // enabled, as rounding conventions may not apply.
3530
+ #ifdef FASTFLOAT_VISUAL_STUDIO
3531
+ # pragma warning(push)
3532
+ // todo: is there a VS warning?
3533
+ // see https://stackoverflow.com/questions/46079446/is-there-a-warning-for-floating-point-equality-checking-in-visual-studio-2013
3534
+ #elif defined(__clang__)
3535
+ # pragma clang diagnostic push
3536
+ # pragma clang diagnostic ignored "-Wfloat-equal"
3537
+ #elif defined(__GNUC__)
3538
+ # pragma GCC diagnostic push
3539
+ # pragma GCC diagnostic ignored "-Wfloat-equal"
3540
+ #endif
3541
+ return (fmini + 1.0f == 1.0f - fmini);
3542
+ #ifdef FASTFLOAT_VISUAL_STUDIO
3543
+ # pragma warning(pop)
3544
+ #elif defined(__clang__)
3545
+ # pragma clang diagnostic pop
3546
+ #elif defined(__GNUC__)
3547
+ # pragma GCC diagnostic pop
3548
+ #endif
3549
+ }
3550
+
3551
+ } // namespace detail
3552
+
3553
+ template <typename T>
3554
+ struct from_chars_caller
3555
+ {
3556
+ template <typename UC>
3557
+ FASTFLOAT_CONSTEXPR20
3558
+ static from_chars_result_t<UC> call(UC const * first, UC const * last,
3559
+ T &value, parse_options_t<UC> options) noexcept {
3560
+ return from_chars_advanced(first, last, value, options);
3561
+ }
3562
+ };
3563
+
3564
+ #if __STDCPP_FLOAT32_T__ == 1
3565
+ template <>
3566
+ struct from_chars_caller<std::float32_t>
3567
+ {
3568
+ template <typename UC>
3569
+ FASTFLOAT_CONSTEXPR20
3570
+ static from_chars_result_t<UC> call(UC const * first, UC const * last,
3571
+ std::float32_t &value, parse_options_t<UC> options) noexcept{
3572
+ // if std::float32_t is defined, and we are in C++23 mode; macro set for float32;
3573
+ // set value to float due to equivalence between float and float32_t
3574
+ float val;
3575
+ auto ret = from_chars_advanced(first, last, val, options);
3576
+ value = val;
3577
+ return ret;
3578
+ }
3579
+ };
3580
+ #endif
3581
+
3582
+ #if __STDCPP_FLOAT64_T__ == 1
3583
+ template <>
3584
+ struct from_chars_caller<std::float64_t>
3585
+ {
3586
+ template <typename UC>
3587
+ FASTFLOAT_CONSTEXPR20
3588
+ static from_chars_result_t<UC> call(UC const * first, UC const * last,
3589
+ std::float64_t &value, parse_options_t<UC> options) noexcept{
3590
+ // if std::float64_t is defined, and we are in C++23 mode; macro set for float64;
3591
+ // set value as double due to equivalence between double and float64_t
3592
+ double val;
3593
+ auto ret = from_chars_advanced(first, last, val, options);
3594
+ value = val;
3595
+ return ret;
3596
+ }
3597
+ };
3598
+ #endif
3599
+
3600
+
3601
+ template<typename T, typename UC, typename>
3602
+ FASTFLOAT_CONSTEXPR20
3603
+ from_chars_result_t<UC> from_chars(UC const * first, UC const * last,
3604
+ T &value, chars_format fmt /*= chars_format::general*/) noexcept {
3605
+ return from_chars_caller<T>::call(first, last, value, parse_options_t<UC>(fmt));
3606
+ }
3607
+
3608
+ template<typename T, typename UC>
3609
+ FASTFLOAT_CONSTEXPR20
3610
+ from_chars_result_t<UC> from_chars_advanced(UC const * first, UC const * last,
3611
+ T &value, parse_options_t<UC> options) noexcept {
3612
+
3613
+ static_assert (is_supported_float_type<T>(), "only some floating-point types are supported");
3614
+ static_assert (is_supported_char_type<UC>(), "only char, wchar_t, char16_t and char32_t are supported");
3615
+
3616
+ from_chars_result_t<UC> answer;
3617
+ #ifdef FASTFLOAT_SKIP_WHITE_SPACE // disabled by default
3618
+ while ((first != last) && fast_float::is_space(uint8_t(*first))) {
3619
+ first++;
3620
+ }
3621
+ #endif
3622
+ if (first == last) {
3623
+ answer.ec = std::errc::invalid_argument;
3624
+ answer.ptr = first;
3625
+ return answer;
3626
+ }
3627
+ parsed_number_string_t<UC> pns = parse_number_string<UC>(first, last, options);
3628
+ if (!pns.valid) {
3629
+ if (options.format & chars_format::no_infnan) {
3630
+ answer.ec = std::errc::invalid_argument;
3631
+ answer.ptr = first;
3632
+ return answer;
3633
+ } else {
3634
+ return detail::parse_infnan(first, last, value);
3635
+ }
3636
+ }
3637
+
3638
+ answer.ec = std::errc(); // be optimistic
3639
+ answer.ptr = pns.lastmatch;
3640
+ // The implementation of the Clinger's fast path is convoluted because
3641
+ // we want round-to-nearest in all cases, irrespective of the rounding mode
3642
+ // selected on the thread.
3643
+ // We proceed optimistically, assuming that detail::rounds_to_nearest() returns
3644
+ // true.
3645
+ if (binary_format<T>::min_exponent_fast_path() <= pns.exponent && pns.exponent <= binary_format<T>::max_exponent_fast_path() && !pns.too_many_digits) {
3646
+ // Unfortunately, the conventional Clinger's fast path is only possible
3647
+ // when the system rounds to the nearest float.
3648
+ //
3649
+ // We expect the next branch to almost always be selected.
3650
+ // We could check it first (before the previous branch), but
3651
+ // there might be performance advantages at having the check
3652
+ // be last.
3653
+ if(!cpp20_and_in_constexpr() && detail::rounds_to_nearest()) {
3654
+ // We have that fegetround() == FE_TONEAREST.
3655
+ // Next is Clinger's fast path.
3656
+ if (pns.mantissa <=binary_format<T>::max_mantissa_fast_path()) {
3657
+ value = T(pns.mantissa);
3658
+ if (pns.exponent < 0) { value = value / binary_format<T>::exact_power_of_ten(-pns.exponent); }
3659
+ else { value = value * binary_format<T>::exact_power_of_ten(pns.exponent); }
3660
+ if (pns.negative) { value = -value; }
3661
+ return answer;
3662
+ }
3663
+ } else {
3664
+ // We do not have that fegetround() == FE_TONEAREST.
3665
+ // Next is a modified Clinger's fast path, inspired by Jakub Jelínek's proposal
3666
+ if (pns.exponent >= 0 && pns.mantissa <=binary_format<T>::max_mantissa_fast_path(pns.exponent)) {
3667
+ #if defined(__clang__) || defined(FASTFLOAT_32BIT)
3668
+ // Clang may map 0 to -0.0 when fegetround() == FE_DOWNWARD
3669
+ if(pns.mantissa == 0) {
3670
+ value = pns.negative ? T(-0.) : T(0.);
3671
+ return answer;
3672
+ }
3673
+ #endif
3674
+ value = T(pns.mantissa) * binary_format<T>::exact_power_of_ten(pns.exponent);
3675
+ if (pns.negative) { value = -value; }
3676
+ return answer;
3677
+ }
3678
+ }
3679
+ }
3680
+ adjusted_mantissa am = compute_float<binary_format<T>>(pns.exponent, pns.mantissa);
3681
+ if(pns.too_many_digits && am.power2 >= 0) {
3682
+ if(am != compute_float<binary_format<T>>(pns.exponent, pns.mantissa + 1)) {
3683
+ am = compute_error<binary_format<T>>(pns.exponent, pns.mantissa);
3684
+ }
3685
+ }
3686
+ // If we called compute_float<binary_format<T>>(pns.exponent, pns.mantissa) and we have an invalid power (am.power2 < 0),
3687
+ // then we need to go the long way around again. This is very uncommon.
3688
+ if(am.power2 < 0) { am = digit_comp<T>(pns, am); }
3689
+ to_float(pns.negative, am, value);
3690
+ // Test for over/underflow.
3691
+ if ((pns.mantissa != 0 && am.mantissa == 0 && am.power2 == 0) || am.power2 == binary_format<T>::infinite_power()) {
3692
+ answer.ec = std::errc::result_out_of_range;
3693
+ }
3694
+ return answer;
3695
+ }
3696
+
3697
+
3698
+ template <typename T, typename UC, typename>
3699
+ FASTFLOAT_CONSTEXPR20
3700
+ from_chars_result_t<UC> from_chars(UC const* first, UC const* last, T& value, int base) noexcept {
3701
+ static_assert (is_supported_char_type<UC>(), "only char, wchar_t, char16_t and char32_t are supported");
3702
+
3703
+ from_chars_result_t<UC> answer;
3704
+ #ifdef FASTFLOAT_SKIP_WHITE_SPACE // disabled by default
3705
+ while ((first != last) && fast_float::is_space(uint8_t(*first))) {
3706
+ first++;
3707
+ }
3708
+ #endif
3709
+ if (first == last || base < 2 || base > 36) {
3710
+ answer.ec = std::errc::invalid_argument;
3711
+ answer.ptr = first;
3712
+ return answer;
3713
+ }
3714
+ return parse_int_string(first, last, value, base);
3715
+ }
3716
+
3717
+ } // namespace fast_float
3718
+
3719
+ #endif
3720
+