CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

iterating on other mesh

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 16, 2012, 02:51
Default iterating on other mesh
  #1
Super Moderator
 
-mAx-'s Avatar
 
Maxime Perelli
Join Date: Mar 2009
Location: Switzerland
Posts: 3,297
Rep Power: 41
-mAx- will become famous soon enough
Hello,
I have a simple question.
My calculation is finished, but I forgot to define one wall-BC for computing force on it. (I don't want to recompute from 0)
I just have to define my BC, and re-export my final (and right) mesh, and I need to iterate one time on new mesh (but from older mesh solution) for getting my force.
How can I do that?
Or is it a way to interpolate my solution from older mesh to new one?
Thanks in advance
__________________
In memory of my friend Hervé: CFD engineer & freerider
-mAx- is offline   Reply With Quote

Old   February 16, 2012, 12:20
Default
  #2
Senior Member
 
Phoevos
Join Date: Mar 2009
Posts: 104
Rep Power: 17
fivos is on a distinguished road
Hi Max,

I don't know exactly how you want to compute force and what you want to change with your BCs, but can't you simply change the BC at the last time step and change also the controldict file to add the force calculation (see here http://cfdcomputing.com/documents/drag_openfoam.htm also here http://www.cfd-online.com/Forums/ope...rces-of15.html)? Of course then you have to continue from latest time step, by modifying the controlDict file.

If you want to interpolate your ready solution on your new mesh, you should use mapFields (see also here: http://www.openfoam.org/docs/user/st...-utilities.php), it does exactly what you want.

See also the tutorial for the cavity in OpenFoam web page (http://www.openfoam.org/docs/user/ca...#x5-350002.1.9 - go to section 2.1.9). In the tutorial the solution of the lid-driven cavity is mapped on a clipped cavity and the solution goes on.

I hope this helps you.

Last edited by fivos; February 16, 2012 at 12:44.
fivos is offline   Reply With Quote

Old   February 16, 2012, 16:38
Default
  #3
Senior Member
 
Philippose Rajan
Join Date: Mar 2009
Location: Germany
Posts: 552
Rep Power: 25
philippose will become famous soon enough
Hello Maxime,

As long as your mesh is exactly the same, and all you do is add on a patch definition, then you only need to re-export the mesh into OpenFOAM, and make the following changes:

In the controlDict file:
1. Set the "startFrom" option in controlDict to "latestTime"

2. Increase your "endTime" to some number higher than the current last iteration you have on disk

3. change "stopAt" to "writeNow" (This causes the simulation to run for one iteration, force the results to be written to disk, and then stop the simulation)


In the field files (U, p, epsilon, k, etc...) in your last iteration, add on the boundary patch that you just added using the same conditions you have used for any of the other walls you have in the mesh.


Now, rerun your solver (for example, simpleFoam).

This will cause OpenFOAM to run the solver for one iteration, and write the results to disk. These last set of results will have the pressure distribution on your new patch too, which you can then use to calculate the force.


In case you have any doubts, feel free to call :-)!

Have a nice day!

Philippose Rajan
(BHRS)
philippose is offline   Reply With Quote

Old   February 17, 2012, 01:32
Default
  #4
Super Moderator
 
-mAx-'s Avatar
 
Maxime Perelli
Join Date: Mar 2009
Location: Switzerland
Posts: 3,297
Rep Power: 41
-mAx- will become famous soon enough
exactly what I wanted Philippose.
Great job!
Thanks also fivos for your time
__________________
In memory of my friend Hervé: CFD engineer & freerider
-mAx- is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[ICEM] surface mesh merging problem everest ANSYS Meshing & Geometry 44 April 14, 2016 06:41
Converting Starccm+ mesh Ladnam OpenFOAM 0 September 14, 2011 06:30
Meshing aifoil in ICEM student123a ANSYS Meshing & Geometry 13 December 8, 2010 10:40
2d irregular grid Remy Main CFD Forum 1 December 22, 2008 04:49
basic of mesh refinement arya CFX 4 June 19, 2007 12:21


All times are GMT -4. The time now is 18:53.