22 #ifndef GEOMETRY_GEOMETRYHANDLER_HPP
23 #define GEOMETRY_GEOMETRYHANDLER_HPP
25 #include <LbmLib/include/geometry/Connection.hpp>
26 #include <LbmLib/include/geometry/Geometry.hpp>
33 #include <unordered_set>
98 return boundaryNodes_;
105 const std::map<unsigned int,double>
computeAreas()
const;
135 std::shared_ptr<nodes::GeometryNode>
const p2,
136 const std::map<std::string, std::vector<std::string> > boundaryconditiondescriptor,
137 const unsigned int domainidentifier);
150 const std::shared_ptr<nodes::GeometryNode>
returnGeometryNode(
const unsigned int nodeID)
const;
179 std::map<unsigned int,unsigned int>&
193 void perturbConnections();
198 void generateBoundaryNodes();
203 void generatePhysicalGrid();
208 void makePhysicalGridConnections();
213 void makePeriodicBoundary();
219 void connectGeometryNodesToPhysicalNodes(std::shared_ptr<nodes::GeometryNode> pt);
224 void connectGeometryNodesToPhysicalNodes();
229 void updateDomainIdentifier();
234 void updateAllDomainIdentifiers();
239 std::map<unsigned int,unsigned int> cellTypeTrackerMap_;
244 std::vector<std::vector<nodes::PhysicalNode*> > physicalGrid_;
248 std::unordered_set<nodes::BoundaryNode*> boundaryNodes_;
255 #endif // GEOMETRY_GEOMETRYHANDLER_HPP
void copyCellTypeToPhysicalNodes(std::map< unsigned int, unsigned int > &celltrackermap)
update the celltypes of all *PhysicalNode*s with domainid
void eraseConnection(std::shared_ptr< Connection > toErase)
Erases the Connection.
void checkLatticeIntegrity()
Check lattice integrity.
const std::shared_ptr< nodes::GeometryNode > returnGeometryNode(const unsigned int nodeID) const
returnGeometryNode
~GeometryHandler()
~GeometryHandler Destroyes all nodes.
std::map< unsigned int, double > computeAccumulatedDomainConcentrations(const std::string &name) const
Compute the accumulated concentrations of species name in all domains.
bool checkGeometryIntegrity(void) const
checkGeometryIntegrity
void createConnection(std::shared_ptr< nodes::GeometryNode > const p1, std::shared_ptr< nodes::GeometryNode > const p2, const std::map< std::string, std::vector< std::string > > boundaryconditiondescriptor, const unsigned int domainidentifier)
Create a new connection.
void coarsenBoundary()
If *Connection*s are too short, a GeometryNode is remove.
void moveLattice()
moveLattcie Updates the Lattice after the Geometric Points have been moved
const Geometry & getGeometry() const
getter for the geometry
void cureLattice()
Cure the Lattice: update *BoundaryNode*s, DomainIdentifier, and IB connections.
const std::map< unsigned int, double > computeAreas() const
Compute the areas of the domains by using the domainIdentifiers.
unsigned int remeshBoundary()
If a Connection is too long, a GeometryNode is added and linked.
void checkBoundaryNodeIntegrity()
checkBoundaryNodeIntegrity Checks the integrity of the boundary node pairs.
unsigned int createGeometryNode(const double xpos, const double ypos)
Add a new GeometryNode.
const std::unordered_set< nodes::BoundaryNode * > & getBoundaryNodes() const
Getter for the Boundary nodes.
GeometryHandler(const Geometry &geometry)
GeometryHandler Constructs the simulation grid.
class representing the external geometry
std::map< unsigned int, unsigned int > & getCellTypeTrackerMap(void)
Returns a reference to the cellTypeTrackerMap.
const std::vector< std::vector< nodes::PhysicalNode * > > & getPhysicalNodes() const
getPhysicalNodes Getter method for the physical node grid
class responsible for generating the internal geometry representation