CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Meshing & Mesh Conversion (https://www.cfd-online.com/Forums/openfoam-meshing/)
-   -   [mesh manipulation] Converting a 2Dmesh to axisymmetric (https://www.cfd-online.com/Forums/openfoam-meshing/61473-converting-2dmesh-axisymmetric.html)

gschaider June 18, 2013 11:59

Quote:

Originally Posted by shash (Post 434414)
hi bernhard,

I am sorry , i didn't go thru prevoius threads. Thanks a lot for ur answer now its up and running, I also wanted to confirm something, thou collapseEdges 1e-06 175 command after makeaxialmesh worked for me on OF ver 2.1 but a friend of mine is getting troubles running the same command collapseEdges 1e-06 175 for same case on OF ver 2.2, whats the reason for that, its showing required 0 argument, 2 given

Seems like they changed the way it works. Try the -h option to see if there are options you like. Run without arguments and see what happens. I'm currently on vacation so it might be faster for you if you try some experiments yourself

shuoxue June 18, 2013 23:43

Hi, gschaider!

It seems that you know much about #0 Foam::error::printStack error.
I have received this kind of error when running interFoam with Gambit mesh.
Would you please check the error for me. Thanks a lot.
http://www.cfd-online.com/Forums/ope...tml#post434749

I installed openfoam 2.2.0 on ubuntu 12.04.

Best regards.

gschaider June 20, 2013 20:15

Quote:

Originally Posted by shuoxue (Post 434752)
Hi, gschaider!

It seems that you know much about #0 Foam::error::printStack error.
I have received this kind of error when running interFoam with Gambit mesh.
Would you please check the error for me. Thanks a lot.
http://www.cfd-online.com/Forums/ope...tml#post434749

I installed openfoam 2.2.0 on ubuntu 12.04.

Best regards.

printStack can be anything. See http://openfoamwiki.net/index.php/HowTo_debugging on how to interpret it. And I don't answer questions that do not belong in this thread

yash.aesi August 14, 2013 07:23

Error while running ..rhocentralfoam
 
helo ,
i converted my 2D axisymmetry fluent mesh into OF and then changed the 0 folder according to my values also i checked mesh with checkmesh command its ok but when i tried to run it run it is giving me following error , can anybody please help me how to overcome from this error ?

FOAM FATAL IO ERROR:
inconsistent patch and patchField types for
patch type symmetryPlane and patchField type empty

file: /home/yash/OpenFOAM/yash-2.2.0/run/tutorials/compressible/rhoCentralFoam/exsercisePrb/0/p.boundaryField.Axis from line 39 to line 39.

From function fvPatchField<Type>::New(const fvPatch&, const DimensionedField<Type, volMesh>&, const dictionary&)
in file /home/opencfd/OpenFOAM/OpenFOAM-2.2.0/src/finiteVolume/lnInclude/fvPatchFieldNew.C at line 165.

nimasam August 14, 2013 09:30

look at the error line, it says:
Quote:

patch type symmetryPlane and patchField type empty
so you should make those types consistent :), if you choose symmetryPlane as patch type, then p, U or other variables should have the same patch type means symmetryPlane not empty ;)

yash.aesi August 14, 2013 14:30

helo
can you please look into the p file and tell me wts wrong in it which you had mentioned , thanks alot for your reply ,

/*--------------------------------*- C++ -*----------------------------------*\
| ========= | |
| \\ / F ield | OpenFOAM: The Open Source CFD Toolbox |
| \\ / O peration | Version: 2.2.0 |
| \\ / A nd | Web: www.OpenFOAM.org |
| \\/ M anipulation | |
\*---------------------------------------------------------------------------*/
FoamFile
{
version 2.0;
format ascii;
class volScalarField;
object p;
}
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //

dimensions [1 -1 -2 0 0 0 0];

internalField uniform 101325;

boundaryField
{
fuel_inlet
{
type zeroGradient;
}

coflow_inlet
{
type zeroGradient;
}

Outlet
{
type zeroGradient;
}
Axis
{
type empty;
}
Upperwall
{
type zeroGradient;
}

frontAndBack
{
type empty;
}
}

