finesse.cymath.cmatrix.KLUMatrix

Overview

class finesse.cymath.cmatrix.KLUMatrix(name, klu_ordering=0, *, klu_scale=2, klu_btf=1, klu_maxwork=0, double tol=1e-3)

Bases: CCSMatrix

An object representation of a CCS matrix with methods to factor and solve the matrix via KLU.

Parameters
nameunicode

The name of the matrix.

klu_orderingint, optional

The ordering method to use in KLU, by default 0.

klu_scaleint, optional

The scaling method to use in KLU, by default 2.

klu_btfint, optional

Whether to use BTF preordering in KLU, by default 1.

klu_maxworkint, optional

The maximum amount of work to do in KLU, by default 0.

tolfloat, optional

The tolerance to use in KLU for partial pivotting, by default 1e-3.

Methods

KLUMatrix.__init__(*args, **kwargs)

KLUMatrix.condest(self)

klu_condest

KLUMatrix.factor(self)

Factor the matrix using KLU.

KLUMatrix.rcond(self)

klu_rcond: compute min(abs(diag(U))) / max(abs(diag(U)))

KLUMatrix.refactor(self)

Refactor the matrix using KLU.

KLUMatrix.rgrowth(self)

klu_rgrowth : compute the reciprocal pivot growth

KLUMatrix.solve(self, int transpose=False, ...)

Solve the matrix with options for transposing and conjugating.

KLUMatrix.solve_extra_rhs(self, ...)

Solve the matrix for all present rhs vectors except the main one, with options for transposing and conjugating.

KLUMatrix.zgemv(self, double complex[, ...)

Multiply this matrix with the rhs vector corresponding to rhs_index, and store the result in out.