CFD Online Discussion Forums

CFD Online Discussion Forums (http://www.cfd-online.com/Forums/)
-   FLUENT (http://www.cfd-online.com/Forums/fluent/)
-   -   Shock tube simulation in Fluent (http://www.cfd-online.com/Forums/fluent/73300-shock-tube-simulation-fluent.html)

Vinoo_P March 4, 2010 01:55

Shock tube simulation in Fluent
 
Hi everyone i want to run a shock tube simulation case to verify if the data can match experimental data from our lab. What boundary condition do i assign to the diaphragm of the shock tube in Fluent? Ive tried interior, symmetry and internal but they dont work. Please help. Thx.

agd March 4, 2010 11:27

Don't use a BC - set the initial distributions of density, temperature, and pressure as if the diaphragm is there (i.e. step in pressure and density with constant temp across the diaphragm is the normal setup). Then let the simulation run. You are simulating the situation where the diaphragm is instantly removed from the system, so no BC for the diaphragm.

Vinoo_P March 5, 2010 04:32

Ok I will try that right away

alikami March 5, 2010 06:12

shock tube
 
can u mail me ur case file....a1k1s1@yahoo.com
thanks
regards

vchhabra18 March 8, 2010 15:23

Same issue
 
Hi everyone here,

I just this post after searching for the same question for such a long. Even I am doing an MSc project on a shock tube and not too sure how to go about the diaphragm.

'agd' Your suggestion sounds very promising but to be honest, I am not too clever in fluent so would you mind just expalining the same thing a little more. It'll be of great help if you can please.

And Vinoo if you understood what agd was explaining and you tried that method too, than again it'll be very helpful if you could send me your case file to have a better idea.

Many thanks in advance

I will be waiting for the replies
Best Regards

agd March 8, 2010 21:35

Let your tube be length L. From 0 to L/2 initialize your field as (p1,T1,rho1,u1=0). From L/2 to L, initialize the field as (p2,T2,rho2,u2=0). Run simulation for some time length, post-process results.

vchhabra18 March 8, 2010 22:00

Thanks
 
Thanks a lot AGD for your prompt reply. I guess I know what you mean now. I will try this out tmrw or day after and will get back if any more issues will come up.

I hope you would not mind helping me out than as well.

Many thanks once again
Best Regards
Vivek Chhabra

praveen2008 November 27, 2011 07:54

shock tube modelling using ansys design modeller, ansys meshing and ansys fluent
 
Hi,

can anyone tell me if i could model a shock tube simulation using ansys design modeller, ansys meshing and ansys fluent??? and if someone could send me a case file to praveen2008@gmail.com just to get a glimpse of the problem as I am new to ansys. It would be a great help if someone could help with how to define the diaphram and how to give the boundary conditions.

Please Help

Thankyou

esikhatar February 18, 2012 09:51

shock tube
 
Dear agd,
How we can do this initialize in the Fluent?
I cann't do that! :-(
Can you please send me a case file?
Thanks
zztnshn_2@yahoo.com

Quote:

Originally Posted by agd (Post 249064)
Let your tube be length L. From 0 to L/2 initialize your field as (p1,T1,rho1,u1=0). From L/2 to L, initialize the field as (p2,T2,rho2,u2=0). Run simulation for some time length, post-process results.


agd February 19, 2012 19:33

I'm sorry, but I do not use Fluent. Perhaps someone else can supply the case file you are looking for.

moein_joon27 June 15, 2014 16:56

initialization of separate cells with different values in fluent
 
Hi Everyone

Here's my solution to your problem in initializing fluent with separate values and simulating a shock tube. I have tested it, I have got the results and I am sure it works properly.
you need a very simple grid which should be like a 2D rectangle. you don't need to separate it or create 2 zones. A simple 1-zone grid will work just fine. we will try to initialize that zone with different values.

suppose the problem says the parameters ( as an example ) are as the case in Hirsch's book:

length of tube=10 m.
width of tube is not important ( because the problem is actually one dimensional when considered inviscid ) i.e. give the width as you wish!


Left:
Pressure=100,000
density=1.
velocity = 0

Right:
Pressure=10,000
density=0.125
velocity = 0

you should introduce the UDF mentioned below to fluent. Save it to a text file:


#include "udf.h"

DEFINE_INIT(moein_shock_tube_init,d)
{
cell_t c;
Thread *t;
real xc[ND_ND];

/* loop over all cell threads in the domain */
thread_loop_c(t,d)
{

/* loop over all cells */
begin_c_loop_all(c,t)
{

C_CENTROID(xc,c,t);

if (xc[0] < 5. )

{

C_U(c,t) = 0.;
C_V(c,t) = 0.;
C_P(c,t) = 100000.;
C_T(c,t) = 348.362;
C_R(c,t) = 1.;
}

else

{

C_U(c,t) = 0.;
C_V(c,t) = 0.;
C_P(c,t) = 10000.;
C_T(c,t) = 278.689;
C_R(c,t) = 0.125;



}

}
end_c_loop_all(c,t)
}
}


then go to Define> User Defined > Functions > interpreted and browse to the text file ( you must save it as *.c first) then again go to Define> User Defined > Function Hooks > initialization > Edit > select the name "moein_shock_tube_init" and then click on Add and then Ok.

then go to Solve > Initialiaze > press Init.
Dont' worry. the numbers like 300 kelvin in initialization dialog box will not influence your simulation and the udf will override them.
now you can plot contours or XY Diagrams and see the result.

Some more tips:
Is giving the temperature values like 348.362 necessary?
I don't think so, because you define your material as an ideal gas, since there is an ideal gas relation P = density * R * T. but I haven't tried eliminating that. :) you can try!
Also make sure to go to Operating Conditions and set the pressure to 0, since you must work with Absolute Pressures.
if you don't understand the commands in the UDF, search them in internet.

Define_init was the the key to this solution, but I'm happy I turned that key to open a door to salvation. :) I am now tired of typing, but I have a good sensation...


All times are GMT -4. The time now is 09:38.