// ************************************************** *********************** //

nimasam August 14, 2013 15:34

Quote:

Axis
{
type empty;
}
well, it should be
Quote:

Axis
{
type symmetryPlane;
}
also i thing your frontAndBack should be wedge type :P, however you may face this problem next ;)

yash.aesi August 14, 2013 15:45

thanks alot nima. i will try this and then inform you ......thanks again for helping :)

zhixuan August 16, 2014 15:35

hi, all foamers,

I came across problems when using makeAxisMesh in OF2.3.0. Here are steps I went through:
1. run blockMesh, where axis_plane has been set as planar type
2. run makeAxialMesh -axis axis_plane -wedge frontAndback

however, it says
HTML Code:

Symmetry plane 'axis_plane' is not planar.
At local face at (0 -0.075565 0.0025) the normal (0 0 0) differs from the average normal (0.438889 0 0) by 0.192623
Either split the patch into planar parts or use the symmetry patch type

I changed the "axis_plane" to be "symmetric", it still cannot work.

Then I changed the coordinates, such as switching X axis and Y axis, it works somehow with a new error:
HTML Code:

--> FOAM FATAL ERROR:
wedge frontAndback_pos plane aligns with a coordinate plane.
    The wedge plane should make a small angle (~2.5deg) with the coordinate plane
    and the the pair of wedge planes should be symmetric about the coordinate plane.
    Normal of face 0 is (-1 0 0) , implied coordinate plane direction is (-1 0 0)

    From function wedgePolyPatch::initTransforms()
    in file meshes/polyMesh/polyPatches/constraint/wedge/wedgePolyPatch.C at line 78.

FOAM exiting

I tired several times rotating the coordinator. But still, nothing improved. So I'm wondering if anyone can provide hints on this issue.

I also enclosed my blockMeshDict for your reference.

Thank you in advance.

gschaider August 17, 2014 17:33

Quote:

Originally Posted by zhixuan (Post 506286)
hi, all foamers,

I came across problems when using makeAxisMesh in OF2.3.0. Here are steps I went through:
1. run blockMesh, where axis_plane has been set as planar type
2. run makeAxialMesh -axis axis_plane -wedge frontAndback

however, it says
HTML Code:

Symmetry plane 'axis_plane' is not planar.
At local face at (0 -0.075565 0.0025) the normal (0 0 0) differs from the average normal (0.438889 0 0) by 0.192623
Either split the patch into planar parts or use the symmetry patch type


