CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Pre-Processing

Non-planar initial free surface with setFields

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By roenby

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 18, 2013, 04:29
Default Non-planar initial free surface with setFields
  #1
Member
 
Johan Roenby
Join Date: May 2011
Location: Denmark
Posts: 92
Rep Power: 20
roenby will become famous soon enough
I want to share a problem I've had and its solution:

I am running interFoam in a 3D wave tank, initially setting the water surface to be completely planar at y=0 using setFields, e.g. with a system/setFieldsDict containing:

boxToCell
{
box (-1e10 -1e10 -1e10) (1e10 0 1e10);

fieldValues
(
volScalarFieldValue alpha1 1
);
}

I have noted that this sometimes gives rise to small holes in the initial horizontal surface like the ones shown in the first attached picture.

The explanation is that my blockMesh generated mesh has cells with centres lying just around y=0 plus/minus round-off errors.

The rings in the water set up by these holes can make the solver run very slow initially.

The obvious solution is to replace the line:

box (-1e10 -1e10 -1e10) (1e10 0 1e10);

in system/setFieldsDict with something like:

box (-1e10 -1e10 -1e10) (1e10 0.00001 1e10);

(Depending on your grid resolution, of course) which for me resultet in the completely planar initial free surface shown in the 2nd attached picture.

Hope this is useful to others as well.

Johan
Attached Images
File Type: jpg setFieldsIssue0.jpg (15.4 KB, 39 views)
File Type: jpg setFieldsIssue0p00001.jpg (14.7 KB, 32 views)
nimasam likes this.
roenby is offline   Reply With Quote

Reply

Tags
blockmesh, interfoam, setfields, setfieldsdict


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
calculation stops after few time steps sivakumar OpenFOAM Running, Solving & CFD 7 March 17, 2013 06:37
pisoFoam with k-epsilon turb blows up - Some questions Heroic OpenFOAM Running, Solving & CFD 26 December 17, 2012 03:34
Upgraded from Karmic Koala 9.10 to Lucid Lynx10.04.3 bookie56 OpenFOAM Installation 8 August 13, 2011 04:03
Problems with simulating TurbFOAM barath.ezhilan OpenFOAM 13 July 16, 2009 05:55
Could anybody help me see this error and give help liugx212 OpenFOAM Running, Solving & CFD 3 January 4, 2006 18:07


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