tomoto 0.2.3 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +8 -10
- data/ext/tomoto/extconf.rb +6 -2
- data/ext/tomoto/{ext.cpp → tomoto.cpp} +1 -1
- data/lib/tomoto/version.rb +1 -1
- data/lib/tomoto.rb +5 -1
- data/vendor/EigenRand/EigenRand/Core.h +10 -10
- data/vendor/EigenRand/EigenRand/Dists/Basic.h +208 -9
- data/vendor/EigenRand/EigenRand/Dists/Discrete.h +52 -31
- data/vendor/EigenRand/EigenRand/Dists/GammaPoisson.h +9 -8
- data/vendor/EigenRand/EigenRand/Dists/NormalExp.h +28 -21
- data/vendor/EigenRand/EigenRand/EigenRand +11 -6
- data/vendor/EigenRand/EigenRand/Macro.h +13 -7
- data/vendor/EigenRand/EigenRand/MorePacketMath.h +348 -740
- data/vendor/EigenRand/EigenRand/MvDists/Multinomial.h +5 -3
- data/vendor/EigenRand/EigenRand/MvDists/MvNormal.h +9 -3
- data/vendor/EigenRand/EigenRand/PacketFilter.h +11 -253
- data/vendor/EigenRand/EigenRand/PacketRandomEngine.h +21 -47
- data/vendor/EigenRand/EigenRand/RandUtils.h +50 -344
- data/vendor/EigenRand/EigenRand/arch/AVX/MorePacketMath.h +619 -0
- data/vendor/EigenRand/EigenRand/arch/AVX/PacketFilter.h +149 -0
- data/vendor/EigenRand/EigenRand/arch/AVX/RandUtils.h +228 -0
- data/vendor/EigenRand/EigenRand/arch/NEON/MorePacketMath.h +473 -0
- data/vendor/EigenRand/EigenRand/arch/NEON/PacketFilter.h +142 -0
- data/vendor/EigenRand/EigenRand/arch/NEON/RandUtils.h +126 -0
- data/vendor/EigenRand/EigenRand/arch/SSE/MorePacketMath.h +501 -0
- data/vendor/EigenRand/EigenRand/arch/SSE/PacketFilter.h +133 -0
- data/vendor/EigenRand/EigenRand/arch/SSE/RandUtils.h +120 -0
- data/vendor/EigenRand/EigenRand/doc.h +24 -12
- data/vendor/EigenRand/README.md +57 -4
- data/vendor/eigen/COPYING.APACHE +203 -0
- data/vendor/eigen/COPYING.BSD +1 -1
- data/vendor/eigen/COPYING.MINPACK +51 -52
- data/vendor/eigen/Eigen/Cholesky +0 -1
- data/vendor/eigen/Eigen/Core +112 -265
- data/vendor/eigen/Eigen/Eigenvalues +2 -3
- data/vendor/eigen/Eigen/Geometry +5 -8
- data/vendor/eigen/Eigen/Householder +0 -1
- data/vendor/eigen/Eigen/Jacobi +0 -1
- data/vendor/eigen/Eigen/KLUSupport +41 -0
- data/vendor/eigen/Eigen/LU +2 -5
- data/vendor/eigen/Eigen/OrderingMethods +0 -3
- data/vendor/eigen/Eigen/PaStiXSupport +1 -0
- data/vendor/eigen/Eigen/PardisoSupport +0 -0
- data/vendor/eigen/Eigen/QR +2 -3
- data/vendor/eigen/Eigen/QtAlignedMalloc +0 -1
- data/vendor/eigen/Eigen/SVD +0 -1
- data/vendor/eigen/Eigen/Sparse +0 -2
- data/vendor/eigen/Eigen/SparseCholesky +0 -8
- data/vendor/eigen/Eigen/SparseLU +4 -0
- data/vendor/eigen/Eigen/SparseQR +0 -1
- data/vendor/eigen/Eigen/src/Cholesky/LDLT.h +42 -27
- data/vendor/eigen/Eigen/src/Cholesky/LLT.h +39 -23
- data/vendor/eigen/Eigen/src/CholmodSupport/CholmodSupport.h +90 -47
- data/vendor/eigen/Eigen/src/Core/ArithmeticSequence.h +413 -0
- data/vendor/eigen/Eigen/src/Core/Array.h +99 -11
- data/vendor/eigen/Eigen/src/Core/ArrayBase.h +3 -3
- data/vendor/eigen/Eigen/src/Core/ArrayWrapper.h +21 -21
- data/vendor/eigen/Eigen/src/Core/Assign.h +1 -1
- data/vendor/eigen/Eigen/src/Core/AssignEvaluator.h +125 -50
- data/vendor/eigen/Eigen/src/Core/Assign_MKL.h +10 -10
- data/vendor/eigen/Eigen/src/Core/BandMatrix.h +16 -16
- data/vendor/eigen/Eigen/src/Core/Block.h +56 -60
- data/vendor/eigen/Eigen/src/Core/BooleanRedux.h +29 -31
- data/vendor/eigen/Eigen/src/Core/CommaInitializer.h +7 -3
- data/vendor/eigen/Eigen/src/Core/CoreEvaluators.h +325 -272
- data/vendor/eigen/Eigen/src/Core/CoreIterators.h +5 -0
- data/vendor/eigen/Eigen/src/Core/CwiseBinaryOp.h +21 -22
- data/vendor/eigen/Eigen/src/Core/CwiseNullaryOp.h +153 -18
- data/vendor/eigen/Eigen/src/Core/CwiseUnaryOp.h +6 -6
- data/vendor/eigen/Eigen/src/Core/CwiseUnaryView.h +14 -10
- data/vendor/eigen/Eigen/src/Core/DenseBase.h +132 -42
- data/vendor/eigen/Eigen/src/Core/DenseCoeffsBase.h +25 -21
- data/vendor/eigen/Eigen/src/Core/DenseStorage.h +153 -71
- data/vendor/eigen/Eigen/src/Core/Diagonal.h +21 -23
- data/vendor/eigen/Eigen/src/Core/DiagonalMatrix.h +50 -2
- data/vendor/eigen/Eigen/src/Core/DiagonalProduct.h +1 -1
- data/vendor/eigen/Eigen/src/Core/Dot.h +10 -10
- data/vendor/eigen/Eigen/src/Core/EigenBase.h +10 -9
- data/vendor/eigen/Eigen/src/Core/ForceAlignedAccess.h +8 -4
- data/vendor/eigen/Eigen/src/Core/Fuzzy.h +3 -3
- data/vendor/eigen/Eigen/src/Core/GeneralProduct.h +20 -10
- data/vendor/eigen/Eigen/src/Core/GenericPacketMath.h +599 -152
- data/vendor/eigen/Eigen/src/Core/GlobalFunctions.h +40 -33
- data/vendor/eigen/Eigen/src/Core/IO.h +40 -7
- data/vendor/eigen/Eigen/src/Core/IndexedView.h +237 -0
- data/vendor/eigen/Eigen/src/Core/Inverse.h +9 -10
- data/vendor/eigen/Eigen/src/Core/Map.h +7 -7
- data/vendor/eigen/Eigen/src/Core/MapBase.h +10 -3
- data/vendor/eigen/Eigen/src/Core/MathFunctions.h +767 -125
- data/vendor/eigen/Eigen/src/Core/MathFunctionsImpl.h +118 -19
- data/vendor/eigen/Eigen/src/Core/Matrix.h +131 -25
- data/vendor/eigen/Eigen/src/Core/MatrixBase.h +21 -3
- data/vendor/eigen/Eigen/src/Core/NestByValue.h +25 -50
- data/vendor/eigen/Eigen/src/Core/NoAlias.h +4 -3
- data/vendor/eigen/Eigen/src/Core/NumTraits.h +107 -20
- data/vendor/eigen/Eigen/src/Core/PartialReduxEvaluator.h +232 -0
- data/vendor/eigen/Eigen/src/Core/PermutationMatrix.h +3 -31
- data/vendor/eigen/Eigen/src/Core/PlainObjectBase.h +152 -59
- data/vendor/eigen/Eigen/src/Core/Product.h +30 -25
- data/vendor/eigen/Eigen/src/Core/ProductEvaluators.h +192 -125
- data/vendor/eigen/Eigen/src/Core/Random.h +37 -1
- data/vendor/eigen/Eigen/src/Core/Redux.h +180 -170
- data/vendor/eigen/Eigen/src/Core/Ref.h +121 -23
- data/vendor/eigen/Eigen/src/Core/Replicate.h +8 -8
- data/vendor/eigen/Eigen/src/Core/Reshaped.h +454 -0
- data/vendor/eigen/Eigen/src/Core/ReturnByValue.h +7 -5
- data/vendor/eigen/Eigen/src/Core/Reverse.h +18 -12
- data/vendor/eigen/Eigen/src/Core/Select.h +8 -6
- data/vendor/eigen/Eigen/src/Core/SelfAdjointView.h +33 -20
- data/vendor/eigen/Eigen/src/Core/Solve.h +14 -14
- data/vendor/eigen/Eigen/src/Core/SolveTriangular.h +16 -16
- data/vendor/eigen/Eigen/src/Core/SolverBase.h +41 -3
- data/vendor/eigen/Eigen/src/Core/StableNorm.h +100 -70
- data/vendor/eigen/Eigen/src/Core/StlIterators.h +463 -0
- data/vendor/eigen/Eigen/src/Core/Stride.h +9 -4
- data/vendor/eigen/Eigen/src/Core/Swap.h +5 -4
- data/vendor/eigen/Eigen/src/Core/Transpose.h +88 -27
- data/vendor/eigen/Eigen/src/Core/Transpositions.h +26 -47
- data/vendor/eigen/Eigen/src/Core/TriangularMatrix.h +93 -75
- data/vendor/eigen/Eigen/src/Core/VectorBlock.h +5 -5
- data/vendor/eigen/Eigen/src/Core/VectorwiseOp.h +159 -70
- data/vendor/eigen/Eigen/src/Core/Visitor.h +137 -29
- data/vendor/eigen/Eigen/src/Core/arch/AVX/Complex.h +50 -129
- data/vendor/eigen/Eigen/src/Core/arch/AVX/MathFunctions.h +126 -337
- data/vendor/eigen/Eigen/src/Core/arch/AVX/PacketMath.h +1092 -155
- data/vendor/eigen/Eigen/src/Core/arch/AVX/TypeCasting.h +65 -1
- data/vendor/eigen/Eigen/src/Core/arch/AVX512/Complex.h +422 -0
- data/vendor/eigen/Eigen/src/Core/arch/AVX512/MathFunctions.h +207 -236
- data/vendor/eigen/Eigen/src/Core/arch/AVX512/PacketMath.h +1482 -495
- data/vendor/eigen/Eigen/src/Core/arch/AVX512/TypeCasting.h +89 -0
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/Complex.h +152 -165
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/MathFunctions.h +19 -251
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProduct.h +2937 -0
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductCommon.h +221 -0
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/MatrixProductMMA.h +629 -0
- data/vendor/eigen/Eigen/src/Core/arch/AltiVec/PacketMath.h +2042 -392
- data/vendor/eigen/Eigen/src/Core/arch/CUDA/Complex.h +235 -80
- data/vendor/eigen/Eigen/src/Core/arch/Default/BFloat16.h +700 -0
- data/vendor/eigen/Eigen/src/Core/arch/Default/ConjHelper.h +102 -14
- data/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctions.h +1649 -0
- data/vendor/eigen/Eigen/src/Core/arch/Default/GenericPacketMathFunctionsFwd.h +110 -0
- data/vendor/eigen/Eigen/src/Core/arch/Default/Half.h +942 -0
- data/vendor/eigen/Eigen/src/Core/arch/Default/Settings.h +1 -1
- data/vendor/eigen/Eigen/src/Core/arch/Default/TypeCasting.h +120 -0
- data/vendor/eigen/Eigen/src/Core/arch/{CUDA → GPU}/MathFunctions.h +16 -4
- data/vendor/eigen/Eigen/src/Core/arch/GPU/PacketMath.h +1685 -0
- data/vendor/eigen/Eigen/src/Core/arch/GPU/TypeCasting.h +80 -0
- data/vendor/eigen/Eigen/src/Core/arch/HIP/hcc/math_constants.h +23 -0
- data/vendor/eigen/Eigen/src/Core/arch/MSA/Complex.h +648 -0
- data/vendor/eigen/Eigen/src/Core/arch/MSA/MathFunctions.h +387 -0
- data/vendor/eigen/Eigen/src/Core/arch/MSA/PacketMath.h +1233 -0
- data/vendor/eigen/Eigen/src/Core/arch/NEON/Complex.h +313 -219
- data/vendor/eigen/Eigen/src/Core/arch/NEON/GeneralBlockPanelKernel.h +183 -0
- data/vendor/eigen/Eigen/src/Core/arch/NEON/MathFunctions.h +54 -70
- data/vendor/eigen/Eigen/src/Core/arch/NEON/PacketMath.h +4376 -549
- data/vendor/eigen/Eigen/src/Core/arch/NEON/TypeCasting.h +1419 -0
- data/vendor/eigen/Eigen/src/Core/arch/SSE/Complex.h +59 -179
- data/vendor/eigen/Eigen/src/Core/arch/SSE/MathFunctions.h +65 -428
- data/vendor/eigen/Eigen/src/Core/arch/SSE/PacketMath.h +893 -283
- data/vendor/eigen/Eigen/src/Core/arch/SSE/TypeCasting.h +65 -0
- data/vendor/eigen/Eigen/src/Core/arch/SVE/MathFunctions.h +44 -0
- data/vendor/eigen/Eigen/src/Core/arch/SVE/PacketMath.h +752 -0
- data/vendor/eigen/Eigen/src/Core/arch/SVE/TypeCasting.h +49 -0
- data/vendor/eigen/Eigen/src/Core/arch/SYCL/InteropHeaders.h +232 -0
- data/vendor/eigen/Eigen/src/Core/arch/SYCL/MathFunctions.h +301 -0
- data/vendor/eigen/Eigen/src/Core/arch/SYCL/PacketMath.h +670 -0
- data/vendor/eigen/Eigen/src/Core/arch/SYCL/SyclMemoryModel.h +694 -0
- data/vendor/eigen/Eigen/src/Core/arch/SYCL/TypeCasting.h +85 -0
- data/vendor/eigen/Eigen/src/Core/arch/ZVector/Complex.h +212 -183
- data/vendor/eigen/Eigen/src/Core/arch/ZVector/MathFunctions.h +101 -5
- data/vendor/eigen/Eigen/src/Core/arch/ZVector/PacketMath.h +510 -395
- data/vendor/eigen/Eigen/src/Core/functors/AssignmentFunctors.h +11 -2
- data/vendor/eigen/Eigen/src/Core/functors/BinaryFunctors.h +112 -46
- data/vendor/eigen/Eigen/src/Core/functors/NullaryFunctors.h +31 -30
- data/vendor/eigen/Eigen/src/Core/functors/StlFunctors.h +32 -2
- data/vendor/eigen/Eigen/src/Core/functors/UnaryFunctors.h +355 -16
- data/vendor/eigen/Eigen/src/Core/products/GeneralBlockPanelKernel.h +1075 -586
- data/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix.h +49 -24
- data/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular.h +41 -35
- data/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrixTriangular_BLAS.h +6 -6
- data/vendor/eigen/Eigen/src/Core/products/GeneralMatrixMatrix_BLAS.h +4 -2
- data/vendor/eigen/Eigen/src/Core/products/GeneralMatrixVector.h +382 -483
- data/vendor/eigen/Eigen/src/Core/products/Parallelizer.h +22 -5
- data/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix.h +53 -30
- data/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixMatrix_BLAS.h +16 -8
- data/vendor/eigen/Eigen/src/Core/products/SelfadjointMatrixVector.h +8 -6
- data/vendor/eigen/Eigen/src/Core/products/SelfadjointProduct.h +4 -4
- data/vendor/eigen/Eigen/src/Core/products/SelfadjointRank2Update.h +5 -4
- data/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix.h +33 -27
- data/vendor/eigen/Eigen/src/Core/products/TriangularMatrixMatrix_BLAS.h +14 -12
- data/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix.h +36 -34
- data/vendor/eigen/Eigen/src/Core/products/TriangularSolverMatrix_BLAS.h +8 -4
- data/vendor/eigen/Eigen/src/Core/products/TriangularSolverVector.h +13 -10
- data/vendor/eigen/Eigen/src/Core/util/BlasUtil.h +304 -119
- data/vendor/eigen/Eigen/src/Core/util/ConfigureVectorization.h +512 -0
- data/vendor/eigen/Eigen/src/Core/util/Constants.h +25 -9
- data/vendor/eigen/Eigen/src/Core/util/DisableStupidWarnings.h +26 -3
- data/vendor/eigen/Eigen/src/Core/util/ForwardDeclarations.h +29 -9
- data/vendor/eigen/Eigen/src/Core/util/IndexedViewHelper.h +186 -0
- data/vendor/eigen/Eigen/src/Core/util/IntegralConstant.h +272 -0
- data/vendor/eigen/Eigen/src/Core/util/MKL_support.h +8 -1
- data/vendor/eigen/Eigen/src/Core/util/Macros.h +709 -246
- data/vendor/eigen/Eigen/src/Core/util/Memory.h +222 -52
- data/vendor/eigen/Eigen/src/Core/util/Meta.h +355 -77
- data/vendor/eigen/Eigen/src/Core/util/ReenableStupidWarnings.h +5 -1
- data/vendor/eigen/Eigen/src/Core/util/ReshapedHelper.h +51 -0
- data/vendor/eigen/Eigen/src/Core/util/StaticAssert.h +8 -5
- data/vendor/eigen/Eigen/src/Core/util/SymbolicIndex.h +293 -0
- data/vendor/eigen/Eigen/src/Core/util/XprHelper.h +65 -30
- data/vendor/eigen/Eigen/src/Eigenvalues/ComplexEigenSolver.h +1 -1
- data/vendor/eigen/Eigen/src/Eigenvalues/ComplexSchur.h +7 -4
- data/vendor/eigen/Eigen/src/Eigenvalues/EigenSolver.h +2 -2
- data/vendor/eigen/Eigen/src/Eigenvalues/GeneralizedSelfAdjointEigenSolver.h +1 -1
- data/vendor/eigen/Eigen/src/Eigenvalues/HessenbergDecomposition.h +2 -2
- data/vendor/eigen/Eigen/src/Eigenvalues/MatrixBaseEigenvalues.h +2 -2
- data/vendor/eigen/Eigen/src/Eigenvalues/RealQZ.h +9 -6
- data/vendor/eigen/Eigen/src/Eigenvalues/RealSchur.h +21 -9
- data/vendor/eigen/Eigen/src/Eigenvalues/SelfAdjointEigenSolver.h +77 -43
- data/vendor/eigen/Eigen/src/Eigenvalues/Tridiagonalization.h +20 -15
- data/vendor/eigen/Eigen/src/Geometry/AlignedBox.h +99 -5
- data/vendor/eigen/Eigen/src/Geometry/AngleAxis.h +4 -4
- data/vendor/eigen/Eigen/src/Geometry/EulerAngles.h +3 -3
- data/vendor/eigen/Eigen/src/Geometry/Homogeneous.h +15 -11
- data/vendor/eigen/Eigen/src/Geometry/Hyperplane.h +1 -1
- data/vendor/eigen/Eigen/src/Geometry/OrthoMethods.h +3 -2
- data/vendor/eigen/Eigen/src/Geometry/ParametrizedLine.h +39 -2
- data/vendor/eigen/Eigen/src/Geometry/Quaternion.h +70 -14
- data/vendor/eigen/Eigen/src/Geometry/Rotation2D.h +3 -3
- data/vendor/eigen/Eigen/src/Geometry/Scaling.h +23 -5
- data/vendor/eigen/Eigen/src/Geometry/Transform.h +88 -67
- data/vendor/eigen/Eigen/src/Geometry/Translation.h +6 -12
- data/vendor/eigen/Eigen/src/Geometry/Umeyama.h +1 -1
- data/vendor/eigen/Eigen/src/Geometry/arch/Geometry_SIMD.h +168 -0
- data/vendor/eigen/Eigen/src/Householder/BlockHouseholder.h +9 -2
- data/vendor/eigen/Eigen/src/Householder/Householder.h +8 -4
- data/vendor/eigen/Eigen/src/Householder/HouseholderSequence.h +123 -48
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/BasicPreconditioners.h +15 -15
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/BiCGSTAB.h +7 -23
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/ConjugateGradient.h +5 -22
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteCholesky.h +41 -47
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/IncompleteLUT.h +51 -60
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/IterativeSolverBase.h +70 -20
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/LeastSquareConjugateGradient.h +2 -20
- data/vendor/eigen/Eigen/src/IterativeLinearSolvers/SolveWithGuess.h +11 -9
- data/vendor/eigen/Eigen/src/Jacobi/Jacobi.h +31 -10
- data/vendor/eigen/Eigen/src/KLUSupport/KLUSupport.h +358 -0
- data/vendor/eigen/Eigen/src/LU/Determinant.h +35 -19
- data/vendor/eigen/Eigen/src/LU/FullPivLU.h +29 -43
- data/vendor/eigen/Eigen/src/LU/InverseImpl.h +25 -8
- data/vendor/eigen/Eigen/src/LU/PartialPivLU.h +71 -58
- data/vendor/eigen/Eigen/src/LU/arch/InverseSize4.h +351 -0
- data/vendor/eigen/Eigen/src/OrderingMethods/Amd.h +7 -17
- data/vendor/eigen/Eigen/src/OrderingMethods/Eigen_Colamd.h +297 -277
- data/vendor/eigen/Eigen/src/OrderingMethods/Ordering.h +6 -10
- data/vendor/eigen/Eigen/src/PaStiXSupport/PaStiXSupport.h +1 -1
- data/vendor/eigen/Eigen/src/PardisoSupport/PardisoSupport.h +9 -7
- data/vendor/eigen/Eigen/src/QR/ColPivHouseholderQR.h +41 -20
- data/vendor/eigen/Eigen/src/QR/CompleteOrthogonalDecomposition.h +100 -27
- data/vendor/eigen/Eigen/src/QR/FullPivHouseholderQR.h +59 -22
- data/vendor/eigen/Eigen/src/QR/HouseholderQR.h +48 -23
- data/vendor/eigen/Eigen/src/SPQRSupport/SuiteSparseQRSupport.h +25 -3
- data/vendor/eigen/Eigen/src/SVD/BDCSVD.h +183 -63
- data/vendor/eigen/Eigen/src/SVD/JacobiSVD.h +22 -14
- data/vendor/eigen/Eigen/src/SVD/SVDBase.h +83 -22
- data/vendor/eigen/Eigen/src/SVD/UpperBidiagonalization.h +3 -3
- data/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky.h +17 -9
- data/vendor/eigen/Eigen/src/SparseCholesky/SimplicialCholesky_impl.h +12 -37
- data/vendor/eigen/Eigen/src/SparseCore/AmbiVector.h +3 -2
- data/vendor/eigen/Eigen/src/SparseCore/CompressedStorage.h +16 -0
- data/vendor/eigen/Eigen/src/SparseCore/ConservativeSparseSparseProduct.h +6 -6
- data/vendor/eigen/Eigen/src/SparseCore/SparseAssign.h +81 -27
- data/vendor/eigen/Eigen/src/SparseCore/SparseBlock.h +25 -57
- data/vendor/eigen/Eigen/src/SparseCore/SparseCompressedBase.h +40 -11
- data/vendor/eigen/Eigen/src/SparseCore/SparseCwiseBinaryOp.h +11 -15
- data/vendor/eigen/Eigen/src/SparseCore/SparseCwiseUnaryOp.h +4 -2
- data/vendor/eigen/Eigen/src/SparseCore/SparseDenseProduct.h +30 -8
- data/vendor/eigen/Eigen/src/SparseCore/SparseMatrix.h +126 -11
- data/vendor/eigen/Eigen/src/SparseCore/SparseMatrixBase.h +5 -12
- data/vendor/eigen/Eigen/src/SparseCore/SparseProduct.h +13 -1
- data/vendor/eigen/Eigen/src/SparseCore/SparseRef.h +7 -7
- data/vendor/eigen/Eigen/src/SparseCore/SparseSelfAdjointView.h +5 -2
- data/vendor/eigen/Eigen/src/SparseCore/SparseUtil.h +8 -0
- data/vendor/eigen/Eigen/src/SparseCore/SparseVector.h +1 -1
- data/vendor/eigen/Eigen/src/SparseCore/SparseView.h +1 -0
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU.h +162 -12
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU_Memory.h +1 -1
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU_SupernodalMatrix.h +76 -2
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU_column_dfs.h +2 -2
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU_gemm_kernel.h +1 -1
- data/vendor/eigen/Eigen/src/SparseLU/SparseLU_panel_bmod.h +1 -1
- data/vendor/eigen/Eigen/src/SparseQR/SparseQR.h +19 -6
- data/vendor/eigen/Eigen/src/StlSupport/StdDeque.h +2 -12
- data/vendor/eigen/Eigen/src/StlSupport/StdList.h +2 -2
- data/vendor/eigen/Eigen/src/StlSupport/StdVector.h +2 -2
- data/vendor/eigen/Eigen/src/SuperLUSupport/SuperLUSupport.h +6 -8
- data/vendor/eigen/Eigen/src/UmfPackSupport/UmfPackSupport.h +175 -39
- data/vendor/eigen/Eigen/src/misc/lapacke.h +5 -4
- data/vendor/eigen/Eigen/src/plugins/ArrayCwiseBinaryOps.h +28 -2
- data/vendor/eigen/Eigen/src/plugins/ArrayCwiseUnaryOps.h +155 -11
- data/vendor/eigen/Eigen/src/plugins/BlockMethods.h +626 -242
- data/vendor/eigen/Eigen/src/plugins/CommonCwiseUnaryOps.h +14 -0
- data/vendor/eigen/Eigen/src/plugins/IndexedViewMethods.h +262 -0
- data/vendor/eigen/Eigen/src/plugins/MatrixCwiseBinaryOps.h +4 -4
- data/vendor/eigen/Eigen/src/plugins/MatrixCwiseUnaryOps.h +10 -0
- data/vendor/eigen/Eigen/src/plugins/ReshapedMethods.h +149 -0
- data/vendor/eigen/README.md +2 -0
- data/vendor/eigen/bench/btl/README +1 -1
- data/vendor/eigen/bench/tensors/README +6 -7
- data/vendor/eigen/ci/README.md +56 -0
- data/vendor/eigen/demos/mix_eigen_and_c/README +1 -1
- data/vendor/eigen/unsupported/Eigen/CXX11/src/Tensor/README.md +213 -158
- data/vendor/eigen/unsupported/README.txt +1 -1
- data/vendor/tomotopy/README.kr.rst +21 -0
- data/vendor/tomotopy/README.rst +20 -0
- data/vendor/tomotopy/src/Labeling/FoRelevance.cpp +2 -2
- data/vendor/tomotopy/src/Labeling/Phraser.hpp +1 -1
- data/vendor/tomotopy/src/TopicModel/CTModel.hpp +2 -1
- data/vendor/tomotopy/src/TopicModel/DMRModel.hpp +2 -1
- data/vendor/tomotopy/src/TopicModel/DTModel.hpp +1 -1
- data/vendor/tomotopy/src/TopicModel/GDMRModel.hpp +2 -2
- data/vendor/tomotopy/src/TopicModel/HDP.h +1 -0
- data/vendor/tomotopy/src/TopicModel/HDPModel.hpp +53 -2
- data/vendor/tomotopy/src/TopicModel/HLDAModel.hpp +1 -1
- data/vendor/tomotopy/src/TopicModel/HPAModel.hpp +1 -0
- data/vendor/tomotopy/src/TopicModel/LDACVB0Model.hpp +2 -2
- data/vendor/tomotopy/src/TopicModel/LDAModel.hpp +16 -5
- data/vendor/tomotopy/src/TopicModel/LLDAModel.hpp +1 -0
- data/vendor/tomotopy/src/TopicModel/MGLDAModel.hpp +1 -0
- data/vendor/tomotopy/src/TopicModel/PLDAModel.hpp +1 -0
- data/vendor/tomotopy/src/TopicModel/PT.h +3 -1
- data/vendor/tomotopy/src/TopicModel/PTModel.hpp +31 -1
- data/vendor/tomotopy/src/TopicModel/SLDAModel.hpp +2 -2
- data/vendor/tomotopy/src/TopicModel/TopicModel.hpp +7 -5
- data/vendor/tomotopy/src/Utils/EigenAddonOps.hpp +36 -1
- data/vendor/tomotopy/src/Utils/exception.h +6 -0
- data/vendor/tomotopy/src/Utils/sample.hpp +14 -12
- data/vendor/tomotopy/src/Utils/sse_gamma.h +0 -3
- metadata +60 -14
- data/vendor/eigen/Eigen/CMakeLists.txt +0 -19
- data/vendor/eigen/Eigen/src/Core/arch/CUDA/Half.h +0 -674
- data/vendor/eigen/Eigen/src/Core/arch/CUDA/PacketMath.h +0 -333
- data/vendor/eigen/Eigen/src/Core/arch/CUDA/PacketMathHalf.h +0 -1124
- data/vendor/eigen/Eigen/src/Core/arch/CUDA/TypeCasting.h +0 -212
- data/vendor/eigen/Eigen/src/Geometry/arch/Geometry_SSE.h +0 -161
- data/vendor/eigen/Eigen/src/LU/arch/Inverse_SSE.h +0 -338
@@ -36,7 +36,7 @@ namespace std \
|
|
36
36
|
vector(InputIterator first, InputIterator last, const allocator_type& a = allocator_type()) : vector_base(first, last, a) {} \
|
37
37
|
vector(const vector& c) : vector_base(c) {} \
|
38
38
|
explicit vector(size_type num, const value_type& val = value_type()) : vector_base(num, val) {} \
|
39
|
-
vector(iterator
|
39
|
+
vector(iterator start_, iterator end_) : vector_base(start_, end_) {} \
|
40
40
|
vector& operator=(const vector& x) { \
|
41
41
|
vector_base::operator=(x); \
|
42
42
|
return *this; \
|
@@ -62,7 +62,7 @@ namespace std {
|
|
62
62
|
: vector_base(first, last, a) {} \
|
63
63
|
vector(const vector& c) : vector_base(c) {} \
|
64
64
|
explicit vector(size_type num, const value_type& val = value_type()) : vector_base(num, val) {} \
|
65
|
-
vector(iterator
|
65
|
+
vector(iterator start_, iterator end_) : vector_base(start_, end_) {} \
|
66
66
|
vector& operator=(const vector& x) { \
|
67
67
|
vector_base::operator=(x); \
|
68
68
|
return *this; \
|
@@ -217,12 +217,12 @@ struct SluMatrix : SuperMatrix
|
|
217
217
|
res.setScalarType<typename MatrixType::Scalar>();
|
218
218
|
|
219
219
|
// FIXME the following is not very accurate
|
220
|
-
if (MatrixType::Flags & Upper)
|
220
|
+
if (int(MatrixType::Flags) & int(Upper))
|
221
221
|
res.Mtype = SLU_TRU;
|
222
|
-
if (MatrixType::Flags & Lower)
|
222
|
+
if (int(MatrixType::Flags) & int(Lower))
|
223
223
|
res.Mtype = SLU_TRL;
|
224
224
|
|
225
|
-
eigen_assert(((MatrixType::Flags & SelfAdjoint)==0) && "SelfAdjoint matrix shape not supported by SuperLU");
|
225
|
+
eigen_assert(((int(MatrixType::Flags) & int(SelfAdjoint))==0) && "SelfAdjoint matrix shape not supported by SuperLU");
|
226
226
|
|
227
227
|
return res;
|
228
228
|
}
|
@@ -352,7 +352,7 @@ class SuperLUBase : public SparseSolverBase<Derived>
|
|
352
352
|
|
353
353
|
/** \brief Reports whether previous computation was successful.
|
354
354
|
*
|
355
|
-
* \returns \c Success if computation was
|
355
|
+
* \returns \c Success if computation was successful,
|
356
356
|
* \c NumericalIssue if the matrix.appears to be negative.
|
357
357
|
*/
|
358
358
|
ComputationInfo info() const
|
@@ -650,9 +650,8 @@ void SuperLU<MatrixType>::_solve_impl(const MatrixBase<Rhs> &b, MatrixBase<Dest>
|
|
650
650
|
{
|
651
651
|
eigen_assert(m_factorizationIsOk && "The decomposition is not in a valid state for solving, you must first call either compute() or analyzePattern()/factorize()");
|
652
652
|
|
653
|
-
const Index size = m_matrix.rows();
|
654
653
|
const Index rhsCols = b.cols();
|
655
|
-
eigen_assert(
|
654
|
+
eigen_assert(m_matrix.rows()==b.rows());
|
656
655
|
|
657
656
|
m_sluOptions.Trans = NOTRANS;
|
658
657
|
m_sluOptions.Fact = FACTORED;
|
@@ -974,9 +973,8 @@ void SuperILU<MatrixType>::_solve_impl(const MatrixBase<Rhs> &b, MatrixBase<Dest
|
|
974
973
|
{
|
975
974
|
eigen_assert(m_factorizationIsOk && "The decomposition is not in a valid state for solving, you must first call either compute() or analyzePattern()/factorize()");
|
976
975
|
|
977
|
-
const int size = m_matrix.rows();
|
978
976
|
const int rhsCols = b.cols();
|
979
|
-
eigen_assert(
|
977
|
+
eigen_assert(m_matrix.rows()==b.rows());
|
980
978
|
|
981
979
|
m_sluOptions.Trans = NOTRANS;
|
982
980
|
m_sluOptions.Fact = FACTORED;
|
@@ -10,6 +10,16 @@
|
|
10
10
|
#ifndef EIGEN_UMFPACKSUPPORT_H
|
11
11
|
#define EIGEN_UMFPACKSUPPORT_H
|
12
12
|
|
13
|
+
// for compatibility with super old version of umfpack,
|
14
|
+
// not sure this is really needed, but this is harmless.
|
15
|
+
#ifndef SuiteSparse_long
|
16
|
+
#ifdef UF_long
|
17
|
+
#define SuiteSparse_long UF_long
|
18
|
+
#else
|
19
|
+
#error neither SuiteSparse_long nor UF_long are defined
|
20
|
+
#endif
|
21
|
+
#endif
|
22
|
+
|
13
23
|
namespace Eigen {
|
14
24
|
|
15
25
|
/* TODO extract L, extract U, compute det, etc... */
|
@@ -17,42 +27,85 @@ namespace Eigen {
|
|
17
27
|
// generic double/complex<double> wrapper functions:
|
18
28
|
|
19
29
|
|
20
|
-
|
30
|
+
// Defaults
|
31
|
+
inline void umfpack_defaults(double control[UMFPACK_CONTROL], double, int)
|
21
32
|
{ umfpack_di_defaults(control); }
|
22
33
|
|
23
|
-
inline void umfpack_defaults(double control[UMFPACK_CONTROL], std::complex<double
|
34
|
+
inline void umfpack_defaults(double control[UMFPACK_CONTROL], std::complex<double>, int)
|
24
35
|
{ umfpack_zi_defaults(control); }
|
25
36
|
|
26
|
-
inline void
|
37
|
+
inline void umfpack_defaults(double control[UMFPACK_CONTROL], double, SuiteSparse_long)
|
38
|
+
{ umfpack_dl_defaults(control); }
|
39
|
+
|
40
|
+
inline void umfpack_defaults(double control[UMFPACK_CONTROL], std::complex<double>, SuiteSparse_long)
|
41
|
+
{ umfpack_zl_defaults(control); }
|
42
|
+
|
43
|
+
// Report info
|
44
|
+
inline void umfpack_report_info(double control[UMFPACK_CONTROL], double info[UMFPACK_INFO], double, int)
|
27
45
|
{ umfpack_di_report_info(control, info);}
|
28
46
|
|
29
|
-
inline void umfpack_report_info(double control[UMFPACK_CONTROL], double info[UMFPACK_INFO], std::complex<double
|
47
|
+
inline void umfpack_report_info(double control[UMFPACK_CONTROL], double info[UMFPACK_INFO], std::complex<double>, int)
|
30
48
|
{ umfpack_zi_report_info(control, info);}
|
31
49
|
|
32
|
-
inline void
|
50
|
+
inline void umfpack_report_info(double control[UMFPACK_CONTROL], double info[UMFPACK_INFO], double, SuiteSparse_long)
|
51
|
+
{ umfpack_dl_report_info(control, info);}
|
52
|
+
|
53
|
+
inline void umfpack_report_info(double control[UMFPACK_CONTROL], double info[UMFPACK_INFO], std::complex<double>, SuiteSparse_long)
|
54
|
+
{ umfpack_zl_report_info(control, info);}
|
55
|
+
|
56
|
+
// Report status
|
57
|
+
inline void umfpack_report_status(double control[UMFPACK_CONTROL], int status, double, int)
|
33
58
|
{ umfpack_di_report_status(control, status);}
|
34
59
|
|
35
|
-
inline void umfpack_report_status(double control[UMFPACK_CONTROL], int status, std::complex<double
|
60
|
+
inline void umfpack_report_status(double control[UMFPACK_CONTROL], int status, std::complex<double>, int)
|
36
61
|
{ umfpack_zi_report_status(control, status);}
|
37
62
|
|
38
|
-
inline void
|
63
|
+
inline void umfpack_report_status(double control[UMFPACK_CONTROL], int status, double, SuiteSparse_long)
|
64
|
+
{ umfpack_dl_report_status(control, status);}
|
65
|
+
|
66
|
+
inline void umfpack_report_status(double control[UMFPACK_CONTROL], int status, std::complex<double>, SuiteSparse_long)
|
67
|
+
{ umfpack_zl_report_status(control, status);}
|
68
|
+
|
69
|
+
// report control
|
70
|
+
inline void umfpack_report_control(double control[UMFPACK_CONTROL], double, int)
|
39
71
|
{ umfpack_di_report_control(control);}
|
40
72
|
|
41
|
-
inline void umfpack_report_control(double control[UMFPACK_CONTROL], std::complex<double
|
73
|
+
inline void umfpack_report_control(double control[UMFPACK_CONTROL], std::complex<double>, int)
|
42
74
|
{ umfpack_zi_report_control(control);}
|
43
75
|
|
44
|
-
inline void
|
76
|
+
inline void umfpack_report_control(double control[UMFPACK_CONTROL], double, SuiteSparse_long)
|
77
|
+
{ umfpack_dl_report_control(control);}
|
78
|
+
|
79
|
+
inline void umfpack_report_control(double control[UMFPACK_CONTROL], std::complex<double>, SuiteSparse_long)
|
80
|
+
{ umfpack_zl_report_control(control);}
|
81
|
+
|
82
|
+
// Free numeric
|
83
|
+
inline void umfpack_free_numeric(void **Numeric, double, int)
|
45
84
|
{ umfpack_di_free_numeric(Numeric); *Numeric = 0; }
|
46
85
|
|
47
|
-
inline void umfpack_free_numeric(void **Numeric, std::complex<double
|
86
|
+
inline void umfpack_free_numeric(void **Numeric, std::complex<double>, int)
|
48
87
|
{ umfpack_zi_free_numeric(Numeric); *Numeric = 0; }
|
49
88
|
|
50
|
-
inline void
|
89
|
+
inline void umfpack_free_numeric(void **Numeric, double, SuiteSparse_long)
|
90
|
+
{ umfpack_dl_free_numeric(Numeric); *Numeric = 0; }
|
91
|
+
|
92
|
+
inline void umfpack_free_numeric(void **Numeric, std::complex<double>, SuiteSparse_long)
|
93
|
+
{ umfpack_zl_free_numeric(Numeric); *Numeric = 0; }
|
94
|
+
|
95
|
+
// Free symbolic
|
96
|
+
inline void umfpack_free_symbolic(void **Symbolic, double, int)
|
51
97
|
{ umfpack_di_free_symbolic(Symbolic); *Symbolic = 0; }
|
52
98
|
|
53
|
-
inline void umfpack_free_symbolic(void **Symbolic, std::complex<double
|
99
|
+
inline void umfpack_free_symbolic(void **Symbolic, std::complex<double>, int)
|
54
100
|
{ umfpack_zi_free_symbolic(Symbolic); *Symbolic = 0; }
|
55
101
|
|
102
|
+
inline void umfpack_free_symbolic(void **Symbolic, double, SuiteSparse_long)
|
103
|
+
{ umfpack_dl_free_symbolic(Symbolic); *Symbolic = 0; }
|
104
|
+
|
105
|
+
inline void umfpack_free_symbolic(void **Symbolic, std::complex<double>, SuiteSparse_long)
|
106
|
+
{ umfpack_zl_free_symbolic(Symbolic); *Symbolic = 0; }
|
107
|
+
|
108
|
+
// Symbolic
|
56
109
|
inline int umfpack_symbolic(int n_row,int n_col,
|
57
110
|
const int Ap[], const int Ai[], const double Ax[], void **Symbolic,
|
58
111
|
const double Control [UMFPACK_CONTROL], double Info [UMFPACK_INFO])
|
@@ -66,7 +119,21 @@ inline int umfpack_symbolic(int n_row,int n_col,
|
|
66
119
|
{
|
67
120
|
return umfpack_zi_symbolic(n_row,n_col,Ap,Ai,&numext::real_ref(Ax[0]),0,Symbolic,Control,Info);
|
68
121
|
}
|
122
|
+
inline SuiteSparse_long umfpack_symbolic( SuiteSparse_long n_row,SuiteSparse_long n_col,
|
123
|
+
const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const double Ax[], void **Symbolic,
|
124
|
+
const double Control [UMFPACK_CONTROL], double Info [UMFPACK_INFO])
|
125
|
+
{
|
126
|
+
return umfpack_dl_symbolic(n_row,n_col,Ap,Ai,Ax,Symbolic,Control,Info);
|
127
|
+
}
|
69
128
|
|
129
|
+
inline SuiteSparse_long umfpack_symbolic( SuiteSparse_long n_row,SuiteSparse_long n_col,
|
130
|
+
const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const std::complex<double> Ax[], void **Symbolic,
|
131
|
+
const double Control [UMFPACK_CONTROL], double Info [UMFPACK_INFO])
|
132
|
+
{
|
133
|
+
return umfpack_zl_symbolic(n_row,n_col,Ap,Ai,&numext::real_ref(Ax[0]),0,Symbolic,Control,Info);
|
134
|
+
}
|
135
|
+
|
136
|
+
// Numeric
|
70
137
|
inline int umfpack_numeric( const int Ap[], const int Ai[], const double Ax[],
|
71
138
|
void *Symbolic, void **Numeric,
|
72
139
|
const double Control[UMFPACK_CONTROL],double Info [UMFPACK_INFO])
|
@@ -80,7 +147,21 @@ inline int umfpack_numeric( const int Ap[], const int Ai[], const std::complex<d
|
|
80
147
|
{
|
81
148
|
return umfpack_zi_numeric(Ap,Ai,&numext::real_ref(Ax[0]),0,Symbolic,Numeric,Control,Info);
|
82
149
|
}
|
150
|
+
inline SuiteSparse_long umfpack_numeric(const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const double Ax[],
|
151
|
+
void *Symbolic, void **Numeric,
|
152
|
+
const double Control[UMFPACK_CONTROL],double Info [UMFPACK_INFO])
|
153
|
+
{
|
154
|
+
return umfpack_dl_numeric(Ap,Ai,Ax,Symbolic,Numeric,Control,Info);
|
155
|
+
}
|
83
156
|
|
157
|
+
inline SuiteSparse_long umfpack_numeric(const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const std::complex<double> Ax[],
|
158
|
+
void *Symbolic, void **Numeric,
|
159
|
+
const double Control[UMFPACK_CONTROL],double Info [UMFPACK_INFO])
|
160
|
+
{
|
161
|
+
return umfpack_zl_numeric(Ap,Ai,&numext::real_ref(Ax[0]),0,Symbolic,Numeric,Control,Info);
|
162
|
+
}
|
163
|
+
|
164
|
+
// solve
|
84
165
|
inline int umfpack_solve( int sys, const int Ap[], const int Ai[], const double Ax[],
|
85
166
|
double X[], const double B[], void *Numeric,
|
86
167
|
const double Control[UMFPACK_CONTROL], double Info[UMFPACK_INFO])
|
@@ -95,6 +176,21 @@ inline int umfpack_solve( int sys, const int Ap[], const int Ai[], const std::co
|
|
95
176
|
return umfpack_zi_solve(sys,Ap,Ai,&numext::real_ref(Ax[0]),0,&numext::real_ref(X[0]),0,&numext::real_ref(B[0]),0,Numeric,Control,Info);
|
96
177
|
}
|
97
178
|
|
179
|
+
inline SuiteSparse_long umfpack_solve(int sys, const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const double Ax[],
|
180
|
+
double X[], const double B[], void *Numeric,
|
181
|
+
const double Control[UMFPACK_CONTROL], double Info[UMFPACK_INFO])
|
182
|
+
{
|
183
|
+
return umfpack_dl_solve(sys,Ap,Ai,Ax,X,B,Numeric,Control,Info);
|
184
|
+
}
|
185
|
+
|
186
|
+
inline SuiteSparse_long umfpack_solve(int sys, const SuiteSparse_long Ap[], const SuiteSparse_long Ai[], const std::complex<double> Ax[],
|
187
|
+
std::complex<double> X[], const std::complex<double> B[], void *Numeric,
|
188
|
+
const double Control[UMFPACK_CONTROL], double Info[UMFPACK_INFO])
|
189
|
+
{
|
190
|
+
return umfpack_zl_solve(sys,Ap,Ai,&numext::real_ref(Ax[0]),0,&numext::real_ref(X[0]),0,&numext::real_ref(B[0]),0,Numeric,Control,Info);
|
191
|
+
}
|
192
|
+
|
193
|
+
// Get Lunz
|
98
194
|
inline int umfpack_get_lunz(int *lnz, int *unz, int *n_row, int *n_col, int *nz_udiag, void *Numeric, double)
|
99
195
|
{
|
100
196
|
return umfpack_di_get_lunz(lnz,unz,n_row,n_col,nz_udiag,Numeric);
|
@@ -105,6 +201,19 @@ inline int umfpack_get_lunz(int *lnz, int *unz, int *n_row, int *n_col, int *nz_
|
|
105
201
|
return umfpack_zi_get_lunz(lnz,unz,n_row,n_col,nz_udiag,Numeric);
|
106
202
|
}
|
107
203
|
|
204
|
+
inline SuiteSparse_long umfpack_get_lunz( SuiteSparse_long *lnz, SuiteSparse_long *unz, SuiteSparse_long *n_row, SuiteSparse_long *n_col,
|
205
|
+
SuiteSparse_long *nz_udiag, void *Numeric, double)
|
206
|
+
{
|
207
|
+
return umfpack_dl_get_lunz(lnz,unz,n_row,n_col,nz_udiag,Numeric);
|
208
|
+
}
|
209
|
+
|
210
|
+
inline SuiteSparse_long umfpack_get_lunz( SuiteSparse_long *lnz, SuiteSparse_long *unz, SuiteSparse_long *n_row, SuiteSparse_long *n_col,
|
211
|
+
SuiteSparse_long *nz_udiag, void *Numeric, std::complex<double>)
|
212
|
+
{
|
213
|
+
return umfpack_zl_get_lunz(lnz,unz,n_row,n_col,nz_udiag,Numeric);
|
214
|
+
}
|
215
|
+
|
216
|
+
// Get Numeric
|
108
217
|
inline int umfpack_get_numeric(int Lp[], int Lj[], double Lx[], int Up[], int Ui[], double Ux[],
|
109
218
|
int P[], int Q[], double Dx[], int *do_recip, double Rs[], void *Numeric)
|
110
219
|
{
|
@@ -120,18 +229,45 @@ inline int umfpack_get_numeric(int Lp[], int Lj[], std::complex<double> Lx[], in
|
|
120
229
|
return umfpack_zi_get_numeric(Lp,Lj,Lx?&lx0_real:0,0,Up,Ui,Ux?&ux0_real:0,0,P,Q,
|
121
230
|
Dx?&dx0_real:0,0,do_recip,Rs,Numeric);
|
122
231
|
}
|
232
|
+
inline SuiteSparse_long umfpack_get_numeric(SuiteSparse_long Lp[], SuiteSparse_long Lj[], double Lx[], SuiteSparse_long Up[], SuiteSparse_long Ui[], double Ux[],
|
233
|
+
SuiteSparse_long P[], SuiteSparse_long Q[], double Dx[], SuiteSparse_long *do_recip, double Rs[], void *Numeric)
|
234
|
+
{
|
235
|
+
return umfpack_dl_get_numeric(Lp,Lj,Lx,Up,Ui,Ux,P,Q,Dx,do_recip,Rs,Numeric);
|
236
|
+
}
|
123
237
|
|
124
|
-
inline
|
238
|
+
inline SuiteSparse_long umfpack_get_numeric(SuiteSparse_long Lp[], SuiteSparse_long Lj[], std::complex<double> Lx[], SuiteSparse_long Up[], SuiteSparse_long Ui[], std::complex<double> Ux[],
|
239
|
+
SuiteSparse_long P[], SuiteSparse_long Q[], std::complex<double> Dx[], SuiteSparse_long *do_recip, double Rs[], void *Numeric)
|
240
|
+
{
|
241
|
+
double& lx0_real = numext::real_ref(Lx[0]);
|
242
|
+
double& ux0_real = numext::real_ref(Ux[0]);
|
243
|
+
double& dx0_real = numext::real_ref(Dx[0]);
|
244
|
+
return umfpack_zl_get_numeric(Lp,Lj,Lx?&lx0_real:0,0,Up,Ui,Ux?&ux0_real:0,0,P,Q,
|
245
|
+
Dx?&dx0_real:0,0,do_recip,Rs,Numeric);
|
246
|
+
}
|
247
|
+
|
248
|
+
// Get Determinant
|
249
|
+
inline int umfpack_get_determinant(double *Mx, double *Ex, void *NumericHandle, double User_Info [UMFPACK_INFO], int)
|
125
250
|
{
|
126
251
|
return umfpack_di_get_determinant(Mx,Ex,NumericHandle,User_Info);
|
127
252
|
}
|
128
253
|
|
129
|
-
inline int umfpack_get_determinant(std::complex<double> *Mx, double *Ex, void *NumericHandle, double User_Info [UMFPACK_INFO])
|
254
|
+
inline int umfpack_get_determinant(std::complex<double> *Mx, double *Ex, void *NumericHandle, double User_Info [UMFPACK_INFO], int)
|
130
255
|
{
|
131
256
|
double& mx_real = numext::real_ref(*Mx);
|
132
257
|
return umfpack_zi_get_determinant(&mx_real,0,Ex,NumericHandle,User_Info);
|
133
258
|
}
|
134
259
|
|
260
|
+
inline SuiteSparse_long umfpack_get_determinant(double *Mx, double *Ex, void *NumericHandle, double User_Info [UMFPACK_INFO], SuiteSparse_long)
|
261
|
+
{
|
262
|
+
return umfpack_dl_get_determinant(Mx,Ex,NumericHandle,User_Info);
|
263
|
+
}
|
264
|
+
|
265
|
+
inline SuiteSparse_long umfpack_get_determinant(std::complex<double> *Mx, double *Ex, void *NumericHandle, double User_Info [UMFPACK_INFO], SuiteSparse_long)
|
266
|
+
{
|
267
|
+
double& mx_real = numext::real_ref(*Mx);
|
268
|
+
return umfpack_zl_get_determinant(&mx_real,0,Ex,NumericHandle,User_Info);
|
269
|
+
}
|
270
|
+
|
135
271
|
|
136
272
|
/** \ingroup UmfPackSupport_Module
|
137
273
|
* \brief A sparse LU factorization and solver based on UmfPack
|
@@ -164,7 +300,7 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
164
300
|
typedef Matrix<int, 1, MatrixType::ColsAtCompileTime> IntRowVectorType;
|
165
301
|
typedef Matrix<int, MatrixType::RowsAtCompileTime, 1> IntColVectorType;
|
166
302
|
typedef SparseMatrix<Scalar> LUMatrixType;
|
167
|
-
typedef SparseMatrix<Scalar,ColMajor,
|
303
|
+
typedef SparseMatrix<Scalar,ColMajor,StorageIndex> UmfpackMatrixType;
|
168
304
|
typedef Ref<const UmfpackMatrixType, StandardCompressedFormat> UmfpackMatrixRef;
|
169
305
|
enum {
|
170
306
|
ColsAtCompileTime = MatrixType::ColsAtCompileTime,
|
@@ -192,8 +328,8 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
192
328
|
|
193
329
|
~UmfPackLU()
|
194
330
|
{
|
195
|
-
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar());
|
196
|
-
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar());
|
331
|
+
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar(), StorageIndex());
|
332
|
+
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar(), StorageIndex());
|
197
333
|
}
|
198
334
|
|
199
335
|
inline Index rows() const { return mp_matrix.rows(); }
|
@@ -201,7 +337,7 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
201
337
|
|
202
338
|
/** \brief Reports whether previous computation was successful.
|
203
339
|
*
|
204
|
-
* \returns \c Success if computation was
|
340
|
+
* \returns \c Success if computation was successful,
|
205
341
|
* \c NumericalIssue if the matrix.appears to be negative.
|
206
342
|
*/
|
207
343
|
ComputationInfo info() const
|
@@ -241,8 +377,8 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
241
377
|
template<typename InputMatrixType>
|
242
378
|
void compute(const InputMatrixType& matrix)
|
243
379
|
{
|
244
|
-
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar());
|
245
|
-
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar());
|
380
|
+
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar(),StorageIndex());
|
381
|
+
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar(),StorageIndex());
|
246
382
|
grab(matrix.derived());
|
247
383
|
analyzePattern_impl();
|
248
384
|
factorize_impl();
|
@@ -257,8 +393,8 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
257
393
|
template<typename InputMatrixType>
|
258
394
|
void analyzePattern(const InputMatrixType& matrix)
|
259
395
|
{
|
260
|
-
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar());
|
261
|
-
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar());
|
396
|
+
if(m_symbolic) umfpack_free_symbolic(&m_symbolic,Scalar(),StorageIndex());
|
397
|
+
if(m_numeric) umfpack_free_numeric(&m_numeric,Scalar(),StorageIndex());
|
262
398
|
|
263
399
|
grab(matrix.derived());
|
264
400
|
|
@@ -309,7 +445,7 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
309
445
|
{
|
310
446
|
eigen_assert(m_analysisIsOk && "UmfPackLU: you must first call analyzePattern()");
|
311
447
|
if(m_numeric)
|
312
|
-
umfpack_free_numeric(&m_numeric,Scalar());
|
448
|
+
umfpack_free_numeric(&m_numeric,Scalar(),StorageIndex());
|
313
449
|
|
314
450
|
grab(matrix.derived());
|
315
451
|
|
@@ -320,28 +456,28 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
320
456
|
*
|
321
457
|
* \sa umfpackControl()
|
322
458
|
*/
|
323
|
-
void
|
459
|
+
void printUmfpackControl()
|
324
460
|
{
|
325
|
-
umfpack_report_control(m_control.data(), Scalar());
|
461
|
+
umfpack_report_control(m_control.data(), Scalar(),StorageIndex());
|
326
462
|
}
|
327
463
|
|
328
464
|
/** Prints statistics collected by UmfPack.
|
329
465
|
*
|
330
466
|
* \sa analyzePattern(), compute()
|
331
467
|
*/
|
332
|
-
void
|
468
|
+
void printUmfpackInfo()
|
333
469
|
{
|
334
470
|
eigen_assert(m_analysisIsOk && "UmfPackLU: you must first call analyzePattern()");
|
335
|
-
umfpack_report_info(m_control.data(), m_umfpackInfo.data(), Scalar());
|
471
|
+
umfpack_report_info(m_control.data(), m_umfpackInfo.data(), Scalar(),StorageIndex());
|
336
472
|
}
|
337
473
|
|
338
474
|
/** Prints the status of the previous factorization operation performed by UmfPack (symbolic or numerical factorization).
|
339
475
|
*
|
340
476
|
* \sa analyzePattern(), compute()
|
341
477
|
*/
|
342
|
-
void
|
478
|
+
void printUmfpackStatus() {
|
343
479
|
eigen_assert(m_analysisIsOk && "UmfPackLU: you must first call analyzePattern()");
|
344
|
-
umfpack_report_status(m_control.data(), m_fact_errorCode, Scalar());
|
480
|
+
umfpack_report_status(m_control.data(), m_fact_errorCode, Scalar(),StorageIndex());
|
345
481
|
}
|
346
482
|
|
347
483
|
/** \internal */
|
@@ -362,13 +498,13 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
362
498
|
m_symbolic = 0;
|
363
499
|
m_extractedDataAreDirty = true;
|
364
500
|
|
365
|
-
umfpack_defaults(m_control.data(), Scalar());
|
501
|
+
umfpack_defaults(m_control.data(), Scalar(),StorageIndex());
|
366
502
|
}
|
367
503
|
|
368
504
|
void analyzePattern_impl()
|
369
505
|
{
|
370
|
-
m_fact_errorCode = umfpack_symbolic(internal::convert_index<
|
371
|
-
internal::convert_index<
|
506
|
+
m_fact_errorCode = umfpack_symbolic(internal::convert_index<StorageIndex>(mp_matrix.rows()),
|
507
|
+
internal::convert_index<StorageIndex>(mp_matrix.cols()),
|
372
508
|
mp_matrix.outerIndexPtr(), mp_matrix.innerIndexPtr(), mp_matrix.valuePtr(),
|
373
509
|
&m_symbolic, m_control.data(), m_umfpackInfo.data());
|
374
510
|
|
@@ -408,7 +544,7 @@ class UmfPackLU : public SparseSolverBase<UmfPackLU<_MatrixType> >
|
|
408
544
|
|
409
545
|
// cached data to reduce reallocation, etc.
|
410
546
|
mutable LUMatrixType m_l;
|
411
|
-
|
547
|
+
StorageIndex m_fact_errorCode;
|
412
548
|
UmfpackControl m_control;
|
413
549
|
mutable UmfpackInfo m_umfpackInfo;
|
414
550
|
|
@@ -438,7 +574,7 @@ void UmfPackLU<MatrixType>::extractData() const
|
|
438
574
|
if (m_extractedDataAreDirty)
|
439
575
|
{
|
440
576
|
// get size of the data
|
441
|
-
|
577
|
+
StorageIndex lnz, unz, rows, cols, nz_udiag;
|
442
578
|
umfpack_get_lunz(&lnz, &unz, &rows, &cols, &nz_udiag, m_numeric, Scalar());
|
443
579
|
|
444
580
|
// allocate data
|
@@ -464,7 +600,7 @@ template<typename MatrixType>
|
|
464
600
|
typename UmfPackLU<MatrixType>::Scalar UmfPackLU<MatrixType>::determinant() const
|
465
601
|
{
|
466
602
|
Scalar det;
|
467
|
-
umfpack_get_determinant(&det, 0, m_numeric, 0);
|
603
|
+
umfpack_get_determinant(&det, 0, m_numeric, 0, StorageIndex());
|
468
604
|
return det;
|
469
605
|
}
|
470
606
|
|
@@ -477,7 +613,6 @@ bool UmfPackLU<MatrixType>::_solve_impl(const MatrixBase<BDerived> &b, MatrixBas
|
|
477
613
|
eigen_assert((XDerived::Flags&RowMajorBit)==0 && "UmfPackLU backend does not support non col-major result yet");
|
478
614
|
eigen_assert(b.derived().data() != x.derived().data() && " Umfpack does not support inplace solve");
|
479
615
|
|
480
|
-
int errorCode;
|
481
616
|
Scalar* x_ptr = 0;
|
482
617
|
Matrix<Scalar,Dynamic,1> x_tmp;
|
483
618
|
if(x.innerStride()!=1)
|
@@ -489,9 +624,10 @@ bool UmfPackLU<MatrixType>::_solve_impl(const MatrixBase<BDerived> &b, MatrixBas
|
|
489
624
|
{
|
490
625
|
if(x.innerStride()==1)
|
491
626
|
x_ptr = &x.col(j).coeffRef(0);
|
492
|
-
errorCode = umfpack_solve(UMFPACK_A,
|
493
|
-
|
494
|
-
|
627
|
+
StorageIndex errorCode = umfpack_solve(UMFPACK_A,
|
628
|
+
mp_matrix.outerIndexPtr(), mp_matrix.innerIndexPtr(), mp_matrix.valuePtr(),
|
629
|
+
x_ptr, &b.const_cast_derived().col(j).coeffRef(0),
|
630
|
+
m_numeric, m_control.data(), m_umfpackInfo.data());
|
495
631
|
if(x.innerStride()!=1)
|
496
632
|
x.col(j) = x_tmp;
|
497
633
|
if (errorCode!=0)
|
@@ -43,10 +43,6 @@
|
|
43
43
|
#include "lapacke_config.h"
|
44
44
|
#endif
|
45
45
|
|
46
|
-
#ifdef __cplusplus
|
47
|
-
extern "C" {
|
48
|
-
#endif /* __cplusplus */
|
49
|
-
|
50
46
|
#include <stdlib.h>
|
51
47
|
|
52
48
|
#ifndef lapack_int
|
@@ -108,6 +104,11 @@ lapack_complex_double lapack_make_complex_double( double re, double im );
|
|
108
104
|
|
109
105
|
#endif
|
110
106
|
|
107
|
+
|
108
|
+
#ifdef __cplusplus
|
109
|
+
extern "C" {
|
110
|
+
#endif /* __cplusplus */
|
111
|
+
|
111
112
|
#ifndef LAPACKE_malloc
|
112
113
|
#define LAPACKE_malloc( size ) malloc( size )
|
113
114
|
#endif
|
@@ -75,6 +75,32 @@ max
|
|
75
75
|
return (max)(Derived::PlainObject::Constant(rows(), cols(), other));
|
76
76
|
}
|
77
77
|
|
78
|
+
/** \returns an expression of the coefficient-wise absdiff of \c *this and \a other
|
79
|
+
*
|
80
|
+
* Example: \include Cwise_absolute_difference.cpp
|
81
|
+
* Output: \verbinclude Cwise_absolute_difference.out
|
82
|
+
*
|
83
|
+
* \sa absolute_difference()
|
84
|
+
*/
|
85
|
+
EIGEN_MAKE_CWISE_BINARY_OP(absolute_difference,absolute_difference)
|
86
|
+
|
87
|
+
/** \returns an expression of the coefficient-wise absolute_difference of \c *this and scalar \a other
|
88
|
+
*
|
89
|
+
* \sa absolute_difference()
|
90
|
+
*/
|
91
|
+
EIGEN_DEVICE_FUNC
|
92
|
+
EIGEN_STRONG_INLINE const CwiseBinaryOp<internal::scalar_absolute_difference_op<Scalar,Scalar>, const Derived,
|
93
|
+
const CwiseNullaryOp<internal::scalar_constant_op<Scalar>, PlainObject> >
|
94
|
+
#ifdef EIGEN_PARSED_BY_DOXYGEN
|
95
|
+
absolute_difference
|
96
|
+
#else
|
97
|
+
(absolute_difference)
|
98
|
+
#endif
|
99
|
+
(const Scalar &other) const
|
100
|
+
{
|
101
|
+
return (absolute_difference)(Derived::PlainObject::Constant(rows(), cols(), other));
|
102
|
+
}
|
103
|
+
|
78
104
|
/** \returns an expression of the coefficient-wise power of \c *this to the given array of \a exponents.
|
79
105
|
*
|
80
106
|
* This function computes the coefficient-wise power.
|
@@ -119,7 +145,7 @@ OP(const Scalar& s) const { \
|
|
119
145
|
return this->OP(Derived::PlainObject::Constant(rows(), cols(), s)); \
|
120
146
|
} \
|
121
147
|
EIGEN_DEVICE_FUNC friend EIGEN_STRONG_INLINE const RCmp ## COMPARATOR ## ReturnType \
|
122
|
-
OP(const Scalar& s, const Derived
|
148
|
+
OP(const Scalar& s, const EIGEN_CURRENT_STORAGE_BASE_CLASS<Derived>& d) { \
|
123
149
|
return Derived::PlainObject::Constant(d.rows(), d.cols(), s).OP(d); \
|
124
150
|
}
|
125
151
|
|
@@ -314,9 +340,9 @@ polygamma(const EIGEN_CURRENT_STORAGE_BASE_CLASS<DerivedN> &n) const
|
|
314
340
|
*
|
315
341
|
* It returns the Riemann zeta function of two arguments \c *this and \a q:
|
316
342
|
*
|
317
|
-
* \param *this is the exposent, it must be > 1
|
318
343
|
* \param q is the shift, it must be > 0
|
319
344
|
*
|
345
|
+
* \note *this is the exponent, it must be > 1.
|
320
346
|
* \note This function supports only float and double scalar types. To support other scalar types, the user has
|
321
347
|
* to provide implementations of zeta(T,T) for any scalar type T to be supported.
|
322
348
|
*
|