|
[Sponsors] |
October 13, 2009, 11:49 |
Help: Steps to convert 2D to 3D code
|
#1 |
Senior Member
TWB
Join Date: Mar 2009
Posts: 409
Rep Power: 19 |
Hi guys n gals,
I want to convert my 2D fractional step NS solver into a 3D one. I tried but make a mess of it. I would like to start again but can someone with experience give me some guides or steps to follow? I wonder if I should change the boundary condition to make it into a 3D lid driven cavity test to do some initial verification. My code is also parallel but I also have a serial version. I wonder if I should edit the serial one 1st or just do the parallel code in one go. How to prevent the code changing into a debugging nightmare... ;-) Thanks alot! |
|
October 23, 2009, 10:33 |
|
#2 |
New Member
Nicholas F Camus
Join Date: Sep 2009
Location: London, England.
Posts: 21
Rep Power: 17 |
Quarkz,
Allways but always ammend the serial code first! As you rightly point out and no doubt know from experience debugging a parralell code can be a nightmare. I take it you are using some simple cartesien, or spherically symmetric 2D mesh, which you parralellise in some way. The best way is not to try to ammend the 2d version per say, but right all new 3D routines based on the older 2D versions. Ammending existing subroutines is not the way to go, and you can end up creating rubbish and getting lost. Be structured and methodical using the routines from the 2D version where possible... Hope this helps. All the best and good luck. Nick |
|
October 24, 2009, 00:32 |
|
#3 |
Senior Member
TWB
Join Date: Mar 2009
Posts: 409
Rep Power: 19 |
Hmm... thanks Killercam.
while I was waiting for a response, I decided to change my code to a semi 2d/3d one by adding a 3rd dimension such that v(x,y) = v(x,y,1). I thought this will enable me to do some check "halfway". if it can't work, i'll use your suggestion, which is of cos a much safer way. |
|
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Debugging Unsteady 2-D Panel Method Code: Wake Modeling | RajeshAero | Main CFD Forum | 5 | November 10, 2011 06:48 |
Small 3-D code | Zdravko Stojanovic | Main CFD Forum | 2 | July 19, 2010 11:11 |
cfx does not give time steps in cfxpost.why.urgent | prakash | CFX | 2 | November 24, 2005 00:06 |
Convert Euler code to full N-S | Soren | Main CFD Forum | 3 | June 25, 2002 05:47 |