@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.
- package/LICENSE +23 -0
- package/README.md +954 -2
- package/README.zh-CN.md +578 -0
- package/THIRD_PARTY_NOTICES.md +553 -0
- package/binding.gyp +89 -0
- package/dist/cjs/exceptions/MathArgumentException.d.ts +11 -0
- package/dist/cjs/exceptions/MathArgumentException.js +18 -0
- package/dist/cjs/exceptions/MathCancelledException.d.ts +10 -0
- package/dist/cjs/exceptions/MathCancelledException.js +17 -0
- package/dist/cjs/exceptions/MathDefinitionException.d.ts +11 -0
- package/dist/cjs/exceptions/MathDefinitionException.js +18 -0
- package/dist/cjs/exceptions/MathDivisionByZeroException.d.ts +10 -0
- package/dist/cjs/exceptions/MathDivisionByZeroException.js +17 -0
- package/dist/cjs/exceptions/MathDomainException.d.ts +11 -0
- package/dist/cjs/exceptions/MathDomainException.js +18 -0
- package/dist/cjs/exceptions/MathException.d.ts +19 -0
- package/dist/cjs/exceptions/MathException.js +22 -0
- package/dist/cjs/exceptions/MathNotSupportedException.d.ts +11 -0
- package/dist/cjs/exceptions/MathNotSupportedException.js +18 -0
- package/dist/cjs/exceptions/MathSyntaxException.d.ts +11 -0
- package/dist/cjs/exceptions/MathSyntaxException.js +18 -0
- package/dist/cjs/exceptions/MathTimeoutException.d.ts +10 -0
- package/dist/cjs/exceptions/MathTimeoutException.js +17 -0
- package/dist/cjs/exceptions/MathUnitException.d.ts +11 -0
- package/dist/cjs/exceptions/MathUnitException.js +18 -0
- package/dist/cjs/exceptions/MathUnknownFunctionException.d.ts +12 -0
- package/dist/cjs/exceptions/MathUnknownFunctionException.js +19 -0
- package/dist/cjs/exports/Math.d.ts +28 -0
- package/dist/cjs/exports/Math.js +84 -0
- package/dist/cjs/lib/Addon.d.ts +5 -0
- package/dist/cjs/lib/Addon.js +9 -0
- package/dist/cjs/lib/Context.d.ts +90 -0
- package/dist/cjs/lib/Context.js +134 -0
- package/dist/cjs/lib/Decimal.d.ts +276 -0
- package/dist/cjs/lib/Decimal.js +402 -0
- package/dist/cjs/lib/Defaults.d.ts +273 -0
- package/dist/cjs/lib/Defaults.js +308 -0
- package/dist/cjs/lib/Distribution.d.ts +177 -0
- package/dist/cjs/lib/Distribution.js +196 -0
- package/dist/cjs/lib/Expression.d.ts +791 -0
- package/dist/cjs/lib/Expression.js +991 -0
- package/dist/cjs/lib/ExpressionMatrix.d.ts +284 -0
- package/dist/cjs/lib/ExpressionMatrix.js +412 -0
- package/dist/cjs/lib/LinearAlgebra.d.ts +613 -0
- package/dist/cjs/lib/LinearAlgebra.js +712 -0
- package/dist/cjs/lib/MathScope.d.ts +268 -0
- package/dist/cjs/lib/MathScope.js +316 -0
- package/dist/cjs/lib/MathSet.d.ts +139 -0
- package/dist/cjs/lib/MathSet.js +376 -0
- package/dist/cjs/lib/Matrix.d.ts +212 -0
- package/dist/cjs/lib/Matrix.js +393 -0
- package/dist/cjs/lib/Native.d.ts +80 -0
- package/dist/cjs/lib/Native.js +61 -0
- package/dist/cjs/lib/NumberTheory.d.ts +356 -0
- package/dist/cjs/lib/NumberTheory.js +524 -0
- package/dist/cjs/lib/Numeric.d.ts +363 -0
- package/dist/cjs/lib/Numeric.js +243 -0
- package/dist/cjs/lib/Polynomials.d.ts +140 -0
- package/dist/cjs/lib/Polynomials.js +167 -0
- package/dist/cjs/lib/SparseMatrix.d.ts +125 -0
- package/dist/cjs/lib/SparseMatrix.js +341 -0
- package/dist/cjs/lib/Statistics.d.ts +366 -0
- package/dist/cjs/lib/Statistics.js +380 -0
- package/dist/cjs/lib/Unit.d.ts +342 -0
- package/dist/cjs/lib/Unit.js +1027 -0
- package/dist/cjs/lib/UnitTable.d.ts +39 -0
- package/dist/cjs/lib/UnitTable.js +634 -0
- package/dist/cjs/package.json +1 -0
- package/dist/esm/exceptions/MathArgumentException.js +14 -0
- package/dist/esm/exceptions/MathCancelledException.js +13 -0
- package/dist/esm/exceptions/MathDefinitionException.js +14 -0
- package/dist/esm/exceptions/MathDivisionByZeroException.js +13 -0
- package/dist/esm/exceptions/MathDomainException.js +14 -0
- package/dist/esm/exceptions/MathException.js +18 -0
- package/dist/esm/exceptions/MathNotSupportedException.js +14 -0
- package/dist/esm/exceptions/MathSyntaxException.js +14 -0
- package/dist/esm/exceptions/MathTimeoutException.js +13 -0
- package/dist/esm/exceptions/MathUnitException.js +14 -0
- package/dist/esm/exceptions/MathUnknownFunctionException.js +15 -0
- package/dist/esm/exports/Math.js +26 -0
- package/dist/esm/lib/Addon.js +10 -0
- package/dist/esm/lib/Context.js +128 -0
- package/dist/esm/lib/Decimal.js +397 -0
- package/dist/esm/lib/Defaults.js +290 -0
- package/dist/esm/lib/Distribution.js +191 -0
- package/dist/esm/lib/Expression.js +979 -0
- package/dist/esm/lib/ExpressionMatrix.js +407 -0
- package/dist/esm/lib/LinearAlgebra.js +708 -0
- package/dist/esm/lib/MathScope.js +311 -0
- package/dist/esm/lib/MathSet.js +370 -0
- package/dist/esm/lib/Matrix.js +382 -0
- package/dist/esm/lib/Native.js +56 -0
- package/dist/esm/lib/NumberTheory.js +520 -0
- package/dist/esm/lib/Numeric.js +239 -0
- package/dist/esm/lib/Polynomials.js +163 -0
- package/dist/esm/lib/SparseMatrix.js +332 -0
- package/dist/esm/lib/Statistics.js +376 -0
- package/dist/esm/lib/Unit.js +1018 -0
- package/dist/esm/lib/UnitTable.js +631 -0
- package/dist/types/exceptions/MathArgumentException.d.ts +11 -0
- package/dist/types/exceptions/MathCancelledException.d.ts +10 -0
- package/dist/types/exceptions/MathDefinitionException.d.ts +11 -0
- package/dist/types/exceptions/MathDivisionByZeroException.d.ts +10 -0
- package/dist/types/exceptions/MathDomainException.d.ts +11 -0
- package/dist/types/exceptions/MathException.d.ts +19 -0
- package/dist/types/exceptions/MathNotSupportedException.d.ts +11 -0
- package/dist/types/exceptions/MathSyntaxException.d.ts +11 -0
- package/dist/types/exceptions/MathTimeoutException.d.ts +10 -0
- package/dist/types/exceptions/MathUnitException.d.ts +11 -0
- package/dist/types/exceptions/MathUnknownFunctionException.d.ts +12 -0
- package/dist/types/exports/Math.d.ts +28 -0
- package/dist/types/lib/Addon.d.ts +5 -0
- package/dist/types/lib/Context.d.ts +90 -0
- package/dist/types/lib/Decimal.d.ts +276 -0
- package/dist/types/lib/Defaults.d.ts +273 -0
- package/dist/types/lib/Distribution.d.ts +177 -0
- package/dist/types/lib/Expression.d.ts +791 -0
- package/dist/types/lib/ExpressionMatrix.d.ts +284 -0
- package/dist/types/lib/LinearAlgebra.d.ts +613 -0
- package/dist/types/lib/MathScope.d.ts +268 -0
- package/dist/types/lib/MathSet.d.ts +139 -0
- package/dist/types/lib/Matrix.d.ts +212 -0
- package/dist/types/lib/Native.d.ts +80 -0
- package/dist/types/lib/NumberTheory.d.ts +356 -0
- package/dist/types/lib/Numeric.d.ts +363 -0
- package/dist/types/lib/Polynomials.d.ts +140 -0
- package/dist/types/lib/SparseMatrix.d.ts +125 -0
- package/dist/types/lib/Statistics.d.ts +366 -0
- package/dist/types/lib/Unit.d.ts +342 -0
- package/dist/types/lib/UnitTable.d.ts +39 -0
- package/native/addon.cpp +1374 -0
- package/native/async/Pool.cpp +133 -0
- package/native/async/Pool.h +59 -0
- package/native/config/boost_math_policy.h +26 -0
- package/native/config/mpdecimal/mpdecimal.h +809 -0
- package/native/config/symengine/symengine_config.h +44 -0
- package/native/config/symengine/symengine_export.h +19 -0
- package/native/core/Errors.cpp +77 -0
- package/native/core/Errors.h +72 -0
- package/native/core/Handle.cpp +109 -0
- package/native/core/Handle.h +72 -0
- package/native/core/Scope.cpp +122 -0
- package/native/core/Scope.h +36 -0
- package/native/functions/Functions.cpp +468 -0
- package/native/functions/Functions.h +115 -0
- package/native/functions/Gosper.cpp +429 -0
- package/native/functions/Gosper.h +20 -0
- package/native/functions/SpecialIntegrals.cpp +329 -0
- package/native/functions/SpecialIntegrals.h +53 -0
- package/native/functions/Summation.cpp +645 -0
- package/native/functions/Summation.h +42 -0
- package/native/integrals/Integrals.cpp +1428 -0
- package/native/integrals/Integrals.h +32 -0
- package/native/limits/Gruntz.cpp +1332 -0
- package/native/limits/Gruntz.h +24 -0
- package/native/linalg/Decompositions.cpp +159 -0
- package/native/linalg/Functions.cpp +199 -0
- package/native/linalg/Linalg.cpp +123 -0
- package/native/linalg/Linalg.h +67 -0
- package/native/linalg/LinalgSupport.h +69 -0
- package/native/linalg/Sparse.cpp +172 -0
- package/native/matrix/Matrices.cpp +766 -0
- package/native/matrix/Matrices.h +74 -0
- package/native/ntheory/NumberTheory.cpp +754 -0
- package/native/ntheory/NumberTheory.h +56 -0
- package/native/numeric/Compiled.cpp +93 -0
- package/native/numeric/Compiled.h +49 -0
- package/native/numeric/Integrate.cpp +718 -0
- package/native/numeric/Numeric.h +95 -0
- package/native/numeric/ODE.cpp +542 -0
- package/native/numeric/Roots.cpp +402 -0
- package/native/ops/Decimal.cpp +776 -0
- package/native/ops/Decimal.h +182 -0
- package/native/ops/DecimalComplex.cpp +738 -0
- package/native/ops/DecimalEvaluator.h +79 -0
- package/native/ops/DecimalFunctions.cpp +439 -0
- package/native/ops/DecimalOperations.cpp +236 -0
- package/native/ops/DecimalSpecial.cpp +1028 -0
- package/native/ops/DecimalSupport.h +109 -0
- package/native/ops/Operations.cpp +969 -0
- package/native/ops/Operations.h +120 -0
- package/native/ops/Piecewise.cpp +195 -0
- package/native/ops/Piecewise.h +40 -0
- package/native/parser/Parser.cpp +853 -0
- package/native/parser/Parser.h +56 -0
- package/native/poly/Convert.cpp +210 -0
- package/native/poly/Convert.h +40 -0
- package/native/poly/Dense.cpp +1008 -0
- package/native/poly/Dense.h +136 -0
- package/native/poly/Euclid.cpp +446 -0
- package/native/poly/Euclid.h +44 -0
- package/native/poly/Factor.cpp +919 -0
- package/native/poly/Factor.h +36 -0
- package/native/poly/Galois.cpp +439 -0
- package/native/poly/Galois.h +86 -0
- package/native/poly/Inequalities.cpp +227 -0
- package/native/poly/Inequalities.h +21 -0
- package/native/poly/Poly.cpp +338 -0
- package/native/poly/Poly.h +46 -0
- package/native/poly/Rational.cpp +403 -0
- package/native/poly/Rational.h +33 -0
- package/native/poly/RealRoots.cpp +136 -0
- package/native/poly/RealRoots.h +35 -0
- package/native/printer/Printer.cpp +973 -0
- package/native/printer/Printer.h +23 -0
- package/native/simplify/Simplify.cpp +921 -0
- package/native/simplify/Simplify.h +21 -0
- package/native/stats/Distributions.cpp +392 -0
- package/native/stats/Distributions.h +33 -0
- package/native/stats/Statistics.cpp +255 -0
- package/native/stats/Statistics.h +25 -0
- package/package.json +85 -4
- package/scripts/sources.mjs +35 -0
- package/vendor/PATCHES.md +169 -0
- package/vendor/boost/config/README.md +43 -0
- package/vendor/boost/config/include/boost/config/abi/borland_prefix.hpp +27 -0
- package/vendor/boost/config/include/boost/config/abi/borland_suffix.hpp +12 -0
- package/vendor/boost/config/include/boost/config/abi/msvc_prefix.hpp +22 -0
- package/vendor/boost/config/include/boost/config/abi/msvc_suffix.hpp +8 -0
- package/vendor/boost/config/include/boost/config/abi_prefix.hpp +25 -0
- package/vendor/boost/config/include/boost/config/abi_suffix.hpp +25 -0
- package/vendor/boost/config/include/boost/config/assert_cxx03.hpp +211 -0
- package/vendor/boost/config/include/boost/config/assert_cxx11.hpp +212 -0
- package/vendor/boost/config/include/boost/config/assert_cxx14.hpp +47 -0
- package/vendor/boost/config/include/boost/config/assert_cxx17.hpp +65 -0
- package/vendor/boost/config/include/boost/config/assert_cxx20.hpp +59 -0
- package/vendor/boost/config/include/boost/config/assert_cxx23.hpp +41 -0
- package/vendor/boost/config/include/boost/config/assert_cxx98.hpp +23 -0
- package/vendor/boost/config/include/boost/config/auto_link.hpp +530 -0
- package/vendor/boost/config/include/boost/config/compiler/borland.hpp +342 -0
- package/vendor/boost/config/include/boost/config/compiler/clang.hpp +370 -0
- package/vendor/boost/config/include/boost/config/compiler/clang_version.hpp +98 -0
- package/vendor/boost/config/include/boost/config/compiler/codegear.hpp +389 -0
- package/vendor/boost/config/include/boost/config/compiler/comeau.hpp +59 -0
- package/vendor/boost/config/include/boost/config/compiler/common_edg.hpp +185 -0
- package/vendor/boost/config/include/boost/config/compiler/compaq_cxx.hpp +19 -0
- package/vendor/boost/config/include/boost/config/compiler/cray.hpp +446 -0
- package/vendor/boost/config/include/boost/config/compiler/diab.hpp +26 -0
- package/vendor/boost/config/include/boost/config/compiler/digitalmars.hpp +146 -0
- package/vendor/boost/config/include/boost/config/compiler/gcc.hpp +386 -0
- package/vendor/boost/config/include/boost/config/compiler/gcc_xml.hpp +115 -0
- package/vendor/boost/config/include/boost/config/compiler/greenhills.hpp +28 -0
- package/vendor/boost/config/include/boost/config/compiler/hp_acc.hpp +153 -0
- package/vendor/boost/config/include/boost/config/compiler/intel.hpp +577 -0
- package/vendor/boost/config/include/boost/config/compiler/kai.hpp +33 -0
- package/vendor/boost/config/include/boost/config/compiler/metrowerks.hpp +201 -0
- package/vendor/boost/config/include/boost/config/compiler/mpw.hpp +143 -0
- package/vendor/boost/config/include/boost/config/compiler/nvcc.hpp +64 -0
- package/vendor/boost/config/include/boost/config/compiler/pathscale.hpp +141 -0
- package/vendor/boost/config/include/boost/config/compiler/pgi.hpp +23 -0
- package/vendor/boost/config/include/boost/config/compiler/sgi_mipspro.hpp +29 -0
- package/vendor/boost/config/include/boost/config/compiler/sunpro_cc.hpp +225 -0
- package/vendor/boost/config/include/boost/config/compiler/vacpp.hpp +189 -0
- package/vendor/boost/config/include/boost/config/compiler/visualc.hpp +400 -0
- package/vendor/boost/config/include/boost/config/compiler/xlcpp.hpp +303 -0
- package/vendor/boost/config/include/boost/config/compiler/xlcpp_zos.hpp +174 -0
- package/vendor/boost/config/include/boost/config/detail/cxx_composite.hpp +218 -0
- package/vendor/boost/config/include/boost/config/detail/posix_features.hpp +95 -0
- package/vendor/boost/config/include/boost/config/detail/select_compiler_config.hpp +157 -0
- package/vendor/boost/config/include/boost/config/detail/select_platform_config.hpp +147 -0
- package/vendor/boost/config/include/boost/config/detail/select_stdlib_config.hpp +121 -0
- package/vendor/boost/config/include/boost/config/detail/suffix.hpp +1334 -0
- package/vendor/boost/config/include/boost/config/header_deprecated.hpp +26 -0
- package/vendor/boost/config/include/boost/config/helper_macros.hpp +37 -0
- package/vendor/boost/config/include/boost/config/no_tr1/cmath.hpp +28 -0
- package/vendor/boost/config/include/boost/config/no_tr1/complex.hpp +28 -0
- package/vendor/boost/config/include/boost/config/no_tr1/functional.hpp +28 -0
- package/vendor/boost/config/include/boost/config/no_tr1/memory.hpp +28 -0
- package/vendor/boost/config/include/boost/config/no_tr1/utility.hpp +28 -0
- package/vendor/boost/config/include/boost/config/platform/aix.hpp +33 -0
- package/vendor/boost/config/include/boost/config/platform/amigaos.hpp +15 -0
- package/vendor/boost/config/include/boost/config/platform/beos.hpp +26 -0
- package/vendor/boost/config/include/boost/config/platform/bsd.hpp +83 -0
- package/vendor/boost/config/include/boost/config/platform/cloudabi.hpp +18 -0
- package/vendor/boost/config/include/boost/config/platform/cray.hpp +18 -0
- package/vendor/boost/config/include/boost/config/platform/cygwin.hpp +71 -0
- package/vendor/boost/config/include/boost/config/platform/haiku.hpp +31 -0
- package/vendor/boost/config/include/boost/config/platform/hpux.hpp +87 -0
- package/vendor/boost/config/include/boost/config/platform/irix.hpp +31 -0
- package/vendor/boost/config/include/boost/config/platform/linux.hpp +106 -0
- package/vendor/boost/config/include/boost/config/platform/macos.hpp +87 -0
- package/vendor/boost/config/include/boost/config/platform/qnxnto.hpp +31 -0
- package/vendor/boost/config/include/boost/config/platform/solaris.hpp +31 -0
- package/vendor/boost/config/include/boost/config/platform/symbian.hpp +97 -0
- package/vendor/boost/config/include/boost/config/platform/vms.hpp +25 -0
- package/vendor/boost/config/include/boost/config/platform/vxworks.hpp +422 -0
- package/vendor/boost/config/include/boost/config/platform/wasm.hpp +23 -0
- package/vendor/boost/config/include/boost/config/platform/win32.hpp +90 -0
- package/vendor/boost/config/include/boost/config/platform/zos.hpp +32 -0
- package/vendor/boost/config/include/boost/config/pragma_message.hpp +31 -0
- package/vendor/boost/config/include/boost/config/requires_threads.hpp +92 -0
- package/vendor/boost/config/include/boost/config/stdlib/dinkumware.hpp +324 -0
- package/vendor/boost/config/include/boost/config/stdlib/libcomo.hpp +93 -0
- package/vendor/boost/config/include/boost/config/stdlib/libcpp.hpp +185 -0
- package/vendor/boost/config/include/boost/config/stdlib/libstdcpp3.hpp +482 -0
- package/vendor/boost/config/include/boost/config/stdlib/modena.hpp +79 -0
- package/vendor/boost/config/include/boost/config/stdlib/msl.hpp +98 -0
- package/vendor/boost/config/include/boost/config/stdlib/roguewave.hpp +208 -0
- package/vendor/boost/config/include/boost/config/stdlib/sgi.hpp +168 -0
- package/vendor/boost/config/include/boost/config/stdlib/stlport.hpp +258 -0
- package/vendor/boost/config/include/boost/config/stdlib/vacpp.hpp +74 -0
- package/vendor/boost/config/include/boost/config/stdlib/xlcpp_zos.hpp +61 -0
- package/vendor/boost/config/include/boost/config/user.hpp +133 -0
- package/vendor/boost/config/include/boost/config/warning_disable.hpp +47 -0
- package/vendor/boost/config/include/boost/config/workaround.hpp +310 -0
- package/vendor/boost/config/include/boost/config.hpp +67 -0
- package/vendor/boost/config/include/boost/cstdint.hpp +556 -0
- package/vendor/boost/config/include/boost/cxx11_char_types.hpp +70 -0
- package/vendor/boost/config/include/boost/detail/workaround.hpp +10 -0
- package/vendor/boost/config/include/boost/limits.hpp +146 -0
- package/vendor/boost/config/include/boost/static_assert.hpp +179 -0
- package/vendor/boost/config/include/boost/version.hpp +32 -0
- package/vendor/boost/math/LICENSE +23 -0
- package/vendor/boost/math/README.md +184 -0
- package/vendor/boost/math/include/boost/cstdfloat.hpp +58 -0
- package/vendor/boost/math/include/boost/math/bindings/detail/big_digamma.hpp +297 -0
- package/vendor/boost/math/include/boost/math/bindings/detail/big_lanczos.hpp +777 -0
- package/vendor/boost/math/include/boost/math/bindings/mpfr.hpp +974 -0
- package/vendor/boost/math/include/boost/math/bindings/mpreal.hpp +921 -0
- package/vendor/boost/math/include/boost/math/bindings/rr.hpp +876 -0
- package/vendor/boost/math/include/boost/math/ccmath/abs.hpp +89 -0
- package/vendor/boost/math/include/boost/math/ccmath/ccmath.hpp +45 -0
- package/vendor/boost/math/include/boost/math/ccmath/ceil.hpp +78 -0
- package/vendor/boost/math/include/boost/math/ccmath/copysign.hpp +81 -0
- package/vendor/boost/math/include/boost/math/ccmath/detail/config.hpp +52 -0
- package/vendor/boost/math/include/boost/math/ccmath/detail/swap.hpp +21 -0
- package/vendor/boost/math/include/boost/math/ccmath/div.hpp +86 -0
- package/vendor/boost/math/include/boost/math/ccmath/fabs.hpp +41 -0
- package/vendor/boost/math/include/boost/math/ccmath/fdim.hpp +93 -0
- package/vendor/boost/math/include/boost/math/ccmath/floor.hpp +131 -0
- package/vendor/boost/math/include/boost/math/ccmath/fma.hpp +130 -0
- package/vendor/boost/math/include/boost/math/ccmath/fmax.hpp +89 -0
- package/vendor/boost/math/include/boost/math/ccmath/fmin.hpp +89 -0
- package/vendor/boost/math/include/boost/math/ccmath/fmod.hpp +114 -0
- package/vendor/boost/math/include/boost/math/ccmath/fpclassify.hpp +48 -0
- package/vendor/boost/math/include/boost/math/ccmath/frexp.hpp +101 -0
- package/vendor/boost/math/include/boost/math/ccmath/hypot.hpp +116 -0
- package/vendor/boost/math/include/boost/math/ccmath/ilogb.hpp +60 -0
- package/vendor/boost/math/include/boost/math/ccmath/isfinite.hpp +53 -0
- package/vendor/boost/math/include/boost/math/ccmath/isgreater.hpp +42 -0
- package/vendor/boost/math/include/boost/math/ccmath/isgreaterequal.hpp +42 -0
- package/vendor/boost/math/include/boost/math/ccmath/isinf.hpp +61 -0
- package/vendor/boost/math/include/boost/math/ccmath/isless.hpp +42 -0
- package/vendor/boost/math/include/boost/math/ccmath/islessequal.hpp +42 -0
- package/vendor/boost/math/include/boost/math/ccmath/isnan.hpp +42 -0
- package/vendor/boost/math/include/boost/math/ccmath/isnormal.hpp +47 -0
- package/vendor/boost/math/include/boost/math/ccmath/isunordered.hpp +35 -0
- package/vendor/boost/math/include/boost/math/ccmath/ldexp.hpp +81 -0
- package/vendor/boost/math/include/boost/math/ccmath/logb.hpp +86 -0
- package/vendor/boost/math/include/boost/math/ccmath/modf.hpp +79 -0
- package/vendor/boost/math/include/boost/math/ccmath/next.hpp +458 -0
- package/vendor/boost/math/include/boost/math/ccmath/remainder.hpp +106 -0
- package/vendor/boost/math/include/boost/math/ccmath/round.hpp +179 -0
- package/vendor/boost/math/include/boost/math/ccmath/scalbln.hpp +60 -0
- package/vendor/boost/math/include/boost/math/ccmath/scalbn.hpp +81 -0
- package/vendor/boost/math/include/boost/math/ccmath/signbit.hpp +218 -0
- package/vendor/boost/math/include/boost/math/ccmath/sqrt.hpp +80 -0
- package/vendor/boost/math/include/boost/math/ccmath/trunc.hpp +70 -0
- package/vendor/boost/math/include/boost/math/common_factor.hpp +23 -0
- package/vendor/boost/math/include/boost/math/common_factor_ct.hpp +34 -0
- package/vendor/boost/math/include/boost/math/common_factor_rt.hpp +30 -0
- package/vendor/boost/math/include/boost/math/complex/acos.hpp +245 -0
- package/vendor/boost/math/include/boost/math/complex/acosh.hpp +34 -0
- package/vendor/boost/math/include/boost/math/complex/asin.hpp +252 -0
- package/vendor/boost/math/include/boost/math/complex/asinh.hpp +32 -0
- package/vendor/boost/math/include/boost/math/complex/atan.hpp +36 -0
- package/vendor/boost/math/include/boost/math/complex/atanh.hpp +214 -0
- package/vendor/boost/math/include/boost/math/complex/details.hpp +68 -0
- package/vendor/boost/math/include/boost/math/complex/fabs.hpp +23 -0
- package/vendor/boost/math/include/boost/math/complex.hpp +32 -0
- package/vendor/boost/math/include/boost/math/concepts/distributions.hpp +497 -0
- package/vendor/boost/math/include/boost/math/concepts/real_concept.hpp +400 -0
- package/vendor/boost/math/include/boost/math/concepts/real_type_concept.hpp +119 -0
- package/vendor/boost/math/include/boost/math/concepts/std_real_concept.hpp +427 -0
- package/vendor/boost/math/include/boost/math/constants/calculate_constants.hpp +1117 -0
- package/vendor/boost/math/include/boost/math/constants/constants.hpp +360 -0
- package/vendor/boost/math/include/boost/math/constants/info.hpp +169 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_cmath.hpp +1012 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_complex.hpp +38 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_complex_std.hpp +813 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_iostream.hpp +822 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_limits.hpp +87 -0
- package/vendor/boost/math/include/boost/math/cstdfloat/cstdfloat_types.hpp +441 -0
- package/vendor/boost/math/include/boost/math/differentiation/autodiff.hpp +2061 -0
- package/vendor/boost/math/include/boost/math/differentiation/autodiff_cpp11.hpp +387 -0
- package/vendor/boost/math/include/boost/math/differentiation/autodiff_reverse.hpp +811 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_operator_expressions.hpp +276 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_ops_et.hpp +160 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_basic_ops_no_et.hpp +154 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_comparison_operator_overloads.hpp +167 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_erf_overloads.hpp +234 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_expression_template_base.hpp +258 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_helper_functions.hpp +18 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_memory_management.hpp +462 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_et.hpp +275 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_expressions.hpp +852 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_stl_no_et.hpp +266 -0
- package/vendor/boost/math/include/boost/math/differentiation/detail/reverse_mode_autodiff_utilities.hpp +51 -0
- package/vendor/boost/math/include/boost/math/differentiation/finite_difference.hpp +266 -0
- package/vendor/boost/math/include/boost/math/differentiation/lanczos_smoothing.hpp +591 -0
- package/vendor/boost/math/include/boost/math/distributions/arcsine.hpp +593 -0
- package/vendor/boost/math/include/boost/math/distributions/bernoulli.hpp +349 -0
- package/vendor/boost/math/include/boost/math/distributions/beta.hpp +584 -0
- package/vendor/boost/math/include/boost/math/distributions/binomial.hpp +729 -0
- package/vendor/boost/math/include/boost/math/distributions/cauchy.hpp +379 -0
- package/vendor/boost/math/include/boost/math/distributions/chi_squared.hpp +345 -0
- package/vendor/boost/math/include/boost/math/distributions/complement.hpp +198 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/common_error_handling.hpp +228 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/derived_accessors.hpp +190 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/generic_mode.hpp +145 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/generic_quantile.hpp +100 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_cdf.hpp +101 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_pdf.hpp +490 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/hypergeometric_quantile.hpp +245 -0
- package/vendor/boost/math/include/boost/math/distributions/detail/inv_discrete_quantile.hpp +583 -0
- package/vendor/boost/math/include/boost/math/distributions/empirical_cumulative_distribution_function.hpp +73 -0
- package/vendor/boost/math/include/boost/math/distributions/exponential.hpp +352 -0
- package/vendor/boost/math/include/boost/math/distributions/extreme_value.hpp +388 -0
- package/vendor/boost/math/include/boost/math/distributions/find_location.hpp +141 -0
- package/vendor/boost/math/include/boost/math/distributions/find_scale.hpp +200 -0
- package/vendor/boost/math/include/boost/math/distributions/fisher_f.hpp +393 -0
- package/vendor/boost/math/include/boost/math/distributions/fwd.hpp +171 -0
- package/vendor/boost/math/include/boost/math/distributions/gamma.hpp +396 -0
- package/vendor/boost/math/include/boost/math/distributions/geometric.hpp +571 -0
- package/vendor/boost/math/include/boost/math/distributions/holtsmark.hpp +2518 -0
- package/vendor/boost/math/include/boost/math/distributions/hyperexponential.hpp +641 -0
- package/vendor/boost/math/include/boost/math/distributions/hypergeometric.hpp +313 -0
- package/vendor/boost/math/include/boost/math/distributions/inverse_chi_squared.hpp +398 -0
- package/vendor/boost/math/include/boost/math/distributions/inverse_gamma.hpp +504 -0
- package/vendor/boost/math/include/boost/math/distributions/inverse_gaussian.hpp +566 -0
- package/vendor/boost/math/include/boost/math/distributions/kolmogorov_smirnov.hpp +511 -0
- package/vendor/boost/math/include/boost/math/distributions/landau.hpp +4642 -0
- package/vendor/boost/math/include/boost/math/distributions/laplace.hpp +494 -0
- package/vendor/boost/math/include/boost/math/distributions/logistic.hpp +377 -0
- package/vendor/boost/math/include/boost/math/distributions/lognormal.hpp +361 -0
- package/vendor/boost/math/include/boost/math/distributions/mapairy.hpp +4220 -0
- package/vendor/boost/math/include/boost/math/distributions/negative_binomial.hpp +609 -0
- package/vendor/boost/math/include/boost/math/distributions/non_central_beta.hpp +981 -0
- package/vendor/boost/math/include/boost/math/distributions/non_central_chi_squared.hpp +998 -0
- package/vendor/boost/math/include/boost/math/distributions/non_central_f.hpp +712 -0
- package/vendor/boost/math/include/boost/math/distributions/non_central_t.hpp +1324 -0
- package/vendor/boost/math/include/boost/math/distributions/normal.hpp +368 -0
- package/vendor/boost/math/include/boost/math/distributions/pareto.hpp +508 -0
- package/vendor/boost/math/include/boost/math/distributions/poisson.hpp +563 -0
- package/vendor/boost/math/include/boost/math/distributions/rayleigh.hpp +381 -0
- package/vendor/boost/math/include/boost/math/distributions/saspoint5.hpp +2796 -0
- package/vendor/boost/math/include/boost/math/distributions/skew_normal.hpp +760 -0
- package/vendor/boost/math/include/boost/math/distributions/students_t.hpp +721 -0
- package/vendor/boost/math/include/boost/math/distributions/triangular.hpp +548 -0
- package/vendor/boost/math/include/boost/math/distributions/uniform.hpp +398 -0
- package/vendor/boost/math/include/boost/math/distributions/weibull.hpp +487 -0
- package/vendor/boost/math/include/boost/math/distributions.hpp +58 -0
- package/vendor/boost/math/include/boost/math/filters/daubechies.hpp +99 -0
- package/vendor/boost/math/include/boost/math/interpolators/barycentric_rational.hpp +99 -0
- package/vendor/boost/math/include/boost/math/interpolators/bezier_polynomial.hpp +60 -0
- package/vendor/boost/math/include/boost/math/interpolators/bilinear_uniform.hpp +54 -0
- package/vendor/boost/math/include/boost/math/interpolators/cardinal_cubic_b_spline.hpp +87 -0
- package/vendor/boost/math/include/boost/math/interpolators/cardinal_quadratic_b_spline.hpp +57 -0
- package/vendor/boost/math/include/boost/math/interpolators/cardinal_quintic_b_spline.hpp +62 -0
- package/vendor/boost/math/include/boost/math/interpolators/cardinal_trigonometric.hpp +58 -0
- package/vendor/boost/math/include/boost/math/interpolators/catmull_rom.hpp +310 -0
- package/vendor/boost/math/include/boost/math/interpolators/cubic_b_spline.hpp +90 -0
- package/vendor/boost/math/include/boost/math/interpolators/cubic_hermite.hpp +142 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/barycentric_rational_detail.hpp +215 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/bezier_polynomial_detail.hpp +167 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/bilinear_uniform_detail.hpp +137 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_cubic_b_spline_detail.hpp +331 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_quadratic_b_spline_detail.hpp +208 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_quintic_b_spline_detail.hpp +241 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cardinal_trigonometric_detail.hpp +684 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cubic_b_spline_detail.hpp +330 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/cubic_hermite_detail.hpp +439 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/quintic_hermite_detail.hpp +586 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/septic_hermite_detail.hpp +653 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/vector_barycentric_rational_detail.hpp +196 -0
- package/vendor/boost/math/include/boost/math/interpolators/detail/whittaker_shannon_detail.hpp +128 -0
- package/vendor/boost/math/include/boost/math/interpolators/makima.hpp +178 -0
- package/vendor/boost/math/include/boost/math/interpolators/pchip.hpp +136 -0
- package/vendor/boost/math/include/boost/math/interpolators/quintic_hermite.hpp +143 -0
- package/vendor/boost/math/include/boost/math/interpolators/septic_hermite.hpp +147 -0
- package/vendor/boost/math/include/boost/math/interpolators/vector_barycentric_rational.hpp +82 -0
- package/vendor/boost/math/include/boost/math/interpolators/whittaker_shannon.hpp +47 -0
- package/vendor/boost/math/include/boost/math/octonion.hpp +4254 -0
- package/vendor/boost/math/include/boost/math/optimization/cma_es.hpp +392 -0
- package/vendor/boost/math/include/boost/math/optimization/detail/common.hpp +200 -0
- package/vendor/boost/math/include/boost/math/optimization/detail/differentiable_opt_utilties.hpp +157 -0
- package/vendor/boost/math/include/boost/math/optimization/detail/gradient_opt_base.hpp +92 -0
- package/vendor/boost/math/include/boost/math/optimization/detail/line_search_policies.hpp +206 -0
- package/vendor/boost/math/include/boost/math/optimization/detail/rdiff_optimization_policies.hpp +134 -0
- package/vendor/boost/math/include/boost/math/optimization/differential_evolution.hpp +236 -0
- package/vendor/boost/math/include/boost/math/optimization/gradient_descent.hpp +202 -0
- package/vendor/boost/math/include/boost/math/optimization/gradient_optimizers.hpp +18 -0
- package/vendor/boost/math/include/boost/math/optimization/jso.hpp +465 -0
- package/vendor/boost/math/include/boost/math/optimization/lbfgs.hpp +382 -0
- package/vendor/boost/math/include/boost/math/optimization/minimizer.hpp +336 -0
- package/vendor/boost/math/include/boost/math/optimization/nesterov.hpp +208 -0
- package/vendor/boost/math/include/boost/math/optimization/random_search.hpp +145 -0
- package/vendor/boost/math/include/boost/math/policies/error_handling.hpp +1062 -0
- package/vendor/boost/math/include/boost/math/policies/policy.hpp +1034 -0
- package/vendor/boost/math/include/boost/math/quadrature/detail/exp_sinh_detail.hpp +2002 -0
- package/vendor/boost/math/include/boost/math/quadrature/detail/ooura_fourier_integrals_detail.hpp +692 -0
- package/vendor/boost/math/include/boost/math/quadrature/detail/sinh_sinh_detail.hpp +1353 -0
- package/vendor/boost/math/include/boost/math/quadrature/detail/tanh_sinh_detail.hpp +879 -0
- package/vendor/boost/math/include/boost/math/quadrature/exp_sinh.hpp +180 -0
- package/vendor/boost/math/include/boost/math/quadrature/gauss.hpp +904 -0
- package/vendor/boost/math/include/boost/math/quadrature/gauss_kronrod.hpp +1317 -0
- package/vendor/boost/math/include/boost/math/quadrature/naive_monte_carlo.hpp +469 -0
- package/vendor/boost/math/include/boost/math/quadrature/ooura_fourier_integrals.hpp +68 -0
- package/vendor/boost/math/include/boost/math/quadrature/sinh_sinh.hpp +72 -0
- package/vendor/boost/math/include/boost/math/quadrature/tanh_sinh.hpp +289 -0
- package/vendor/boost/math/include/boost/math/quadrature/trapezoidal.hpp +125 -0
- package/vendor/boost/math/include/boost/math/quadrature/wavelet_transforms.hpp +47 -0
- package/vendor/boost/math/include/boost/math/quaternion.hpp +1190 -0
- package/vendor/boost/math/include/boost/math/special_functions/acosh.hpp +102 -0
- package/vendor/boost/math/include/boost/math/special_functions/airy.hpp +475 -0
- package/vendor/boost/math/include/boost/math/special_functions/asinh.hpp +110 -0
- package/vendor/boost/math/include/boost/math/special_functions/atanh.hpp +116 -0
- package/vendor/boost/math/include/boost/math/special_functions/bernoulli.hpp +149 -0
- package/vendor/boost/math/include/boost/math/special_functions/bessel.hpp +795 -0
- package/vendor/boost/math/include/boost/math/special_functions/bessel_iterators.hpp +187 -0
- package/vendor/boost/math/include/boost/math/special_functions/bessel_prime.hpp +343 -0
- package/vendor/boost/math/include/boost/math/special_functions/beta.hpp +1870 -0
- package/vendor/boost/math/include/boost/math/special_functions/binomial.hpp +87 -0
- package/vendor/boost/math/include/boost/math/special_functions/cardinal_b_spline.hpp +218 -0
- package/vendor/boost/math/include/boost/math/special_functions/cbrt.hpp +215 -0
- package/vendor/boost/math/include/boost/math/special_functions/chebyshev.hpp +314 -0
- package/vendor/boost/math/include/boost/math/special_functions/chebyshev_transform.hpp +237 -0
- package/vendor/boost/math/include/boost/math/special_functions/cos_pi.hpp +128 -0
- package/vendor/boost/math/include/boost/math/special_functions/daubechies_scaling.hpp +491 -0
- package/vendor/boost/math/include/boost/math/special_functions/daubechies_wavelet.hpp +266 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/airy_ai_bi_zero.hpp +222 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bernoulli_details.hpp +629 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_derivatives_linear.hpp +107 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_i0.hpp +550 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_i1.hpp +556 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_ik.hpp +447 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_j0.hpp +192 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_j1.hpp +179 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jn.hpp +127 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy.hpp +603 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_asym.hpp +230 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_derivatives_asym.hpp +141 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_derivatives_series.hpp +219 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_series.hpp +267 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_jy_zero.hpp +643 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_k0.hpp +485 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_k1.hpp +526 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_kn.hpp +91 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_y0.hpp +205 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_y1.hpp +183 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/bessel_yn.hpp +113 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/daubechies_scaling_integer_grid.hpp +244 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/erf_inv.hpp +559 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/fp_traits.hpp +562 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/gamma_inva.hpp +241 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_0F1_bessel.hpp +46 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_addition_theorems_on_z.hpp +293 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_bessel.hpp +768 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_by_ratios.hpp +678 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_cf.hpp +50 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_large_a.hpp +35 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_large_abz.hpp +492 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_negative_b_regions.hpp +521 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_recurrence.hpp +522 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_scaled_series.hpp +60 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_1F1_small_a_negative_b_by_ratio.hpp +70 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_asym.hpp +179 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_cf.hpp +228 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_pFq_checked_series.hpp +687 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_pade.hpp +131 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_rational.hpp +167 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_separated_series.hpp +50 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/hypergeometric_series.hpp +434 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/ibeta_inv_ab.hpp +331 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/ibeta_inverse.hpp +1122 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/iconv.hpp +43 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/igamma_inverse.hpp +587 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/igamma_large.hpp +823 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/lambert_w_lookup_table.ipp +162 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/lanczos_sse2.hpp +238 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/lgamma_small.hpp +569 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/polygamma.hpp +538 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/round_fwd.hpp +87 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/t_distribution_inv.hpp +567 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/unchecked_bernoulli.hpp +1305 -0
- package/vendor/boost/math/include/boost/math/special_functions/detail/unchecked_factorial.hpp +1727 -0
- package/vendor/boost/math/include/boost/math/special_functions/digamma.hpp +631 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_1.hpp +815 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_2.hpp +756 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_3.hpp +374 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_d.hpp +183 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_rc.hpp +112 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_rd.hpp +207 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_rf.hpp +169 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_rg.hpp +130 -0
- package/vendor/boost/math/include/boost/math/special_functions/ellint_rj.hpp +299 -0
- package/vendor/boost/math/include/boost/math/special_functions/erf.hpp +1334 -0
- package/vendor/boost/math/include/boost/math/special_functions/expint.hpp +1614 -0
- package/vendor/boost/math/include/boost/math/special_functions/expm1.hpp +416 -0
- package/vendor/boost/math/include/boost/math/special_functions/factorials.hpp +276 -0
- package/vendor/boost/math/include/boost/math/special_functions/fibonacci.hpp +92 -0
- package/vendor/boost/math/include/boost/math/special_functions/fourier_transform_daubechies.hpp +248 -0
- package/vendor/boost/math/include/boost/math/special_functions/fpclassify.hpp +797 -0
- package/vendor/boost/math/include/boost/math/special_functions/gamma.hpp +2628 -0
- package/vendor/boost/math/include/boost/math/special_functions/gegenbauer.hpp +84 -0
- package/vendor/boost/math/include/boost/math/special_functions/hankel.hpp +186 -0
- package/vendor/boost/math/include/boost/math/special_functions/hermite.hpp +79 -0
- package/vendor/boost/math/include/boost/math/special_functions/heuman_lambda.hpp +97 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_0F1.hpp +116 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_1F0.hpp +69 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_1F1.hpp +822 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_2F0.hpp +163 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypergeometric_pFq.hpp +205 -0
- package/vendor/boost/math/include/boost/math/special_functions/hypot.hpp +148 -0
- package/vendor/boost/math/include/boost/math/special_functions/jacobi.hpp +69 -0
- package/vendor/boost/math/include/boost/math/special_functions/jacobi_elliptic.hpp +319 -0
- package/vendor/boost/math/include/boost/math/special_functions/jacobi_theta.hpp +802 -0
- package/vendor/boost/math/include/boost/math/special_functions/jacobi_zeta.hpp +83 -0
- package/vendor/boost/math/include/boost/math/special_functions/laguerre.hpp +139 -0
- package/vendor/boost/math/include/boost/math/special_functions/lambert_w.hpp +2171 -0
- package/vendor/boost/math/include/boost/math/special_functions/lanczos.hpp +2760 -0
- package/vendor/boost/math/include/boost/math/special_functions/legendre.hpp +380 -0
- package/vendor/boost/math/include/boost/math/special_functions/legendre_stieltjes.hpp +234 -0
- package/vendor/boost/math/include/boost/math/special_functions/log1p.hpp +417 -0
- package/vendor/boost/math/include/boost/math/special_functions/logaddexp.hpp +41 -0
- package/vendor/boost/math/include/boost/math/special_functions/logistic_sigmoid.hpp +46 -0
- package/vendor/boost/math/include/boost/math/special_functions/logit.hpp +56 -0
- package/vendor/boost/math/include/boost/math/special_functions/logsumexp.hpp +60 -0
- package/vendor/boost/math/include/boost/math/special_functions/math_fwd.hpp +1927 -0
- package/vendor/boost/math/include/boost/math/special_functions/modf.hpp +74 -0
- package/vendor/boost/math/include/boost/math/special_functions/next.hpp +886 -0
- package/vendor/boost/math/include/boost/math/special_functions/nonfinite_num_facets.hpp +588 -0
- package/vendor/boost/math/include/boost/math/special_functions/owens_t.hpp +1067 -0
- package/vendor/boost/math/include/boost/math/special_functions/polygamma.hpp +83 -0
- package/vendor/boost/math/include/boost/math/special_functions/pow.hpp +144 -0
- package/vendor/boost/math/include/boost/math/special_functions/powm1.hpp +101 -0
- package/vendor/boost/math/include/boost/math/special_functions/prime.hpp +2433 -0
- package/vendor/boost/math/include/boost/math/special_functions/relative_difference.hpp +134 -0
- package/vendor/boost/math/include/boost/math/special_functions/round.hpp +353 -0
- package/vendor/boost/math/include/boost/math/special_functions/rsqrt.hpp +52 -0
- package/vendor/boost/math/include/boost/math/special_functions/sign.hpp +241 -0
- package/vendor/boost/math/include/boost/math/special_functions/sin_pi.hpp +135 -0
- package/vendor/boost/math/include/boost/math/special_functions/sinc.hpp +123 -0
- package/vendor/boost/math/include/boost/math/special_functions/sinhc.hpp +142 -0
- package/vendor/boost/math/include/boost/math/special_functions/spherical_harmonic.hpp +205 -0
- package/vendor/boost/math/include/boost/math/special_functions/sqrt1pm1.hpp +49 -0
- package/vendor/boost/math/include/boost/math/special_functions/trigamma.hpp +448 -0
- package/vendor/boost/math/include/boost/math/special_functions/trunc.hpp +385 -0
- package/vendor/boost/math/include/boost/math/special_functions/ulp.hpp +102 -0
- package/vendor/boost/math/include/boost/math/special_functions/zeta.hpp +1081 -0
- package/vendor/boost/math/include/boost/math/special_functions.hpp +86 -0
- package/vendor/boost/math/include/boost/math/statistics/anderson_darling.hpp +112 -0
- package/vendor/boost/math/include/boost/math/statistics/bivariate_statistics.hpp +470 -0
- package/vendor/boost/math/include/boost/math/statistics/chatterjee_correlation.hpp +159 -0
- package/vendor/boost/math/include/boost/math/statistics/detail/rank.hpp +140 -0
- package/vendor/boost/math/include/boost/math/statistics/detail/single_pass.hpp +401 -0
- package/vendor/boost/math/include/boost/math/statistics/linear_regression.hpp +133 -0
- package/vendor/boost/math/include/boost/math/statistics/ljung_box.hpp +70 -0
- package/vendor/boost/math/include/boost/math/statistics/runs_test.hpp +121 -0
- package/vendor/boost/math/include/boost/math/statistics/signal_statistics.hpp +350 -0
- package/vendor/boost/math/include/boost/math/statistics/t_test.hpp +275 -0
- package/vendor/boost/math/include/boost/math/statistics/univariate_statistics.hpp +1184 -0
- package/vendor/boost/math/include/boost/math/statistics/z_test.hpp +161 -0
- package/vendor/boost/math/include/boost/math/tools/agm.hpp +47 -0
- package/vendor/boost/math/include/boost/math/tools/array.hpp +41 -0
- package/vendor/boost/math/include/boost/math/tools/assert.hpp +49 -0
- package/vendor/boost/math/include/boost/math/tools/atomic.hpp +50 -0
- package/vendor/boost/math/include/boost/math/tools/big_constant.hpp +110 -0
- package/vendor/boost/math/include/boost/math/tools/bivariate_statistics.hpp +96 -0
- package/vendor/boost/math/include/boost/math/tools/centered_continued_fraction.hpp +173 -0
- package/vendor/boost/math/include/boost/math/tools/cohen_acceleration.hpp +51 -0
- package/vendor/boost/math/include/boost/math/tools/color_maps.hpp +1943 -0
- package/vendor/boost/math/include/boost/math/tools/complex.hpp +115 -0
- package/vendor/boost/math/include/boost/math/tools/concepts.hpp +24 -0
- package/vendor/boost/math/include/boost/math/tools/condition_numbers.hpp +144 -0
- package/vendor/boost/math/include/boost/math/tools/config.hpp +856 -0
- package/vendor/boost/math/include/boost/math/tools/convert_from_string.hpp +85 -0
- package/vendor/boost/math/include/boost/math/tools/cstdint.hpp +107 -0
- package/vendor/boost/math/include/boost/math/tools/cubic_roots.hpp +198 -0
- package/vendor/boost/math/include/boost/math/tools/cxx03_warn.hpp +95 -0
- package/vendor/boost/math/include/boost/math/tools/detail/is_const_iterable.hpp +38 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_10.hpp +84 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_11.hpp +90 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_12.hpp +96 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_13.hpp +102 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_14.hpp +108 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_15.hpp +114 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_16.hpp +120 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_17.hpp +126 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_18.hpp +132 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_19.hpp +138 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_2.hpp +36 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_20.hpp +144 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_3.hpp +42 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_4.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_5.hpp +54 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_6.hpp +60 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_7.hpp +66 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_8.hpp +72 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner1_9.hpp +78 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_10.hpp +90 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_11.hpp +97 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_12.hpp +104 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_13.hpp +111 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_14.hpp +118 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_15.hpp +125 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_16.hpp +132 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_17.hpp +139 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_18.hpp +146 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_19.hpp +153 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_2.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_20.hpp +160 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_3.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_4.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_5.hpp +55 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_6.hpp +62 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_7.hpp +69 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_8.hpp +76 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner2_9.hpp +83 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_10.hpp +156 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_11.hpp +181 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_12.hpp +208 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_13.hpp +237 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_14.hpp +268 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_15.hpp +301 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_16.hpp +336 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_17.hpp +373 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_18.hpp +412 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_19.hpp +453 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_2.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_20.hpp +496 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_3.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_4.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_5.hpp +61 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_6.hpp +76 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_7.hpp +93 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_8.hpp +112 -0
- package/vendor/boost/math/include/boost/math/tools/detail/polynomial_horner3_9.hpp +133 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_10.hpp +138 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_11.hpp +150 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_12.hpp +162 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_13.hpp +174 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_14.hpp +186 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_15.hpp +198 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_16.hpp +210 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_17.hpp +222 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_18.hpp +234 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_19.hpp +246 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_2.hpp +42 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_20.hpp +258 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_3.hpp +54 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_4.hpp +66 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_5.hpp +78 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_6.hpp +90 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_7.hpp +102 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_8.hpp +114 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner1_9.hpp +126 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_10.hpp +144 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_11.hpp +160 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_12.hpp +176 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_13.hpp +192 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_14.hpp +208 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_15.hpp +224 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_16.hpp +240 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_17.hpp +256 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_18.hpp +272 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_19.hpp +288 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_2.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_20.hpp +304 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_3.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_4.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_5.hpp +64 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_6.hpp +80 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_7.hpp +96 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_8.hpp +112 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner2_9.hpp +128 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_10.hpp +396 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_11.hpp +482 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_12.hpp +576 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_13.hpp +678 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_14.hpp +788 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_15.hpp +906 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_16.hpp +1032 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_17.hpp +1166 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_18.hpp +1308 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_19.hpp +1458 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_2.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_20.hpp +1616 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_3.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_4.hpp +48 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_5.hpp +86 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_6.hpp +132 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_7.hpp +186 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_8.hpp +248 -0
- package/vendor/boost/math/include/boost/math/tools/detail/rational_horner3_9.hpp +318 -0
- package/vendor/boost/math/include/boost/math/tools/engel_expansion.hpp +124 -0
- package/vendor/boost/math/include/boost/math/tools/estrin.hpp +72 -0
- package/vendor/boost/math/include/boost/math/tools/fraction.hpp +354 -0
- package/vendor/boost/math/include/boost/math/tools/header_deprecated.hpp +27 -0
- package/vendor/boost/math/include/boost/math/tools/is_constant_evaluated.hpp +51 -0
- package/vendor/boost/math/include/boost/math/tools/is_detected.hpp +56 -0
- package/vendor/boost/math/include/boost/math/tools/is_standalone.hpp +18 -0
- package/vendor/boost/math/include/boost/math/tools/luroth_expansion.hpp +147 -0
- package/vendor/boost/math/include/boost/math/tools/minima.hpp +164 -0
- package/vendor/boost/math/include/boost/math/tools/mp.hpp +423 -0
- package/vendor/boost/math/include/boost/math/tools/norms.hpp +638 -0
- package/vendor/boost/math/include/boost/math/tools/nothrow.hpp +27 -0
- package/vendor/boost/math/include/boost/math/tools/numeric_limits.hpp +888 -0
- package/vendor/boost/math/include/boost/math/tools/numerical_differentiation.hpp +12 -0
- package/vendor/boost/math/include/boost/math/tools/polynomial.hpp +862 -0
- package/vendor/boost/math/include/boost/math/tools/polynomial_gcd.hpp +268 -0
- package/vendor/boost/math/include/boost/math/tools/precision.hpp +418 -0
- package/vendor/boost/math/include/boost/math/tools/promotion.hpp +135 -0
- package/vendor/boost/math/include/boost/math/tools/quartic_roots.hpp +157 -0
- package/vendor/boost/math/include/boost/math/tools/random_vector.hpp +101 -0
- package/vendor/boost/math/include/boost/math/tools/rational.hpp +346 -0
- package/vendor/boost/math/include/boost/math/tools/real_cast.hpp +31 -0
- package/vendor/boost/math/include/boost/math/tools/recurrence.hpp +330 -0
- package/vendor/boost/math/include/boost/math/tools/roots.hpp +1072 -0
- package/vendor/boost/math/include/boost/math/tools/series.hpp +221 -0
- package/vendor/boost/math/include/boost/math/tools/signal_statistics.hpp +353 -0
- package/vendor/boost/math/include/boost/math/tools/simple_continued_fraction.hpp +177 -0
- package/vendor/boost/math/include/boost/math/tools/stats.hpp +87 -0
- package/vendor/boost/math/include/boost/math/tools/test_value.hpp +143 -0
- package/vendor/boost/math/include/boost/math/tools/throw_exception.hpp +43 -0
- package/vendor/boost/math/include/boost/math/tools/toms748_solve.hpp +636 -0
- package/vendor/boost/math/include/boost/math/tools/traits.hpp +140 -0
- package/vendor/boost/math/include/boost/math/tools/tuple.hpp +88 -0
- package/vendor/boost/math/include/boost/math/tools/type_traits.hpp +489 -0
- package/vendor/boost/math/include/boost/math/tools/ulps_plot.hpp +598 -0
- package/vendor/boost/math/include/boost/math/tools/univariate_statistics.hpp +437 -0
- package/vendor/boost/math/include/boost/math/tools/user.hpp +105 -0
- package/vendor/boost/math/include/boost/math/tools/utility.hpp +69 -0
- package/vendor/boost/math/include/boost/math/tools/workaround.hpp +42 -0
- package/vendor/boost/math/include/boost/math/tr1.hpp +1121 -0
- package/vendor/boost/math/include/boost/math/tr1_c_macros.ipp +810 -0
- package/vendor/boost/math/include/boost/math_fwd.hpp +42 -0
- package/vendor/boost/multiprecision/LICENSE +23 -0
- package/vendor/boost/multiprecision/README.md +168 -0
- package/vendor/boost/multiprecision/include/boost/config/abi/borland_prefix.hpp +27 -0
- package/vendor/boost/multiprecision/include/boost/config/abi/borland_suffix.hpp +12 -0
- package/vendor/boost/multiprecision/include/boost/config/abi/msvc_prefix.hpp +22 -0
- package/vendor/boost/multiprecision/include/boost/config/abi/msvc_suffix.hpp +8 -0
- package/vendor/boost/multiprecision/include/boost/config/abi_prefix.hpp +25 -0
- package/vendor/boost/multiprecision/include/boost/config/abi_suffix.hpp +25 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx03.hpp +211 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx11.hpp +212 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx14.hpp +47 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx17.hpp +65 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx20.hpp +59 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx23.hpp +41 -0
- package/vendor/boost/multiprecision/include/boost/config/assert_cxx98.hpp +23 -0
- package/vendor/boost/multiprecision/include/boost/config/auto_link.hpp +530 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/borland.hpp +342 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/clang.hpp +370 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/clang_version.hpp +98 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/codegear.hpp +389 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/comeau.hpp +59 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/common_edg.hpp +185 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/compaq_cxx.hpp +19 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/cray.hpp +446 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/diab.hpp +26 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/digitalmars.hpp +146 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/gcc.hpp +386 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/gcc_xml.hpp +115 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/greenhills.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/hp_acc.hpp +153 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/intel.hpp +577 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/kai.hpp +33 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/metrowerks.hpp +201 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/mpw.hpp +143 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/nvcc.hpp +64 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/pathscale.hpp +141 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/pgi.hpp +23 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/sgi_mipspro.hpp +29 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/sunpro_cc.hpp +225 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/vacpp.hpp +189 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/visualc.hpp +400 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/xlcpp.hpp +303 -0
- package/vendor/boost/multiprecision/include/boost/config/compiler/xlcpp_zos.hpp +174 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/cxx_composite.hpp +218 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/posix_features.hpp +95 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/select_compiler_config.hpp +157 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/select_platform_config.hpp +147 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/select_stdlib_config.hpp +121 -0
- package/vendor/boost/multiprecision/include/boost/config/detail/suffix.hpp +1334 -0
- package/vendor/boost/multiprecision/include/boost/config/header_deprecated.hpp +26 -0
- package/vendor/boost/multiprecision/include/boost/config/helper_macros.hpp +37 -0
- package/vendor/boost/multiprecision/include/boost/config/no_tr1/cmath.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/no_tr1/complex.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/no_tr1/functional.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/no_tr1/memory.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/no_tr1/utility.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/aix.hpp +33 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/amigaos.hpp +15 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/beos.hpp +26 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/bsd.hpp +83 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/cloudabi.hpp +18 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/cray.hpp +18 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/cygwin.hpp +71 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/haiku.hpp +31 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/hpux.hpp +87 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/irix.hpp +31 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/linux.hpp +106 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/macos.hpp +87 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/qnxnto.hpp +31 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/solaris.hpp +31 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/symbian.hpp +97 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/vms.hpp +25 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/vxworks.hpp +422 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/wasm.hpp +23 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/win32.hpp +90 -0
- package/vendor/boost/multiprecision/include/boost/config/platform/zos.hpp +32 -0
- package/vendor/boost/multiprecision/include/boost/config/pragma_message.hpp +31 -0
- package/vendor/boost/multiprecision/include/boost/config/requires_threads.hpp +92 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/dinkumware.hpp +324 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/libcomo.hpp +93 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/libcpp.hpp +185 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/libstdcpp3.hpp +482 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/modena.hpp +79 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/msl.hpp +98 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/roguewave.hpp +208 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/sgi.hpp +168 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/stlport.hpp +258 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/vacpp.hpp +74 -0
- package/vendor/boost/multiprecision/include/boost/config/stdlib/xlcpp_zos.hpp +61 -0
- package/vendor/boost/multiprecision/include/boost/config/user.hpp +133 -0
- package/vendor/boost/multiprecision/include/boost/config/warning_disable.hpp +47 -0
- package/vendor/boost/multiprecision/include/boost/config/workaround.hpp +310 -0
- package/vendor/boost/multiprecision/include/boost/config.hpp +67 -0
- package/vendor/boost/multiprecision/include/boost/cstdint.hpp +556 -0
- package/vendor/boost/multiprecision/include/boost/cxx11_char_types.hpp +70 -0
- package/vendor/boost/multiprecision/include/boost/detail/workaround.hpp +10 -0
- package/vendor/boost/multiprecision/include/boost/limits.hpp +146 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/complex128.hpp +24 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/complex_adaptor.hpp +1049 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/concepts/mp_number_archetypes.hpp +257 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float/io.hpp +700 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float/transcendental.hpp +157 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_bin_float.hpp +2374 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_complex.hpp +12 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_dec_float.hpp +3807 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail.hpp +177 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath.hpp +25 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fabs.hpp +27 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_floor.hpp +116 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fma.hpp +65 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_fpclassify.hpp +52 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_frexp.hpp +93 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_isinf.hpp +24 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_isnan.hpp +21 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_ldexp.hpp +71 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_limits.hpp +218 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_log.hpp +172 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_ccmath_sqrt.hpp +57 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_df_qf/cpp_df_qf_detail_constants.hpp +80 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_double_fp.hpp +2690 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/add.hpp +368 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/add_unsigned.hpp +387 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/bitwise.hpp +896 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/checked.hpp +178 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/comparison.hpp +374 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/cpp_int_config.hpp +161 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/divide.hpp +703 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/import_export.hpp +248 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/intel_intrinsics.hpp +138 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/limits.hpp +292 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/literals.hpp +296 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/misc.hpp +1462 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/multiply.hpp +848 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/serialize.hpp +209 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int/value_pack.hpp +42 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/cpp_int.hpp +2360 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/debug_adaptor.hpp +760 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/assert.hpp +29 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/atomic.hpp +62 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/bitscan.hpp +317 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/check_cpp11_config.hpp +64 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/constexpr.hpp +88 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/default_ops.hpp +4077 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/digits.hpp +49 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/dynamic_array.hpp +44 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/empty_value.hpp +87 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/endian.hpp +35 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/et_ops.hpp +1831 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/float128_functions.hpp +95 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/float_string_cvt.hpp +333 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/fpclassify.hpp +101 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/constants.hpp +289 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/pow.hpp +941 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/trig.hpp +1064 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/functions/trunc.hpp +82 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/generic_interconvert.hpp +687 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/hash.hpp +56 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/integer_ops.hpp +474 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/itos.hpp +39 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/min_max.hpp +106 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/no_et_ops.hpp +661 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/no_exceptions_support.hpp +55 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/number_base.hpp +1656 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/number_compare.hpp +848 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/precision.hpp +313 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/rebind.hpp +19 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/standalone_config.hpp +165 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/static_array.hpp +42 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/string_helpers.hpp +48 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/tables.hpp +80 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/ublas_interop.hpp +75 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/uniform_int_distribution.hpp +212 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/detail/utype_helper.hpp +374 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/eigen.hpp +248 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/float128.hpp +960 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/fwd.hpp +268 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/gmp.hpp +4100 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/integer.hpp +363 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/logged_adaptor.hpp +834 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/miller_rabin.hpp +221 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/mpc.hpp +1721 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/mpfi.hpp +2579 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/mpfr.hpp +3668 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/number.hpp +2491 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/random.hpp +23 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/rational_adaptor.hpp +1289 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/tommath.hpp +1044 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/explicit_conversion.hpp +67 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/extract_exponent_type.hpp +28 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_backend.hpp +91 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_byte_container.hpp +51 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_complex.hpp +22 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_convertible_arithmetic.hpp +51 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_restricted_conversion.hpp +47 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/is_variable_precision.hpp +25 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/max_digits10.hpp +79 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/std_integer_traits.hpp +95 -0
- package/vendor/boost/multiprecision/include/boost/multiprecision/traits/transcendental_reduction_type.hpp +21 -0
- package/vendor/boost/multiprecision/include/boost/static_assert.hpp +179 -0
- package/vendor/boost/multiprecision/include/boost/version.hpp +32 -0
- package/vendor/eigen/COPYING.APACHE +203 -0
- package/vendor/eigen/COPYING.BSD +26 -0
- package/vendor/eigen/COPYING.MPL2 +373 -0
- package/vendor/eigen/COPYING.README +6 -0
- package/vendor/eigen/Eigen/AccelerateSupport +52 -0
- package/vendor/eigen/Eigen/Cholesky +43 -0
- package/vendor/eigen/Eigen/CholmodSupport +48 -0
- package/vendor/eigen/Eigen/Core +451 -0
- package/vendor/eigen/Eigen/Dense +7 -0
- package/vendor/eigen/Eigen/Eigen +2 -0
- package/vendor/eigen/Eigen/Eigenvalues +63 -0
- package/vendor/eigen/Eigen/Geometry +59 -0
- package/vendor/eigen/Eigen/Householder +31 -0
- package/vendor/eigen/Eigen/IterativeLinearSolvers +52 -0
- package/vendor/eigen/Eigen/Jacobi +33 -0
- package/vendor/eigen/Eigen/KLUSupport +43 -0
- package/vendor/eigen/Eigen/LU +46 -0
- package/vendor/eigen/Eigen/MetisSupport +35 -0
- package/vendor/eigen/Eigen/OrderingMethods +73 -0
- package/vendor/eigen/Eigen/PaStiXSupport +51 -0
- package/vendor/eigen/Eigen/PardisoSupport +38 -0
- package/vendor/eigen/Eigen/QR +48 -0
- package/vendor/eigen/Eigen/QtAlignedMalloc +32 -0
- package/vendor/eigen/Eigen/SPQRSupport +41 -0
- package/vendor/eigen/Eigen/SVD +56 -0
- package/vendor/eigen/Eigen/Sparse +33 -0
- package/vendor/eigen/Eigen/SparseCholesky +40 -0
- package/vendor/eigen/Eigen/SparseCore +70 -0
- package/vendor/eigen/Eigen/SparseLU +50 -0
- package/vendor/eigen/Eigen/SparseQR +38 -0
- package/vendor/eigen/Eigen/StdDeque +30 -0
- package/vendor/eigen/Eigen/StdList +29 -0
- package/vendor/eigen/Eigen/StdVector +30 -0
- package/vendor/eigen/Eigen/SuperLUSupport +70 -0
- package/vendor/eigen/Eigen/ThreadPool +80 -0
- package/vendor/eigen/Eigen/UmfPackSupport +42 -0
- package/vendor/eigen/Eigen/Version +14 -0
- package/vendor/eigen/Eigen/src/AccelerateSupport/AccelerateSupport.h +423 -0
- package/vendor/eigen/Eigen/src/AccelerateSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Cholesky/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Cholesky/LDLT.h +649 -0
- package/vendor/eigen/Eigen/src/Cholesky/LLT.h +514 -0
- package/vendor/eigen/Eigen/src/Cholesky/LLT_LAPACKE.h +124 -0
- package/vendor/eigen/Eigen/src/CholmodSupport/CholmodSupport.h +738 -0
- package/vendor/eigen/Eigen/src/CholmodSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Core/ArithmeticSequence.h +239 -0
- package/vendor/eigen/Eigen/src/Core/Array.h +376 -0
- package/vendor/eigen/Eigen/src/Core/ArrayBase.h +213 -0
- package/vendor/eigen/Eigen/src/Core/ArrayWrapper.h +165 -0
- package/vendor/eigen/Eigen/src/Core/Assign.h +80 -0
- package/vendor/eigen/Eigen/src/Core/AssignEvaluator.h +1057 -0
- package/vendor/eigen/Eigen/src/Core/Assign_MKL.h +183 -0
- package/vendor/eigen/Eigen/src/Core/BandMatrix.h +338 -0
- package/vendor/eigen/Eigen/src/Core/Block.h +429 -0
- package/vendor/eigen/Eigen/src/Core/CommaInitializer.h +149 -0
- package/vendor/eigen/Eigen/src/Core/ConditionEstimator.h +173 -0
- package/vendor/eigen/Eigen/src/Core/CoreEvaluators.h +2018 -0
- package/vendor/eigen/Eigen/src/Core/CoreIterators.h +141 -0
- package/vendor/eigen/Eigen/src/Core/CwiseBinaryOp.h +166 -0
- package/vendor/eigen/Eigen/src/Core/CwiseNullaryOp.h +975 -0
- package/vendor/eigen/Eigen/src/Core/CwiseTernaryOp.h +171 -0
- package/vendor/eigen/Eigen/src/Core/CwiseUnaryOp.h +91 -0
- package/vendor/eigen/Eigen/src/Core/CwiseUnaryView.h +167 -0
- package/vendor/eigen/Eigen/src/Core/DenseBase.h +673 -0
- package/vendor/eigen/Eigen/src/Core/DenseCoeffsBase.h +568 -0
- package/vendor/eigen/Eigen/src/Core/DenseStorage.h +573 -0
- package/vendor/eigen/Eigen/src/Core/DeviceWrapper.h +153 -0
- package/vendor/eigen/Eigen/src/Core/Diagonal.h +219 -0
- package/vendor/eigen/Eigen/src/Core/DiagonalMatrix.h +420 -0
- package/vendor/eigen/Eigen/src/Core/DiagonalProduct.h +30 -0
- package/vendor/eigen/Eigen/src/Core/Dot.h +268 -0
- package/vendor/eigen/Eigen/src/Core/EigenBase.h +149 -0
- package/vendor/eigen/Eigen/src/Core/Fill.h +138 -0
- package/vendor/eigen/Eigen/src/Core/FindCoeff.h +464 -0
- package/vendor/eigen/Eigen/src/Core/ForceAlignedAccess.h +127 -0
- package/vendor/eigen/Eigen/src/Core/Fuzzy.h +132 -0
- package/vendor/eigen/Eigen/src/Core/GeneralProduct.h +519 -0
- package/vendor/eigen/Eigen/src/Core/GenericPacketMath.h +1702 -0
- package/vendor/eigen/Eigen/src/Core/GlobalFunctions.h +230 -0
- package/vendor/eigen/Eigen/src/Core/IO.h +233 -0
- package/vendor/eigen/Eigen/src/Core/IndexedView.h +321 -0
- package/vendor/eigen/Eigen/src/Core/InnerProduct.h +260 -0
- package/vendor/eigen/Eigen/src/Core/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Core/Inverse.h +108 -0
- package/vendor/eigen/Eigen/src/Core/Map.h +153 -0
- package/vendor/eigen/Eigen/src/Core/MapBase.h +283 -0
- package/vendor/eigen/Eigen/src/Core/MathFunctions.h +2103 -0
- package/vendor/eigen/Eigen/src/Core/MathFunctionsImpl.h +263 -0
- package/vendor/eigen/Eigen/src/Core/Matrix.h +534 -0
- package/vendor/eigen/Eigen/src/Core/MatrixBase.h +545 -0
- package/vendor/eigen/Eigen/src/Core/NestByValue.h +91 -0
- package/vendor/eigen/Eigen/src/Core/NoAlias.h +102 -0
- package/vendor/eigen/Eigen/src/Core/NumTraits.h +335 -0
- package/vendor/eigen/Eigen/src/Core/PartialReduxEvaluator.h +253 -0
- package/vendor/eigen/Eigen/src/Core/PermutationMatrix.h +555 -0
- package/vendor/eigen/Eigen/src/Core/PlainObjectBase.h +1014 -0
- package/vendor/eigen/Eigen/src/Core/Product.h +307 -0
- package/vendor/eigen/Eigen/src/Core/ProductEvaluators.h +1287 -0
- package/vendor/eigen/Eigen/src/Core/Random.h +207 -0
- package/vendor/eigen/Eigen/src/Core/RandomImpl.h +262 -0
- package/vendor/eigen/Eigen/src/Core/RealView.h +250 -0
- package/vendor/eigen/Eigen/src/Core/Redux.h +535 -0
- package/vendor/eigen/Eigen/src/Core/Ref.h +383 -0
- package/vendor/eigen/Eigen/src/Core/Replicate.h +130 -0
- package/vendor/eigen/Eigen/src/Core/Reshaped.h +398 -0
- package/vendor/eigen/Eigen/src/Core/ReturnByValue.h +111 -0
- package/vendor/eigen/Eigen/src/Core/Reverse.h +202 -0
- package/vendor/eigen/Eigen/src/Core/Select.h +92 -0
- package/vendor/eigen/Eigen/src/Core/SelfAdjointView.h +329 -0
- package/vendor/eigen/Eigen/src/Core/SelfCwiseBinaryOp.h +50 -0
- package/vendor/eigen/Eigen/src/Core/SkewSymmetricMatrix3.h +382 -0
- package/vendor/eigen/Eigen/src/Core/Solve.h +174 -0
- package/vendor/eigen/Eigen/src/Core/SolveTriangular.h +237 -0
- package/vendor/eigen/Eigen/src/Core/SolverBase.h +167 -0
- package/vendor/eigen/Eigen/src/Core/StableNorm.h +217 -0
- package/vendor/eigen/Eigen/src/Core/StlIterators.h +619 -0
- package/vendor/eigen/Eigen/src/Core/Stride.h +114 -0
- package/vendor/eigen/Eigen/src/Core/Swap.h +99 -0
- package/vendor/eigen/Eigen/src/Core/Transpose.h +427 -0
- package/vendor/eigen/Eigen/src/Core/Transpositions.h +323 -0
- package/vendor/eigen/Eigen/src/Core/TriangularMatrix.h +900 -0
- package/vendor/eigen/Eigen/src/Core/VectorBlock.h +83 -0
- package/vendor/eigen/Eigen/src/Core/VectorwiseOp.h +733 -0
- package/vendor/eigen/Eigen/src/Core/Visitor.h +537 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX/Complex.h +565 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX/MathFunctions.h +130 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX/PacketMath.h +3081 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX/Reductions.h +353 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX/TypeCasting.h +308 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/Complex.h +472 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/GemmKernel.h +1245 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/MathFunctions.h +141 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/MathFunctionsFP16.h +75 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/PacketMath.h +3146 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/PacketMathFP16.h +1413 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/Reductions.h +297 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/TrsmKernel.h +1167 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/TrsmUnrolls.inc +1219 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/TypeCasting.h +277 -0
- package/vendor/eigen/Eigen/src/Core/arch/AVX512/TypeCastingFP16.h +130 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/Complex.h +653 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MathFunctions.h +81 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProduct.h +3686 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductCommon.h +205 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductMMA.h +901 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductMMAbfloat16.h +742 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixVectorProduct.inc +2818 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/PacketMath.h +3729 -0
- package/vendor/eigen/Eigen/src/Core/arch/AltiVec/TypeCasting.h +153 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/BFloat16.h +866 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/ConjHelper.h +128 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h +2634 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctionsFwd.h +227 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/Half.h +1091 -0
- package/vendor/eigen/Eigen/src/Core/arch/Default/Settings.h +47 -0
- package/vendor/eigen/Eigen/src/Core/arch/GPU/Complex.h +244 -0
- package/vendor/eigen/Eigen/src/Core/arch/GPU/MathFunctions.h +104 -0
- package/vendor/eigen/Eigen/src/Core/arch/GPU/PacketMath.h +1712 -0
- package/vendor/eigen/Eigen/src/Core/arch/GPU/Tuple.h +268 -0
- package/vendor/eigen/Eigen/src/Core/arch/GPU/TypeCasting.h +77 -0
- package/vendor/eigen/Eigen/src/Core/arch/HIP/hcc/math_constants.h +23 -0
- package/vendor/eigen/Eigen/src/Core/arch/HVX/PacketMath.h +1088 -0
- package/vendor/eigen/Eigen/src/Core/arch/LSX/Complex.h +520 -0
- package/vendor/eigen/Eigen/src/Core/arch/LSX/GeneralBlockPanelKernel.h +23 -0
- package/vendor/eigen/Eigen/src/Core/arch/LSX/MathFunctions.h +43 -0
- package/vendor/eigen/Eigen/src/Core/arch/LSX/PacketMath.h +2866 -0
- package/vendor/eigen/Eigen/src/Core/arch/LSX/TypeCasting.h +526 -0
- package/vendor/eigen/Eigen/src/Core/arch/MSA/Complex.h +620 -0
- package/vendor/eigen/Eigen/src/Core/arch/MSA/MathFunctions.h +379 -0
- package/vendor/eigen/Eigen/src/Core/arch/MSA/PacketMath.h +1237 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/Complex.h +732 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/GeneralBlockPanelKernel.h +243 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/MathFunctions.h +68 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/PacketMath.h +6096 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/TypeCasting.h +1642 -0
- package/vendor/eigen/Eigen/src/Core/arch/NEON/UnaryFunctors.h +57 -0
- package/vendor/eigen/Eigen/src/Core/arch/SSE/Complex.h +503 -0
- package/vendor/eigen/Eigen/src/Core/arch/SSE/MathFunctions.h +88 -0
- package/vendor/eigen/Eigen/src/Core/arch/SSE/PacketMath.h +2384 -0
- package/vendor/eigen/Eigen/src/Core/arch/SSE/Reductions.h +324 -0
- package/vendor/eigen/Eigen/src/Core/arch/SSE/TypeCasting.h +230 -0
- package/vendor/eigen/Eigen/src/Core/arch/SVE/MathFunctions.h +48 -0
- package/vendor/eigen/Eigen/src/Core/arch/SVE/PacketMath.h +674 -0
- package/vendor/eigen/Eigen/src/Core/arch/SVE/TypeCasting.h +52 -0
- package/vendor/eigen/Eigen/src/Core/arch/SYCL/InteropHeaders.h +227 -0
- package/vendor/eigen/Eigen/src/Core/arch/SYCL/MathFunctions.h +303 -0
- package/vendor/eigen/Eigen/src/Core/arch/SYCL/PacketMath.h +576 -0
- package/vendor/eigen/Eigen/src/Core/arch/SYCL/TypeCasting.h +83 -0
- package/vendor/eigen/Eigen/src/Core/arch/ZVector/Complex.h +570 -0
- package/vendor/eigen/Eigen/src/Core/arch/ZVector/MathFunctions.h +244 -0
- package/vendor/eigen/Eigen/src/Core/arch/ZVector/PacketMath.h +1413 -0
- package/vendor/eigen/Eigen/src/Core/functors/AssignmentFunctors.h +174 -0
- package/vendor/eigen/Eigen/src/Core/functors/BinaryFunctors.h +747 -0
- package/vendor/eigen/Eigen/src/Core/functors/NullaryFunctors.h +274 -0
- package/vendor/eigen/Eigen/src/Core/functors/StlFunctors.h +149 -0
- package/vendor/eigen/Eigen/src/Core/functors/TernaryFunctors.h +52 -0
- package/vendor/eigen/Eigen/src/Core/functors/UnaryFunctors.h +1420 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralBlockPanelKernel.h +3153 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix.h +459 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h +330 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h +148 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix_BLAS.h +205 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixVector.h +473 -0
- package/vendor/eigen/Eigen/src/Core/products/GeneralMatrixVector_BLAS.h +139 -0
- package/vendor/eigen/Eigen/src/Core/products/Parallelizer.h +282 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix.h +483 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix_BLAS.h +277 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixVector.h +253 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixVector_BLAS.h +115 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointProduct.h +133 -0
- package/vendor/eigen/Eigen/src/Core/products/SelfadjointRank2Update.h +95 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix.h +397 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix_BLAS.h +325 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixVector.h +347 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularMatrixVector_BLAS.h +275 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix.h +388 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix_BLAS.h +166 -0
- package/vendor/eigen/Eigen/src/Core/products/TriangularSolverVector.h +122 -0
- package/vendor/eigen/Eigen/src/Core/util/Assert.h +158 -0
- package/vendor/eigen/Eigen/src/Core/util/BlasUtil.h +622 -0
- package/vendor/eigen/Eigen/src/Core/util/ConfigureVectorization.h +543 -0
- package/vendor/eigen/Eigen/src/Core/util/Constants.h +598 -0
- package/vendor/eigen/Eigen/src/Core/util/DisableStupidWarnings.h +146 -0
- package/vendor/eigen/Eigen/src/Core/util/EmulateArray.h +270 -0
- package/vendor/eigen/Eigen/src/Core/util/ForwardDeclarations.h +524 -0
- package/vendor/eigen/Eigen/src/Core/util/GpuHipCudaDefines.inc +101 -0
- package/vendor/eigen/Eigen/src/Core/util/GpuHipCudaUndefines.inc +45 -0
- package/vendor/eigen/Eigen/src/Core/util/IndexedViewHelper.h +487 -0
- package/vendor/eigen/Eigen/src/Core/util/IntegralConstant.h +279 -0
- package/vendor/eigen/Eigen/src/Core/util/MKL_support.h +139 -0
- package/vendor/eigen/Eigen/src/Core/util/Macros.h +1346 -0
- package/vendor/eigen/Eigen/src/Core/util/MaxSizeVector.h +139 -0
- package/vendor/eigen/Eigen/src/Core/util/Memory.h +1385 -0
- package/vendor/eigen/Eigen/src/Core/util/Meta.h +760 -0
- package/vendor/eigen/Eigen/src/Core/util/MoreMeta.h +638 -0
- package/vendor/eigen/Eigen/src/Core/util/ReenableStupidWarnings.h +44 -0
- package/vendor/eigen/Eigen/src/Core/util/ReshapedHelper.h +51 -0
- package/vendor/eigen/Eigen/src/Core/util/Serializer.h +209 -0
- package/vendor/eigen/Eigen/src/Core/util/StaticAssert.h +105 -0
- package/vendor/eigen/Eigen/src/Core/util/SymbolicIndex.h +445 -0
- package/vendor/eigen/Eigen/src/Core/util/XprHelper.h +1093 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/ComplexEigenSolver.h +315 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/ComplexSchur.h +442 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/ComplexSchur_LAPACKE.h +95 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/EigenSolver.h +579 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/GeneralizedEigenSolver.h +402 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h +212 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/HessenbergDecomposition.h +356 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h +142 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/RealQZ.h +587 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/RealSchur.h +519 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/RealSchur_LAPACKE.h +83 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h +850 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/SelfAdjointEigenSolver_LAPACKE.h +90 -0
- package/vendor/eigen/Eigen/src/Eigenvalues/Tridiagonalization.h +529 -0
- package/vendor/eigen/Eigen/src/Geometry/AlignedBox.h +485 -0
- package/vendor/eigen/Eigen/src/Geometry/AngleAxis.h +245 -0
- package/vendor/eigen/Eigen/src/Geometry/EulerAngles.h +203 -0
- package/vendor/eigen/Eigen/src/Geometry/Homogeneous.h +453 -0
- package/vendor/eigen/Eigen/src/Geometry/Hyperplane.h +273 -0
- package/vendor/eigen/Eigen/src/Geometry/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Geometry/OrthoMethods.h +257 -0
- package/vendor/eigen/Eigen/src/Geometry/ParametrizedLine.h +232 -0
- package/vendor/eigen/Eigen/src/Geometry/Quaternion.h +930 -0
- package/vendor/eigen/Eigen/src/Geometry/Rotation2D.h +201 -0
- package/vendor/eigen/Eigen/src/Geometry/RotationBase.h +209 -0
- package/vendor/eigen/Eigen/src/Geometry/Scaling.h +195 -0
- package/vendor/eigen/Eigen/src/Geometry/Transform.h +1485 -0
- package/vendor/eigen/Eigen/src/Geometry/Translation.h +204 -0
- package/vendor/eigen/Eigen/src/Geometry/Umeyama.h +161 -0
- package/vendor/eigen/Eigen/src/Geometry/arch/Geometry_SIMD.h +154 -0
- package/vendor/eigen/Eigen/src/Householder/BlockHouseholder.h +115 -0
- package/vendor/eigen/Eigen/src/Householder/Householder.h +154 -0
- package/vendor/eigen/Eigen/src/Householder/HouseholderSequence.h +504 -0
- package/vendor/eigen/Eigen/src/Householder/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/BasicPreconditioners.h +213 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h +220 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/ConjugateGradient.h +217 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteCholesky.h +402 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteLUT.h +449 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/IterativeSolverBase.h +395 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/LeastSquareConjugateGradient.h +193 -0
- package/vendor/eigen/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h +111 -0
- package/vendor/eigen/Eigen/src/Jacobi/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/Jacobi/Jacobi.h +427 -0
- package/vendor/eigen/Eigen/src/KLUSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/KLUSupport/KLUSupport.h +339 -0
- package/vendor/eigen/Eigen/src/LU/Determinant.h +98 -0
- package/vendor/eigen/Eigen/src/LU/FullPivLU.h +826 -0
- package/vendor/eigen/Eigen/src/LU/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/LU/InverseImpl.h +353 -0
- package/vendor/eigen/Eigen/src/LU/PartialPivLU.h +586 -0
- package/vendor/eigen/Eigen/src/LU/PartialPivLU_LAPACKE.h +97 -0
- package/vendor/eigen/Eigen/src/LU/arch/InverseSize4.h +353 -0
- package/vendor/eigen/Eigen/src/MetisSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/MetisSupport/MetisSupport.h +125 -0
- package/vendor/eigen/Eigen/src/OrderingMethods/Amd.h +413 -0
- package/vendor/eigen/Eigen/src/OrderingMethods/Eigen_Colamd.h +1690 -0
- package/vendor/eigen/Eigen/src/OrderingMethods/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/OrderingMethods/Ordering.h +146 -0
- package/vendor/eigen/Eigen/src/PaStiXSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/PaStiXSupport/PaStiXSupport.h +632 -0
- package/vendor/eigen/Eigen/src/PardisoSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/PardisoSupport/PardisoSupport.h +500 -0
- package/vendor/eigen/Eigen/src/QR/ColPivHouseholderQR.h +674 -0
- package/vendor/eigen/Eigen/src/QR/ColPivHouseholderQR_LAPACKE.h +161 -0
- package/vendor/eigen/Eigen/src/QR/CompleteOrthogonalDecomposition.h +648 -0
- package/vendor/eigen/Eigen/src/QR/FullPivHouseholderQR.h +733 -0
- package/vendor/eigen/Eigen/src/QR/HouseholderQR.h +543 -0
- package/vendor/eigen/Eigen/src/QR/HouseholderQR_LAPACKE.h +77 -0
- package/vendor/eigen/Eigen/src/QR/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SPQRSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SPQRSupport/SuiteSparseQRSupport.h +315 -0
- package/vendor/eigen/Eigen/src/SVD/BDCSVD.h +1470 -0
- package/vendor/eigen/Eigen/src/SVD/BDCSVD_LAPACKE.h +174 -0
- package/vendor/eigen/Eigen/src/SVD/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SVD/JacobiSVD.h +846 -0
- package/vendor/eigen/Eigen/src/SVD/JacobiSVD_LAPACKE.h +127 -0
- package/vendor/eigen/Eigen/src/SVD/SVDBase.h +436 -0
- package/vendor/eigen/Eigen/src/SVD/UpperBidiagonalization.h +379 -0
- package/vendor/eigen/Eigen/src/SparseCholesky/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky.h +868 -0
- package/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky_impl.h +388 -0
- package/vendor/eigen/Eigen/src/SparseCore/AmbiVector.h +329 -0
- package/vendor/eigen/Eigen/src/SparseCore/CompressedStorage.h +206 -0
- package/vendor/eigen/Eigen/src/SparseCore/ConservativeSparseSparseProduct.h +308 -0
- package/vendor/eigen/Eigen/src/SparseCore/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseAssign.h +279 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseBlock.h +534 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseColEtree.h +194 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseCompressedBase.h +592 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +938 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseCwiseUnaryOp.h +142 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseDenseProduct.h +314 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseDiagonalProduct.h +138 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseDot.h +100 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseFuzzy.h +31 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseMap.h +295 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseMatrix.h +1876 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseMatrixBase.h +451 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparsePermutation.h +249 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseProduct.h +178 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseRedux.h +47 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseRef.h +370 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseSelfAdjointView.h +613 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseSolverBase.h +115 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseSparseProductWithPruning.h +184 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseTranspose.h +83 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseTriangularView.h +177 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseUtil.h +209 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseVector.h +532 -0
- package/vendor/eigen/Eigen/src/SparseCore/SparseView.h +225 -0
- package/vendor/eigen/Eigen/src/SparseCore/TriangularSolver.h +274 -0
- package/vendor/eigen/Eigen/src/SparseLU/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU.h +969 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLUImpl.h +79 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Memory.h +210 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Structs.h +113 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_SupernodalMatrix.h +319 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_Utils.h +75 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_column_bmod.h +177 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_column_dfs.h +168 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_copy_to_ucol.h +106 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_heap_relax_snode.h +114 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_kernel_bmod.h +133 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_panel_bmod.h +215 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_panel_dfs.h +235 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_pivotL.h +136 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_pruneL.h +130 -0
- package/vendor/eigen/Eigen/src/SparseLU/SparseLU_relax_snode.h +81 -0
- package/vendor/eigen/Eigen/src/SparseQR/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SparseQR/SparseQR.h +706 -0
- package/vendor/eigen/Eigen/src/StlSupport/StdDeque.h +51 -0
- package/vendor/eigen/Eigen/src/StlSupport/StdList.h +50 -0
- package/vendor/eigen/Eigen/src/StlSupport/StdVector.h +51 -0
- package/vendor/eigen/Eigen/src/StlSupport/details.h +82 -0
- package/vendor/eigen/Eigen/src/SuperLUSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/SuperLUSupport/SuperLUSupport.h +929 -0
- package/vendor/eigen/Eigen/src/ThreadPool/Barrier.h +70 -0
- package/vendor/eigen/Eigen/src/ThreadPool/CoreThreadPoolDevice.h +336 -0
- package/vendor/eigen/Eigen/src/ThreadPool/EventCount.h +241 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ForkJoin.h +140 -0
- package/vendor/eigen/Eigen/src/ThreadPool/InternalHeaderCheck.h +4 -0
- package/vendor/eigen/Eigen/src/ThreadPool/NonBlockingThreadPool.h +587 -0
- package/vendor/eigen/Eigen/src/ThreadPool/RunQueue.h +230 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ThreadCancel.h +21 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ThreadEnvironment.h +43 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ThreadLocal.h +289 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ThreadPoolInterface.h +50 -0
- package/vendor/eigen/Eigen/src/ThreadPool/ThreadYield.h +16 -0
- package/vendor/eigen/Eigen/src/UmfPackSupport/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/UmfPackSupport/UmfPackSupport.h +606 -0
- package/vendor/eigen/Eigen/src/misc/Image.h +80 -0
- package/vendor/eigen/Eigen/src/misc/InternalHeaderCheck.h +3 -0
- package/vendor/eigen/Eigen/src/misc/Kernel.h +77 -0
- package/vendor/eigen/Eigen/src/misc/RealSvd2x2.h +53 -0
- package/vendor/eigen/Eigen/src/misc/blas.h +97 -0
- package/vendor/eigen/Eigen/src/misc/lapacke.h +10085 -0
- package/vendor/eigen/Eigen/src/misc/lapacke_helpers.h +163 -0
- package/vendor/eigen/Eigen/src/misc/lapacke_mangling.h +16 -0
- package/vendor/eigen/Eigen/src/plugins/ArrayCwiseBinaryOps.inc +344 -0
- package/vendor/eigen/Eigen/src/plugins/ArrayCwiseUnaryOps.inc +544 -0
- package/vendor/eigen/Eigen/src/plugins/BlockMethods.inc +1370 -0
- package/vendor/eigen/Eigen/src/plugins/CommonCwiseBinaryOps.inc +116 -0
- package/vendor/eigen/Eigen/src/plugins/CommonCwiseUnaryOps.inc +167 -0
- package/vendor/eigen/Eigen/src/plugins/IndexedViewMethods.inc +192 -0
- package/vendor/eigen/Eigen/src/plugins/InternalHeaderCheck.inc +3 -0
- package/vendor/eigen/Eigen/src/plugins/MatrixCwiseBinaryOps.inc +331 -0
- package/vendor/eigen/Eigen/src/plugins/MatrixCwiseUnaryOps.inc +118 -0
- package/vendor/eigen/Eigen/src/plugins/ReshapedMethods.inc +133 -0
- package/vendor/eigen/README.md +5 -0
- package/vendor/mpdecimal/COPYRIGHT.txt +23 -0
- package/vendor/mpdecimal/README.txt +53 -0
- package/vendor/mpdecimal/libmpdec/.objs/README.txt +8 -0
- package/vendor/mpdecimal/libmpdec/.objs/symbols32.exp +343 -0
- package/vendor/mpdecimal/libmpdec/.objs/symbols64.exp +347 -0
- package/vendor/mpdecimal/libmpdec/.pc/libmpdec.pc.in +11 -0
- package/vendor/mpdecimal/libmpdec/.profile/train.sh +35 -0
- package/vendor/mpdecimal/libmpdec/README.txt +84 -0
- package/vendor/mpdecimal/libmpdec/basearith.c +649 -0
- package/vendor/mpdecimal/libmpdec/basearith.h +217 -0
- package/vendor/mpdecimal/libmpdec/bits.h +188 -0
- package/vendor/mpdecimal/libmpdec/constants.c +129 -0
- package/vendor/mpdecimal/libmpdec/constants.h +88 -0
- package/vendor/mpdecimal/libmpdec/context.c +285 -0
- package/vendor/mpdecimal/libmpdec/convolute.c +172 -0
- package/vendor/mpdecimal/libmpdec/convolute.h +48 -0
- package/vendor/mpdecimal/libmpdec/crt.c +178 -0
- package/vendor/mpdecimal/libmpdec/crt.h +45 -0
- package/vendor/mpdecimal/libmpdec/difradix2.c +171 -0
- package/vendor/mpdecimal/libmpdec/difradix2.h +46 -0
- package/vendor/mpdecimal/libmpdec/fnt.c +77 -0
- package/vendor/mpdecimal/libmpdec/fnt.h +46 -0
- package/vendor/mpdecimal/libmpdec/fourstep.c +242 -0
- package/vendor/mpdecimal/libmpdec/fourstep.h +46 -0
- package/vendor/mpdecimal/libmpdec/io.c +1610 -0
- package/vendor/mpdecimal/libmpdec/io.h +61 -0
- package/vendor/mpdecimal/libmpdec/mpalloc.c +347 -0
- package/vendor/mpdecimal/libmpdec/mpalloc.h +53 -0
- package/vendor/mpdecimal/libmpdec/mpdecimal.c +9155 -0
- package/vendor/mpdecimal/libmpdec/mpdecimal.h.in +804 -0
- package/vendor/mpdecimal/libmpdec/mpsignal.c +966 -0
- package/vendor/mpdecimal/libmpdec/numbertheory.c +129 -0
- package/vendor/mpdecimal/libmpdec/numbertheory.h +75 -0
- package/vendor/mpdecimal/libmpdec/sixstep.c +212 -0
- package/vendor/mpdecimal/libmpdec/sixstep.h +46 -0
- package/vendor/mpdecimal/libmpdec/transpose.c +275 -0
- package/vendor/mpdecimal/libmpdec/transpose.h +60 -0
- package/vendor/mpdecimal/libmpdec/typearith.h +661 -0
- package/vendor/mpdecimal/libmpdec/umodarith.h +645 -0
- package/vendor/symengine/AUTHORS +101 -0
- package/vendor/symengine/LICENSE +254 -0
- package/vendor/symengine/README.md +199 -0
- package/vendor/symengine/symengine/add.cpp +508 -0
- package/vendor/symengine/symengine/add.h +187 -0
- package/vendor/symengine/symengine/as_real_imag.cpp +289 -0
- package/vendor/symengine/symengine/assumptions.cpp +202 -0
- package/vendor/symengine/symengine/assumptions.h +47 -0
- package/vendor/symengine/symengine/basic-inl.h +152 -0
- package/vendor/symengine/symengine/basic-methods.inc +9 -0
- package/vendor/symengine/symengine/basic.cpp +110 -0
- package/vendor/symengine/symengine/basic.h +356 -0
- package/vendor/symengine/symengine/complex.cpp +198 -0
- package/vendor/symengine/symengine/complex.h +396 -0
- package/vendor/symengine/symengine/complex_double.cpp +72 -0
- package/vendor/symengine/symengine/complex_double.h +570 -0
- package/vendor/symengine/symengine/complex_mpc.h +406 -0
- package/vendor/symengine/symengine/constants.cpp +130 -0
- package/vendor/symengine/symengine/constants.h +81 -0
- package/vendor/symengine/symengine/cse.cpp +556 -0
- package/vendor/symengine/symengine/cwrapper.h +949 -0
- package/vendor/symengine/symengine/dense_matrix.cpp +2100 -0
- package/vendor/symengine/symengine/derivative.cpp +841 -0
- package/vendor/symengine/symengine/derivative.h +137 -0
- package/vendor/symengine/symengine/dict.cpp +125 -0
- package/vendor/symengine/symengine/dict.h +333 -0
- package/vendor/symengine/symengine/diophantine.cpp +139 -0
- package/vendor/symengine/symengine/diophantine.h +20 -0
- package/vendor/symengine/symengine/eval.cpp +109 -0
- package/vendor/symengine/symengine/eval.h +40 -0
- package/vendor/symengine/symengine/eval_arb.h +31 -0
- package/vendor/symengine/symengine/eval_double.cpp +959 -0
- package/vendor/symengine/symengine/eval_double.h +28 -0
- package/vendor/symengine/symengine/eval_mpc.h +29 -0
- package/vendor/symengine/symengine/eval_mpfr.h +26 -0
- package/vendor/symengine/symengine/expand.cpp +379 -0
- package/vendor/symengine/symengine/expression.cpp +24 -0
- package/vendor/symengine/symengine/expression.h +375 -0
- package/vendor/symengine/symengine/fields.cpp +861 -0
- package/vendor/symengine/symengine/fields.h +647 -0
- package/vendor/symengine/symengine/finitediff.cpp +70 -0
- package/vendor/symengine/symengine/finitediff.h +21 -0
- package/vendor/symengine/symengine/flint_wrapper.h +1010 -0
- package/vendor/symengine/symengine/functions.cpp +3913 -0
- package/vendor/symengine/symengine/functions.h +1321 -0
- package/vendor/symengine/symengine/infinity.cpp +537 -0
- package/vendor/symengine/symengine/infinity.h +118 -0
- package/vendor/symengine/symengine/integer.cpp +153 -0
- package/vendor/symengine/symengine/integer.h +227 -0
- package/vendor/symengine/symengine/interruption.cpp +9 -0
- package/vendor/symengine/symengine/interruption.h +19 -0
- package/vendor/symengine/symengine/lambda_double.h +918 -0
- package/vendor/symengine/symengine/limits.h +35 -0
- package/vendor/symengine/symengine/llvm_double.h +201 -0
- package/vendor/symengine/symengine/logic.cpp +812 -0
- package/vendor/symengine/symengine/logic.h +281 -0
- package/vendor/symengine/symengine/matrices/conjugate_matrix.cpp +139 -0
- package/vendor/symengine/symengine/matrices/conjugate_matrix.h +39 -0
- package/vendor/symengine/symengine/matrices/diagonal_matrix.cpp +79 -0
- package/vendor/symengine/symengine/matrices/diagonal_matrix.h +52 -0
- package/vendor/symengine/symengine/matrices/hadamard_product.cpp +151 -0
- package/vendor/symengine/symengine/matrices/hadamard_product.h +42 -0
- package/vendor/symengine/symengine/matrices/identity_matrix.cpp +63 -0
- package/vendor/symengine/symengine/matrices/identity_matrix.h +40 -0
- package/vendor/symengine/symengine/matrices/immutable_dense_matrix.cpp +143 -0
- package/vendor/symengine/symengine/matrices/immutable_dense_matrix.h +65 -0
- package/vendor/symengine/symengine/matrices/is_diagonal.cpp +115 -0
- package/vendor/symengine/symengine/matrices/is_lower.cpp +110 -0
- package/vendor/symengine/symengine/matrices/is_real.cpp +78 -0
- package/vendor/symengine/symengine/matrices/is_square.cpp +85 -0
- package/vendor/symengine/symengine/matrices/is_symmetric.cpp +112 -0
- package/vendor/symengine/symengine/matrices/is_toeplitz.cpp +104 -0
- package/vendor/symengine/symengine/matrices/is_upper.cpp +108 -0
- package/vendor/symengine/symengine/matrices/is_zero.cpp +81 -0
- package/vendor/symengine/symengine/matrices/matrix_add.cpp +176 -0
- package/vendor/symengine/symengine/matrices/matrix_add.h +42 -0
- package/vendor/symengine/symengine/matrices/matrix_expr.h +19 -0
- package/vendor/symengine/symengine/matrices/matrix_mul.cpp +258 -0
- package/vendor/symengine/symengine/matrices/matrix_mul.h +55 -0
- package/vendor/symengine/symengine/matrices/matrix_symbol.cpp +34 -0
- package/vendor/symengine/symengine/matrices/matrix_symbol.h +41 -0
- package/vendor/symengine/symengine/matrices/size.cpp +121 -0
- package/vendor/symengine/symengine/matrices/size.h +15 -0
- package/vendor/symengine/symengine/matrices/trace.cpp +112 -0
- package/vendor/symengine/symengine/matrices/trace.h +31 -0
- package/vendor/symengine/symengine/matrices/transpose.cpp +126 -0
- package/vendor/symengine/symengine/matrices/transpose.h +39 -0
- package/vendor/symengine/symengine/matrices/zero_matrix.cpp +94 -0
- package/vendor/symengine/symengine/matrices/zero_matrix.h +47 -0
- package/vendor/symengine/symengine/matrix.cpp +33 -0
- package/vendor/symengine/symengine/matrix.h +675 -0
- package/vendor/symengine/symengine/matrix_expressions.h +51 -0
- package/vendor/symengine/symengine/monomials.cpp +33 -0
- package/vendor/symengine/symengine/monomials.h +20 -0
- package/vendor/symengine/symengine/mp_boost.cpp +635 -0
- package/vendor/symengine/symengine/mp_class.h +1286 -0
- package/vendor/symengine/symengine/mp_wrapper.h +510 -0
- package/vendor/symengine/symengine/mul.cpp +629 -0
- package/vendor/symengine/symengine/mul.h +146 -0
- package/vendor/symengine/symengine/nan.cpp +234 -0
- package/vendor/symengine/symengine/nan.h +82 -0
- package/vendor/symengine/symengine/ntheory.cpp +1700 -0
- package/vendor/symengine/symengine/ntheory.h +213 -0
- package/vendor/symengine/symengine/ntheory_funcs.cpp +189 -0
- package/vendor/symengine/symengine/ntheory_funcs.h +78 -0
- package/vendor/symengine/symengine/number.cpp +36 -0
- package/vendor/symengine/symengine/number.h +256 -0
- package/vendor/symengine/symengine/numer_denom.cpp +149 -0
- package/vendor/symengine/symengine/parser/parser.cpp +367 -0
- package/vendor/symengine/symengine/parser/parser.h +56 -0
- package/vendor/symengine/symengine/parser/parser.tab.cc +1495 -0
- package/vendor/symengine/symengine/parser/parser.tab.hh +1410 -0
- package/vendor/symengine/symengine/parser/parser_old.cpp +688 -0
- package/vendor/symengine/symengine/parser/tokenizer.cpp +435 -0
- package/vendor/symengine/symengine/parser/tokenizer.h +35 -0
- package/vendor/symengine/symengine/parser.h +25 -0
- package/vendor/symengine/symengine/polys/basic_conversions.cpp +178 -0
- package/vendor/symengine/symengine/polys/basic_conversions.h +575 -0
- package/vendor/symengine/symengine/polys/cancel.h +39 -0
- package/vendor/symengine/symengine/polys/msymenginepoly.cpp +130 -0
- package/vendor/symengine/symengine/polys/msymenginepoly.h +536 -0
- package/vendor/symengine/symengine/polys/uexprpoly.cpp +90 -0
- package/vendor/symengine/symengine/polys/uexprpoly.h +205 -0
- package/vendor/symengine/symengine/polys/uintpoly.cpp +62 -0
- package/vendor/symengine/symengine/polys/uintpoly.h +134 -0
- package/vendor/symengine/symengine/polys/uintpoly_flint.h +228 -0
- package/vendor/symengine/symengine/polys/uintpoly_piranha.h +373 -0
- package/vendor/symengine/symengine/polys/upolybase.h +769 -0
- package/vendor/symengine/symengine/polys/uratpoly.cpp +59 -0
- package/vendor/symengine/symengine/polys/uratpoly.h +58 -0
- package/vendor/symengine/symengine/polys/usymenginepoly.h +139 -0
- package/vendor/symengine/symengine/pow.cpp +303 -0
- package/vendor/symengine/symengine/pow.h +76 -0
- package/vendor/symengine/symengine/prime_sieve.cpp +143 -0
- package/vendor/symengine/symengine/prime_sieve.h +64 -0
- package/vendor/symengine/symengine/printers/codegen.cpp +716 -0
- package/vendor/symengine/symengine/printers/codegen.h +168 -0
- package/vendor/symengine/symengine/printers/latex.cpp +630 -0
- package/vendor/symengine/symengine/printers/latex.h +76 -0
- package/vendor/symengine/symengine/printers/mathml.cpp +358 -0
- package/vendor/symengine/symengine/printers/mathml.h +62 -0
- package/vendor/symengine/symengine/printers/stringbox.cpp +276 -0
- package/vendor/symengine/symengine/printers/stringbox.h +60 -0
- package/vendor/symengine/symengine/printers/strprinter.cpp +1212 -0
- package/vendor/symengine/symengine/printers/strprinter.h +217 -0
- package/vendor/symengine/symengine/printers/unicode.cpp +730 -0
- package/vendor/symengine/symengine/printers/unicode.h +84 -0
- package/vendor/symengine/symengine/printers.h +46 -0
- package/vendor/symengine/symengine/rational.cpp +365 -0
- package/vendor/symengine/symengine/rational.h +341 -0
- package/vendor/symengine/symengine/real_double.cpp +388 -0
- package/vendor/symengine/symengine/real_double.h +492 -0
- package/vendor/symengine/symengine/real_mpfr.h +379 -0
- package/vendor/symengine/symengine/refine.cpp +213 -0
- package/vendor/symengine/symengine/refine.h +43 -0
- package/vendor/symengine/symengine/rewrite.cpp +235 -0
- package/vendor/symengine/symengine/rings.cpp +107 -0
- package/vendor/symengine/symengine/rings.h +24 -0
- package/vendor/symengine/symengine/serialize-cereal.h +964 -0
- package/vendor/symengine/symengine/series.cpp +85 -0
- package/vendor/symengine/symengine/series.h +727 -0
- package/vendor/symengine/symengine/series_flint.h +214 -0
- package/vendor/symengine/symengine/series_generic.cpp +247 -0
- package/vendor/symengine/symengine/series_generic.h +86 -0
- package/vendor/symengine/symengine/series_piranha.h +95 -0
- package/vendor/symengine/symengine/series_visitor.h +357 -0
- package/vendor/symengine/symengine/set_funcs.cpp +296 -0
- package/vendor/symengine/symengine/sets.cpp +1854 -0
- package/vendor/symengine/symengine/sets.h +696 -0
- package/vendor/symengine/symengine/simplify.cpp +62 -0
- package/vendor/symengine/symengine/simplify.h +34 -0
- package/vendor/symengine/symengine/solve.cpp +665 -0
- package/vendor/symengine/symengine/solve.h +117 -0
- package/vendor/symengine/symengine/sparse_matrix.cpp +776 -0
- package/vendor/symengine/symengine/special_boost.cpp +85 -0
- package/vendor/symengine/symengine/special_double.h +570 -0
- package/vendor/symengine/symengine/subs.h +579 -0
- package/vendor/symengine/symengine/symbol.cpp +88 -0
- package/vendor/symengine/symengine/symbol.h +116 -0
- package/vendor/symengine/symengine/symengine_assert.h +50 -0
- package/vendor/symengine/symengine/symengine_casts.h +139 -0
- package/vendor/symengine/symengine/symengine_exception.h +101 -0
- package/vendor/symengine/symengine/symengine_rcp.cpp +21 -0
- package/vendor/symengine/symengine/symengine_rcp.h +384 -0
- package/vendor/symengine/symengine/test_visitors.cpp +1083 -0
- package/vendor/symengine/symengine/test_visitors.h +466 -0
- package/vendor/symengine/symengine/tribool.h +85 -0
- package/vendor/symengine/symengine/tuple.cpp +47 -0
- package/vendor/symengine/symengine/tuple.h +32 -0
- package/vendor/symengine/symengine/type_codes.inc +139 -0
- package/vendor/symengine/symengine/utilities/cereal/LICENSE +24 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/access.hpp +351 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/adapters.hpp +163 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/binary.hpp +169 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/json.hpp +1024 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/portable_binary.hpp +334 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/archives/xml.hpp +956 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/cereal.hpp +1120 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/helpers.hpp +422 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/polymorphic_impl.hpp +825 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/polymorphic_impl_fwd.hpp +65 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/static_object.hpp +128 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/traits.hpp +1411 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/details/util.hpp +84 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/macros.hpp +156 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/specialize.hpp +139 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/array.hpp +79 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/atomic.hpp +55 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/base_class.hpp +203 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/bitset.hpp +176 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/boost_variant.hpp +164 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/chrono.hpp +72 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/common.hpp +129 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/complex.hpp +56 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/concepts/pair_associative_container.hpp +73 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/deque.hpp +62 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/forward_list.hpp +68 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/functional.hpp +43 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/list.hpp +62 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/map.hpp +36 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/memory.hpp +425 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/optional.hpp +65 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/polymorphic.hpp +483 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/queue.hpp +132 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/set.hpp +103 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/stack.hpp +76 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/string.hpp +61 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/tuple.hpp +123 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/unordered_map.hpp +36 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/unordered_set.hpp +99 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/utility.hpp +47 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/valarray.hpp +89 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/variant.hpp +108 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/types/vector.hpp +112 -0
- package/vendor/symengine/symengine/utilities/cereal/include/cereal/version.hpp +52 -0
- package/vendor/symengine/symengine/utilities/fast_float/include/fast_float/fast_float.h +3720 -0
- package/vendor/symengine/symengine/utilities/stream_fmt.h +25 -0
- package/vendor/symengine/symengine/visitor.cpp +348 -0
- package/vendor/symengine/symengine/visitor.h +425 -0
package/native/addon.cpp
ADDED
|
@@ -0,0 +1,1374 @@
|
|
|
1
|
+
//The addon of @lakutata/math: its functions, given to JavaScript by Node-API (through node-addon-api). The operations
|
|
2
|
+
//that can take long are jobs: their arguments read in the thread of JavaScript, their work done in it (run) or in the
|
|
3
|
+
//pool of the addon (runAsync), their result turned into JavaScript values back in the thread of JavaScript.
|
|
4
|
+
#include <napi.h>
|
|
5
|
+
|
|
6
|
+
#include <cmath>
|
|
7
|
+
#include <cstdint>
|
|
8
|
+
#include <cstring>
|
|
9
|
+
#include <optional>
|
|
10
|
+
#include <iterator>
|
|
11
|
+
#include <limits>
|
|
12
|
+
#include <map>
|
|
13
|
+
#include <mutex>
|
|
14
|
+
#include <unordered_map>
|
|
15
|
+
#include <Eigen/Core>
|
|
16
|
+
#include <symengine/interruption.h>
|
|
17
|
+
#include <symengine/lambda_double.h>
|
|
18
|
+
|
|
19
|
+
#include "async/Pool.h"
|
|
20
|
+
#include "core/Errors.h"
|
|
21
|
+
#include "linalg/Linalg.h"
|
|
22
|
+
#include "matrix/Matrices.h"
|
|
23
|
+
#include "integrals/Integrals.h"
|
|
24
|
+
#include "limits/Gruntz.h"
|
|
25
|
+
#include "poly/Inequalities.h"
|
|
26
|
+
#include "poly/Poly.h"
|
|
27
|
+
#include "numeric/Compiled.h"
|
|
28
|
+
#include "numeric/Numeric.h"
|
|
29
|
+
#include "stats/Distributions.h"
|
|
30
|
+
#include "stats/Statistics.h"
|
|
31
|
+
#include "core/Handle.h"
|
|
32
|
+
#include "core/Scope.h"
|
|
33
|
+
#include "ops/Decimal.h"
|
|
34
|
+
#include "ntheory/NumberTheory.h"
|
|
35
|
+
#include "ops/Operations.h"
|
|
36
|
+
#include "parser/Parser.h"
|
|
37
|
+
#include "printer/Printer.h"
|
|
38
|
+
|
|
39
|
+
using namespace math;
|
|
40
|
+
|
|
41
|
+
namespace {
|
|
42
|
+
|
|
43
|
+
//What a job gives back: its result as a JavaScript value, made in the thread of JavaScript
|
|
44
|
+
using Builder = std::function<Napi::Value(Napi::Env)>;
|
|
45
|
+
using Job = std::function<Builder()>;
|
|
46
|
+
using JobFactory = Job (*)(const Napi::Array &arguments);
|
|
47
|
+
|
|
48
|
+
//Whether the job being made copies the data of its arguments: an asynchronous operation reads them in another thread,
|
|
49
|
+
//after its call has returned (a synchronous one reads them in place). Set by RunAsync around the making of its job
|
|
50
|
+
thread_local bool copyingArguments = false;
|
|
51
|
+
|
|
52
|
+
class CopyingArguments {
|
|
53
|
+
public:
|
|
54
|
+
CopyingArguments()
|
|
55
|
+
{
|
|
56
|
+
copyingArguments = true;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
~CopyingArguments()
|
|
60
|
+
{
|
|
61
|
+
copyingArguments = false;
|
|
62
|
+
}
|
|
63
|
+
};
|
|
64
|
+
|
|
65
|
+
std::string stringAt(const Napi::Array &arguments, uint32_t index, const char *what)
|
|
66
|
+
{
|
|
67
|
+
Napi::Value value = arguments.Get(index);
|
|
68
|
+
if (!value.IsString()) throw MathError(ErrorCode::Argument, std::string(what) + " is not a string");
|
|
69
|
+
return value.As<Napi::String>().Utf8Value();
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
double numberAt(const Napi::Array &arguments, uint32_t index, const char *what)
|
|
73
|
+
{
|
|
74
|
+
Napi::Value value = arguments.Get(index);
|
|
75
|
+
if (!value.IsNumber()) throw MathError(ErrorCode::Argument, std::string(what) + " is not a number");
|
|
76
|
+
return value.As<Napi::Number>().DoubleValue();
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
Expr expressionAt(const Napi::Array &arguments, uint32_t index)
|
|
80
|
+
{
|
|
81
|
+
return unwrapExpression(arguments.Get(index));
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
std::vector<Expr> expressionsAt(const Napi::Array &arguments, uint32_t index)
|
|
85
|
+
{
|
|
86
|
+
Napi::Value value = arguments.Get(index);
|
|
87
|
+
if (!value.IsArray()) throw MathError(ErrorCode::Argument, "Not an array of expressions");
|
|
88
|
+
Napi::Array array = value.As<Napi::Array>();
|
|
89
|
+
std::vector<Expr> expressions;
|
|
90
|
+
for (uint32_t i = 0; i < array.Length(); i++) expressions.push_back(unwrapExpression(array.Get(i)));
|
|
91
|
+
return expressions;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
std::vector<std::string> stringsAt(const Napi::Array &arguments, uint32_t index)
|
|
95
|
+
{
|
|
96
|
+
Napi::Value value = arguments.Get(index);
|
|
97
|
+
if (!value.IsArray()) throw MathError(ErrorCode::Argument, "Not an array of names");
|
|
98
|
+
Napi::Array array = value.As<Napi::Array>();
|
|
99
|
+
std::vector<std::string> strings;
|
|
100
|
+
for (uint32_t i = 0; i < array.Length(); i++) strings.push_back(stringAt(array, i, "A name"));
|
|
101
|
+
return strings;
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
//An integer of JavaScript: a bigint, or a number that is a safe integer (-0 is 0)
|
|
105
|
+
Integer integerOf(const Napi::Value &value, const std::string &what)
|
|
106
|
+
{
|
|
107
|
+
if (value.IsBigInt()) {
|
|
108
|
+
Napi::BigInt big = value.As<Napi::BigInt>();
|
|
109
|
+
int sign = 0;
|
|
110
|
+
size_t count = big.WordCount();
|
|
111
|
+
std::vector<uint64_t> words(std::max<size_t>(count, 1));
|
|
112
|
+
big.ToWords(&sign, &count, words.data());
|
|
113
|
+
//0n has no words (Boost fails on an empty range)
|
|
114
|
+
if (count == 0) return 0;
|
|
115
|
+
//The words of Node-API from the least significant one
|
|
116
|
+
Integer result = 0;
|
|
117
|
+
boost::multiprecision::import_bits(result, words.begin(), words.begin() + count, 64, false);
|
|
118
|
+
return sign ? Integer(-result) : result;
|
|
119
|
+
}
|
|
120
|
+
if (value.IsNumber()) {
|
|
121
|
+
const double number = value.As<Napi::Number>().DoubleValue();
|
|
122
|
+
if (std::isfinite(number) && std::trunc(number) == number && std::fabs(number) <= 9007199254740991.0) return Integer(static_cast<long long>(number));
|
|
123
|
+
}
|
|
124
|
+
throw MathError(ErrorCode::Argument, what + " is not an integer: a bigint, or a number that is a safe integer");
|
|
125
|
+
}
|
|
126
|
+
|
|
127
|
+
Napi::Value bigintValue(Napi::Env env, const Integer &value)
|
|
128
|
+
{
|
|
129
|
+
std::vector<uint64_t> words;
|
|
130
|
+
boost::multiprecision::export_bits(value < 0 ? Integer(-value) : value, std::back_inserter(words), 64, false);
|
|
131
|
+
if (words.empty()) words.push_back(0);
|
|
132
|
+
return Napi::BigInt::New(env, value < 0 ? 1 : 0, words.size(), words.data());
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
Napi::Value numberTheoryValue(Napi::Env env, const NumberTheoryResult &result)
|
|
136
|
+
{
|
|
137
|
+
using Kind = NumberTheoryResult::Kind;
|
|
138
|
+
switch (result.kind) {
|
|
139
|
+
case Kind::Integer:
|
|
140
|
+
return bigintValue(env, result.integers[0]);
|
|
141
|
+
case Kind::Boolean:
|
|
142
|
+
return Napi::Boolean::New(env, result.flag);
|
|
143
|
+
case Kind::Sign:
|
|
144
|
+
return Napi::Number::New(env, result.sign);
|
|
145
|
+
case Kind::Factors: {
|
|
146
|
+
Napi::Array factors = Napi::Array::New(env, result.integers.size() / 2);
|
|
147
|
+
for (size_t i = 0; i + 1 < result.integers.size(); i += 2) {
|
|
148
|
+
Napi::Object factor = Napi::Object::New(env);
|
|
149
|
+
factor.Set("prime", bigintValue(env, result.integers[i]));
|
|
150
|
+
factor.Set("exponent", Napi::Number::New(env, result.integers[i + 1].convert_to<double>()));
|
|
151
|
+
factors.Set(static_cast<uint32_t>(i / 2), factor);
|
|
152
|
+
}
|
|
153
|
+
return factors;
|
|
154
|
+
}
|
|
155
|
+
case Kind::Rational:
|
|
156
|
+
return wrapExpression(env, result.expression);
|
|
157
|
+
case Kind::Integers: {
|
|
158
|
+
Napi::Array integers = Napi::Array::New(env, result.integers.size());
|
|
159
|
+
for (size_t i = 0; i < result.integers.size(); i++) integers.Set(static_cast<uint32_t>(i), bigintValue(env, result.integers[i]));
|
|
160
|
+
return integers;
|
|
161
|
+
}
|
|
162
|
+
case Kind::Missing:
|
|
163
|
+
break;
|
|
164
|
+
}
|
|
165
|
+
return env.Undefined();
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
Builder expressionResult(const Expr &expression)
|
|
169
|
+
{
|
|
170
|
+
return [expression](Napi::Env env) { return wrapExpression(env, expression); };
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
Napi::Value expressionsValue(Napi::Env env, const std::vector<Expr> &expressions)
|
|
174
|
+
{
|
|
175
|
+
Napi::Array array = Napi::Array::New(env, expressions.size());
|
|
176
|
+
for (uint32_t i = 0; i < expressions.size(); i++) array.Set(i, wrapExpression(env, expressions[i]));
|
|
177
|
+
return array;
|
|
178
|
+
}
|
|
179
|
+
|
|
180
|
+
Job expandJob(const Napi::Array &arguments)
|
|
181
|
+
{
|
|
182
|
+
Expr expression = expressionAt(arguments, 0);
|
|
183
|
+
return [expression] { return expressionResult(expandOf(expression)); };
|
|
184
|
+
}
|
|
185
|
+
|
|
186
|
+
Job simplifyJob(const Napi::Array &arguments)
|
|
187
|
+
{
|
|
188
|
+
Expr expression = expressionAt(arguments, 0);
|
|
189
|
+
return [expression] { return expressionResult(simplifyOf(expression)); };
|
|
190
|
+
}
|
|
191
|
+
|
|
192
|
+
Job diffJob(const Napi::Array &arguments)
|
|
193
|
+
{
|
|
194
|
+
Expr expression = expressionAt(arguments, 0);
|
|
195
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
196
|
+
const double times = numberAt(arguments, 2, "The number of derivatives");
|
|
197
|
+
if (times < 1 || times > 1000 || times != std::floor(times)) throw MathError(ErrorCode::Argument, "The number of derivatives is an integer from 1 to 1000");
|
|
198
|
+
return [expression, variable, times] { return expressionResult(differentiate(expression, variable, static_cast<unsigned>(times))); };
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
Job substituteJob(const Napi::Array &arguments)
|
|
202
|
+
{
|
|
203
|
+
Expr expression = expressionAt(arguments, 0);
|
|
204
|
+
Napi::Value pairs = arguments.Get(1);
|
|
205
|
+
if (!pairs.IsArray()) throw MathError(ErrorCode::Argument, "Not an array of values");
|
|
206
|
+
std::vector<std::pair<std::string, Expr>> values;
|
|
207
|
+
Napi::Array array = pairs.As<Napi::Array>();
|
|
208
|
+
for (uint32_t i = 0; i < array.Length(); i++) {
|
|
209
|
+
Napi::Array pair = array.Get(i).As<Napi::Array>();
|
|
210
|
+
values.emplace_back(stringAt(pair, 0, "The variable"), expressionAt(pair, 1));
|
|
211
|
+
}
|
|
212
|
+
return [expression, values] { return expressionResult(substitute(expression, values)); };
|
|
213
|
+
}
|
|
214
|
+
|
|
215
|
+
Job seriesJob(const Napi::Array &arguments)
|
|
216
|
+
{
|
|
217
|
+
Expr expression = expressionAt(arguments, 0);
|
|
218
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
219
|
+
Expr point = expressionAt(arguments, 2);
|
|
220
|
+
const double order = numberAt(arguments, 3, "The order");
|
|
221
|
+
if (order != std::floor(order)) throw MathError(ErrorCode::Argument, "The order of a series is an integer");
|
|
222
|
+
return [expression, variable, point, order] { return expressionResult(seriesOf(expression, variable, point, static_cast<unsigned>(order))); };
|
|
223
|
+
}
|
|
224
|
+
|
|
225
|
+
//Solutions as an object: their kind, their values, their intervals, the text of a set not solved
|
|
226
|
+
Builder solutionsBuilder(const Solutions &solutions)
|
|
227
|
+
{
|
|
228
|
+
return Builder([solutions](Napi::Env env) -> Napi::Value {
|
|
229
|
+
Napi::Object result = Napi::Object::New(env);
|
|
230
|
+
result.Set("kind", solutions.kind);
|
|
231
|
+
result.Set("values", expressionsValue(env, solutions.values));
|
|
232
|
+
Napi::Array intervals = Napi::Array::New(env, solutions.intervals.size());
|
|
233
|
+
for (uint32_t i = 0; i < solutions.intervals.size(); i++) {
|
|
234
|
+
Napi::Object interval = Napi::Object::New(env);
|
|
235
|
+
interval.Set("start", wrapExpression(env, solutions.intervals[i].start));
|
|
236
|
+
interval.Set("end", wrapExpression(env, solutions.intervals[i].end));
|
|
237
|
+
interval.Set("startOpen", solutions.intervals[i].startOpen);
|
|
238
|
+
interval.Set("endOpen", solutions.intervals[i].endOpen);
|
|
239
|
+
intervals.Set(i, interval);
|
|
240
|
+
}
|
|
241
|
+
result.Set("intervals", intervals);
|
|
242
|
+
if (!solutions.text.empty()) result.Set("text", solutions.text);
|
|
243
|
+
return result;
|
|
244
|
+
});
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
Job solveJob(const Napi::Array &arguments)
|
|
248
|
+
{
|
|
249
|
+
Expr expression = expressionAt(arguments, 0);
|
|
250
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
251
|
+
const bool real = arguments.Get(2).ToBoolean().Value();
|
|
252
|
+
return [expression, variable, real] {
|
|
253
|
+
return solutionsBuilder(solveOf(expression, variable, real));
|
|
254
|
+
};
|
|
255
|
+
}
|
|
256
|
+
|
|
257
|
+
//An antiderivative of an expression in a variable, or its definite integral between two values
|
|
258
|
+
Job integralJob(const Napi::Array &arguments)
|
|
259
|
+
{
|
|
260
|
+
Expr expression = expressionAt(arguments, 0);
|
|
261
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
262
|
+
if (arguments.Length() < 4) return [expression, variable] { return expressionResult(antiderivativeOf(expression, variable)); };
|
|
263
|
+
Expr from = expressionAt(arguments, 2), to = expressionAt(arguments, 3);
|
|
264
|
+
return [expression, variable, from, to] { return expressionResult(definiteIntegralOf(expression, variable, from, to)); };
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
//The Laplace transform of an expression (its variable, the variable of the transform), or its inverse
|
|
268
|
+
Job laplaceJob(const Napi::Array &arguments)
|
|
269
|
+
{
|
|
270
|
+
Expr expression = expressionAt(arguments, 0);
|
|
271
|
+
std::string from = stringAt(arguments, 1, "The variable"), to = stringAt(arguments, 2, "The variable of the transform");
|
|
272
|
+
const bool inverse = arguments.Length() > 3 && arguments.Get(3u).ToBoolean().Value();
|
|
273
|
+
return [expression, from, to, inverse] { return expressionResult(inverse ? inverseLaplaceOf(expression, from, to) : laplaceOf(expression, from, to)); };
|
|
274
|
+
}
|
|
275
|
+
|
|
276
|
+
//The limit of an expression for a variable going to a point, from a direction
|
|
277
|
+
Job limitJob(const Napi::Array &arguments)
|
|
278
|
+
{
|
|
279
|
+
Expr expression = expressionAt(arguments, 0);
|
|
280
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
281
|
+
Expr point = expressionAt(arguments, 2);
|
|
282
|
+
std::string direction = stringAt(arguments, 3, "The direction");
|
|
283
|
+
return [expression, variable, point, direction] { return expressionResult(limitOf(expression, variable, point, direction)); };
|
|
284
|
+
}
|
|
285
|
+
|
|
286
|
+
//expression < 0 (or <=, >, >=) solved for a variable in the real numbers
|
|
287
|
+
Job inequalityJob(const Napi::Array &arguments)
|
|
288
|
+
{
|
|
289
|
+
Expr expression = expressionAt(arguments, 0);
|
|
290
|
+
std::string relation = stringAt(arguments, 1, "The relation");
|
|
291
|
+
std::string variable = stringAt(arguments, 2, "The variable");
|
|
292
|
+
return [expression, relation, variable] {
|
|
293
|
+
return solutionsBuilder(inequalityOf(expression, relation, variable));
|
|
294
|
+
};
|
|
295
|
+
}
|
|
296
|
+
|
|
297
|
+
Job solveLinearJob(const Napi::Array &arguments)
|
|
298
|
+
{
|
|
299
|
+
std::vector<Expr> equations = expressionsAt(arguments, 0);
|
|
300
|
+
std::vector<std::string> variables = stringsAt(arguments, 1);
|
|
301
|
+
return [equations, variables] {
|
|
302
|
+
LinearSolution solution = solveLinearOf(equations, variables);
|
|
303
|
+
return Builder([solution](Napi::Env env) -> Napi::Value {
|
|
304
|
+
Napi::Object result = Napi::Object::New(env);
|
|
305
|
+
result.Set("kind", solution.kind);
|
|
306
|
+
Napi::Object values = Napi::Object::New(env);
|
|
307
|
+
for (const auto &[name, value] : solution.values) values.Set(name, wrapExpression(env, value));
|
|
308
|
+
result.Set("values", values);
|
|
309
|
+
return result;
|
|
310
|
+
});
|
|
311
|
+
};
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
Job equalsJob(const Napi::Array &arguments)
|
|
315
|
+
{
|
|
316
|
+
Expr a = expressionAt(arguments, 0);
|
|
317
|
+
Expr b = expressionAt(arguments, 1);
|
|
318
|
+
return [a, b] {
|
|
319
|
+
const bool equal = equalsOf(a, b);
|
|
320
|
+
return Builder([equal](Napi::Env env) { return Napi::Boolean::New(env, equal); });
|
|
321
|
+
};
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
Job decimalJob(const Napi::Array &arguments)
|
|
325
|
+
{
|
|
326
|
+
Expr expression = expressionAt(arguments, 0);
|
|
327
|
+
const double digits = numberAt(arguments, 1, "The number of digits");
|
|
328
|
+
if (digits != std::floor(digits) || digits < 1 || digits > 100000) throw MathError(ErrorCode::Argument, "The number of digits is from 1 to 100000");
|
|
329
|
+
return [expression, digits] {
|
|
330
|
+
std::string text = toDecimal(expression, static_cast<long>(digits));
|
|
331
|
+
return Builder([text](Napi::Env env) { return Napi::String::New(env, text); });
|
|
332
|
+
};
|
|
333
|
+
}
|
|
334
|
+
|
|
335
|
+
Job complexDecimalJob(const Napi::Array &arguments)
|
|
336
|
+
{
|
|
337
|
+
Expr expression = expressionAt(arguments, 0);
|
|
338
|
+
const double digits = numberAt(arguments, 1, "The number of digits");
|
|
339
|
+
if (digits != std::floor(digits) || digits < 1 || digits > 100000) throw MathError(ErrorCode::Argument, "The number of digits is from 1 to 100000");
|
|
340
|
+
return [expression, digits] {
|
|
341
|
+
const std::pair<std::string, std::string> parts = toComplexDecimal(expression, static_cast<long>(digits));
|
|
342
|
+
return Builder([parts](Napi::Env env) {
|
|
343
|
+
Napi::Array result = Napi::Array::New(env, 2);
|
|
344
|
+
result.Set(0u, Napi::String::New(env, parts.first));
|
|
345
|
+
result.Set(1u, Napi::String::New(env, parts.second));
|
|
346
|
+
return result;
|
|
347
|
+
});
|
|
348
|
+
};
|
|
349
|
+
}
|
|
350
|
+
|
|
351
|
+
//decimalOperation(operation, precision, ...values): an operation of the Decimal class, its values as texts
|
|
352
|
+
Job decimalOperationJob(const Napi::Array &arguments)
|
|
353
|
+
{
|
|
354
|
+
std::string operation = stringAt(arguments, 0, "The operation");
|
|
355
|
+
const double precision = numberAt(arguments, 1, "The precision");
|
|
356
|
+
if (precision != std::floor(precision) || precision < 1 || precision > 100000) throw MathError(ErrorCode::Argument, "The precision is an integer from 1 to 100000");
|
|
357
|
+
std::vector<std::string> values;
|
|
358
|
+
for (uint32_t i = 2; i < arguments.Length(); i++) values.push_back(stringAt(arguments, i, "A decimal"));
|
|
359
|
+
return [operation, precision, values] {
|
|
360
|
+
std::string text = decimalOperation(operation, static_cast<long>(precision), values);
|
|
361
|
+
return Builder([text](Napi::Env env) { return Napi::String::New(env, text); });
|
|
362
|
+
};
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
//Whether the elements of a typed array are aligned for their type: V8 with pointer compression (Electron) may keep the
|
|
366
|
+
//elements of a small typed array in its heap 4-byte aligned, where Eigen's maps assert ("data is not scalar-aligned")
|
|
367
|
+
//and reads of their type are not defined
|
|
368
|
+
template <typename T>
|
|
369
|
+
bool aligned(const T *data)
|
|
370
|
+
{
|
|
371
|
+
return reinterpret_cast<std::uintptr_t>(data) % alignof(T) == 0;
|
|
372
|
+
}
|
|
373
|
+
|
|
374
|
+
//The elements of a typed array, copied by their bytes (aligned or not)
|
|
375
|
+
template <typename T>
|
|
376
|
+
std::vector<T> elementsOf(const Napi::TypedArrayOf<T> &array)
|
|
377
|
+
{
|
|
378
|
+
std::vector<T> elements(array.ElementLength());
|
|
379
|
+
if (!elements.empty()) std::memcpy(elements.data(), array.Data(), elements.size() * sizeof(T));
|
|
380
|
+
return elements;
|
|
381
|
+
}
|
|
382
|
+
|
|
383
|
+
//A matrix given as [rows, columns, Float64Array] (its elements row-major)
|
|
384
|
+
MatrixArgument matrixArgumentOf(const Napi::Value &value)
|
|
385
|
+
{
|
|
386
|
+
if (!value.IsArray()) throw MathError(ErrorCode::Argument, "A matrix is given as [rows, columns, Float64Array]");
|
|
387
|
+
const Napi::Array parts = value.As<Napi::Array>();
|
|
388
|
+
const Napi::Value rows = parts.Get(0u), columns = parts.Get(1u), data = parts.Get(2u);
|
|
389
|
+
auto dimension = [](const Napi::Value &number) {
|
|
390
|
+
if (!number.IsNumber()) throw MathError(ErrorCode::Argument, "A dimension of a matrix is not a number");
|
|
391
|
+
const double size = number.As<Napi::Number>().DoubleValue();
|
|
392
|
+
if (size != std::floor(size) || size < 0 || size > 4294967295.0) throw MathError(ErrorCode::Argument, "A dimension of a matrix is not an integer of 0 or more");
|
|
393
|
+
return static_cast<size_t>(size);
|
|
394
|
+
};
|
|
395
|
+
MatrixArgument matrix;
|
|
396
|
+
matrix.rows = dimension(rows);
|
|
397
|
+
matrix.columns = dimension(columns);
|
|
398
|
+
if (!data.IsTypedArray() || data.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The elements of a matrix are not a Float64Array");
|
|
399
|
+
const Napi::Float64Array elements = data.As<Napi::Float64Array>();
|
|
400
|
+
if (static_cast<double>(elements.ElementLength()) != static_cast<double>(matrix.rows) * static_cast<double>(matrix.columns)) {
|
|
401
|
+
throw MathError(ErrorCode::Argument, "A matrix of " + std::to_string(matrix.rows) + "×" + std::to_string(matrix.columns) + " has " + std::to_string(elements.ElementLength()) + " elements");
|
|
402
|
+
}
|
|
403
|
+
if (copyingArguments || !aligned(elements.Data())) {
|
|
404
|
+
matrix.owned = std::make_shared<const std::vector<double>>(elementsOf(elements));
|
|
405
|
+
matrix.values = matrix.owned->data();
|
|
406
|
+
} else {
|
|
407
|
+
matrix.values = elements.Data();
|
|
408
|
+
}
|
|
409
|
+
return matrix;
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
//linalg(operation, matrices, numbers?, option?): an operation of the linear algebra; its results as [rows, columns,
|
|
413
|
+
//Float64Array]
|
|
414
|
+
Job linalgJob(const Napi::Array &arguments)
|
|
415
|
+
{
|
|
416
|
+
std::string operation = stringAt(arguments, 0, "The operation");
|
|
417
|
+
const Napi::Value list = arguments.Get(1u);
|
|
418
|
+
if (!list.IsArray()) throw MathError(ErrorCode::Argument, "The matrices of an operation are an array");
|
|
419
|
+
std::vector<MatrixArgument> matrices;
|
|
420
|
+
const Napi::Array given = list.As<Napi::Array>();
|
|
421
|
+
for (uint32_t i = 0; i < given.Length(); i++) matrices.push_back(matrixArgumentOf(given.Get(i)));
|
|
422
|
+
std::vector<double> numbers;
|
|
423
|
+
if (arguments.Length() > 2 && arguments.Get(2u).IsArray()) {
|
|
424
|
+
const Napi::Array values = arguments.Get(2u).As<Napi::Array>();
|
|
425
|
+
for (uint32_t i = 0; i < values.Length(); i++) numbers.push_back(numberAt(values, i, "An option"));
|
|
426
|
+
}
|
|
427
|
+
std::string option = arguments.Length() > 3 && arguments.Get(3u).IsString() ? arguments.Get(3u).As<Napi::String>().Utf8Value() : std::string();
|
|
428
|
+
return [operation, matrices, numbers, option] {
|
|
429
|
+
auto results = std::make_shared<std::vector<MatrixResult>>(linalgOf(operation, matrices, numbers, option));
|
|
430
|
+
return Builder([results](Napi::Env env) {
|
|
431
|
+
Napi::Array array = Napi::Array::New(env, results->size());
|
|
432
|
+
for (uint32_t i = 0; i < results->size(); i++) {
|
|
433
|
+
const MatrixResult &result = (*results)[i];
|
|
434
|
+
Napi::Float64Array data = Napi::Float64Array::New(env, result.values.size());
|
|
435
|
+
if (!result.values.empty()) std::memcpy(data.Data(), result.values.data(), result.values.size() * sizeof(double));
|
|
436
|
+
Napi::Array matrix = Napi::Array::New(env, 3);
|
|
437
|
+
matrix.Set(0u, static_cast<double>(result.rows));
|
|
438
|
+
matrix.Set(1u, static_cast<double>(result.columns));
|
|
439
|
+
matrix.Set(2u, data);
|
|
440
|
+
array.Set(i, matrix);
|
|
441
|
+
}
|
|
442
|
+
return array;
|
|
443
|
+
});
|
|
444
|
+
};
|
|
445
|
+
}
|
|
446
|
+
|
|
447
|
+
//A sparse matrix given as [rows, columns, Int32Array of the row pointers, Int32Array of the columns, Float64Array of
|
|
448
|
+
//the values]: the lengths are checked here, the structure by sparseOf()
|
|
449
|
+
SparseArgument sparseArgumentOf(const Napi::Value &value)
|
|
450
|
+
{
|
|
451
|
+
if (!value.IsArray()) throw MathError(ErrorCode::Argument, "A sparse matrix is given as [rows, columns, Int32Array, Int32Array, Float64Array]");
|
|
452
|
+
const Napi::Array parts = value.As<Napi::Array>();
|
|
453
|
+
auto dimension = [](const Napi::Value &number) {
|
|
454
|
+
if (!number.IsNumber()) throw MathError(ErrorCode::Argument, "A dimension of a sparse matrix is not a number");
|
|
455
|
+
const double size = number.As<Napi::Number>().DoubleValue();
|
|
456
|
+
if (size != std::floor(size) || size < 0 || size > 2147483647.0) throw MathError(ErrorCode::Argument, "A dimension of a sparse matrix is not an integer from 0 to 2^31 - 1");
|
|
457
|
+
return static_cast<size_t>(size);
|
|
458
|
+
};
|
|
459
|
+
auto integers = [](const Napi::Value &array, const char *what) {
|
|
460
|
+
if (!array.IsTypedArray() || array.As<Napi::TypedArray>().TypedArrayType() != napi_int32_array) throw MathError(ErrorCode::Argument, std::string(what) + " of a sparse matrix are not an Int32Array");
|
|
461
|
+
return array.As<Napi::Int32Array>();
|
|
462
|
+
};
|
|
463
|
+
SparseArgument matrix;
|
|
464
|
+
matrix.rows = dimension(parts.Get(0u));
|
|
465
|
+
matrix.columns = dimension(parts.Get(1u));
|
|
466
|
+
const Napi::Int32Array pointers = integers(parts.Get(2u), "The row pointers"), indices = integers(parts.Get(3u), "The columns");
|
|
467
|
+
const Napi::Value data = parts.Get(4u);
|
|
468
|
+
if (!data.IsTypedArray() || data.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The values of a sparse matrix are not a Float64Array");
|
|
469
|
+
const Napi::Float64Array values = data.As<Napi::Float64Array>();
|
|
470
|
+
if (pointers.ElementLength() != matrix.rows + 1) throw MathError(ErrorCode::Argument, "A sparse matrix of " + std::to_string(matrix.rows) + " rows has " + std::to_string(pointers.ElementLength()) + " row pointers");
|
|
471
|
+
if (indices.ElementLength() != values.ElementLength()) throw MathError(ErrorCode::Argument, "A sparse matrix has " + std::to_string(indices.ElementLength()) + " columns of entries and " + std::to_string(values.ElementLength()) + " values");
|
|
472
|
+
matrix.entries = values.ElementLength();
|
|
473
|
+
if (copyingArguments || !aligned(pointers.Data()) || !aligned(indices.Data()) || !aligned(values.Data())) {
|
|
474
|
+
matrix.ownedPointers = std::make_shared<const std::vector<int32_t>>(elementsOf(pointers));
|
|
475
|
+
matrix.ownedIndices = std::make_shared<const std::vector<int32_t>>(elementsOf(indices));
|
|
476
|
+
matrix.ownedValues = std::make_shared<const std::vector<double>>(elementsOf(values));
|
|
477
|
+
matrix.pointers = matrix.ownedPointers->data();
|
|
478
|
+
matrix.indices = matrix.ownedIndices->data();
|
|
479
|
+
matrix.values = matrix.ownedValues->data();
|
|
480
|
+
} else {
|
|
481
|
+
matrix.pointers = pointers.Data();
|
|
482
|
+
matrix.indices = indices.Data();
|
|
483
|
+
matrix.values = values.Data();
|
|
484
|
+
}
|
|
485
|
+
return matrix;
|
|
486
|
+
}
|
|
487
|
+
|
|
488
|
+
//sparse(operation, sparse matrices, dense matrices, numbers?): an operation on sparse matrices; its results as
|
|
489
|
+
//[[dense matrices as [rows, columns, Float64Array]], [sparse matrices as [rows, columns, Int32Array, Int32Array,
|
|
490
|
+
//Float64Array]]]
|
|
491
|
+
Job sparseJob(const Napi::Array &arguments)
|
|
492
|
+
{
|
|
493
|
+
std::string operation = stringAt(arguments, 0, "The operation");
|
|
494
|
+
auto listAt = [&arguments](uint32_t index, const char *what) {
|
|
495
|
+
const Napi::Value list = arguments.Get(index);
|
|
496
|
+
if (!list.IsArray()) throw MathError(ErrorCode::Argument, std::string(what) + " of an operation are an array");
|
|
497
|
+
return list.As<Napi::Array>();
|
|
498
|
+
};
|
|
499
|
+
std::vector<SparseArgument> sparse;
|
|
500
|
+
const Napi::Array sparseList = listAt(1, "The sparse matrices");
|
|
501
|
+
for (uint32_t i = 0; i < sparseList.Length(); i++) sparse.push_back(sparseArgumentOf(sparseList.Get(i)));
|
|
502
|
+
std::vector<MatrixArgument> dense;
|
|
503
|
+
const Napi::Array denseList = listAt(2, "The matrices");
|
|
504
|
+
for (uint32_t i = 0; i < denseList.Length(); i++) dense.push_back(matrixArgumentOf(denseList.Get(i)));
|
|
505
|
+
std::vector<double> numbers;
|
|
506
|
+
if (arguments.Length() > 3 && arguments.Get(3u).IsArray()) {
|
|
507
|
+
const Napi::Array values = arguments.Get(3u).As<Napi::Array>();
|
|
508
|
+
for (uint32_t i = 0; i < values.Length(); i++) numbers.push_back(numberAt(values, i, "An option"));
|
|
509
|
+
}
|
|
510
|
+
return [operation, sparse, dense, numbers] {
|
|
511
|
+
auto results = std::make_shared<SparseResults>(sparseOf(operation, sparse, dense, numbers));
|
|
512
|
+
return Builder([results](Napi::Env env) {
|
|
513
|
+
Napi::Array denseResults = Napi::Array::New(env, results->dense.size());
|
|
514
|
+
for (uint32_t i = 0; i < results->dense.size(); i++) {
|
|
515
|
+
const MatrixResult &result = results->dense[i];
|
|
516
|
+
Napi::Float64Array data = Napi::Float64Array::New(env, result.values.size());
|
|
517
|
+
if (!result.values.empty()) std::memcpy(data.Data(), result.values.data(), result.values.size() * sizeof(double));
|
|
518
|
+
Napi::Array matrix = Napi::Array::New(env, 3);
|
|
519
|
+
matrix.Set(0u, static_cast<double>(result.rows));
|
|
520
|
+
matrix.Set(1u, static_cast<double>(result.columns));
|
|
521
|
+
matrix.Set(2u, data);
|
|
522
|
+
denseResults.Set(i, matrix);
|
|
523
|
+
}
|
|
524
|
+
Napi::Array sparseResults = Napi::Array::New(env, results->sparse.size());
|
|
525
|
+
for (uint32_t i = 0; i < results->sparse.size(); i++) {
|
|
526
|
+
const SparseResult &result = results->sparse[i];
|
|
527
|
+
Napi::Int32Array pointers = Napi::Int32Array::New(env, result.pointers.size());
|
|
528
|
+
Napi::Int32Array indices = Napi::Int32Array::New(env, result.indices.size());
|
|
529
|
+
Napi::Float64Array values = Napi::Float64Array::New(env, result.values.size());
|
|
530
|
+
if (!result.pointers.empty()) std::memcpy(pointers.Data(), result.pointers.data(), result.pointers.size() * sizeof(int32_t));
|
|
531
|
+
if (!result.indices.empty()) std::memcpy(indices.Data(), result.indices.data(), result.indices.size() * sizeof(int32_t));
|
|
532
|
+
if (!result.values.empty()) std::memcpy(values.Data(), result.values.data(), result.values.size() * sizeof(double));
|
|
533
|
+
Napi::Array matrix = Napi::Array::New(env, 5);
|
|
534
|
+
matrix.Set(0u, static_cast<double>(result.rows));
|
|
535
|
+
matrix.Set(1u, static_cast<double>(result.columns));
|
|
536
|
+
matrix.Set(2u, pointers);
|
|
537
|
+
matrix.Set(3u, indices);
|
|
538
|
+
matrix.Set(4u, values);
|
|
539
|
+
sparseResults.Set(i, matrix);
|
|
540
|
+
}
|
|
541
|
+
Napi::Array array = Napi::Array::New(env, 2);
|
|
542
|
+
array.Set(0u, denseResults);
|
|
543
|
+
array.Set(1u, sparseResults);
|
|
544
|
+
return array;
|
|
545
|
+
});
|
|
546
|
+
};
|
|
547
|
+
}
|
|
548
|
+
|
|
549
|
+
//stats(operation, vectors as Float64Arrays, numbers?): a statistic of vectors; its results as Float64Arrays
|
|
550
|
+
Job statisticsJob(const Napi::Array &arguments)
|
|
551
|
+
{
|
|
552
|
+
std::string operation = stringAt(arguments, 0, "The operation");
|
|
553
|
+
const Napi::Value list = arguments.Get(1u);
|
|
554
|
+
if (!list.IsArray()) throw MathError(ErrorCode::Argument, "The vectors of a statistic are an array");
|
|
555
|
+
std::vector<VectorArgument> vectors;
|
|
556
|
+
const Napi::Array given = list.As<Napi::Array>();
|
|
557
|
+
for (uint32_t i = 0; i < given.Length(); i++) {
|
|
558
|
+
const Napi::Value value = given.Get(i);
|
|
559
|
+
if (!value.IsTypedArray() || value.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The values of a statistic are a Float64Array");
|
|
560
|
+
const Napi::Float64Array elements = value.As<Napi::Float64Array>();
|
|
561
|
+
VectorArgument vector;
|
|
562
|
+
vector.size = elements.ElementLength();
|
|
563
|
+
if (copyingArguments || !aligned(elements.Data())) {
|
|
564
|
+
vector.owned = std::make_shared<const std::vector<double>>(elementsOf(elements));
|
|
565
|
+
vector.values = vector.owned->data();
|
|
566
|
+
} else {
|
|
567
|
+
vector.values = elements.Data();
|
|
568
|
+
}
|
|
569
|
+
vectors.push_back(vector);
|
|
570
|
+
}
|
|
571
|
+
std::vector<double> numbers;
|
|
572
|
+
if (arguments.Length() > 2 && arguments.Get(2u).IsArray()) {
|
|
573
|
+
const Napi::Array values = arguments.Get(2u).As<Napi::Array>();
|
|
574
|
+
for (uint32_t i = 0; i < values.Length(); i++) numbers.push_back(numberAt(values, i, "An option"));
|
|
575
|
+
}
|
|
576
|
+
return [operation, vectors, numbers] {
|
|
577
|
+
auto results = std::make_shared<std::vector<std::vector<double>>>(statisticsOf(operation, vectors, numbers));
|
|
578
|
+
return Builder([results](Napi::Env env) {
|
|
579
|
+
Napi::Array array = Napi::Array::New(env, results->size());
|
|
580
|
+
for (uint32_t i = 0; i < results->size(); i++) {
|
|
581
|
+
const std::vector<double> &result = (*results)[i];
|
|
582
|
+
Napi::Float64Array data = Napi::Float64Array::New(env, result.size());
|
|
583
|
+
if (!result.empty()) std::memcpy(data.Data(), result.data(), result.size() * sizeof(double));
|
|
584
|
+
array.Set(i, data);
|
|
585
|
+
}
|
|
586
|
+
return array;
|
|
587
|
+
});
|
|
588
|
+
};
|
|
589
|
+
}
|
|
590
|
+
|
|
591
|
+
//The four words of the state of a random generator: a BigUint64Array, which a synchronous operation advances in
|
|
592
|
+
//place (an asynchronous one would change it from another thread: refused)
|
|
593
|
+
uint64_t *generatorStateAt(const Napi::Array &arguments, uint32_t index)
|
|
594
|
+
{
|
|
595
|
+
if (copyingArguments) throw MathError(ErrorCode::Argument, "The random numbers are drawn synchronously");
|
|
596
|
+
const Napi::Value value = arguments.Get(index);
|
|
597
|
+
if (!value.IsTypedArray() || value.As<Napi::TypedArray>().TypedArrayType() != napi_biguint64_array) throw MathError(ErrorCode::Argument, "The state of a random generator is a BigUint64Array");
|
|
598
|
+
Napi::TypedArrayOf<uint64_t> state = value.As<Napi::TypedArrayOf<uint64_t>>();
|
|
599
|
+
if (state.ElementLength() != 4) throw MathError(ErrorCode::Argument, "The state of a random generator has 4 words");
|
|
600
|
+
return state.Data();
|
|
601
|
+
}
|
|
602
|
+
|
|
603
|
+
//An operation on the state of a generator, on an aligned copy written back after (see aligned())
|
|
604
|
+
template <typename F>
|
|
605
|
+
auto withState(uint64_t *state, F &&operation)
|
|
606
|
+
{
|
|
607
|
+
uint64_t words[4];
|
|
608
|
+
std::memcpy(words, state, sizeof(words));
|
|
609
|
+
auto result = operation(words);
|
|
610
|
+
std::memcpy(state, words, sizeof(words));
|
|
611
|
+
return result;
|
|
612
|
+
}
|
|
613
|
+
|
|
614
|
+
size_t countAt(const Napi::Array &arguments, uint32_t index)
|
|
615
|
+
{
|
|
616
|
+
const double count = numberAt(arguments, index, "The count");
|
|
617
|
+
if (count != std::floor(count) || count < 0 || count > 4294967295.0) throw MathError(ErrorCode::Argument, "The count of random numbers is an integer of 0 or more");
|
|
618
|
+
return static_cast<size_t>(count);
|
|
619
|
+
}
|
|
620
|
+
|
|
621
|
+
Builder vectorBuilder(std::vector<double> values)
|
|
622
|
+
{
|
|
623
|
+
auto results = std::make_shared<std::vector<double>>(std::move(values));
|
|
624
|
+
return Builder([results](Napi::Env env) {
|
|
625
|
+
Napi::Float64Array data = Napi::Float64Array::New(env, results->size());
|
|
626
|
+
if (!results->empty()) std::memcpy(data.Data(), results->data(), results->size() * sizeof(double));
|
|
627
|
+
return data;
|
|
628
|
+
});
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
//distribution(function, name, parameters, values | count, state?): describe (its support and moments), pdf, cdf,
|
|
632
|
+
//survival, quantile, survivalQuantile of values, or a sample of a count by the generator of a state
|
|
633
|
+
Job distributionJob(const Napi::Array &arguments)
|
|
634
|
+
{
|
|
635
|
+
const std::string function = stringAt(arguments, 0, "The function");
|
|
636
|
+
const std::string name = stringAt(arguments, 1, "The distribution");
|
|
637
|
+
const Napi::Value list = arguments.Get(2u);
|
|
638
|
+
if (!list.IsArray()) throw MathError(ErrorCode::Argument, "The parameters of a distribution are an array");
|
|
639
|
+
std::vector<double> parameters;
|
|
640
|
+
const Napi::Array given = list.As<Napi::Array>();
|
|
641
|
+
for (uint32_t i = 0; i < given.Length(); i++) parameters.push_back(numberAt(given, i, "A parameter"));
|
|
642
|
+
if (function == "describe") {
|
|
643
|
+
return [name, parameters] { return vectorBuilder(describeDistribution(name, parameters)); };
|
|
644
|
+
}
|
|
645
|
+
if (function == "sample") {
|
|
646
|
+
const size_t count = countAt(arguments, 3);
|
|
647
|
+
uint64_t *state = generatorStateAt(arguments, 4);
|
|
648
|
+
return [name, parameters, count, state] { return withState(state, [&name, ¶meters, count](uint64_t *words) { return vectorBuilder(sampleDistribution(name, parameters, count, words)); }); };
|
|
649
|
+
}
|
|
650
|
+
const Napi::Value data = arguments.Get(3u);
|
|
651
|
+
if (!data.IsTypedArray() || data.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The values of a distribution are a Float64Array");
|
|
652
|
+
const Napi::Float64Array elements = data.As<Napi::Float64Array>();
|
|
653
|
+
auto values = std::make_shared<const std::vector<double>>(elements.Data(), elements.Data() + elements.ElementLength());
|
|
654
|
+
return [function, name, parameters, values] { return vectorBuilder(distributionAt(name, parameters, function, values->data(), values->size())); };
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
//random(operation, state, ...): seed (of a BigUint64Array of one word), uniform (count), integers (count, lower, upper)
|
|
658
|
+
Job randomJob(const Napi::Array &arguments)
|
|
659
|
+
{
|
|
660
|
+
const std::string operation = stringAt(arguments, 0, "The operation");
|
|
661
|
+
uint64_t *state = generatorStateAt(arguments, 1);
|
|
662
|
+
if (operation == "seed") {
|
|
663
|
+
const Napi::Value value = arguments.Get(2u);
|
|
664
|
+
if (!value.IsTypedArray() || value.As<Napi::TypedArray>().TypedArrayType() != napi_biguint64_array) throw MathError(ErrorCode::Argument, "The seed is a BigUint64Array");
|
|
665
|
+
const std::vector<uint64_t> words = elementsOf(value.As<Napi::TypedArrayOf<uint64_t>>());
|
|
666
|
+
if (words.empty()) throw MathError(ErrorCode::Argument, "The seed is a BigUint64Array of one word");
|
|
667
|
+
const uint64_t seed = words[0];
|
|
668
|
+
return [state, seed] {
|
|
669
|
+
return withState(state, [seed](uint64_t *words) {
|
|
670
|
+
seedGenerator(seed, words);
|
|
671
|
+
return vectorBuilder({});
|
|
672
|
+
});
|
|
673
|
+
};
|
|
674
|
+
}
|
|
675
|
+
const size_t count = countAt(arguments, 2);
|
|
676
|
+
if (operation == "uniform") return [count, state] { return withState(state, [count](uint64_t *words) { return vectorBuilder(uniformNumbers(count, words)); }); };
|
|
677
|
+
if (operation == "integers") {
|
|
678
|
+
const double lower = numberAt(arguments, 3, "The lower bound"), upper = numberAt(arguments, 4, "The upper bound");
|
|
679
|
+
return [count, state, lower, upper] { return withState(state, [count, lower, upper](uint64_t *words) { return vectorBuilder(uniformIntegers(count, lower, upper, words)); }); };
|
|
680
|
+
}
|
|
681
|
+
throw MathError(ErrorCode::Argument, "Unknown operation of a random generator: " + operation);
|
|
682
|
+
}
|
|
683
|
+
|
|
684
|
+
Napi::Float64Array float64ArrayOf(Napi::Env env, const std::vector<double> &values)
|
|
685
|
+
{
|
|
686
|
+
Napi::Float64Array array = Napi::Float64Array::New(env, values.size());
|
|
687
|
+
if (!values.empty()) std::memcpy(array.Data(), values.data(), values.size() * sizeof(double));
|
|
688
|
+
return array;
|
|
689
|
+
}
|
|
690
|
+
|
|
691
|
+
Napi::Value iterativeValue(Napi::Env env, const IterativeResult &result)
|
|
692
|
+
{
|
|
693
|
+
Napi::Object value = Napi::Object::New(env);
|
|
694
|
+
value.Set("solution", float64ArrayOf(env, result.solution));
|
|
695
|
+
value.Set("converged", result.converged);
|
|
696
|
+
value.Set("iterations", static_cast<double>(result.iterations));
|
|
697
|
+
value.Set("residual", result.residual);
|
|
698
|
+
return value;
|
|
699
|
+
}
|
|
700
|
+
|
|
701
|
+
size_t iterationsAt(const Napi::Array &arguments, uint32_t index)
|
|
702
|
+
{
|
|
703
|
+
const double iterations = numberAt(arguments, index, "The largest number of iterations");
|
|
704
|
+
if (iterations != std::floor(iterations) || iterations < 0 || iterations > 1e9) throw MathError(ErrorCode::Argument, "The largest number of iterations is an integer from 0 to 10^9");
|
|
705
|
+
return static_cast<size_t>(iterations);
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
//polynomialRoots(polynomial, variable) or polynomialRoots(Float64Array of the coefficients from the constant term
|
|
709
|
+
//up): {re, im}
|
|
710
|
+
Job polynomialRootsJob(const Napi::Array &arguments)
|
|
711
|
+
{
|
|
712
|
+
const Napi::Value first = arguments.Get(0u);
|
|
713
|
+
std::optional<std::vector<std::complex<double>>> coefficients;
|
|
714
|
+
Expr polynomial;
|
|
715
|
+
std::string variable;
|
|
716
|
+
if (first.IsTypedArray() && first.As<Napi::TypedArray>().TypedArrayType() == napi_float64_array) {
|
|
717
|
+
const Napi::Float64Array given = first.As<Napi::Float64Array>();
|
|
718
|
+
const std::vector<double> values = elementsOf(given);
|
|
719
|
+
coefficients = std::vector<std::complex<double>>(values.begin(), values.end());
|
|
720
|
+
} else {
|
|
721
|
+
polynomial = expressionAt(arguments, 0);
|
|
722
|
+
variable = stringAt(arguments, 1, "The variable");
|
|
723
|
+
}
|
|
724
|
+
return [coefficients, polynomial, variable] {
|
|
725
|
+
auto roots = std::make_shared<ComplexRoots>(coefficients ? polynomialRootsOf(*coefficients) : polynomialRootsOf(polynomial, variable));
|
|
726
|
+
return Builder([roots](Napi::Env env) {
|
|
727
|
+
Napi::Object value = Napi::Object::New(env);
|
|
728
|
+
value.Set("re", float64ArrayOf(env, roots->re));
|
|
729
|
+
value.Set("im", float64ArrayOf(env, roots->im));
|
|
730
|
+
return value;
|
|
731
|
+
});
|
|
732
|
+
};
|
|
733
|
+
}
|
|
734
|
+
|
|
735
|
+
//findRoot(function, variable, bracket [a, b] or null, guess or null, tolerance, maxIterations)
|
|
736
|
+
Job findRootJob(const Napi::Array &arguments)
|
|
737
|
+
{
|
|
738
|
+
const Expr function = expressionAt(arguments, 0);
|
|
739
|
+
const std::string variable = stringAt(arguments, 1, "The variable");
|
|
740
|
+
std::optional<std::pair<double, double>> bracket;
|
|
741
|
+
std::optional<double> guess;
|
|
742
|
+
if (arguments.Get(2u).IsArray()) {
|
|
743
|
+
const Napi::Array ends = arguments.Get(2u).As<Napi::Array>();
|
|
744
|
+
if (ends.Length() != 2) throw MathError(ErrorCode::Argument, "A bracket is [a, b]");
|
|
745
|
+
bracket = std::make_pair(numberAt(ends, 0, "An end of the bracket"), numberAt(ends, 1, "An end of the bracket"));
|
|
746
|
+
}
|
|
747
|
+
if (arguments.Get(3u).IsNumber()) guess = numberAt(arguments, 3, "The guess");
|
|
748
|
+
if (!bracket && !guess) throw MathError(ErrorCode::Argument, "A root is found in a bracket or from a guess");
|
|
749
|
+
const double tolerance = numberAt(arguments, 4, "The tolerance");
|
|
750
|
+
const size_t iterations = iterationsAt(arguments, 5);
|
|
751
|
+
return [function, variable, bracket, guess, tolerance, iterations] {
|
|
752
|
+
auto result = std::make_shared<IterativeResult>(findRootOf(function, variable, bracket, guess, tolerance, iterations));
|
|
753
|
+
return Builder([result](Napi::Env env) { return iterativeValue(env, *result); });
|
|
754
|
+
};
|
|
755
|
+
}
|
|
756
|
+
|
|
757
|
+
//solveSystem(equations, variables, guess (Float64Array), tolerance, maxIterations)
|
|
758
|
+
Job solveSystemJob(const Napi::Array &arguments)
|
|
759
|
+
{
|
|
760
|
+
const std::vector<Expr> equations = expressionsAt(arguments, 0);
|
|
761
|
+
const std::vector<std::string> variables = stringsAt(arguments, 1);
|
|
762
|
+
const Napi::Value given = arguments.Get(2u);
|
|
763
|
+
if (!given.IsTypedArray() || given.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The guess is a Float64Array");
|
|
764
|
+
const Napi::Float64Array values = given.As<Napi::Float64Array>();
|
|
765
|
+
const std::vector<double> guess = elementsOf(values);
|
|
766
|
+
const double tolerance = numberAt(arguments, 3, "The tolerance");
|
|
767
|
+
const size_t iterations = iterationsAt(arguments, 4);
|
|
768
|
+
return [equations, variables, guess, tolerance, iterations] {
|
|
769
|
+
auto result = std::make_shared<IterativeResult>(solveSystemOf(equations, variables, guess, tolerance, iterations));
|
|
770
|
+
return Builder([result](Napi::Env env) { return iterativeValue(env, *result); });
|
|
771
|
+
};
|
|
772
|
+
}
|
|
773
|
+
|
|
774
|
+
//integrate(function, variable, a, b, points (Float64Array), tolerance): {value, error, converged}
|
|
775
|
+
Job integrateJob(const Napi::Array &arguments)
|
|
776
|
+
{
|
|
777
|
+
const Expr function = expressionAt(arguments, 0);
|
|
778
|
+
const std::string variable = stringAt(arguments, 1, "The variable");
|
|
779
|
+
const double a = numberAt(arguments, 2, "The start of the interval"), b = numberAt(arguments, 3, "The end of the interval");
|
|
780
|
+
const Napi::Value given = arguments.Get(4u);
|
|
781
|
+
if (!given.IsTypedArray() || given.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The points are a Float64Array");
|
|
782
|
+
const Napi::Float64Array values = given.As<Napi::Float64Array>();
|
|
783
|
+
const std::vector<double> points = elementsOf(values);
|
|
784
|
+
const double tolerance = numberAt(arguments, 5, "The tolerance");
|
|
785
|
+
return [function, variable, a, b, points, tolerance] {
|
|
786
|
+
const IntegralResult result = integralOf(function, variable, a, b, points, tolerance);
|
|
787
|
+
return Builder([result](Napi::Env env) {
|
|
788
|
+
Napi::Object value = Napi::Object::New(env);
|
|
789
|
+
value.Set("value", result.value);
|
|
790
|
+
value.Set("error", result.error);
|
|
791
|
+
value.Set("converged", result.converged);
|
|
792
|
+
return value;
|
|
793
|
+
});
|
|
794
|
+
};
|
|
795
|
+
}
|
|
796
|
+
|
|
797
|
+
//solveODE(derivatives, states, time, t0, t1, initial (Float64Array), method, relativeTolerance, absoluteTolerance,
|
|
798
|
+
//maxStep, points (Float64Array), maxSteps): {t, y (rows of states), columns, steps, rejected, evaluations, jacobians,
|
|
799
|
+
//completed, message}
|
|
800
|
+
Job solveODEJob(const Napi::Array &arguments)
|
|
801
|
+
{
|
|
802
|
+
const std::vector<Expr> derivatives = expressionsAt(arguments, 0);
|
|
803
|
+
const std::vector<std::string> states = stringsAt(arguments, 1);
|
|
804
|
+
const std::string time = stringAt(arguments, 2, "The time");
|
|
805
|
+
const double t0 = numberAt(arguments, 3, "The start of the span"), t1 = numberAt(arguments, 4, "The end of the span");
|
|
806
|
+
const auto arrayAt = [&arguments](uint32_t index, const char *what) {
|
|
807
|
+
const Napi::Value given = arguments.Get(index);
|
|
808
|
+
if (!given.IsTypedArray() || given.As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, std::string(what) + " are a Float64Array");
|
|
809
|
+
const Napi::Float64Array values = given.As<Napi::Float64Array>();
|
|
810
|
+
return elementsOf(values);
|
|
811
|
+
};
|
|
812
|
+
const std::vector<double> initial = arrayAt(5, "The initial values");
|
|
813
|
+
ODEOptions options;
|
|
814
|
+
options.method = stringAt(arguments, 6, "The method");
|
|
815
|
+
options.relativeTolerance = numberAt(arguments, 7, "The relative tolerance");
|
|
816
|
+
options.absoluteTolerance = numberAt(arguments, 8, "The absolute tolerance");
|
|
817
|
+
options.maxStep = numberAt(arguments, 9, "The largest step");
|
|
818
|
+
options.points = arrayAt(10, "The points");
|
|
819
|
+
options.maxSteps = iterationsAt(arguments, 11);
|
|
820
|
+
return [derivatives, states, time, t0, t1, initial, options] {
|
|
821
|
+
auto result = std::make_shared<ODEResult>(solveODEOf(derivatives, states, time, t0, t1, initial, options));
|
|
822
|
+
return Builder([result](Napi::Env env) {
|
|
823
|
+
Napi::Object value = Napi::Object::New(env);
|
|
824
|
+
value.Set("t", float64ArrayOf(env, result->t));
|
|
825
|
+
value.Set("y", float64ArrayOf(env, result->y));
|
|
826
|
+
value.Set("steps", static_cast<double>(result->steps));
|
|
827
|
+
value.Set("rejected", static_cast<double>(result->rejected));
|
|
828
|
+
value.Set("evaluations", static_cast<double>(result->evaluations));
|
|
829
|
+
value.Set("jacobians", static_cast<double>(result->jacobians));
|
|
830
|
+
value.Set("completed", result->completed);
|
|
831
|
+
if (!result->message.empty()) value.Set("message", result->message);
|
|
832
|
+
return value;
|
|
833
|
+
});
|
|
834
|
+
};
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
//The value of a matrix of expressions for JavaScript: {matrix, rows, columns}
|
|
838
|
+
Napi::Value matrixValue(Napi::Env env, const MatrixPointer &matrix)
|
|
839
|
+
{
|
|
840
|
+
Napi::Object value = Napi::Object::New(env);
|
|
841
|
+
value.Set("matrix", wrapMatrix(env, matrix));
|
|
842
|
+
value.Set("rows", static_cast<double>(matrix->rows));
|
|
843
|
+
value.Set("columns", static_cast<double>(matrix->columns));
|
|
844
|
+
return value;
|
|
845
|
+
}
|
|
846
|
+
|
|
847
|
+
//matrix(operation, matrices, expressions, numbers, names): an operation of the matrices of expressions; its result as
|
|
848
|
+
//{matrix?, expression?, matrices?, expressions?, numbers?, text?}
|
|
849
|
+
Job matrixJob(const Napi::Array &arguments)
|
|
850
|
+
{
|
|
851
|
+
const std::string operation = stringAt(arguments, 0, "The operation");
|
|
852
|
+
const auto arrayAt = [&arguments](uint32_t index, const char *what) {
|
|
853
|
+
const Napi::Value value = arguments.Get(index);
|
|
854
|
+
if (!value.IsArray()) throw MathError(ErrorCode::Argument, std::string(what) + " are an array");
|
|
855
|
+
return value.As<Napi::Array>();
|
|
856
|
+
};
|
|
857
|
+
std::vector<MatrixPointer> matrices;
|
|
858
|
+
const Napi::Array givenMatrices = arrayAt(1, "The matrices");
|
|
859
|
+
for (uint32_t i = 0; i < givenMatrices.Length(); i++) matrices.push_back(unwrapMatrix(givenMatrices.Get(i)));
|
|
860
|
+
const std::vector<Expr> expressions = expressionsAt(arguments, 2);
|
|
861
|
+
std::vector<double> numbers;
|
|
862
|
+
const Napi::Array givenNumbers = arrayAt(3, "The numbers");
|
|
863
|
+
for (uint32_t i = 0; i < givenNumbers.Length(); i++) numbers.push_back(numberAt(givenNumbers, i, "A number"));
|
|
864
|
+
const std::vector<std::string> names = stringsAt(arguments, 4);
|
|
865
|
+
return [operation, matrices, expressions, numbers, names] {
|
|
866
|
+
auto result = std::make_shared<ExpressionMatrixResult>(matrixOperation(operation, matrices, expressions, numbers, names));
|
|
867
|
+
return Builder([result](Napi::Env env) {
|
|
868
|
+
Napi::Object value = Napi::Object::New(env);
|
|
869
|
+
if (result->matrix) value.Set("matrix", matrixValue(env, result->matrix));
|
|
870
|
+
if (!result->expression.is_null()) value.Set("expression", wrapExpression(env, result->expression));
|
|
871
|
+
Napi::Array matrices = Napi::Array::New(env, result->matrices.size());
|
|
872
|
+
for (uint32_t i = 0; i < result->matrices.size(); i++) matrices.Set(i, matrixValue(env, result->matrices[i]));
|
|
873
|
+
value.Set("matrices", matrices);
|
|
874
|
+
value.Set("expressions", expressionsValue(env, result->expressions));
|
|
875
|
+
Napi::Array numbers = Napi::Array::New(env, result->numbers.size());
|
|
876
|
+
for (uint32_t i = 0; i < result->numbers.size(); i++) numbers.Set(i, result->numbers[i]);
|
|
877
|
+
value.Set("numbers", numbers);
|
|
878
|
+
value.Set("text", result->text);
|
|
879
|
+
return value;
|
|
880
|
+
});
|
|
881
|
+
};
|
|
882
|
+
}
|
|
883
|
+
|
|
884
|
+
Job polyJob(const Napi::Array &arguments)
|
|
885
|
+
{
|
|
886
|
+
const std::string operation = stringAt(arguments, 0, "The operation");
|
|
887
|
+
const std::vector<Expr> expressions = expressionsAt(arguments, 1);
|
|
888
|
+
const std::vector<std::string> names = stringsAt(arguments, 2);
|
|
889
|
+
return [operation, expressions, names] {
|
|
890
|
+
auto result = std::make_shared<PolyResult>(polyOperation(operation, expressions, names));
|
|
891
|
+
return Builder([result](Napi::Env env) {
|
|
892
|
+
Napi::Object value = Napi::Object::New(env);
|
|
893
|
+
if (!result->expression.is_null()) value.Set("expression", wrapExpression(env, result->expression));
|
|
894
|
+
value.Set("expressions", expressionsValue(env, result->expressions));
|
|
895
|
+
Napi::Array numbers = Napi::Array::New(env, result->numbers.size());
|
|
896
|
+
for (uint32_t i = 0; i < result->numbers.size(); i++) numbers.Set(i, result->numbers[i]);
|
|
897
|
+
value.Set("numbers", numbers);
|
|
898
|
+
value.Set("text", result->text);
|
|
899
|
+
return value;
|
|
900
|
+
});
|
|
901
|
+
};
|
|
902
|
+
}
|
|
903
|
+
|
|
904
|
+
Job fractionJob(const Napi::Array &arguments)
|
|
905
|
+
{
|
|
906
|
+
Expr expression = expressionAt(arguments, 0);
|
|
907
|
+
return [expression] {
|
|
908
|
+
const std::pair<Expr, Expr> fraction = fractionOf(expression);
|
|
909
|
+
return Builder([fraction](Napi::Env env) { return expressionsValue(env, {fraction.first, fraction.second}); });
|
|
910
|
+
};
|
|
911
|
+
}
|
|
912
|
+
|
|
913
|
+
Job coefficientsJob(const Napi::Array &arguments)
|
|
914
|
+
{
|
|
915
|
+
Expr expression = expressionAt(arguments, 0);
|
|
916
|
+
std::string variable = stringAt(arguments, 1, "The variable");
|
|
917
|
+
return [expression, variable] {
|
|
918
|
+
const std::vector<Expr> coefficients = coefficientsOf(expression, variable);
|
|
919
|
+
return Builder([coefficients](Napi::Env env) { return expressionsValue(env, coefficients); });
|
|
920
|
+
};
|
|
921
|
+
}
|
|
922
|
+
|
|
923
|
+
Job divideJob(const Napi::Array &arguments)
|
|
924
|
+
{
|
|
925
|
+
Expr dividend = expressionAt(arguments, 0);
|
|
926
|
+
Expr divisor = expressionAt(arguments, 1);
|
|
927
|
+
std::string variable = stringAt(arguments, 2, "The variable");
|
|
928
|
+
return [dividend, divisor, variable] {
|
|
929
|
+
const std::pair<Expr, Expr> result = divideOf(dividend, divisor, variable);
|
|
930
|
+
return Builder([result](Napi::Env env) { return expressionsValue(env, {result.first, result.second}); });
|
|
931
|
+
};
|
|
932
|
+
}
|
|
933
|
+
|
|
934
|
+
Job rewriteJob(const Napi::Array &arguments)
|
|
935
|
+
{
|
|
936
|
+
Expr expression = expressionAt(arguments, 0);
|
|
937
|
+
std::string form = stringAt(arguments, 1, "The form");
|
|
938
|
+
return [expression, form] { return expressionResult(rewriteOf(expression, form)); };
|
|
939
|
+
}
|
|
940
|
+
|
|
941
|
+
Job predicateJob(const Napi::Array &arguments)
|
|
942
|
+
{
|
|
943
|
+
Expr expression = expressionAt(arguments, 0);
|
|
944
|
+
std::string property = stringAt(arguments, 1, "The property");
|
|
945
|
+
return [expression, property] {
|
|
946
|
+
const int answer = predicateOf(expression, property);
|
|
947
|
+
return Builder([answer](Napi::Env env) -> Napi::Value { return answer == -1 ? env.Undefined() : Napi::Boolean::New(env, answer == 1); });
|
|
948
|
+
};
|
|
949
|
+
}
|
|
950
|
+
|
|
951
|
+
Job compareJob(const Napi::Array &arguments)
|
|
952
|
+
{
|
|
953
|
+
Expr a = expressionAt(arguments, 0);
|
|
954
|
+
Expr b = expressionAt(arguments, 1);
|
|
955
|
+
return [a, b] {
|
|
956
|
+
const int order = compareOf(a, b);
|
|
957
|
+
return Builder([order](Napi::Env env) -> Napi::Value { return order == 2 ? env.Undefined() : Napi::Number::New(env, order); });
|
|
958
|
+
};
|
|
959
|
+
}
|
|
960
|
+
|
|
961
|
+
Job codeJob(const Napi::Array &arguments)
|
|
962
|
+
{
|
|
963
|
+
Expr expression = expressionAt(arguments, 0);
|
|
964
|
+
std::string language = stringAt(arguments, 1, "The language");
|
|
965
|
+
if (language != "javascript" && language != "c") throw MathError(ErrorCode::Argument, "The code is written in javascript or c, not " + language);
|
|
966
|
+
return [expression, language] {
|
|
967
|
+
const std::string text = toCode(expression, language == "c");
|
|
968
|
+
return Builder([text](Napi::Env env) { return Napi::String::New(env, text); });
|
|
969
|
+
};
|
|
970
|
+
}
|
|
971
|
+
|
|
972
|
+
Job cseJob(const Napi::Array &arguments)
|
|
973
|
+
{
|
|
974
|
+
std::vector<Expr> expressions = expressionsAt(arguments, 0);
|
|
975
|
+
std::string prefix = stringAt(arguments, 1, "The prefix");
|
|
976
|
+
return [expressions, prefix] {
|
|
977
|
+
const CommonSubexpressions result = cseOf(expressions, prefix);
|
|
978
|
+
return Builder([result](Napi::Env env) {
|
|
979
|
+
Napi::Array replacements = Napi::Array::New(env, result.replacements.size());
|
|
980
|
+
for (size_t i = 0; i < result.replacements.size(); i++) {
|
|
981
|
+
Napi::Object replacement = Napi::Object::New(env);
|
|
982
|
+
replacement.Set("name", result.replacements[i].first);
|
|
983
|
+
replacement.Set("value", wrapExpression(env, result.replacements[i].second));
|
|
984
|
+
replacements.Set(static_cast<uint32_t>(i), replacement);
|
|
985
|
+
}
|
|
986
|
+
Napi::Object value = Napi::Object::New(env);
|
|
987
|
+
value.Set("replacements", replacements);
|
|
988
|
+
value.Set("expressions", expressionsValue(env, result.expressions));
|
|
989
|
+
return Napi::Value(value);
|
|
990
|
+
});
|
|
991
|
+
};
|
|
992
|
+
}
|
|
993
|
+
|
|
994
|
+
Job polarJob(const Napi::Array &arguments)
|
|
995
|
+
{
|
|
996
|
+
Expr expression = expressionAt(arguments, 0);
|
|
997
|
+
return [expression] {
|
|
998
|
+
const std::pair<Expr, Expr> polar = polarOf(expression);
|
|
999
|
+
return Builder([polar](Napi::Env env) { return expressionsValue(env, {polar.first, polar.second}); });
|
|
1000
|
+
};
|
|
1001
|
+
}
|
|
1002
|
+
|
|
1003
|
+
Job rectangularJob(const Napi::Array &arguments)
|
|
1004
|
+
{
|
|
1005
|
+
Expr expression = expressionAt(arguments, 0);
|
|
1006
|
+
return [expression] {
|
|
1007
|
+
const std::pair<Expr, Expr> parts = rectangularOf(expression);
|
|
1008
|
+
return Builder([parts](Napi::Env env) { return expressionsValue(env, {parts.first, parts.second}); });
|
|
1009
|
+
};
|
|
1010
|
+
}
|
|
1011
|
+
|
|
1012
|
+
//An operation of the number theory: its name, then its arguments, integers or arrays of integers
|
|
1013
|
+
Job numberTheoryJob(const Napi::Array &arguments)
|
|
1014
|
+
{
|
|
1015
|
+
std::string operation = stringAt(arguments, 0, "The operation");
|
|
1016
|
+
std::vector<std::vector<Integer>> values;
|
|
1017
|
+
for (uint32_t i = 1; i < arguments.Length(); i++) {
|
|
1018
|
+
Napi::Value value = arguments.Get(i);
|
|
1019
|
+
const std::string what = "Argument " + std::to_string(i) + " of " + operation;
|
|
1020
|
+
std::vector<Integer> list;
|
|
1021
|
+
if (value.IsArray()) {
|
|
1022
|
+
Napi::Array array = value.As<Napi::Array>();
|
|
1023
|
+
for (uint32_t j = 0; j < array.Length(); j++) list.push_back(integerOf(array.Get(j), what + ", at index " + std::to_string(j) + ","));
|
|
1024
|
+
} else {
|
|
1025
|
+
list.push_back(integerOf(value, what));
|
|
1026
|
+
}
|
|
1027
|
+
values.push_back(std::move(list));
|
|
1028
|
+
}
|
|
1029
|
+
return [operation, values] {
|
|
1030
|
+
NumberTheoryResult result = numberTheoryOf(operation, values);
|
|
1031
|
+
return Builder([result](Napi::Env env) { return numberTheoryValue(env, result); });
|
|
1032
|
+
};
|
|
1033
|
+
}
|
|
1034
|
+
|
|
1035
|
+
Job arithmeticJob(const Napi::Array &arguments)
|
|
1036
|
+
{
|
|
1037
|
+
const std::string operation = stringAt(arguments, 0, "The operation");
|
|
1038
|
+
Expr a = expressionAt(arguments, 1);
|
|
1039
|
+
Expr b = expressionAt(arguments, 2);
|
|
1040
|
+
return [operation, a, b] { return expressionResult(arithmeticOf(operation, a, b)); };
|
|
1041
|
+
}
|
|
1042
|
+
|
|
1043
|
+
const std::map<std::string, JobFactory> &jobs()
|
|
1044
|
+
{
|
|
1045
|
+
//The tables of the file are never destroyed: the threads of the addon may still use them while the process exits
|
|
1046
|
+
static const std::map<std::string, JobFactory> &table = *new std::map<std::string, JobFactory>{
|
|
1047
|
+
{"expand", expandJob}, {"simplify", simplifyJob}, {"diff", diffJob}, {"substitute", substituteJob},
|
|
1048
|
+
{"series", seriesJob}, {"solve", solveJob}, {"inequality", inequalityJob}, {"limit", limitJob}, {"integral", integralJob}, {"laplace", laplaceJob}, {"solveLinear", solveLinearJob}, {"equals", equalsJob},
|
|
1049
|
+
{"decimal", decimalJob}, {"complexDecimal", complexDecimalJob}, {"linalg", linalgJob}, {"sparse", sparseJob}, {"stats", statisticsJob}, {"distribution", distributionJob}, {"random", randomJob}, {"polynomialRoots", polynomialRootsJob}, {"findRoot", findRootJob}, {"solveSystem", solveSystemJob}, {"integrate", integrateJob}, {"solveODE", solveODEJob}, {"matrix", matrixJob}, {"poly", polyJob}, {"decimalOperation", decimalOperationJob}, {"arithmetic", arithmeticJob}, {"fraction", fractionJob}, {"coefficients", coefficientsJob},
|
|
1050
|
+
{"divide", divideJob}, {"rewrite", rewriteJob}, {"predicate", predicateJob}, {"compare", compareJob},
|
|
1051
|
+
{"ntheory", numberTheoryJob}, {"code", codeJob}, {"cse", cseJob}, {"polar", polarJob}, {"rectangular", rectangularJob}
|
|
1052
|
+
};
|
|
1053
|
+
return table;
|
|
1054
|
+
}
|
|
1055
|
+
|
|
1056
|
+
Job jobOf(const Napi::CallbackInfo &info)
|
|
1057
|
+
{
|
|
1058
|
+
const std::string name = info[0].As<Napi::String>().Utf8Value();
|
|
1059
|
+
const auto factory = jobs().find(name);
|
|
1060
|
+
if (factory == jobs().end()) throw MathError(ErrorCode::Argument, "Unknown operation " + name);
|
|
1061
|
+
if (!info[1].IsArray()) throw MathError(ErrorCode::Argument, "The arguments of an operation are an array");
|
|
1062
|
+
return factory->second(info[1].As<Napi::Array>());
|
|
1063
|
+
}
|
|
1064
|
+
|
|
1065
|
+
//run(operation, arguments): an operation in the thread of JavaScript
|
|
1066
|
+
Napi::Value Run(const Napi::CallbackInfo &info)
|
|
1067
|
+
{
|
|
1068
|
+
return jobOf(info)()(info.Env());
|
|
1069
|
+
}
|
|
1070
|
+
|
|
1071
|
+
struct Environment;
|
|
1072
|
+
|
|
1073
|
+
//The end of an asynchronous operation, back in the thread of JavaScript
|
|
1074
|
+
struct Completion {
|
|
1075
|
+
std::shared_ptr<Environment> environment;
|
|
1076
|
+
std::shared_ptr<Token> token;
|
|
1077
|
+
Napi::Promise::Deferred deferred;
|
|
1078
|
+
Builder builder;
|
|
1079
|
+
ErrorInfo error;
|
|
1080
|
+
bool failed;
|
|
1081
|
+
};
|
|
1082
|
+
|
|
1083
|
+
void complete(Napi::Env env, Napi::Function, std::nullptr_t *, Completion *completion);
|
|
1084
|
+
|
|
1085
|
+
using CompletionFunction = Napi::TypedThreadSafeFunction<std::nullptr_t, Completion, complete>;
|
|
1086
|
+
|
|
1087
|
+
//The asynchronous operations of an environment of JavaScript (the main thread, a worker thread). Node frees the
|
|
1088
|
+
//thread-safe function of an environment torn down (a worker terminated) while the threads of the pool may still call
|
|
1089
|
+
//it: they call it only while the environment is alive, under the lock its cleanup takes to mark it gone. Its
|
|
1090
|
+
//operations running are cancelled then, their results dropped.
|
|
1091
|
+
struct Environment {
|
|
1092
|
+
std::mutex mutex;
|
|
1093
|
+
bool alive = true;
|
|
1094
|
+
CompletionFunction function;
|
|
1095
|
+
//Only in the thread of JavaScript: the operations running (the loop of events is kept alive while there are some)
|
|
1096
|
+
std::unordered_map<Completion *, std::shared_ptr<Token>> running;
|
|
1097
|
+
};
|
|
1098
|
+
|
|
1099
|
+
std::shared_ptr<Environment> environmentOf(Napi::Env env)
|
|
1100
|
+
{
|
|
1101
|
+
return *env.GetInstanceData<std::shared_ptr<Environment>>();
|
|
1102
|
+
}
|
|
1103
|
+
|
|
1104
|
+
void complete(Napi::Env env, Napi::Function, std::nullptr_t *, Completion *completion)
|
|
1105
|
+
{
|
|
1106
|
+
//No environment: it is being torn down, the promise is gone with it. An environment being torn down may also refuse
|
|
1107
|
+
//to settle the promise (a worker terminated): nothing is left to tell then
|
|
1108
|
+
bool alive = false;
|
|
1109
|
+
if (env != nullptr) {
|
|
1110
|
+
std::lock_guard<std::mutex> lock(completion->environment->mutex);
|
|
1111
|
+
alive = completion->environment->alive;
|
|
1112
|
+
}
|
|
1113
|
+
if (alive) {
|
|
1114
|
+
try {
|
|
1115
|
+
Environment &environment = *completion->environment;
|
|
1116
|
+
environment.running.erase(completion);
|
|
1117
|
+
if (environment.running.empty()) environment.function.Unref(env);
|
|
1118
|
+
if (completion->failed) {
|
|
1119
|
+
completion->deferred.Reject(toError(env, completion->error).Value());
|
|
1120
|
+
} else {
|
|
1121
|
+
try {
|
|
1122
|
+
completion->deferred.Resolve(completion->builder(env));
|
|
1123
|
+
} catch (const Napi::Error &error) {
|
|
1124
|
+
completion->deferred.Reject(error.Value());
|
|
1125
|
+
} catch (...) {
|
|
1126
|
+
completion->deferred.Reject(currentError(env).Value());
|
|
1127
|
+
}
|
|
1128
|
+
}
|
|
1129
|
+
} catch (...) {
|
|
1130
|
+
}
|
|
1131
|
+
}
|
|
1132
|
+
delete completion;
|
|
1133
|
+
}
|
|
1134
|
+
|
|
1135
|
+
//runAsync(operation, arguments, token?): an operation in the pool of the addon, a promise of its result
|
|
1136
|
+
Napi::Value RunAsync(const Napi::CallbackInfo &info)
|
|
1137
|
+
{
|
|
1138
|
+
Job job;
|
|
1139
|
+
{
|
|
1140
|
+
const CopyingArguments copying;
|
|
1141
|
+
job = jobOf(info);
|
|
1142
|
+
}
|
|
1143
|
+
std::shared_ptr<Token> token = info.Length() > 2 && info[2].IsExternal() ? unwrap<Token>(info[2], TOKEN_TAG, "a token") : std::make_shared<Token>();
|
|
1144
|
+
std::shared_ptr<Environment> environment = environmentOf(info.Env());
|
|
1145
|
+
auto *completion = new Completion{environment, token, Napi::Promise::Deferred::New(info.Env()), nullptr, {}, false};
|
|
1146
|
+
Napi::Promise promise = completion->deferred.Promise();
|
|
1147
|
+
if (environment->running.empty()) environment->function.Ref(info.Env());
|
|
1148
|
+
environment->running.emplace(completion, token);
|
|
1149
|
+
Pool::shared().submit([job, completion]() {
|
|
1150
|
+
setCurrentToken(completion->token);
|
|
1151
|
+
try {
|
|
1152
|
+
checkpoint();
|
|
1153
|
+
completion->builder = job();
|
|
1154
|
+
checkpoint();
|
|
1155
|
+
} catch (...) {
|
|
1156
|
+
completion->failed = true;
|
|
1157
|
+
completion->error = currentErrorInfo();
|
|
1158
|
+
}
|
|
1159
|
+
setCurrentToken(nullptr);
|
|
1160
|
+
Environment &environment = *completion->environment;
|
|
1161
|
+
{
|
|
1162
|
+
std::lock_guard<std::mutex> lock(environment.mutex);
|
|
1163
|
+
if (environment.alive && environment.function.NonBlockingCall(completion) == napi_ok) return;
|
|
1164
|
+
}
|
|
1165
|
+
delete completion;
|
|
1166
|
+
});
|
|
1167
|
+
return promise;
|
|
1168
|
+
}
|
|
1169
|
+
|
|
1170
|
+
Napi::Value Versions(const Napi::CallbackInfo &info)
|
|
1171
|
+
{
|
|
1172
|
+
Napi::Object versions = Napi::Object::New(info.Env());
|
|
1173
|
+
versions.Set("symengine", SYMENGINE_VERSION);
|
|
1174
|
+
versions.Set("mpdecimal", mpd_version());
|
|
1175
|
+
versions.Set("eigen", std::to_string(EIGEN_WORLD_VERSION) + "." + std::to_string(EIGEN_MAJOR_VERSION) + "." + std::to_string(EIGEN_MINOR_VERSION));
|
|
1176
|
+
versions.Set("threads", Pool::shared().size());
|
|
1177
|
+
return versions;
|
|
1178
|
+
}
|
|
1179
|
+
|
|
1180
|
+
//scope(parent, definitions): a scope of definitions ([signature, body] pairs) over a parent scope or null
|
|
1181
|
+
Napi::Value MakeScope(const Napi::CallbackInfo &info)
|
|
1182
|
+
{
|
|
1183
|
+
std::shared_ptr<const Scope> parent = info[0].IsExternal() ? unwrap<const Scope>(info[0], SCOPE_TAG, "a scope") : nullptr;
|
|
1184
|
+
std::vector<std::pair<std::string, std::string>> definitions;
|
|
1185
|
+
Napi::Array array = info[1].As<Napi::Array>();
|
|
1186
|
+
for (uint32_t i = 0; i < array.Length(); i++) {
|
|
1187
|
+
Napi::Array pair = array.Get(i).As<Napi::Array>();
|
|
1188
|
+
definitions.emplace_back(stringAt(pair, 0, "The signature of a definition"), stringAt(pair, 1, "The body of a definition"));
|
|
1189
|
+
}
|
|
1190
|
+
std::shared_ptr<const Scope> scope = Scope::make(parent, definitions);
|
|
1191
|
+
return wrap(info.Env(), scope, SCOPE_TAG, 256 + 256 * static_cast<int64_t>(definitions.size()));
|
|
1192
|
+
}
|
|
1193
|
+
|
|
1194
|
+
//parse(scope, text): {kind: 'expression' | 'equation' | 'relation', left, right?, relation?}, or {kind: 'matrix',
|
|
1195
|
+
//matrix: {matrix, rows, columns}}
|
|
1196
|
+
Napi::Value Parse(const Napi::CallbackInfo &info)
|
|
1197
|
+
{
|
|
1198
|
+
std::shared_ptr<const Scope> scope = unwrap<const Scope>(info[0], SCOPE_TAG, "a scope");
|
|
1199
|
+
if (!info[1].IsString()) throw MathError(ErrorCode::Argument, "The formula is not a string");
|
|
1200
|
+
const std::string text = info[1].As<Napi::String>().Utf8Value();
|
|
1201
|
+
Parsed parsed = parse(text, scope->resolver());
|
|
1202
|
+
Napi::Object result = Napi::Object::New(info.Env());
|
|
1203
|
+
if (parsed.kind == Parsed::Kind::Matrix) {
|
|
1204
|
+
result.Set("kind", "matrix");
|
|
1205
|
+
result.Set("matrix", matrixValue(info.Env(), parsed.matrix));
|
|
1206
|
+
return result;
|
|
1207
|
+
}
|
|
1208
|
+
result.Set("kind", parsed.kind == Parsed::Kind::Expression ? "expression" : parsed.kind == Parsed::Kind::Equation ? "equation" : "relation");
|
|
1209
|
+
result.Set("left", wrapExpression(info.Env(), parsed.left));
|
|
1210
|
+
if (parsed.kind != Parsed::Kind::Expression) {
|
|
1211
|
+
result.Set("right", wrapExpression(info.Env(), parsed.right));
|
|
1212
|
+
result.Set("relation", parsed.relation);
|
|
1213
|
+
}
|
|
1214
|
+
return result;
|
|
1215
|
+
}
|
|
1216
|
+
|
|
1217
|
+
Napi::Value Text(const Napi::CallbackInfo &info)
|
|
1218
|
+
{
|
|
1219
|
+
return Napi::String::New(info.Env(), toText(unwrapExpression(info[0])));
|
|
1220
|
+
}
|
|
1221
|
+
|
|
1222
|
+
Napi::Value TeX(const Napi::CallbackInfo &info)
|
|
1223
|
+
{
|
|
1224
|
+
return Napi::String::New(info.Env(), toTeX(unwrapExpression(info[0])));
|
|
1225
|
+
}
|
|
1226
|
+
|
|
1227
|
+
//number(value): the exact value of a number of JavaScript
|
|
1228
|
+
Napi::Value Number(const Napi::CallbackInfo &info)
|
|
1229
|
+
{
|
|
1230
|
+
if (!info[0].IsNumber()) throw MathError(ErrorCode::Argument, "Not a number");
|
|
1231
|
+
return wrapExpression(info.Env(), numberFromDouble(info[0].As<Napi::Number>().DoubleValue()));
|
|
1232
|
+
}
|
|
1233
|
+
|
|
1234
|
+
Napi::Value ToNumber(const Napi::CallbackInfo &info)
|
|
1235
|
+
{
|
|
1236
|
+
return Napi::Number::New(info.Env(), toDouble(unwrapExpression(info[0])));
|
|
1237
|
+
}
|
|
1238
|
+
|
|
1239
|
+
Napi::Value ToComplex(const Napi::CallbackInfo &info)
|
|
1240
|
+
{
|
|
1241
|
+
const std::complex<double> value = toComplex(unwrapExpression(info[0]));
|
|
1242
|
+
Napi::Array result = Napi::Array::New(info.Env(), 2);
|
|
1243
|
+
result.Set(0u, value.real());
|
|
1244
|
+
result.Set(1u, value.imag());
|
|
1245
|
+
return result;
|
|
1246
|
+
}
|
|
1247
|
+
|
|
1248
|
+
Napi::Value Variables(const Napi::CallbackInfo &info)
|
|
1249
|
+
{
|
|
1250
|
+
const std::vector<std::string> names = variablesOf(unwrapExpression(info[0]));
|
|
1251
|
+
Napi::Array result = Napi::Array::New(info.Env(), names.size());
|
|
1252
|
+
for (uint32_t i = 0; i < names.size(); i++) result.Set(i, names[i]);
|
|
1253
|
+
return result;
|
|
1254
|
+
}
|
|
1255
|
+
|
|
1256
|
+
//A formula compiled into a function of numbers (CompiledFunction, of one output)
|
|
1257
|
+
struct Compiled {
|
|
1258
|
+
std::unique_ptr<CompiledFunction> function;
|
|
1259
|
+
size_t inputs;
|
|
1260
|
+
|
|
1261
|
+
void call(double *result, const double *values)
|
|
1262
|
+
{
|
|
1263
|
+
function->call(result, values);
|
|
1264
|
+
}
|
|
1265
|
+
};
|
|
1266
|
+
|
|
1267
|
+
//compile(expression, variables): a compiled function
|
|
1268
|
+
Napi::Value Compile(const Napi::CallbackInfo &info)
|
|
1269
|
+
{
|
|
1270
|
+
Expr expression = unwrapExpression(info[0]);
|
|
1271
|
+
Napi::Array names = info[1].As<Napi::Array>();
|
|
1272
|
+
std::vector<std::string> given;
|
|
1273
|
+
for (uint32_t i = 0; i < names.Length(); i++) given.push_back(stringAt(names, i, "A variable"));
|
|
1274
|
+
auto compiled = std::make_shared<Compiled>();
|
|
1275
|
+
compiled->inputs = given.size();
|
|
1276
|
+
try {
|
|
1277
|
+
compiled->function = std::make_unique<CompiledFunction>(given, std::vector<Expr>{expression});
|
|
1278
|
+
} catch (const MathError &error) {
|
|
1279
|
+
//The message of a compilation names its expression
|
|
1280
|
+
if (error.code() == ErrorCode::NotSupported) throw MathError(ErrorCode::NotSupported, "The expression cannot be compiled: " + toText(expression) + " has a function without a compiled form");
|
|
1281
|
+
throw;
|
|
1282
|
+
}
|
|
1283
|
+
return wrap(info.Env(), compiled, COMPILED_TAG, 1024);
|
|
1284
|
+
}
|
|
1285
|
+
|
|
1286
|
+
//call(compiled, ...values): the value of a compiled function
|
|
1287
|
+
Napi::Value Call(const Napi::CallbackInfo &info)
|
|
1288
|
+
{
|
|
1289
|
+
std::shared_ptr<Compiled> compiled = unwrap<Compiled>(info[0], COMPILED_TAG, "a compiled function");
|
|
1290
|
+
if (info.Length() - 1 != compiled->inputs) throw MathError(ErrorCode::Argument, "The function takes " + std::to_string(compiled->inputs) + " values");
|
|
1291
|
+
double inputs[64];
|
|
1292
|
+
std::vector<double> many;
|
|
1293
|
+
double *values = inputs;
|
|
1294
|
+
if (compiled->inputs > 64) {
|
|
1295
|
+
many.resize(compiled->inputs);
|
|
1296
|
+
values = many.data();
|
|
1297
|
+
}
|
|
1298
|
+
for (size_t i = 0; i < compiled->inputs; i++) values[i] = info[i + 1].As<Napi::Number>().DoubleValue();
|
|
1299
|
+
double result = 0;
|
|
1300
|
+
compiled->call(&result, values);
|
|
1301
|
+
return Napi::Number::New(info.Env(), result);
|
|
1302
|
+
}
|
|
1303
|
+
|
|
1304
|
+
//callBatch(compiled, inputs): the values of a compiled function for rows of inputs (a Float64Array, one row by call)
|
|
1305
|
+
Napi::Value CallBatch(const Napi::CallbackInfo &info)
|
|
1306
|
+
{
|
|
1307
|
+
std::shared_ptr<Compiled> compiled = unwrap<Compiled>(info[0], COMPILED_TAG, "a compiled function");
|
|
1308
|
+
if (!info[1].IsTypedArray() || info[1].As<Napi::TypedArray>().TypedArrayType() != napi_float64_array) throw MathError(ErrorCode::Argument, "The inputs are a Float64Array");
|
|
1309
|
+
Napi::Float64Array inputs = info[1].As<Napi::Float64Array>();
|
|
1310
|
+
const size_t width = compiled->inputs;
|
|
1311
|
+
if (width == 0 ? inputs.ElementLength() != 0 : inputs.ElementLength() % width != 0) throw MathError(ErrorCode::Argument, "The inputs are rows of " + std::to_string(width) + " values");
|
|
1312
|
+
const size_t rows = width == 0 ? 1 : inputs.ElementLength() / width;
|
|
1313
|
+
//(on aligned copies, see aligned())
|
|
1314
|
+
const std::vector<double> given = elementsOf(inputs);
|
|
1315
|
+
std::vector<double> values(rows);
|
|
1316
|
+
for (size_t row = 0; row < rows; row++) compiled->call(values.data() + row, given.data() + row * width);
|
|
1317
|
+
return float64ArrayOf(info.Env(), values);
|
|
1318
|
+
}
|
|
1319
|
+
|
|
1320
|
+
//token(): a token of cancellation; cancel(token, reason): cancel the operations given it ('cancelled' or 'timeout')
|
|
1321
|
+
Napi::Value MakeToken(const Napi::CallbackInfo &info)
|
|
1322
|
+
{
|
|
1323
|
+
return wrap(info.Env(), std::make_shared<Token>(), TOKEN_TAG, 0);
|
|
1324
|
+
}
|
|
1325
|
+
|
|
1326
|
+
Napi::Value Cancel(const Napi::CallbackInfo &info)
|
|
1327
|
+
{
|
|
1328
|
+
std::shared_ptr<Token> token = unwrap<Token>(info[0], TOKEN_TAG, "a token");
|
|
1329
|
+
const std::string reason = info[1].IsString() ? info[1].As<Napi::String>().Utf8Value() : "cancelled";
|
|
1330
|
+
token->cancel(reason == "timeout" ? Token::Reason::Timeout : Token::Reason::Cancelled);
|
|
1331
|
+
return info.Env().Undefined();
|
|
1332
|
+
}
|
|
1333
|
+
|
|
1334
|
+
Napi::Object Init(Napi::Env env, Napi::Object exports)
|
|
1335
|
+
{
|
|
1336
|
+
//The checkpoints of SymEngine's long loops are the ones of the addon (set once, before any operation runs)
|
|
1337
|
+
static const bool interruptible = (SymEngine::interruption_check = &checkpoint, true);
|
|
1338
|
+
(void) interruptible;
|
|
1339
|
+
//The asynchronous operations of the environment: its thread-safe function, unreferenced while none runs, and its
|
|
1340
|
+
//cleanup (registered after the function, so run before Node closes it)
|
|
1341
|
+
auto environment = std::make_shared<Environment>();
|
|
1342
|
+
environment->function = CompletionFunction::New(env, "lakutata-math", 0, 1);
|
|
1343
|
+
environment->function.Unref(env);
|
|
1344
|
+
env.SetInstanceData(new std::shared_ptr<Environment>(environment));
|
|
1345
|
+
env.AddCleanupHook([environment]() {
|
|
1346
|
+
{
|
|
1347
|
+
std::lock_guard<std::mutex> lock(environment->mutex);
|
|
1348
|
+
environment->alive = false;
|
|
1349
|
+
}
|
|
1350
|
+
for (const auto &[completion, token] : environment->running) token->cancel(Token::Reason::Cancelled);
|
|
1351
|
+
environment->running.clear();
|
|
1352
|
+
});
|
|
1353
|
+
exports.Set("versions", Napi::Function::New(env, guarded<Versions>));
|
|
1354
|
+
exports.Set("scope", Napi::Function::New(env, guarded<MakeScope>));
|
|
1355
|
+
exports.Set("parse", Napi::Function::New(env, guarded<Parse>));
|
|
1356
|
+
exports.Set("text", Napi::Function::New(env, guarded<Text>));
|
|
1357
|
+
exports.Set("tex", Napi::Function::New(env, guarded<TeX>));
|
|
1358
|
+
exports.Set("number", Napi::Function::New(env, guarded<Number>));
|
|
1359
|
+
exports.Set("toNumber", Napi::Function::New(env, guarded<ToNumber>));
|
|
1360
|
+
exports.Set("toComplex", Napi::Function::New(env, guarded<ToComplex>));
|
|
1361
|
+
exports.Set("variables", Napi::Function::New(env, guarded<Variables>));
|
|
1362
|
+
exports.Set("compile", Napi::Function::New(env, guarded<Compile>));
|
|
1363
|
+
exports.Set("call", Napi::Function::New(env, guarded<Call>));
|
|
1364
|
+
exports.Set("callBatch", Napi::Function::New(env, guarded<CallBatch>));
|
|
1365
|
+
exports.Set("token", Napi::Function::New(env, guarded<MakeToken>));
|
|
1366
|
+
exports.Set("cancel", Napi::Function::New(env, guarded<Cancel>));
|
|
1367
|
+
exports.Set("run", Napi::Function::New(env, guarded<Run>));
|
|
1368
|
+
exports.Set("runAsync", Napi::Function::New(env, guarded<RunAsync>));
|
|
1369
|
+
return exports;
|
|
1370
|
+
}
|
|
1371
|
+
|
|
1372
|
+
}
|
|
1373
|
+
|
|
1374
|
+
NODE_API_MODULE(math, Init)
|