CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   OpenFOAM (http://www.cfd-online.com/Forums/openfoam/)
-   -   in one solver, two sets of meshes are used? (http://www.cfd-online.com/Forums/openfoam/111412-one-solver-two-sets-meshes-used.html)

hz283 January 6, 2013 14:03

in one solver, two sets of meshes are used?
 
Hi All,

In Openfoam, within one solver, how to realize that some of the governing equations are in one set of mesh (for instance, fine mesh), and others are solved in another set of coarse mesh? the data transfer between two meshes are done by interpolation during each time step. Does anybody know something about this problem? Could you please give me some hints about this?

best,
h

wyldckat January 6, 2013 15:30

Hi H,

Quick answer: look into the solvers with the name patterns "chtMultiRegion*Foam" and "*MRF*". You can search for them with these commands:
Code:

find $FOAM_SOLVERS -name "chtMultiRegion*Foam.C"
find $FOAM_SOLVERS -name "*MRF*.C"

Best regards,
Bruno

akidess January 7, 2013 11:14

Bruno, those solvers couple two or more adjacent meshes. I believe the question was about overlapping meshes. This would e.g. allow you to solve velocity on a fine mesh and temperature on a coarse mesh. Unfortunately I don't have an answer to that question, I don't think it's been done so far.

hz283 January 7, 2013 11:18

Quote:

Originally Posted by akidess (Post 400504)
Bruno, those solvers couple two or more adjacent meshes. I believe the question was about overlapping meshes. This would e.g. allow you to solve velocity on a fine mesh and temperature on a coarse mesh. Unfortunately I don't have an answer to that question, I don't think it's been done so far.

Hi Anton,

You are correct. But I do not how to realize it now.

best regards,
H

codinging January 7, 2013 12:15

get rid of routine head files.
 
to implement this, you have to rewrite the main program without using the routine headfiles such as the setRootCase, createMesh, createTime, createFields. For interpolation between different meshes, you can refer to mapfield tool in the userguide, maybe just copy part of the code to your own program. It would be wise to write your own interpolation function if you know the detail how the coarse mesh is refined. Not difficult, but a time-consuming task.


All times are GMT -4. The time now is 01:43.