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

empty patch as farfield condition

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   September 26, 2013, 13:53
Default empty patch as farfield condition
  #1
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
Hello foamer

please look at the attached file, this file solves a flow over plate by simpleFoam solver in OF-2.2.0, instead of farfield condition, it uses empty BC. I expected it crashes, but it works fine, so whats farfield BC for p,U, and so on? how they can be calculated when we assign it an empty patch?


Best Regards
Attached Images
File Type: png plate.png (9.7 KB, 26 views)
Attached Files
File Type: zip flatplate.zip (87.3 KB, 10 views)
__________________
My Personal Website (http://nimasamkhaniani.ir/)
Telegram channel (https://t.me/cfd_foam)
nimasam is offline   Reply With Quote

Old   September 26, 2013, 16:58
Default
  #2
ngj
Senior Member
 
Niels Gjoel Jacobsen
Join Date: Mar 2009
Location: Copenhagen, Denmark
Posts: 1,900
Rep Power: 37
ngj will become famous soon enoughngj will become famous soon enough
Good evening,

That is very strange. I quickly tried the case on a couple of versions of OpenFoam, and the report is as follows:

- OF2.2.1: The attached simulation runs.
- OF2.2.0: The attached simulation runs.
- OF2.1.0: The attached simulation runs.
- OF1.7.1: The attached simulation fails.
- OF1.6-ext: The attached simulation fails.

Looking at the data, where is actually a non-zero velocity normal to the farfield boundary, so how does an empty boundary condition behave?

This must be a bug in the mesh check prior during runTime. It is on the other hand interesting that only in OF2.1.0 and OF2.2.* does checkMesh complain over the mismatch between number of empty faces and the number of cells. This is not part of the response in neither OF1.7.1 nor OF1.6-ext.

Kind regards

Niels
__________________
Please note that I do not use the Friend-feature, so do not be offended, if I do not accept a request.
ngj is offline   Reply With Quote

Old   April 5, 2014, 14:06
Default
  #3
New Member
 
何刚
Join Date: Jan 2011
Posts: 25
Rep Power: 15
hg2lf is on a distinguished road
Quote:
Originally Posted by nimasam View Post
Hello foamer

please look at the attached file, this file solves a flow over plate by simpleFoam solver in OF-2.2.0, instead of farfield condition, it uses empty BC. I expected it crashes, but it works fine, so whats farfield BC for p,U, and so on? how they can be calculated when we assign it an empty patch?

Have you solved this problem? I faced the problem of how to set far field boundary as well.

Last edited by wyldckat; April 5, 2014 at 17:15. Reason: fixed broken quote
hg2lf is offline   Reply With Quote

Old   April 5, 2014, 16:04
Default
  #4
Senior Member
 
Nima Samkhaniani
Join Date: Sep 2009
Location: Tehran, Iran
Posts: 1,266
Blog Entries: 1
Rep Power: 24
nimasam is on a distinguished road
as Niels mentioned it seems it is a bug in OpenFOAM
__________________
My Personal Website (http://nimasamkhaniani.ir/)
Telegram channel (https://t.me/cfd_foam)
nimasam is offline   Reply With Quote

Old   April 5, 2014, 17:47
Default
  #5
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,974
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Greetings to all!

Thanks to the OpenFOAM-combo repo I created sometime ago ( https://github.com/wyldckat/OpenFOAM-combo/ ), I managed to see what happened in this case.

As of OpenFOAM 2.0.0, they decided to comment out this check, which was made only when the respective debug flag was active. In the latest code at 2.3.x, have a look into the method "updateCoeffs()": https://github.com/OpenFOAM/OpenFOAM...chField.C#L139 - it has this comment there:
Quote:
Code:
    //- Check moved to checkMesh. Test here breaks down if multiple empty
    //  patches.
Now, the big question is whether this can be considered a bug or not. There are a few details to take into account:
  1. The "empty" BC should conceptually act as a "symmetry" BC. Problem is that it is not coded to act as one, since the objective is to report that there are no faces on the respective patch.
  2. OpenFOAM usually does not stop us at the beginning of running a solver, just because the mesh has got imperfections. At most, it complains if something is missing or otherwise it will crash due to the incorrect detail.
  3. The description for the "empty" BC states: https://github.com/OpenFOAM/OpenFOAM...tchField.H#L31
    Quote:
    Code:
    This boundary condition provides an 'empty' condition for reduced
    dimensions cases, i.e. 1- and 2-D geometries. Apply this condition to
    patches whose normal is aligned to geometric directions that do not
    constitue solution directions.
Therefore, according to point #2, the user is always responsible for first diagnose the sanity of the mesh. And according to #3, this can be considered a feature, namely the ability to not calculate in certain "solution directions" .

Best regards,
Bruno
__________________
wyldckat is offline   Reply With Quote

Reply

Tags
empty patch, farfield

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
[Commercial meshers] Fluent msh and cyclic boundary cfdengineering OpenFOAM Meshing & Mesh Conversion 48 January 25, 2013 04:28
Empty patch problem with Netgen to Openfoam troy OpenFOAM 4 August 11, 2010 09:43
mapFields : internal edges Gearb0x OpenFOAM Running, Solving & CFD 3 April 19, 2010 10:02
farfield Vs symmetry boundary condition Rajat FLUENT 1 October 21, 2005 14:53
Multicomponent fluid Andrea CFX 2 October 11, 2004 06:12


All times are GMT -4. The time now is 02:33.