|
[Sponsors] |
May 29, 2011, 08:39 |
Parallel UDF
|
#1 |
New Member
hisham
Join Date: May 2011
Posts: 6
Rep Power: 15 |
Hi,
Can someone help me to modify my UDF below to parallel UDF. I am simulating oscillating cylinder and need to compile my UDF in Linux parallel. #include "udf.h" #define AA 0.03 #define TT 4.1667 #define OM (2.0*M_PI/TT) DEFINE_CG_MOTION(updown,dt,vel,omega,time,dtime) { vel[1] = AA*OM*cos(OM*time); } thanks. sham. |
|
May 31, 2011, 05:04 |
|
#2 |
Senior Member
Dragos
Join Date: Mar 2009
Posts: 648
Rep Power: 20 |
The usual advice in the manual is to enclose the body of your udf in a directive:
Code:
#include "udf.h" #define AA 0.03 #define TT 4.1667 #define OM (2.0*M_PI/TT) DEFINE_CG_MOTION(updown,dt,vel,omega,time,dtime) { #if !RP_HOST vel[1] = AA*OM*cos(OM*time); #endif } |
|
May 31, 2011, 08:11 |
|
#3 |
New Member
hisham
Join Date: May 2011
Posts: 6
Rep Power: 15 |
Thanks. I shall give it a try. My problem is I set up my case in Windows (serial) and run a few iterations there until it reaches a near steady solution. Then I transfer my case to Linux (parallel) and continue running there. However, when I continue my iterations there, the results (Cd and Cl) vary erratically unlike my run in Windows (serial). It runs ok and no error message given. Just the results are unexpected. Hence, I suspect the problem is in the UDF that need to be parallelize.
Would appreciate if you have more input to what my prob could be. |
|
May 31, 2011, 08:23 |
|
#4 |
Senior Member
Dragos
Join Date: Mar 2009
Posts: 648
Rep Power: 20 |
Then the problem is not from DEFINE_CG_MOTION. How do you compute Cd and Cl, are you using fluent reports or you wrote your own udf?
|
|
May 31, 2011, 08:39 |
|
#5 |
New Member
hisham
Join Date: May 2011
Posts: 6
Rep Power: 15 |
Cl and Cd from Fluent Solve > Monitor panel.
I am simulating oscillating cylinder with dynamic mesh. I have tried the same with fixed cylinder (no UDF used) and it was fine when I transferred from Windows serial to Linux parallel and continue running it. |
|
May 31, 2011, 08:55 |
|
#6 |
Senior Member
Dragos
Join Date: Mar 2009
Posts: 648
Rep Power: 20 |
Some differences should appear due to different mesh after remeshing in parallel compared to serial.
|
|
Tags |
udf parallel |
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
UDF parallel error: chip-exec: function not found????? | shankara.2 | Fluent UDF and Scheme Programming | 1 | January 16, 2012 23:14 |
udf compile in parallel system | tahereh | FLUENT | 1 | December 9, 2008 10:48 |
Help: how to realize UDF on parallel cluster? | Haoyin | FLUENT | 1 | August 6, 2007 14:53 |
Parallel Fluent +UDF | Jack Martinez | FLUENT | 0 | June 28, 2007 12:19 |
UDF in parallel version. | yobee | FLUENT | 0 | August 17, 2004 05:12 |