LehrFEM++ 1.0.0
A simple Finite Element Library for teaching
|
A mesh builder for disks with a hole in the middle. More...
#include </home/nico/bildung/SemVI/thesis/lehrfempp/projects/ipdg_stokes/mesh/annulus_triag_mesh_builder.h>
Public Member Functions | |
AnnulusTriagMeshBuilder (std::unique_ptr< lf::mesh::MeshFactory > mesh_factory) | |
Constructor. More... | |
void | setInnerRadius (double r) |
void | setOuterRadius (double r) |
Set the radius of the disk. More... | |
void | setCenterPoint (double x, double y) |
Set the location of the center. More... | |
void | setNumRadialCells (lf::base::size_type n) |
Set the number of cells in the radial direction. More... | |
void | setNumAngularCells (lf::base::size_type n) |
Set the number of cells in the angular direction. More... | |
std::shared_ptr< lf::mesh::Mesh > | Build () |
Build the mesh. More... | |
Private Attributes | |
double | inner_radius_ |
double | outer_radius_ |
lf::base::size_type | num_radial_cells_ |
lf::base::size_type | num_angular_cells_ |
Eigen::Vector2d | center_point_ |
std::unique_ptr< lf::mesh::MeshFactory > | mesh_factory_ |
A mesh builder for disks with a hole in the middle.
The diameter of the hole is controlled by the value passed to setInnerRadius(r)
while the diameter of the disk is controlled by the value passed to setOutrRadius(r)
. The position of the center can be controlled by setting setCenterPoint(x, y)
. The inner radius defaults to 0.25 while the outer radius defaults to 1. The center is at the origin by default.
Definition at line 28 of file annulus_triag_mesh_builder.h.
|
inlineexplicit |
Constructor.
mesh_factory | A unique pointer to a mesh factory object used for the assembly of the mesh |
Definition at line 35 of file annulus_triag_mesh_builder.h.
std::shared_ptr< lf::mesh::Mesh > projects::ipdg_stokes::mesh::AnnulusTriagMeshBuilder::Build | ( | ) |
Build the mesh.
Definition at line 13 of file annulus_triag_mesh_builder.cc.
References inner_radius_, lf::base::RefEl::kTria(), mesh_factory_, num_angular_cells_, num_radial_cells_, and outer_radius_.
|
inline |
Set the location of the center.
x | The x coordinate of the new center of the annulus |
y | The y coordinate of the new center of the annulus |
Definition at line 63 of file annulus_triag_mesh_builder.h.
References center_point_.
|
inline |
@breif Sets the radius of the hole
r | The radius of the hole |
Definition at line 50 of file annulus_triag_mesh_builder.h.
References inner_radius_.
|
inline |
Set the number of cells in the angular direction.
n | The nummber of cells in the angular direction |
Definition at line 75 of file annulus_triag_mesh_builder.h.
References num_angular_cells_.
|
inline |
Set the number of cells in the radial direction.
n | The number of cells in the radial direction |
Definition at line 69 of file annulus_triag_mesh_builder.h.
References num_radial_cells_.
|
inline |
Set the radius of the disk.
r | The radius of the disk |
Definition at line 56 of file annulus_triag_mesh_builder.h.
References outer_radius_.
|
private |
Definition at line 89 of file annulus_triag_mesh_builder.h.
Referenced by setCenterPoint().
|
private |
Definition at line 85 of file annulus_triag_mesh_builder.h.
Referenced by Build(), and setInnerRadius().
|
private |
Definition at line 90 of file annulus_triag_mesh_builder.h.
Referenced by Build().
|
private |
Definition at line 88 of file annulus_triag_mesh_builder.h.
Referenced by Build(), and setNumAngularCells().
|
private |
Definition at line 87 of file annulus_triag_mesh_builder.h.
Referenced by Build(), and setNumRadialCells().
|
private |
Definition at line 86 of file annulus_triag_mesh_builder.h.
Referenced by Build(), and setOuterRadius().