What do you mean with "set as planar type"? The type of the patch is irrelevant. The faces have to be in a plane (that's what "planar" means). That's what the utility checks for. Otherwise the patch can't be used as an axis

zhixuan August 17, 2014 18:31

Quote:

Originally Posted by gschaider (Post 506376)
What do you mean with "set as planar type"? The type of the patch is irrelevant. The faces have to be in a plane (that's what "planar" means). That's what the utility checks for. Otherwise the patch can't be used as an axis

Hi, Bernhard,

Thank you for the response. Originally, I tried the test case you provided here
http://openfoamwiki.net/index.php/Contrib/MakeAxialMesh

I tried
1. blockMesh
2. makeAxialMesh -axis movingWall -wedge frontAndBack

it generates an error, saying

HTML Code:

--> FOAM FATAL ERROR:
Symmetry plane 'movingWall' is not planar.
At local face at (0.00333333 0.1 0) the normal (0 1 0) differs from the average normal (0 0.3 0) by 0.49
Either split the patch into planar parts or use the symmetry patch type

    From function symmetryPlanePolyPatch::n()
    in file meshes/polyMesh/polyPatches/constraint/symmetryPlane/symmetryPlanePolyPatch.C at line 64.

FOAM exiting

I'm confused why it says the points on movingWall is not on a planar.

Then I thought it probably due to the wrong direction since you mentioned "the axis of symmetry is parallel to the XY-plane". So I split the fixedWalls into three surfaces and selected different fixedWalls1(0 4 7 3), fixedWalls2(2 6 5 1), fixedWalls3(1 5 4 0) as the axis. Only the fixedWalls2 (2 6 5 1) can work and it is actually parallel to Y-Z plane.

Based on the experience of the test, I developed my own code

Code:

FoamFile                               
{                                     
    version        2.3;               
    format          ascii;             
                                       
    root            "";             
    case            "";             
    instance        "";             
    local          "";             
                                       
    class          dictionary;       
    object          blockMeshDict;     
}         
                                       
vertices                               
(                                     
        (0 -0.0762  0)  // 0
        (0 -0.0762 0.0079375  ) // 1
        (0 0 0.0079375 )  //2
        (0 0 0.070358 )  //3
        (0 0.1524 0.070358 ) //4
        (0 0.508 0.070358 )  //5
        (0 0.508 0) //6
        (0 0.1524 0)  //7
        (0 0 0) //8

        (0.005 -0.0762 0 )  // 9
        (0.005 -0.0762 0.0079375  ) // 10
        (0.005 0 0.0079375 )  //11
        (0.005 0 0.070358 )  //12
        (0.005 0.1524 0.070358 ) //13
        (0.005 0.508 0.070358 )  //14
        (0.005 0.508 0 ) //15
        (0.005 0.1524 0 )  //16
        (0.005 0 0 ) //17

        (0 0.508 0.0079375 ) //18
        (0.005 0.508 0.0079375 ) //19

        (0 0.1524 0.0079375 ) //20
        (0.005 0.1524 0.0079375 ) //21
 
);

blocks
(               
        // process inlet
        hex (0 8 2 1 9 17 11 10) (60 10 1) simpleGrading (1 1 1)
        // burner 1
        hex (8 7 20 2 17 16 21 11) (60 10 1) simpleGrading (1 1 1)
        // burner 2
        hex (2 20 4 3 11 21 13 12) (60 40 1) simpleGrading (1 1 1)
        // burner 3
        hex (20 18 5 4 21 19 14 13) (60 40 1) simpleGrading (1 1 1)
        // burner 4
        hex (7 6 18 20 16 15 19 21) (60 10 1) simpleGrading (1 1 1)
       
);
                                   
edges                               
(                                   
);                                       
                           

boundary                           
(     
        processInlet             
        {
            type patch;   
            faces
            (
                (0 1 10 9)
            );
        } 

        wall             
        {
            type wall;   
            faces
            (
                (1 2 11 10)
                //(3 2 11 12)
                (12 11 2 3)
            );
        }

        outlet             
        {
            type patch;   
            faces
            (
                (5 18 19 14)
                (18 6 15 19)
            );
        }
       
        axis_plane             
        {
            type symmetry;   
            faces
            ( 
                //(0 8 17 9)
                (9 17 8 0)
                //(8 7 16 17)
                (17 16 7 8)
                (7 6 15 16)
            );
        } 
 
        quenchingWall             
        {
            type wall;   
            faces
            (
                (4 5 14 13)
            );
        }   

        porousInlet             
        {
            type patch;   
            faces
            (
                (3 4 13 12)
            );
        }
                                 
   
        frontAndback             
        {
            type empty;   
            faces
            (
                (0 8 2 1)
                (8 7 20 2)
                (7 6 18 20)
                (2 20 4 3)
                (20 18 5 4)       
                (9 17 11 10)
                (17 16 21 11)
                (16 15 19 21)
                (11 21 13 12)
                (21 19 14 13)       
               
            );
        } 
             
);                                 
                                   
mergePatchPairs
(
);

However, when I run
makeAxialMesh -axis axis_plane -wedge frontAndback

it says

HTML Code:

Create time

Create mesh for time = 0

 Using old mode. Dictionary not used
Plane of the grid: (0 0 1) (0.0025 0.180204 0.0294471)

The rotation-axis: ((0 -0.0762 0.0294471) (0.005 0.508 0.0294471))

Creating wedge with an opening angle of 5 degrees

Projecting nodes
Radius to axis: min = 0 max = 0.00499982
Splitting patch frontAndback

 Copying patches
 Creating Patches
 Creating Pos-patch
 Creating Neg-patch
 Changing patches

Changing patch types
 Changing axis_plane to symmetryPlane
 Changing frontAndback_pos to wedge


--> FOAM FATAL ERROR:
wedge frontAndback_pos plane aligns with a coordinate plane.
    The wedge plane should make a small angle (~2.5deg) with the coordinate plane
    and the the pair of wedge planes should be symmetric about the coordinate plane.
    Normal of face 0 is (-1 0 0) , implied coordinate plane direction is (-1 0 0)

    From function wedgePolyPatch::initTransforms()
    in file meshes/polyMesh/polyPatches/constraint/wedge/wedgePolyPatch.C at line 78.

FOAM exiting

I don't know what's wrong with this error. Again, I rotated the coordinator directions, but nothing is improved.

By the way, I'm using OF2.3.0.


Thank you
Zhixuan

gschaider August 21, 2014 18:48

Quote:

Originally Posted by zhixuan (Post 506380)
Hi, Bernhard,

Thank you for the response. Originally, I tried the test case you provided here
http://openfoamwiki.net/index.php/Contrib/MakeAxialMesh

I tried
1. blockMesh
2. makeAxialMesh -axis movingWall -wedge frontAndBack

it generates an error, saying

HTML Code:

--> FOAM FATAL ERROR:
Symmetry plane 'movingWall' is not planar.
At local face at (0.00333333 0.1 0) the normal (0 1 0) differs from the average normal (0 0.3 0) by 0.49
Either split the patch into planar parts or use the symmetry patch type

    From function symmetryPlanePolyPatch::n()
    in file meshes/polyMesh/polyPatches/constraint/symmetryPlane/symmetryPlanePolyPatch.C at line 64.

FOAM exiting

I'm confused why it says the points on movingWall is not on a planar.

Seems like there is some problem when patches are specified on the command line. I get the same error. But when I run it just with "makeAxialMesh" the dictionary in system is used and it works.

I'd recommend using the dictionary anyway as this is more flexible

davibarreira November 19, 2014 12:55

Im facing the same problem as zhixuan. The thing is, even if I use the dictionary by just running the command makeAxialMesh, the "movingWall" keeps it's patch as "wall". Any thoughts?


Thanks!

zhangyan December 19, 2014 20:55

Quote:

Originally Posted by davibarreira (Post 520040)
Im facing the same problem as zhixuan. The thing is, even if I use the dictionary by just running the command makeAxialMesh, the "movingWall" keeps it's patch as "wall". Any thoughts?


Thanks!


Hi
Have you solved this problem now?

davibarreira December 20, 2014 00:45

Code:

--> FOAM FATAL ERROR:  wedge frontAndback_pos plane aligns with a coordinate plane.    The wedge plane should make a small angle (~2.5deg) with the coordinate plane    and the the pair of wedge planes should be symmetric about the coordinate plane.    Normal of face 0 is (-1 0 0) , implied coordinate plane direction is (-1 0 0)
I managed to solve this problem by using the dictonary rotationDict, and using the option for setting MakeAxialMesh in old version. Below there is a rotationDict with this option turned on:

Code:

/*---------------------------------------------------------------------------*\
| =========                |                                                |
| \\      /  F ield        | OpenFOAM: The Open Source CFD Toolbox          |
|  \\    /  O peration    | Version:  1.0                                  |
|  \\  /    A nd          | Web:      http://www.openfoam.org              |
|    \\/    M anipulation  |                                                |
\*---------------------------------------------------------------------------*/

FoamFile
{
    version        2.0;
    format          ascii;

    root        ".";
    case        "test";
    instance        "system";
    local          "";

    class          dictionary;
    object          radialBCDict;
}


// Use the same parameters as from the command line
makeAxialOldMode 1;

// used in old and in new mode
makeAxialAxisPatch sym;
makeAxialWedgePatch frontandback;

// used only in old mode
makeAxialOffset 0.01;

// used only in new mode
rotationVector (1 0 0);
originVector (0 0 0); //offset
// originVector (0 0 0); // origin

wedgeAngle 5;

// revolve option
// 0 = old and default mode, points are projected on wedges
// 1 = points are revolved
revolve 0;

// ************************************************************************* //

I tried using collapseEdges, but I just couldnt get it to work. So I decided to use my mesh with symmetryPlane in the face that was supposed to be the axis (dont know how correct this is, but the results are looking correct when compared to some 3D simulations I ran).

The patch type I had to change manually in my blockMeshDict file.

I played around with MakeAxialMesh for a while and I really think it has some compatibility error with OpenFOAM 2.3, because the errors occur even in really simple meshes.

zhangyan December 20, 2014 01:43

Hi
I also tried rotateMesh ,but I don't know the usage .Can you help me ?
Code:

zhangyan@ubuntu:~/0.0$ rotateMesh

Usage: rotateMesh [OPTIONS] <n1> <n2>
options:
  -case <dir>      specify alternate case directory, default is the cwd
  -constant        include the 'constant/' dir in the times list
  -latestTime      select the latest time
  -noFunctionObjects
                    do not execute functionObjects
  -noZero          exclude the '0/' dir from the times list, has precedence
                    over the -zeroTime option
  -parallel        run in parallel
  -roots <(dir1 .. dirN)>
                    slave root directories for distributed running
  -time <ranges>    comma-separated time ranges - eg, ':10,20,40:70,1000:'
  -srcDoc          display source code in browser
  -doc              display application documentation in browser
  -help            print the usage


davibarreira December 20, 2014 08:29

rotateMesh is not to create axial meshes, if you want to create an axial mesh use makeAxialMesh. Just create the rotationDict as I posted and put it on your system folder. Then run the command makeAxialMesh. This will create a mesh in a folder such as 0.005, or something like that. Use checkMesh command to see if the mesh is correct, then replace your orignal polymesh folder with the one in the 0.005 folder.

zhangyan December 20, 2014 08:33

Quote:

Originally Posted by davibarreira (Post 524761)
rotateMesh is not to create axial meshes, if you want to create an axial mesh use makeAxialMesh. Just create the rotationDict as I posted and put it on your system folder. Then run the command makeAxialMesh. This will create a mesh in a folder such as 0.005, or something like that. Use checkMesh command to see if the mesh is correct, then replace your orignal polymesh folder with the one in the 0.005 folder.

I also have tried makeaxialMesh.
but ,
Code:

--> FOAM FATAL ERROR:
Symmetry plane 'movingWall' is not planar.
At local face at (0.00333333 0.1 0) the normal (0 1 0) differs from the average normal (0 0.3 0) by 0.49
Either split the patch into planar parts or use the symmetry patch type

    From function symmetryPlanePolyPatch::n()
    in file meshes/polyMesh/polyPatches/constraint/symmetryPlane/symmetryPlanePolyPatch.C at line 64.

FOAM exiting

my movingWall's type is empty, I also tried symmetry and symmetryPlane, but all failed.

zhangyan December 20, 2014 08:35

and another question: rotateDict is used accompany with rotateMesh.
I think makeaxialMesh don't need this dictionary.

davibarreira December 20, 2014 08:47

The dictionary for makeAxilMesh is rotationDict not rotateDict. Can you post your blockMeshDict here so I can take a look?

zhangyan December 20, 2014 09:03

1 Attachment(s)
Quote:

Originally Posted by davibarreira (Post 524765)
The dictionary for makeAxilMesh is rotationDict not rotateDict. Can you post your blockMeshDict here so I can take a look?

oh,thanks!

zhangyan December 20, 2014 09:08

Quote:

Originally Posted by davibarreira (Post 524765)
The dictionary for makeAxilMesh is rotationDict not rotateDict. Can you post your blockMeshDict here so I can take a look?

oh
you mean the command rotateMesh don't need any dictionary?

davibarreira December 20, 2014 18:06

2 Attachment(s)
Ok, so I figured out how to use makeAxialMesh properly thanks to this old thread: http://www.cfd-online.com/Forums/ope...mmetric-6.html

Forget what I said before about using the option makeAxialOldMode 1.

Just put the rotationDict and collapseDict in your system folders (you can use the ones attached, they work on your case). After that, run blockMesh to generate your mesh, then makeAxialMesh. Finally, run collapseEdges -latestTime . Your directory will look something like this (the numbers of the folders may change a bit):

0/ 0.0025/ 0.005/ constant/ system/

Copy the polymesh folder inside the 0.005 directory and replace it with your polymesh inside the constant/ folder (remember to back it up, so you dont lose your original blockMeshDict). And that's it.

P.S: rotateMesh is not for creating axial meshes, so you dont need to use it.

zhangyan December 20, 2014 18:23

thanks for your kindness!
I will try it.

zhangyan December 21, 2014 21:08

Quote:

Originally Posted by davibarreira (Post 524808)
Ok, so I figured out how to use makeAxialMesh properly thanks to this old thread: http://www.cfd-online.com/Forums/ope...mmetric-6.html

Forget what I said before about using the option makeAxialOldMode 1.

Just put the rotationDict and collapseDict in your system folders (you can use the ones attached, they work on your case). After that, run blockMesh to generate your mesh, then makeAxialMesh. Finally, run collapseEdges -latestTime . Your directory will look something like this (the numbers of the folders may change a bit):

0/ 0.0025/ 0.005/ constant/ system/

Copy the polymesh folder inside the 0.005 directory and replace it with your polymesh inside the constant/ folder (remember to back it up, so you dont lose your original blockMeshDict). And that's it.

P.S: rotateMesh is not for creating axial meshes, so you dont need to use it.

maybe I can operate in another way:blockMesh...makeAxialMesh -overwrite...collapseEdges -overwrite?

gschaider January 7, 2015 16:11

Quote:

Originally Posted by zhangyan (Post 524884)
maybe I can operate in another way:blockMesh...makeAxialMesh -overwrite...collapseEdges -overwrite?

Try it. (as some time passed you probably did it and it worked)

dumas March 22, 2015 20:01

Help
 
1 Attachment(s)
I have a problem to generate the axisymmetric mesh in my work, someone could help me, I am sending the files, would be grateful if anyone could help.


My openFoam 2.3

Thanks.


:D

zhangyan March 22, 2015 23:04

Hi Santos,
 
Quote:

Originally Posted by dumas (Post 537739)
I have a problem to generate the axisymmetric mesh in my work, someone could help me, I am sending the files, would be grateful if anyone could help.


My openFoam 2.3

Thanks.


:D


Hi Santos,
1~~~At first,the makeAxialMesh tools should be compiled correctly.
2~~~In the file "blockMeshDict" , you should add a face named "center" which the mesh can rotate around it. Like this :

center
{
type symmetryPlane;
faces
(
(13 0 14 27)
);
}
3~~~And then,in the dictionary "system",two files "rotationDict" and "collapseDict" are needed. See the #183 floor.
4~~~At last,input these commands in order:
blockMesh
makeAxialMesh -overwrite
collapseEdges -overwrite
checkMesh
5~~~Good luck!
6~~~Forgive my poor English.

dumas March 23, 2015 07:12

thanks
 
Thank zhangyan, I will try to perform these procedures. No problem, sorry my English.

dumas March 23, 2015 12:05

Help
 
3 Attachment(s)
Quote:

Originally Posted by zhangyan (Post 537751)
Hi Santos,
1~~~At first,the makeAxialMesh tools should be compiled correctly.
2~~~In the file "blockMeshDict" , you should add a face named "center" which the mesh can rotate around it. Like this :

center
{
type symmetryPlane;
faces
(
(13 0 14 27)
&nbsp;);
}
3~~~And then,in the dictionary "system",two files "rotationDict" and "collapseDict" are needed. See the #183 floor.
4~~~At last,input these commands in order:
blockMesh
makeAxialMesh -overwrite
collapseEdges -overwrite
checkMesh
5~~~Good luck!
6~~~Forgive my poor English.




hello zhangyan,

I tried to take the steps you suggested, but the mesh was the same as the initial mesh. Execultar got the makeAxialMesh program, was generated the 0005 file, but nothing has changed.

Chosen as the center

(
(0 1 7 6) // Bot (0)
(1 12 14 7) // Bot (2)
);

Would have a question,

frontandback is the type empty?

If you could generate this mesh to me with the axis of symmetry equal to figure Site: https://openfoamwiki.net/index.php/C.../MakeAxialMesh

ali.ghaemi April 27, 2015 11:30

Conveerting a 2D mesh to axisymmetric using MAM in OF-2.3.1
 
1 Attachment(s)
Hi Foamers

I am encountering a strange problem creating axisymmetric meshes using MAM. The mesh looks pretty fine in paraview, before using collapseEdges. But when I use collapeEdges, it converts the axisymmetric mesh to the original 2D mesh.
I also tried using makeAxialMesh -overwrite. Thereafter, OF exits by (Floating point exception) error, when I use collapeEdges or checkMesh.
Does any body use MakeAxialMesh_2.x on OF-2.3.1? From what I have read in this thread, I guess it is a compatibility problem.

Thanks in advance


PS: please find attached the corresponding case.

davibarreira August 15, 2015 10:54

You might want to try OF 2.4, they made some improvements to the makeAxialMesh.

Cheers

Antony_Bosco October 2, 2015 11:48

makeAxialMesh
 
Hi,

While running makeAxialMesh i am getting this warnig quite often.


--> FOAM Warning :
From function wedgePolyPatch::calcGeometry(PstreamBuffers&)
in file meshes/polyMesh/polyPatches/constraint/wedge/wedgePolyPatch.C at line 72
Wedge patch 'wedge_neg' is not planar.
At local face at (1.5137 0.0402188 -0.000877755) the normal (8.01877e-18 -0.0218097 -0.999762) differs from the average normal (-3.78148e-22 -0.0218097 -0.999762) by 1.72515e-15

is there something i should check or can i ignore this?

Thanks

schmidt_d October 2, 2015 11:55

round off
 
Looking at the digits of the normal vectors, it appears that this small discrepancy is a consequence of round-off. My guess is that you can safely ignore this warning.

Antony_Bosco October 14, 2015 04:28

checkMesh
 
2 Attachment(s)
Thanks schmidt,

I have yet another problem. I am doing a external flow study on a axis symmetric body.

I am using blockMesh -> snappyHexMesh -> makeAxialMesh -> collapseEdges.

when i view the mesh it is all fine . but when i check the mesh with 'checkMesh' i am getting 7 errors.

I have attached the log file i received for checkMesh.

Is there anything that i have to do with rotationDict or collapseDict?

Code:

Checking topology...    Boundary definition OK.    Cell to face addressing OK.    Point usage OK.    Upper triangular ordering OK.    Face vertices OK.    Number of regions: 1 (OK).  Checking patch topology for multiply connected surfaces...                    Patch    Faces  Points                  Surface topology                    inlet      100      202  ok (non-closed singly connected)                  outlet      100      202  ok (non-closed singly connected)                upperWall    1200    2402  ok (non-closed singly connected)            frontAndBack        0        0                        ok (empty)                lowerWall    1532    2677  ok (non-closed singly connected)                      ua1    31770    32535  ok (non-closed singly connected)        frontAndBack_pos  142483  145823  ok (non-closed singly connected)        frontAndBack_neg  142375  145713  ok (non-closed singly connected)  Checking geometry...    Overall domain bounding box (-1.1 0 -0.0141658) (4.6 0.325 0.0141868)    Mesh (non-empty, non-wedge) directions (1 1 0)    Mesh (non-empty) directions (1 1 1)    Wedge frontAndBack_pos with angle 2.49754 degrees  ***Cannot find opposite wedge for wedge frontAndBack_pos    Boundary openness (-9.02861e-19 1.54122e-14 1.31133e-12) OK.  ***Open cells found, max cell openness: 0.0218662, number of open cells 152521  <<Writing 152521 non closed cells to set nonClosedCells  <<Writing 228809 cells with high aspect ratio to set highAspectRatioCells  ***Zero or negative face area detected.  Minimum area: 0  <<Writing 130 zero area faces to set zeroAreaFaces  ***Zero or negative cell volume detected.  Minimum negative volume: -7.9226e-17, Number of negative volume cells: 120358  <<Writing 120358 zero volume cells to set zeroVolumeCells    Mesh non-orthogonality Max: 175.974 average: 70.2632    *Number of severely non-orthogonal (> 70 degrees) faces: 330991.  ***Number of non-orthogonality errors: 306103.  <<Writing 637094 non-orthogonal faces to set nonOrthoFaces  ***Error in face pyramids: 1338 faces are incorrectly oriented.  <<Writing 1338 faces with incorrect orientation to set wrongOrientedFaces  ***Max skewness = 1.58762e+06, 118079 highly skew faces detected which may impair the quality of the results  <<Writing 118079 skew faces to set skewFaces    Coupled point location match (average 0) OK.  Failed 7 mesh checks.  End

Antony_Bosco October 14, 2015 04:29

sorry for the previous post.

the error is

Code:

Checking topology...
    Boundary definition OK.
    Cell to face addressing OK.
    Point usage OK.
    Upper triangular ordering OK.
    Face vertices OK.
    Number of regions: 1 (OK).

Checking patch topology for multiply connected surfaces...
                  Patch    Faces  Points                  Surface topology
                  inlet      100      202  ok (non-closed singly connected)
                  outlet      100      202  ok (non-closed singly connected)
              upperWall    1200    2402  ok (non-closed singly connected)
            frontAndBack        0        0                        ok (empty)
              lowerWall    1532    2677  ok (non-closed singly connected)
                    ua1    31770    32535  ok (non-closed singly connected)
        frontAndBack_pos  142483  145823  ok (non-closed singly connected)
        frontAndBack_neg  142375  145713  ok (non-closed singly connected)

Checking geometry...
    Overall domain bounding box (-1.1 0 -0.0141658) (4.6 0.325 0.0141868)
    Mesh (non-empty, non-wedge) directions (1 1 0)
    Mesh (non-empty) directions (1 1 1)
    Wedge frontAndBack_pos with angle 2.49754 degrees
 ***Cannot find opposite wedge for wedge frontAndBack_pos
    Boundary openness (-9.02861e-19 1.54122e-14 1.31133e-12) OK.
 ***Open cells found, max cell openness: 0.0218662, number of open cells 152521
  <<Writing 152521 non closed cells to set nonClosedCells
  <<Writing 228809 cells with high aspect ratio to set highAspectRatioCells
 ***Zero or negative face area detected.  Minimum area: 0
  <<Writing 130 zero area faces to set zeroAreaFaces
 ***Zero or negative cell volume detected.  Minimum negative volume: -7.9226e-17, Number of negative volume cells: 120358
  <<Writing 120358 zero volume cells to set zeroVolumeCells
    Mesh non-orthogonality Max: 175.974 average: 70.2632
  *Number of severely non-orthogonal (> 70 degrees) faces: 330991.
 ***Number of non-orthogonality errors: 306103.
  <<Writing 637094 non-orthogonal faces to set nonOrthoFaces
 ***Error in face pyramids: 1338 faces are incorrectly oriented.
  <<Writing 1338 faces with incorrect orientation to set wrongOrientedFaces
 ***Max skewness = 1.58762e+06, 118079 highly skew faces detected which may impair the quality of the results
  <<Writing 118079 skew faces to set skewFaces
    Coupled point location match (average 0) OK.

Failed 7 mesh checks.

End


davibarreira October 14, 2015 06:31

Try to use extrudeMesh after snappyHexMesh

Antony_Bosco October 15, 2015 10:57

extrudeMesh
 
Thanks Davibarreira,

extrudeMesh did not help. But i don't see the use of extrudeMesh. Do i have to make any changes in extrudeMeshDict or in collapseMeshDict??

Hisham October 28, 2015 11:41

Hallo Antony,

Have you defined frontAndBack_neg as wedge in your constant/polyMesh/boundary file?

Best regards
Hisham

Antony_Bosco October 28, 2015 11:53

@Hisham.
After running snappyHexMesh frontAndBack is patch.
After running makeAxialMesh frontAndBack is patch, frontAndBack_pos is wedge and frontAndBack_neg is wedge.


All times are GMT -4. The time now is 21:46.