factorize#

MapdlMath.factorize(mat, algo=None, inplace=True)[source]#

Factorize a matrix.

Parameters:
matansys.mapdl.math.AnsMat

An APDLMath matrix

algostr, optional

Factorization algorithm. Either "LAPACK" (default for dense matrices) or "DSP" (default for sparse matrices).

inplacebool, optional

If False, the factorization is performed on a copy of the input matrix (mat argument), hence this input matrix (mat) is not changed. Default is True.

Returns:
ansys.mapdl.core.math.AnsSolver

An Ansys Solver object.

Examples

Factorize a random matrix.

>>> mm = mapdl.math
>>> dim = 1000
>>> m2 = mm.rand(dim, dim)
>>> m3 = m2.copy()
>>> mat = mm.factorize(m2)