4 #include "../typedefs.hpp"
8 #include <Eigen/Cholesky>
30 if (a_row_index == b_row_index){
33 L_up = (B_pers*B_pers.transpose()).cast<coefficient_type>();
35 }
else if (a_row_index == -1){
39 }
else if (b_col_index == -1){
40 L_up.setZero(a_row_index+1,a_row_index+1);
53 L_up_b_int.selfadjointView<Eigen::Lower>().rankUpdate(B_pers_int);
57 int a_rows = a_row_index + 1;
58 int b_rows = b_row_index + 1;
74 SparseMatrix_PL D = L_up_b.bottomRightCorner(b_rows-a_rows, b_rows-a_rows);
104 auto start_pre_ortho = std::chrono::high_resolution_clock::now();
110 if (a_row_index == b_row_index){
114 L_up = (B_pers*B_pers.transpose()).cast<coefficient_type>();
116 }
else if (a_row_index == -1){
119 }
else if (b_col_index == -1){
120 L_up.setZero(a_row_index+1,a_row_index+1);
125 std::tuple<SparseMatrix_PL,SparseMatrix_PL,std::vector<int>,
int> reduction = fbm->
reduce(a_row_index,b_row_index,b_col_index);
130 std::vector<int> I = std::get<2>(reduction);
131 int num_rows_a = std::get<3>(reduction)+1;
138 L_up.setZero(num_rows_a,num_rows_a);
144 Eigen::ColPivHouseholderQR<DenseMatrix_PL> qr3(Z);
148 Z_ortho = Q3.leftCols(Z.cols()-1);
154 L_up = B_pers*B_pers.transpose();
Definition: FilteredBoundaryMatrix.hpp:16
void submatrix_at_filtration(filtration_type a, Eigen::SparseMatrix< FBMcoeff, Eigen::ColMajor > &M)
Definition: FilteredBoundaryMatrix.hpp:113
int index_of_filtration(bool use_domain_filtrations, filtration_type a)
Definition: FilteredBoundaryMatrix.hpp:79
std::tuple< SparseMatrix_PL, SparseMatrix_PL, std::vector< int >, int > reduce(int a_row_index, int b_row_index, int b_col_index)
Definition: FilteredBoundaryMatrix.hpp:120
Definition: up_algorithms.hpp:101
void operator()(FilteredBoundaryMatrix< storage > *fbm, filtration_type a, filtration_type b, DenseMatrix_PL &L_up)
Definition: up_algorithms.hpp:103
Definition: up_algorithms.hpp:22
void operator()(FilteredBoundaryMatrix< storage > *fbm, filtration_type a, filtration_type b, DenseMatrix_PL &L_up)
Definition: up_algorithms.hpp:24
Definition: PersistentLaplacians.cpp:7
float coefficient_type
Definition: typedefs.hpp:13
Eigen::Matrix< coefficient_type, Eigen::Dynamic, Eigen::Dynamic > DenseMatrix_PL
Definition: typedefs.hpp:24
Eigen::SparseMatrix< storage, Eigen::ColMajor > SparseMatrix_storage
Definition: typedefs.hpp:21
Eigen::SparseMatrix< coefficient_type, Eigen::ColMajor > SparseMatrix_PL
Definition: typedefs.hpp:23
double filtration_type
Definition: typedefs.hpp:34