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

using #calc in parallel with openFOAM 2.2.2

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

Like Tree1Likes
  • 1 Post By wyldckat

Reply
 
LinkBack Thread Tools Display Modes
Old   February 26, 2014, 18:56
Default using #calc in parallel with openFOAM 2.2.2
  #1
Member
 
Pascal
Join Date: Jun 2009
Location: Montreal
Posts: 65
Rep Power: 8
Pascal_doran is on a distinguished road
Hi all,

Does anyone had problem using using #calc in parallel with openFOAM 2.2.2? I use #calc to evaluate algebraic expressions in a file which is read by the controlDict and blockMeshDict. Everything seems to work just fine when I run with 1 processor but in parallel the simulation stop while evaluating some #calc expressions like that :

Code:
ptX0   -4.00 ;
ptX1    4.00 ;
ptY0    0.00 ;
ptY1    4.00 ;
ptZ0    0.00 ;
ptZ1    4.00 ;
Nx      144  ;
Ny      72  ;
Nz      72  ;
Lx      #calc"$ptX1 - $ptX0";
Ly      #calc"$ptY1 - $ptY0";
Lz      #calc"$ptZ1 - $ptZ0";
dx      #calc"$Lx/$Nx";
dy      #calc"$Ly/$Ny";
dz      #calc"$Lz/$Nz";
But if I write this :
Code:
Lx      8;
Ly      4;
Lz      4;
dx      0.0555555555555555;
dy      0.0555555555555555;
dz      0.0555555555555555;
Everything is just fine on a serial or parallel run. Note that this :
Code:
Lx      #calc"8";
Ly      #calc"4";
Lz      #calc"4";
dx      0.0555555555555555;
dy      0.0555555555555555;
dz      0.0555555555555555;
still doesn't work on a parallel run. I have no error message at all time.

Anyone has notice such a behavior using #calc with OF 2.2.2?

Thank you,
Pascal
Pascal_doran is offline   Reply With Quote

Old   March 19, 2014, 10:35
Default
  #2
New Member
 
Jörn Nathan
Join Date: Aug 2011
Location: Montréal
Posts: 11
Rep Power: 5
jona is on a distinguished road
bump,

I am experiencing the same issue. The #calc directives work flawless when run on a single processor, but as soon, as they are called in a parallel run, the solver stucks without any activity or any messages.

Is this a bug or misusage?

Have a nice day,

Jona
jona is offline   Reply With Quote

Old   March 23, 2014, 13:14
Default
  #3
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings to all!

Can any of you provide a simple test case, based on one of OpenFOAM's tutorials? It would make it faster and easier for someone else to diagnose this issue.

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   March 25, 2014, 11:46
Default
  #4
New Member
 
Jörn Nathan
Join Date: Aug 2011
Location: Montréal
Posts: 11
Rep Power: 5
jona is on a distinguished road
Of course. The example is the cavity from the tutorials but decomposed for two processors. So in order to run the case you need to

decomposePar
mpirun -np 2 icoFoam -parallel

When executing icoFoam, it stucks after the lines

Using #calcEntry at line 30 in file ...
Using #codeStream with ...

Thanks a lot for your help,

jona

PS: The #calc entry is in the system/controlDict
Attached Files
File Type: gz cavityDecomposed.tar.gz (17.9 KB, 2 views)
jona is offline   Reply With Quote

Old   April 5, 2014, 19:58
Default
  #5
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,258
Blog Entries: 34
Rep Power: 84
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi jona,

I've finally managed to give a look into this. I've reproduced the issue and it seems to be a bug that has already been fixed in OpenFOAM 2.3.x, which was present in OpenFOAM 2.3.0. Mmm... I guess this was an issue back in OpenFOAM 2.2.2 as well...

Now, if I could only figure out which commit fixed this issue... Found it, it's fixed in commit 8199b97e4a7ab5daa684abe27bdac2610cfb52a3: https://github.com/OpenFOAM/OpenFOAM...dac2610cfb52a3

Now, to apply this fix, it will depend on how you installed OpenFOAM.

Best regards,
Bruno
jona likes this.
wyldckat is offline   Reply With Quote

Old   April 8, 2014, 12:44
Default
  #6
New Member
 
Jörn Nathan
Join Date: Aug 2011
Location: Montréal
Posts: 11
Rep Power: 5
jona is on a distinguished road
Hello Bruno,

great, thanks a lot for looking into it and resolving the issue!

Have a nice day,

Jona
jona is offline   Reply With Quote

Reply

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
Problem with RenumberMesh in parallel in OpenFOAM 2.1.1 srini_esi OpenFOAM Mesh Utilities 1 November 8, 2013 03:48
OpenFOAM 2.2.2 source pack installation on Xubuntu 13.10 zordiack OpenFOAM Installation 1 October 26, 2013 13:08
OpenFOAM doesn't run in parallel callumso OpenFOAM Running, Solving & CFD 0 July 11, 2013 12:17
Parallel cluster solving with OpenFoam? P2P Cluster? hornig OpenFOAM Programming & Development 8 December 5, 2010 17:06
Large test case for running OpenFoam in parallel fhy OpenFOAM Running, Solving & CFD 22 September 22, 2009 11:13


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