Skip to content
  • Marcus Mohr's avatar
    Fixes bug in MeshGenAnnulus · b38cb0c5
    Marcus Mohr authored
    The version that meshes a full annulus and accepts a flavour flag was not
    flagging all nodes correctly. The mesh for the full annulus in this version
    is generated by meshing a rectangle in polar coordinates. This is then
    glued together by removing duplicate nodes and edges at the interface
    phi = 0 = 2*pi.
    
    However, meshRectangle flags all interior nodes as 0 and all nodes on the
    boundary as 1. This was not corrected for at the internal interface. Thus,
    interior nodes with phi = 0 retained their flag of 1.
    
    This commit implements a different approach to flagging. We mark all
    interior nodes as 0, all nodes on the inner (rhoMin) boundary as 1 and
    all nodes on the outer (rhoMax) as 2. While doing so we implicitely also
    fix the bug.
    
    For convenience the commit implements two new private member functions
    - meshInfo::deduceEdgeFlagsFromVertices()
    - meshInfo::deduceFaceFlagsFromVertices()
    These will (re)set all flags for the corresponding entity based on that
    of their two resp. three vertices. If those flags are different the
    argument value flagInconsistent is used instead.
    
    Commit also updates the second version for meshing a full annulus to set
    the flags as {0,1,2}. The new convenience methods allowed to remove also
    the deriveEdgesForFullAnnulus() helper function.
    b38cb0c5