PolyFEM
|
#include <RefElementSampler.hpp>
Public Member Functions | |
RefElementSampler () | |
void | init (const bool is_volume, const int n_elements, const double target_rel_area) |
const Eigen::MatrixXd & | cube_corners () const |
const Eigen::MatrixXd & | cube_points () const |
const Eigen::MatrixXi & | cube_faces () const |
const Eigen::MatrixXi & | cube_volume () const |
const Eigen::MatrixXi & | cube_edges () const |
const Eigen::MatrixXd & | simplex_corners () const |
const Eigen::MatrixXd & | simplex_points () const |
const Eigen::MatrixXi & | simplex_faces () const |
const Eigen::MatrixXi & | simplex_volume () const |
const Eigen::MatrixXi & | simplex_edges () const |
void | sample_polygon (const Eigen::MatrixXd &poly, Eigen::MatrixXd &pts, Eigen::MatrixXi &faces, Eigen::MatrixXi &edges) const |
void | sample_polyhedron (const Eigen::MatrixXd &vertices, const Eigen::MatrixXi &f, Eigen::MatrixXd &pts, Eigen::MatrixXi &faces, Eigen::MatrixXi &edges) const |
int | num_samples () const |
Private Member Functions | |
void | build () |
Private Attributes | |
Eigen::MatrixXi | cube_tets_ |
Eigen::MatrixXi | simplex_tets_ |
Eigen::MatrixXd | cube_corners_ |
Eigen::MatrixXd | cube_points_ |
Eigen::MatrixXi | cube_faces_ |
Eigen::MatrixXi | cube_edges_ |
Eigen::MatrixXd | simplex_corners_ |
Eigen::MatrixXd | simplex_points_ |
Eigen::MatrixXi | simplex_faces_ |
Eigen::MatrixXi | simplex_edges_ |
double | area_param_ |
double | is_volume_ |
Definition at line 30 of file RefElementSampler.hpp.
|
inline |
Definition at line 33 of file RefElementSampler.hpp.
|
private |
Definition at line 214 of file RefElementSampler.cpp.
References area_param_, cube_corners_, cube_edges_, cube_faces_, cube_points_, cube_tets_, polyfem::mesh::extract_parent_edges(), faces, is_volume_, polyfem::utils::regular_2d_grid(), polyfem::utils::regular_3d_grid(), simplex_corners_, simplex_edges_, simplex_faces_, simplex_points_, and simplex_tets_.
Referenced by init().
|
inline |
Definition at line 36 of file RefElementSampler.hpp.
References cube_corners_.
|
inline |
Definition at line 40 of file RefElementSampler.hpp.
References cube_edges_.
|
inline |
Definition at line 38 of file RefElementSampler.hpp.
References cube_faces_.
|
inline |
Definition at line 37 of file RefElementSampler.hpp.
References cube_points_.
Referenced by polyfem::io::Evaluator::check_scalar_value(), polyfem::io::Evaluator::compute_scalar_value(), polyfem::io::Evaluator::compute_tensor_value(), polyfem::io::Evaluator::interpolate_function(), and polyfem::io::Evaluator::mark_flipped_cells().
|
inline |
Definition at line 39 of file RefElementSampler.hpp.
References cube_faces_, cube_tets_, and is_volume_.
void polyfem::utils::RefElementSampler::init | ( | const bool | is_volume, |
const int | n_elements, | ||
const double | target_rel_area | ||
) |
Definition at line 202 of file RefElementSampler.cpp.
References area_param_, build(), and is_volume_.
Referenced by polyfem::io::OutGeometryData::init_sampler().
|
inline |
Definition at line 51 of file RefElementSampler.hpp.
References area_param_, and is_volume_.
Referenced by polyfem::io::OutGeometryData::build_vis_boundary_mesh().
void polyfem::utils::RefElementSampler::sample_polygon | ( | const Eigen::MatrixXd & | poly, |
Eigen::MatrixXd & | pts, | ||
Eigen::MatrixXi & | faces, | ||
Eigen::MatrixXi & | edges | ||
) | const |
Definition at line 368 of file RefElementSampler.cpp.
References area_param_, and faces.
Referenced by polyfem::io::Evaluator::check_scalar_value(), polyfem::io::Evaluator::compute_scalar_value(), polyfem::io::Evaluator::compute_tensor_value(), polyfem::io::Evaluator::interpolate_function(), and polyfem::io::Evaluator::mark_flipped_cells().
void polyfem::utils::RefElementSampler::sample_polyhedron | ( | const Eigen::MatrixXd & | vertices, |
const Eigen::MatrixXi & | f, | ||
Eigen::MatrixXd & | pts, | ||
Eigen::MatrixXi & | faces, | ||
Eigen::MatrixXi & | edges | ||
) | const |
Definition at line 409 of file RefElementSampler.cpp.
References faces, and polyfem::mesh::tertrahedralize_star_shaped_surface().
Referenced by polyfem::io::Evaluator::check_scalar_value(), polyfem::io::Evaluator::compute_scalar_value(), polyfem::io::Evaluator::compute_tensor_value(), polyfem::io::Evaluator::interpolate_function(), and polyfem::io::Evaluator::mark_flipped_cells().
|
inline |
Definition at line 42 of file RefElementSampler.hpp.
References simplex_corners_.
|
inline |
Definition at line 46 of file RefElementSampler.hpp.
References simplex_edges_.
|
inline |
Definition at line 44 of file RefElementSampler.hpp.
References simplex_faces_.
|
inline |
Definition at line 43 of file RefElementSampler.hpp.
References simplex_points_.
Referenced by polyfem::io::Evaluator::check_scalar_value(), polyfem::io::Evaluator::compute_scalar_value(), polyfem::io::Evaluator::compute_tensor_value(), polyfem::io::Evaluator::interpolate_function(), polyfem::io::Evaluator::mark_flipped_cells(), and polyfem::io::OutGeometryData::save_wire().
|
inline |
Definition at line 45 of file RefElementSampler.hpp.
References is_volume_, simplex_faces_, and simplex_tets_.
Referenced by polyfem::io::OutGeometryData::build_vis_mesh().
|
private |
Definition at line 72 of file RefElementSampler.hpp.
Referenced by build(), init(), num_samples(), and sample_polygon().
|
private |
Definition at line 62 of file RefElementSampler.hpp.
Referenced by build(), and cube_corners().
|
private |
Definition at line 65 of file RefElementSampler.hpp.
Referenced by build(), and cube_edges().
|
private |
Definition at line 64 of file RefElementSampler.hpp.
Referenced by build(), cube_faces(), and cube_volume().
|
private |
Definition at line 63 of file RefElementSampler.hpp.
Referenced by build(), and cube_points().
|
private |
Definition at line 59 of file RefElementSampler.hpp.
Referenced by build(), and cube_volume().
|
private |
Definition at line 73 of file RefElementSampler.hpp.
Referenced by build(), cube_volume(), init(), num_samples(), and simplex_volume().
|
private |
Definition at line 67 of file RefElementSampler.hpp.
Referenced by build(), and simplex_corners().
|
private |
Definition at line 70 of file RefElementSampler.hpp.
Referenced by build(), and simplex_edges().
|
private |
Definition at line 69 of file RefElementSampler.hpp.
Referenced by build(), simplex_faces(), and simplex_volume().
|
private |
Definition at line 68 of file RefElementSampler.hpp.
Referenced by build(), and simplex_points().
|
private |
Definition at line 60 of file RefElementSampler.hpp.
Referenced by build(), and simplex_volume().