Skip to content
  • Mark OLESEN's avatar
    ENH: use fallback value if calculated Le() is degenerate (#2592) · 94349722
    Mark OLESEN authored
    - the Le vector is calculated from (edgeVec ^ edgeNorm)
      and should be oriented in direction (faceCentre -> edgeCentre).
    
      If, however, the edgeNorm value is bad for any reason, the
      cross-product falls apart and Le vector is calculated as a zero
      vector!
    
      For these cases, revert to using (faceCentre -> edgeCentre)
      as a better approximation than a zero vector.
    
      In the future, will very likely switch calculating the edge normals
      directly from the attached faces, instead of from the attached
      points as is currently done, which should improve robustness.
    
    ENH: expose fa:geometryOrder as a registered OptimisationSwitch
    
    ENN: reuse polyMesh data (eg, faceCentres) if possible in faMesh
    
    STYLE: add code lambdas and static functions to isolate logic
    94349722