Skip to content

Commit

Permalink
reuse getcoefficientsfrommatrix()
Browse files Browse the repository at this point in the history
  • Loading branch information
atrayees authored Jul 29, 2024
1 parent 2275e61 commit 24eac7d
Showing 1 changed file with 0 additions and 15 deletions.
15 changes: 0 additions & 15 deletions examples/correlation_matrices/sampler.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,21 +60,6 @@ Spectrahedron<Point> prepare_input(int n){
return spectra;
}

template<typename NT, typename MT>
Eigen::Matrix<NT, Eigen::Dynamic, 1> getCoefficientsFromMatrix(const MT& mat) {
int n = mat.rows();
int d = n * (n - 1) / 2;
Eigen::Matrix<NT, Eigen::Dynamic, 1> coeffs(d);
int k = 0;
for (int i = 0; i < n; ++i) {
for (int j = 0; j < i; ++j) {
coeffs(k) = mat(i, j);
++k;
}
}
return coeffs;
}

template<typename WalkType>
void old_uniform_sampling(const unsigned int n, const unsigned int num_points){

Expand Down

0 comments on commit 24eac7d

Please sign in to comment.