6 #ifndef MYRAMATH_MULTIFRONTAL_RLDLT_FACTOR_H 7 #define MYRAMATH_MULTIFRONTAL_RLDLT_FACTOR_H 14 #include <myramath/multifrontal/detail/llt/factor.h> 25 #include <myramath/dense/detail/nwork.h> 28 namespace multifrontal {
32 template<
class Precision>
class JobGraphBase :
public ::myra::multifrontal::detail::llt::factor::JobGraphBase2<RLDLTKernel<Precision> >
37 typedef Precision Number;
39 typedef ::myra::multifrontal::detail::llt::factor::JobGraphBase2<Kernel> Base;
42 typedef ::myra::multifrontal::detail::llt::LContainer<Kernel> LContainer;
47 : Base(in_lcontainer), lcontainer(in_lcontainer) { }
50 virtual ::myra::JobGraphBase* clone()
const 56 virtual uint64_t factor(
int n,
int k)
59 if (k == 0) this->assign_contributions(n,k);
60 return lcontainer->factor(n,k);
64 virtual uint64_t trsm(
int n,
int k,
int i)
67 if (k == 0) this->assign_contributions(n,i,k);
69 const Kernel& Ln_kk = this->l(n,k);
70 uint64_t w = Ln_kk.
solveL(An_ik,
'R',
'T');
76 virtual uint64_t rankk(
int n,
int k,
int ij)
85 Number beta = k ? one : zero;
87 std::pair<int,int> inertia = this->l(n,k).inertia();
89 w += syrk_nwork(An_ij, Ln_ijk. left(inertia.first) ,
'N', -one, beta);
90 w += syrk_nwork(An_ij, Ln_ijk.
right(inertia.second),
'N', one, one );
92 if (k == 0) this->add_contributions(n,ij);
97 virtual uint64_t gemm(
int n,
int k,
int i,
int j)
107 Number beta = k ? one : zero;
109 std::pair<int,int> inertia = this->l(n,k).inertia();
111 w += gemm_nwork(An_ij, Ln_ik. left(inertia.first ),
'N', Ln_jk. left(inertia.first ),
'T', -one, beta);
112 w += gemm_nwork(An_ij, Ln_ik.
right(inertia.second),
'N', Ln_jk.
right(inertia.second),
'T', one, one );
114 if (k == 0) this->add_contributions(n,i,j);
121 LContainer* lcontainer;
Factors A into L*L', presents solve methods.
Definition: Kernel.h:38
Interface class for representing subranges of dense Matrix's.
Pivot factorization for SparseRLDLTSolver.
Represents a mutable LowerMatrixRange.
Definition: conjugate.h:28
uint64_t solveL(const MatrixRange< Precision > &B, char side, char op) const
Solves op(L)*X=B or X*op(L)=B, overwrites B with X.
Definition: Kernel.h:76
Range construct for a lower triangular matrix stored in rectangular packed format.
Represents a const MatrixRange.
Definition: bothcat.h:22
void solveI(const MatrixRange< Precision > &B, char side) const
Solves I*X=B or X*I=B, overwrites B with X.
Definition: Kernel.h:134
Routines for backsolving by a triangular Matrix or LowerMatrix.
Specialized container for a lower triangular matrix, O(N^2/2) storage. Used by symmetry exploiting ma...
CMatrixRange< Number > right(int j) const
Returns the j rightmost columns, this(:,J-j:J)
Definition: MatrixRange.cpp:596
Represents a mutable MatrixRange.
Definition: conjugate.h:26
General purpose dense matrix container, O(i*j) storage.
Stores a lower triangular matrix in rectangular packed format.
Definition: conjugate.h:22
Routines for symmetric rank-k updates, a specialized form of Matrix*Matrix multiplication.
Variety of routines all for dense Matrix*Matrix multiplies. Delegates to the BLAS.