1#ifndef geometry_phase_space_element_h
2#define geometry_phase_space_element_h
9namespace phase_space_element
57 void setup(
const int local_face_index)
59 _local_face_index = local_face_index;
69 _neighbor_local_face_index = neighbor_local_face_index;
99 for (
const auto& component : normal)
101 _real_normal.push_back(component);
102 _isoparametric_normal.push_back(component);
113 for (
const auto& component : iso_normal)
115 _isoparametric_normal.push_back(component);
126 return _real_normal.data();
136 return _isoparametric_normal.data();
146 _N_fp_phase_space = N_fp_phase_space;
156 return _N_fp_phase_space;
166 const int local_face_index)
168 const int* face_nodes = phase_space_basis_set->
getFaceNodes(local_face_index);
169 for (
int i = 0; i < _N_fp_phase_space; i++)
171 _local_face_nodes.push_back(face_nodes[i]);
182 return &(_local_face_nodes[0]);
192 const int neighbor_local_face_index)
196 const int* neighbor_face_nodes =
197 phase_space_basis_set->
getFaceNodes(neighbor_local_face_index);
198 for (
int i = 0; i < _N_fp_phase_space; i++)
200 _neighbor_local_face_nodes.push_back(neighbor_face_nodes[i]);
211 return &(_neighbor_local_face_nodes[0]);
215 int _local_face_index;
216 int _neighbor_local_face_index;
222 std::vector<real> _real_normal;
223 std::vector<real> _isoparametric_normal;
225 int _N_fp_phase_space;
226 std::vector<int> _local_face_nodes;
227 std::vector<int> _neighbor_local_face_nodes;
254 phase_space_dg_geometry);
328 const int physical_element_index,
329 const int phase_space_element_local_face_index,
330 const int phase_space_element_face_node_index)
const;
345 const int phase_space_element_face_node_index,
346 const int neighbor_global_physical_element_index,
347 const int phase_space_neighbor_element_local_face_index,
348 const int orientation,
349 const int velocity_space_element_indexes[3])
const;
357 const int phaseSpaceElementFaceIndex,
358 std::vector<real>& phaseSpaceCommonNormal)
const = 0;
369 std::vector<std::unique_ptr<geometry::phase_space_element::PhaseSpaceFace>>
Definition: wmbasisarrayset.h:13
const int * getFaceNodes(const int face_index) const
Definition: wmbasisarrayset.h:275
Base class used for generating phase space element information for kinetic phase space calculations.
Definition: phase_space_element.h:247
int getNeighborGlobalPhaseSpaceNodeIndexFromSpatialFace(const int phase_space_element_face_node_index, const int neighbor_global_physical_element_index, const int phase_space_neighbor_element_local_face_index, const int orientation, const int velocity_space_element_indexes[3]) const
This gets the neighboring phase space node of a node on a phase space element Written ofr a spatial f...
std::vector< int > _spatial_face_orientation
Definition: phase_space_element.h:378
void setSpatialFaceOrientations()
std::shared_ptr< geometry::phase_space::PhaseSpaceDGGeometry > _phase_space_dg_geometry
Definition: phase_space_element.h:366
virtual void setup()
setup
virtual void getCommonNormal(const int physical_element_index, const int phaseSpaceElementFaceIndex, std::vector< real > &phaseSpaceCommonNormal) const =0
base class function
geometry::phase_space_element::PhaseSpaceFace const * getFace(const int local_face_index) const
Get at face given a local face index of the element.
Definition: phase_space_element.h:314
virtual void setNd()=0
Set _N_d_physical_space, _N_d_velocity_space, _N_d_phase_space for the phase space element Has to be ...
int getNdPhysicalSpace()
Get number of dimensions in physical space.
Definition: phase_space_element.h:272
int getNdVelocitySpace()
Get number of dimensions in velocity space.
Definition: phase_space_element.h:282
int _N_d_physical_space
Definition: phase_space_element.h:361
int getNeighborGlobalPhysicalSpaceNodeIndexFromSpatialFace(const int physical_element_index, const int phase_space_element_local_face_index, const int phase_space_element_face_node_index) const
This gets the neighboring physical space node of a node on a phase space element on a spatial face.
int getNdPhaseSpace()
Get number of dimensions in phase space.
Definition: phase_space_element.h:292
virtual ~PhaseSpaceElement()=default
Destructor.
int _N_d_phase_space
Definition: phase_space_element.h:363
std::vector< std::unique_ptr< geometry::phase_space_element::PhaseSpaceFace > > _phase_space_faces
Definition: phase_space_element.h:370
int _N_d_velocity_space
Definition: phase_space_element.h:362
PhaseSpaceElement(const std::shared_ptr< geometry::phase_space::PhaseSpaceDGGeometry > &phase_space_dg_geometry)
Constructor.
PhaseSpaceFace Class used by PhaseSpaceElements.
Definition: phase_space_element.h:42
void setLocalFaceNodes(const WmBasisArraySet *phase_space_basis_set, const int local_face_index)
Set the local face nodes on this face.
Definition: phase_space_element.h:165
void setup(const int local_face_index)
setup
Definition: phase_space_element.h:57
void setNeighborLocalFaceIndex(const int neighbor_local_face_index)
Set Neighbor Local Face Index.
Definition: phase_space_element.h:67
void setNeighborLocalFaceNodes(const WmBasisArraySet *phase_space_basis_set, const int neighbor_local_face_index)
Set the local face nodes on the neighbor's face.
Definition: phase_space_element.h:191
int getNfp() const
Get Number of face nodes on this phase space face.
Definition: phase_space_element.h:154
PhaseSpaceFace()
Constructor.
Definition: phase_space_element.h:48
const int * getNeighborLocalFaceNodes() const
Get the local face nodes on the neighbor's face.
Definition: phase_space_element.h:209
void setPhaseSpaceNormal(const std::vector< real > normal)
Set Phase Space Normal of this face real and isoparametric normal are assumed same.
Definition: phase_space_element.h:97
const real * getIsoparametricNormal() const
Get Isoparametric Phase Space Normal.
Definition: phase_space_element.h:134
const real * getRealNormal() const
Get Real Phase Space Normal.
Definition: phase_space_element.h:124
const int * getLocalFaceNodes() const
Get the local face nodes on this face.
Definition: phase_space_element.h:180
void setPhaseSpaceIsoparametricNormal(const std::vector< real > &iso_normal)
Set Phase Space Isoparametric Normal of this face.
Definition: phase_space_element.h:111
void setNfp(const int N_fp_phase_space)
Set Number of face nodes on this phase space face.
Definition: phase_space_element.h:144
int getLocalPhaseSpaceNodeIndex(const int l, const int N, const int m, const int i, const int j, const int k)
This gives you the phase space element local node index given:
Definition: phase_space_34duoprism.h:9
#define real
Definition: wmoclunstructuredreconstruction.h:11