CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   Main CFD Forum (http://www.cfd-online.com/Forums/main/)
-   -   SIMPLE algorithm-Please help (http://www.cfd-online.com/Forums/main/68915-simple-algorithm-please-help.html)

Thiyaga October 6, 2009 06:56

SIMPLE algorithm-Please help
 
hi,
i tried to write a code for SIMPLE algorithm in Fortran but found it difficult. can anyone give a sample code on SIMPLE.my mail id is rajandhayalan@gmail.com
thank you
regards
Thiyaga.

zobekenobe October 6, 2009 09:56

are you writing it with colocated grids and staggered grids

Thiyaga October 7, 2009 03:05

Simple
 
hi,
thanks for the reply.iam using staggered grid.
reg
Thiyaga.

Ammar Mushtaq October 8, 2009 06:08

have u tried veersteeg's book, coz the algorithm in it is almost the code. I have implimented it in mathematica.

Thiyaga October 9, 2009 01:46

hi,
thx , i will try...

jyothishkumar October 17, 2009 11:01

Hi Ammar,

I tried with verteeg's book only. But the solution is blowing out (simple algorithm). Please check whether my following boundary conditions are correct:

firstof all i am using staggered grid (backward) and using Explicit scheme.

Assume it is a duct flow --> two walls on the upper and lower side (v velocity = 0), leftside --> inlet (u velocity) and rightside -->outlet (pressure outlet) but the u velocity grid would be the last on the right side

I have just created a dummy nodes outside the main domain (as mentioned in the book).
my domain size is 0.09m by 0.09m, height 0.08m. Grid size is 20 by 20
1. On the inlet i am giving u velocity = 0.1 m/s
2. On the outlet i am extrapolating this u velocity as given in the book
3. On the top and bottom wall my v velocity = 0
4. on the right side (just before the u node -- outlet) i am fixing the pressure as 0

I have doubt in the pressure correction (pprime) bc.

1. On all the sides i am setting the value of pprime = 0.

Withall this my solution is blowing out after few iterations (5 iterations)

Also for the simplicity i am keeping the value of meu and row as constant in all the equations (common row(density) taking out from the equations and canceling). I am not doing any averaging on this scalars. If you wish i can send my code also (its fully commented)
Your suggestion is highly appreciable.

thanks

jyo

artemiss1984 October 17, 2009 17:52

Dear friend. you should tell more details about your problem. your geometry.boundary conditions and...
maybe I can help you

Quote:

Originally Posted by Thiyaga (Post 231612)
hi,
i tried to write a code for SIMPLE algorithm in Fortran but found it difficult. can anyone give a sample code on SIMPLE.my mail id is rajandhayalan@gmail.com
thank you
regards
Thiyaga.


artemiss1984 October 17, 2009 18:15

what are the values of under-relaxation for velocity and pressure?
you should set the pprime value zero at the beginning of each iteration.
for B.cs usually the outlet boundary is difficult to set.

Quote:

Originally Posted by jyothishkumar (Post 233031)
Hi Ammar,

I tried with verteeg's book only. But the solution is blowing out (simple algorithm). Please check whether my following boundary conditions are correct:

firstof all i am using staggered grid (backward) and using Explicit scheme.

Assume it is a duct flow --> two walls on the upper and lower side (v velocity = 0), leftside --> inlet (u velocity) and rightside -->outlet (pressure outlet) but the u velocity grid would be the last on the right side

I have just created a dummy nodes outside the main domain (as mentioned in the book).
my domain size is 0.09m by 0.09m, height 0.08m. Grid size is 20 by 20
1. On the inlet i am giving u velocity = 0.1 m/s
2. On the outlet i am extrapolating this u velocity as given in the book
3. On the top and bottom wall my v velocity = 0
4. on the right side (just before the u node -- outlet) i am fixing the pressure as 0

I have doubt in the pressure correction (pprime) bc.

1. On all the sides i am setting the value of pprime = 0.

Withall this my solution is blowing out after few iterations (5 iterations)

Also for the simplicity i am keeping the value of meu and row as constant in all the equations (common row(density) taking out from the equations and canceling). I am not doing any averaging on this scalars. If you wish i can send my code also (its fully commented)
Your suggestion is highly appreciable.

thanks

jyo


jyothishkumar October 18, 2009 00:56

pprime initialisation
 
Hi Artmiss,

I did the initialization of pprime. My urf for u and v, pressure is 0.3.

for the outlet boundary since i am giving the pressure outlet (0 value -- gauge) my pprime would be zero at the outlet as there are no corrections

my u and v velocities are going very high values and finally diverges.


any suggestions

thanks

jyo

amirbabak1979 October 18, 2009 07:58

Dear jyo,

Put The relaxation factor for U and V around 0.3-0.4 and for Pressure around 0.1. You should notice that relaxation factor for pressure should be less than for U and V ones.

The other thing is before you wanna call your pressure boundary and solver
you should put pprime=0.0 in the main Do of your program.

hope it will work.


Quote:

Originally Posted by jyothishkumar (Post 233061)
Hi Artmiss,

I did the initialization of pprime. My urf for u and v, pressure is 0.3.

for the outlet boundary since i am giving the pressure outlet (0 value -- gauge) my pprime would be zero at the outlet as there are no corrections

my u and v velocities are going very high values and finally diverges.


any suggestions

thanks

jyo


artemiss1984 October 18, 2009 15:25

Dear friend. perform the suggestions of Mr. babak.The SIMPLE algorithm is very sensitive to urf's especially when Re increased.Don't use the values suggested in commercial soft wares. I doubt the reality of convergence with this urf's!
for final check tell me the method of calculation of u and v at solid boundaries.it is important


Quote:

Originally Posted by jyothishkumar (Post 233061)
Hi Artmiss,

I did the initialization of pprime. My urf for u and v, pressure is 0.3.

for the outlet boundary since i am giving the pressure outlet (0 value -- gauge) my pprime would be zero at the outlet as there are no corrections

my u and v velocities are going very high values and finally diverges.


any suggestions

thanks

jyo


jyothishkumar October 19, 2009 04:15

Thanks and i will do that

jyothishkumar October 21, 2009 08:40

Hi,

Again i have restructured my grid pattern in the following manner. I am now giving pressure inlet and pressure outlet boundary. Even on the wall (top and bottom) also i have my pressure and u velocity grid to coincide. This way i am sure about the pprime values at the boundary. Now my pprime value on the left and right side (inlet and exit) boundary will be zero. On the wall i am doing pwall = p(i,1) = 2*p(i,2) - p(i,3), similarly i am doing for pprime also. One more thing that i want to clarify is that i am fixing the value of row and meu everywhere (in the scalar grid points). Is that fine what i am doing. (still on the process of writing the code) Any suggestions ?

thanks

jyo


All times are GMT -4. The time now is 23:56.