RSMesh 1.0.0
一个曲面重构的系统,输入为点云,输出为obj,stl等主流格式的网格文件,使用的方法为径向基函数插值,采取了并行优化、Intel-MKL等优化措施,支持百万级别的点云
载入中...
搜索中...
未找到
coarse_grid.h
1//
2// Created by RainSure on 2024/2/18.
3//
4
5#ifndef RSMESH_COARSE_GRID_H
6#define RSMESH_COARSE_GRID_H
7
8#include "Eigen/Cholesky"
9#include "Eigen/Core"
10#include "Eigen/LU"
11#include "geometry/point3d.h"
12#include "model.h"
13#include "preconditioner/domain.h"
14#include "types.h"
15#include <vector>
16
21namespace rsmesh::preconditioner {
23 public:
25
26 void clear();
27
28 void setup(const geometry::points3d& points_full, const Eigen::MatrixXd& lagrange_pt_full);
29
30 void setup(const geometry::points3d& points_full, const geometry::points3d& grad_points_full,
31 const Eigen::MatrixXd& lagrange_pt_full);
32
33 void set_solution_to(Eigen::Ref<valuesd> weights_full) const;
34
35 void solve(const Eigen::Ref<const valuesd>& values_full);
36 private:
37 const model& model_;
38 const std::vector<index_t> point_idcs_;
39 const std::vector<index_t> grad_point_idcs_;
40
41 const index_t dim_;
42 const index_t l_;
43 const index_t mu_;
44 const index_t sigma_;
45 const index_t m_;
46 index_t mu_full_;
47 index_t sigma_full_;
48
49 // Matrix -E.
50 Eigen::MatrixXd me_;
51
52 // Cholesky decomposition of matrix Q^T A Q.
53 Eigen::LDLT<Eigen::MatrixXd> ldlt_of_qtaq_;
54
55 // First l rows of matrix A.
56 Eigen::MatrixXd a_top_;
57
58 // LU decomposition of first l rows of matrix P.
59 Eigen::FullPivLU<Eigen::MatrixXd> lu_of_p_top_;
60
61 // Current solution.
62 valuesd lambda_c_;
63 };
64}
65
66#endif //RSMESH_COARSE_GRID_H
描述了一个插值模型
Definition model.h:21
vectors3d points3d
3维点的集合
Definition point3d.h:48
该命名空间下主要定义了关于krylov子空间方法的预处理相关的类和函数