CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   How to use mesh adaptation in OpenFOAM (https://www.cfd-online.com/Forums/openfoam-solving/131509-how-use-mesh-adaptation-openfoam.html)

Tensian March 16, 2014 10:38

How to use mesh adaptation in OpenFOAM
 
Hi everyone,

I am trying to learn something about mesh adaptation in OpenFOAM.

I read some works where itīs used, but not on the way I want.

I have stationary problem, so I donīt have to wonder about the variation of boundaries when I am running the code (like for example a free surface flow).

When I used FLUENT, I started the simulation and after some hundreds of iterations I used the adaptation tool. I define thresold for pressure or velocity, then pressed "Adap" buttom and...a new mesh was created, with higher density where gradients was going to be greater!

What I have to do for mimic this procedure in OpenFOAM? I read something about a dictionary called dynamicMeshDict, but I am not sure if I need something more or this is enough. I only want to run the code, and after for example 500 iterations stop it, adapt (increase mesh size for example twice), and then continue iterating until I found a mesh independence solution.

So my questions are:

1. What files do I need in order to adapt my mesh in this way? Have anybody an example of those files?

2. How can I link the adaptation technique with the code? Iam using simpleFoam and rhoSimpleFoam, so, when I create the (unknown for me now) suitable files, will the adaptation work automatically while the solver is running or I have to execute something more than the code? (for example stop simpleFoam run, write on terminal "dynamicMesh" or similar and then run simpleFoam again? Or is it done without user action?)

Any help will be really aprecciated. I am stuck in this issue...:confused::confused::confused:

Josefina May 27, 2014 06:30

Hi!

I started using this kind of tools this morning, so I am not an expert :$ but I think it could be helpful for you if you take a look at interDyMFoam tutorials or at the paper below that explains a little the code and how to create a new solver with a dynamic mesh.

http://www.tfd.chalmers.se/~hani/kur...tersReport.pdf

;)

Josefina May 27, 2014 06:41

On the other hand, as far as your problem is a steady study, you can also try to use the utility refineMesh. The limit could be the fact that you have to know already the zone that you want to refine.

if you only use refineMesh all the domain will be refined. If you want to refine a zone, you can use a dictionary named topoSetDict that should be in the "system" directory of your case.

have a look to:

http://www.cfd-online.com/Forums/ope...efinement.html

good luck!


All times are GMT -4. The time now is 00:16.