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

Running cellSet in parallel

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

Reply
 
LinkBack Thread Tools Display Modes
Old   March 27, 2012, 14:16
Default Running cellSet in parallel
  #1
Member
 
Björn Windén
Join Date: Feb 2012
Location: University of Southampton UK
Posts: 37
Rep Power: 5
winden is on a distinguished road
Hi.

I am trying to run cellSet (OF v.1.7.1) in parallel.

This works fine until I try to use surface-based selection. It seems (unlike e.g. snappyHexMesh) cellSet does not recognize the outsidePoints-entry if it/they are not in the current processor mesh. Is this fixed in setSet in later versions or is there another workaround? I played with the thought of using pointSet before decomposing to create a (very) long list of outside points to give to cellSet but I am sure there is a better way.

-------------------------------------
using:
-------------------------------------
surfaceToCell
{
file "constant/triSurface/stlname.stl";

outsidePoints ((0 0.001 -1.342));
includeCut true;
includeInside false;
includeOutside false;
nearDistance 0.123079;


curvature -100;


}
-------------------------------------
gives error:
-------------------------------------
[0] --> FOAM FATAL ERROR:
[0] outsidePoint (0 0.001 -1.342) is not inside any cell

-------------------------------------
The point works fine with one processor so that's not the issue.

Any ideas?

Kind regards
//Björn
winden is offline   Reply With Quote

Old   March 28, 2012, 11:56
Default
  #2
Member
 
Björn Windén
Join Date: Feb 2012
Location: University of Southampton UK
Posts: 37
Rep Power: 5
winden is on a distinguished road
Ok sorry for spamming my own thread but, to answer parts of my own question: I modified my run-script to work with version 2.0.0 so I could try the new implementation and it works. I still want to be able to run in 1.7 as well though so the question whether there is a workaround still stands.

Another question regarding cellSet/setSet in parallel: How to make it cooperate with refineMesh as you can do in serial?

I.e, how can I either:

Make cellSet/setSet write one single set in constant/polyMesh/sets so refineMesh can read it

or

Make refineMesh read sets from processor*/constant/polyMesh/sets where cellSet/setSet creates them in parallel.

I do not want to have to recompose/decompose between and I want identical final meshes as you would get in serial.

//Björn
winden is offline   Reply With Quote

Old   March 28, 2012, 15:24
Default
  #3
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings Björn,

The usual way of manipulating OpenFOAM meshes that have been decomposed is to run the utilities in parallel as well, for example:
Code:
foamJob -s -p cellSet
Or:
Code:
mpirun -np _number_processes_ cellSet -parallel
Same goes for refineMesh.

The only utilities that aren't executed in parallel are usually the ones that do decomposition and reconstruction.

Nonetheless, if you've already ran cellSet in parallel and it failed to handle those surface selections, then it might be a bug, which may or may not be already fixed in the latest versions of OpenFOAM

If you have a simple test case for us to test, share it here and anyone can easily run it with the version they got at hand. And if you please, make it an easy way to run it, the same way that OpenFOAM's tutorials do it, namely with Allrun scripts.

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   March 29, 2012, 05:19
Default
  #4
Member
 
Björn Windén
Join Date: Feb 2012
Location: University of Southampton UK
Posts: 37
Rep Power: 5
winden is on a distinguished road
Hi Bruno, thanks for your reply.

After testing it seems like this is a bug in version 1.7 (don't know about earlier ones) but which is fixed in later versions. I will see if I can make a small testcase to show it.

The problem I have now with setSet and refineMesh is not to get them to run individually in parallel but that setSet creates a number of decomposed sets in /processor*/constant/polyMesh/sets whereas refineMesh in parallel is still looking for a single set in /constant/polyMesh/sets.

//Björn
winden is offline   Reply With Quote

Old   March 29, 2012, 07:56
Default
  #5
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Björn,

Is that problem occurring with the latest OpenFOAM 2.1.0 or even 2.1.x? If so, I think you should report it as a bug: http://www.openfoam.org/bugs/

Unfortunately, I don't know if there is any way to reconstruct sets

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   March 29, 2012, 10:08
Default
  #6
Member
 
Björn Windén
Join Date: Feb 2012
Location: University of Southampton UK
Posts: 37
Rep Power: 5
winden is on a distinguished road
Hi again.

Here is a testcase that crashes on running in parallel in 1.7 but works fine in serial in all versions and in parallel on 2.0.

Allrun runs cellSet from a dictionary and Allrun2 runs with setSet as required by later versions.

I also tried with other geometries and number of processors. With some I don't get the point error but zero cells get selected in parallel and a non-zero amount gets selected with the exact same setup in serial.

As for the refineMesh-issue, turns out it was not an issue, just a stupid mistake by me .
Attached Files
File Type: zip test_cellSet.zip (43.5 KB, 22 views)
winden is offline   Reply With Quote

Old   April 1, 2012, 05:07
Default
  #7
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,503
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Björn,

I've confirmed that your test case also works with OpenFOAM 2.1.x and gives the same problem on 1.7.x as it does with your 1.7.1 version. I also moved the sphere a bit to the right so it would be between processors and it still worked on 2.1.x.

The simplest solution would be to at least use setSet from 2.0.* or 2.1.* and the rest use from 1.7.1.

So the big question(s) is(are): do you have to use OpenFOAM 1.7.1? Or can you upgrade? Or would a limited upgrade be enough (limited in the sense that only setSet from 2.* is used in your 1.7.1)?

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   April 2, 2012, 06:37
Default
  #8
Member
 
Björn Windén
Join Date: Feb 2012
Location: University of Southampton UK
Posts: 37
Rep Power: 5
winden is on a distinguished road
Hi Bruno.

Thanks for your help in confirming this.

I don't have any problems switching between versions myself. The problem is that I am writing a script that others in my department might want to use and it would be nice if I could make it version independent but perhaps that is not possible. It is already independent when run in serial and I discovered that there is a more serious issue that refineMesh doesn't seem to work very well in parallel either.

http://www.openfoam.org/mantisbt/view.php?id=465

Thank you for your help. If anyone comes up with a sneaky trick to make cellSet run in parallel with surface-based selection in v1.7 and below please tell me, otherwise I will have to settle for serial for the moment.

//Björn
winden is offline   Reply With Quote

Reply

Tags
1.7.1, cellset, parallel

Thread Tools
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 On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
parallel running issue xiaokang Fluent UDF and Scheme Programming 0 January 18, 2012 18:42
Running PimpleDyMFoam in parallel paul b OpenFOAM Running, Solving & CFD 8 April 20, 2011 05:21
running in parallel, at time t>0 bunni OpenFOAM 1 October 21, 2010 09:34
Issue with running in parallel on multiple nodes daveatstyacht OpenFOAM 7 August 31, 2010 17:16
Surface Vector Field Problem at Parallel cwang5 OpenFOAM Bugs 6 July 12, 2010 08:31


All times are GMT -4. The time now is 22:10.