42 #ifndef MATRIX_SYM_POS_DEF_BUNCH_KAUFMAN_H
43 #define MATRIX_SYM_POS_DEF_BUNCH_KAUFMAN_H
47 #include "ConstrainedOptPack_MatrixSymAddDelUpdateableWithOpNonsingular.hpp"
48 #include "AbstractLinAlgPack_MatrixSymAddDelUpdateable.hpp"
49 #include "AbstractLinAlgPack_MatrixSymPosDefCholFactor.hpp"
50 #include "AbstractLinAlgPack_MatrixSymOpNonsingSerial.hpp"
51 #include "DenseLinAlgPack_DMatrixAsTriSym.hpp"
53 namespace ConstrainedOptPack {
67 :
public virtual MatrixSymOpNonsingSerial
68 ,
public virtual MatrixSymAddDelUpdateable
103 const DMatrixSliceSym &A
105 ,
bool force_factorization
107 ,PivotTolerances pivot_tols
117 const DVectorSlice *t
119 ,
bool force_refactorization
120 ,EEigenValType add_eigen_val
121 ,PivotTolerances pivot_tols
126 ,
bool force_refactorization
127 ,EEigenValType drop_eigen_val
128 ,PivotTolerances pivot_tols
139 std::ostream&
output(std::ostream& out)
const;
143 ,
const DVectorSlice& vs_rhs2, value_type beta
148 ,
const DVectorSlice& vs_rhs2
156 typedef std::vector<FortranTypes::f_int> IPIV_t;
168 MatrixSymAddDelUpdateable::Inertia
182 MatrixSymPosDefCholFactor
191 DMatrixSliceTriEle DU(
size_type S_size,
bool fact_in1);
193 const DMatrixSliceTriEle DU(
size_type S_size,
bool fact_in1)
const;
198 const DMatrixSliceSym S(
size_type S_size)
const;
200 void assert_initialized()
const;
202 void resize_DU_store(
bool in_store1 );
207 void copy_and_factor_matrix(
size_type S_size,
bool fact_in1 );
212 void factor_matrix(
size_type S_size,
bool fact_in1 );
219 bool compute_assert_inertia(
221 ,
const Inertia& expected_inertia,
const char func_name[]
222 ,PivotTolerances pivot_tols, Inertia* comp_inertia, std::ostringstream* err_msg, value_type* gamma );
234 DMatrixSliceTriEle MatrixSymAddDelBunchKaufman::DU(
size_type S_size,
bool fact_in1)
236 resize_DU_store(fact_in1);
237 return DenseLinAlgPack::nonconst_tri_ele(
238 ( fact_in1 ? S_store1_ : S_store2_ )(1,S_size,2,S_size+1)
243 const DMatrixSliceTriEle MatrixSymAddDelBunchKaufman::DU(
size_type S_size,
bool fact_in1)
const
245 return DenseLinAlgPack::tri_ele(
246 ( fact_in1 ? S_store1_ : S_store2_ )(1,S_size,2,S_size+1)
251 DMatrixSliceSym MatrixSymAddDelBunchKaufman::S(
size_type S_size)
253 return DenseLinAlgPack::nonconst_sym(
254 S_store1_(2,S_size+1,1,S_size)
259 const DMatrixSliceSym MatrixSymAddDelBunchKaufman::S(
size_type S_size)
const
261 return DenseLinAlgPack::sym(
262 S_store1_(2,S_size+1,1,S_size)
268 #endif // MATRIX_SYM_POS_DEF_BUNCH_KAUFMAN_H
void Vp_StMtV(DVectorSlice *vs_lhs, value_type alpha, BLAS_Cpp::Transp trans_rhs1, const DVectorSlice &vs_rhs2, value_type beta) const
void initialize(value_type alpha, size_type max_size)
MatrixSymAddDelUpdateable & update_interface()
std::ostream & output(std::ostream &out) const
PivotTolerances pivot_tols() const
This class maintains the factorization of symmetric indefinite matrix using a Bunch & Kaufman factori...
const MatrixSymOpNonsing & op_interface() const
Interface for updating a symmetric matrix and its factorization by adding and deleting rows and colum...
void augment_update(const DVectorSlice *t, value_type alpha, bool force_refactorization, EEigenValType add_eigen_val, PivotTolerances pivot_tols)
size_type max_size() const
MatrixSymAddDelBunchKaufman()
Initializes with 0x0 and pivot_tols == (0.0,0.0,0.0).
void delete_update(size_type jd, bool force_refactorization, EEigenValType drop_eigen_val, PivotTolerances pivot_tols)
void V_InvMtV(DVectorSlice *vs_lhs, BLAS_Cpp::Transp trans_rhs1, const DVectorSlice &vs_rhs2) const