title: Axisymmetric blockMeshDict: FOAM FATAL ERROR: wedge ... centre plane does not align with a coordinate plane by
body: <p>I'm trying to follow <a href="https://openfoamwiki.net/index.php/Main_ContribExamples/AxiSymmetric" rel="nofollow noreferrer">this tutorial</a>  to create the axisymmetric model below: </p>
  
  <blockquote>
    <p><a href="https://i.stack.imgur.com/4uJQe.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/4uJQe.png" alt="enter image description here"></a></p>
  </blockquote>
  
  <p>Following the discussions over <a href="https://www.cfd-online.com/Forums/openfoam-meshing-blockmesh/205599-creating-axisymmetric-piston-cylinder-blockmeshdict.html" rel="nofollow noreferrer">here</a>, my <code>blockMeshDict</code> file is:</p>
  
  <pre><code>FoamFile
  {
      version     2.0;
      format      ascii;
      class       dictionary;
      object      blockMeshDict;
  }
  
  convertToMeters 0.001;
  
  wa 5.0;
  cr 10.0;
  pr 8.0;
  cl 50.0;
  px 20.0; 
  pl 10.0; 
  px2 #calc "$px+$pl"; 
  ms 50; 
  
  vertices
  (
      (0                      0                         0)    //00
      (#calc "$pr*cos($wa/2)" #calc "$pr*sin($wa/2)"    0)    //01
      (#calc "$pr*cos($wa/2)" #calc "-$pr*sin($wa/2)"   0)    //02
      (#calc "$pr*cos($wa/2)" #calc "-$pr*sin($wa/2)"   $px)  //03
      (#calc "$pr*cos($wa/2)" #calc "$pr*sin($wa/2)"    $px)  //04
      (0                      0                         $px)  //05
      (#calc "$cr*cos($wa/2)" #calc "$cr*sin($wa/2)"    $px)  //06
      (#calc "$cr*cos($wa/2)" #calc "$cr*sin($wa/2)"    0)    //07
      (#calc "$cr*cos($wa/2)" #calc "-$cr*sin($wa/2)"   0)    //08
      (#calc "$cr*cos($wa/2)" #calc "-$cr*sin($wa/2)"   $px)  //09
      (#calc "$cr*cos($wa/2)" #calc "-$cr*sin($wa/2)"   $px2) //10
      (#calc "$cr*cos($wa/2)" #calc "$cr*sin($wa/2)"    $px2) //11
      (#calc "$pr*cos($wa/2)" #calc "$pr*sin($wa/2)"    $px2) //12
      (#calc "$pr*cos($wa/2)" #calc "-$pr*sin($wa/2)"   $px2) //13
      (#calc "$pr*cos($wa/2)" #calc "-$pr*sin($wa/2)"   $cl)  //14
      (#calc "$pr*cos($wa/2)" #calc "$pr*sin($wa/2)"    $cl)  //15
      (#calc "$cr*cos($wa/2)" #calc "$cr*sin($wa/2)"    $cl)  //16
      (#calc "$cr*cos($wa/2)" #calc "-$cr*sin($wa/2)"   $cl)  //17
      (0                      0                         $cl)  //18
      (0                      0                         $px2) //19
  );
  
  blocks
  (
      hex (0  1  2  0  5  4  3  5)         ($ms 1 $ms) simpleGrading (1 1 1)
      hex (1  7  8  2  4  6  9  3)         ($ms 1 $ms) simpleGrading (1 1 1)
      hex (4  6  9  3  12 11 10 13)        ($ms 1 $ms) simpleGrading (1 1 1)
      hex (12 11 10 13 15 16 17 14)        ($ms 1 $ms) simpleGrading (1 1 1)
      hex (19 12 13 19 18 15 14 18)        ($ms 1 $ms) simpleGrading (1 1 1)
  );
  
  edges
  (
  );
  
  boundary
  (
      inlet
      {
          type patch;
          faces
          (
              (0 1 2 0)
              (1 7 8 2)
          );
      }
      outlet
      {
          type patch;
          faces
          (
              (18 15 14 18)
              (15 16 17 14)
          );
      }
      walls
      {
          type wall;
          faces
          (
              (7  8  9  6)
              (6  9  10 11)
              (11 10 17 16)
          );
      }
      wedgeBack
      {
          type wedge;
          faces
          (
              (0  1  4  5)
              (1  7  6  4)
              (4  6  11 12)
              (12 11 16 15)
              (19 12 15 18)
          );
      }
  
      wedgeFront
      {
          type wedge;
          faces
          (
              (0  2  3  5)
              (2  8  9  3)
              (3  9  10 13)
              (13 10 17 14)
              (19 13 14 18)
          );
      }
  
      axis
       { 
             type empty;
             faces  
             (
                 (0  5  5  0)
                 (19 18 18 19)
             );
      }
  );
  
  mergePatchPairs
  (
  );
  </code></pre>
  
  <p>But when i run the <code>blockMesh</code> I get the warnings like:</p>
  
  <blockquote>
    <p>Creating block mesh topology
    --> FOAM Warning :
       From function Foam::polyMesh::polyMesh(const Foam::IOobject&amp;, const Foam::Xfer > >&amp;, const cellShapeList&amp;, const faceListList&amp;, const wordList&amp;, const Foam::PtrList&amp;, const Foam::word&amp;, const Foam::word&amp;, bool)
            in file meshes/polyMesh/polyMeshFromShapeMesh.C at line 871
        Found 3 undefined faces in mesh; adding to default patch.</p>
  </blockquote>
  
  <p>followed by the error:</p>
  
  <blockquote>
    <p>--> FOAM FATAL ERROR:
    wedge wedgeFront centre plane does not align with a coordinate plane by 0.360319
    From function virtual void Foam::wedgePolyPatch::calcGeometry(Foam::PstreamBuffers&amp;)
        in file meshes/polyMesh/polyPatches/constraint/wedge/wedgePolyPatch.C at line 98.</p>
  </blockquote>
  
  <p>unfortunately Googling the error message doesn't return <a href="https://www.google.nl/search?newwindow=1&amp;ei=k_N9W8jhKNDSkwWXpKHoCQ&amp;q=FOAM%20FATAL%20ERROR%20wedge%20%22centre%20plane%20does%20not%20align%20with%20a%20coordinate%20plane%20by%22&amp;oq=FOAM%20FATAL%20ERROR%20wedge%20%22centre%20plane%20does%20not%20align%20with%20a%20coordinate%20plane%20by%22&amp;gs_l=psy-ab.3..35i39k1.8641.16137.0.16734.2.2.0.0.0.0.50.93.2.2.0....0...1c.1.64.psy-ab..0.2.93....0.HvFrsBGHHKA" rel="nofollow noreferrer">much</a>. I would appreciate if you could help me know what is the problem and how I can solve it. </p>