CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > FLUENT

Simulation of sloshing by time varying gravity

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

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 19, 2005, 03:25
Default Simulation of sloshing by time varying gravity
  #1
Manoj Kumar
Guest
 
Posts: n/a
Hi I am trying to simulate sloshing in a tank. I tried solving the problem by adding a source term in the momentum equation using following code..

#include "udf.h" #define pie 3.141592654

DEFINE_SOURCE(cell_x_source, cell, thread, dS, eqn) { real source;

/* source term */

source=(-0.15)*pow((2*pie/1.70),2)*C_R(cell,thread)*sin((2*pie/1.70)*CURRENT_TIME);

dS[eqn] = 0.;

return source; }

I compared my results with published experimental and CFD results, and found that the change in freesurface with time is not matching.

Now I want to solve the problem by using a time varying gravity. Is follwing code sufficient ?

#include "udf.h" #DEFINE g 9.81 #DEFINE pie 3.14 #DEFINE timeperiod 1.70

DEFINE_ADJUST(my_adjust,d) { M_gravity[ND_ND]=g*sin((2*pie/timeperiod)*CURRENT_TIME); }

Thanks

Manoj
  Reply With Quote

Old   August 19, 2005, 03:29
Default Re: Simulation of sloshing by time varying gravity
  #2
Manoj Kumar
Guest
 
Posts: n/a
The codes are ..

#include "udf.h"

#define pie 3.141592654

DEFINE_SOURCE(cell_x_source, cell, thread, dS, eqn)

{

real source;

/* source term */

source=(-0.15)*pow((2*pie/1.70),2)*C_R(cell,thread)*sin((2*pie/1.70)*CURRENT_TIME);

dS[eqn] = 0.;

return source;

}

and

#include "udf.h"

#DEFINE g 9.81

#DEFINE pie 3.14

#DEFINE timeperiod 1.70

DEFINE_ADJUST(my_adjust,d)

{

M_gravity[ND_ND]=g*sin((2*pie/timeperiod)*CURRENT_TIME);

}

  Reply With Quote

Old   November 30, 2009, 21:01
Default
  #3
New Member
 
Saeed Abbasi
Join Date: Sep 2009
Location: Iran
Posts: 20
Rep Power: 16
sabbasi_mr is on a distinguished road
Dear friend, I utilized your posts very much.
I appreciate your activities.
Thanks a lot.
Saeed
sabbasi_mr is offline   Reply With Quote

Old   June 13, 2011, 04:34
Default gravity variation in Fluent?
  #4
New Member
 
Joyi Wang
Join Date: Apr 2010
Posts: 8
Rep Power: 15
zcjwyl is on a distinguished road
Hi, for the second method, I've tried to implement your code in Fluent 6.3 but it can not recognize the item "M-gravity".

Does anyone know the definition of gravity in Fluent code,? I can't find it in the udf manual.
zcjwyl is offline   Reply With Quote

Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Extrusion with OpenFoam problem No. Iterations 0 Lord Kelvin OpenFOAM Running, Solving & CFD 8 March 28, 2016 12:08
Superlinear speedup in OpenFOAM 13 msrinath80 OpenFOAM Running, Solving & CFD 18 March 3, 2015 06:36
Orifice Plate with a fully developed flow - Problems with convergence jonmec OpenFOAM Running, Solving & CFD 3 July 28, 2011 06:24
Could anybody help me see this error and give help liugx212 OpenFOAM Running, Solving & CFD 3 January 4, 2006 19:07
influence of time step in insationary simulation Sascha Behrens FLUENT 0 December 1, 2005 10:08


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