CFD Online Logo CFD Online URL
Home > Forums > Software User Forums > ANSYS > FLUENT

variation of gravity with time

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

LinkBack Thread Tools Search this Thread Display Modes
Old   February 16, 2005, 03:45
Default variation of gravity with time
Posts: n/a

I am hereby writing about few questions in UDF. First of all, I am modeling a helium jet injected into ambient air. The flow is laminar, non reacting, axisymmetric and unsteady. I have already studied the effects of gravity on the jet flow i.e I run the case with g=9.81 for some time( say 1 sec) and then switch off the gravity i.e g=0.0 after 1 sec. I have been doing this using the operating conditions panel. Now instead of suddenly changing from g=9.81to 0.0, I would like to put in a linear variation for the change in g within a time of 0.2s. So the value of gravity changes with time accordingly. In order to achieve this, I understand that I have to write a UDF. So, I disenabled the gravity term from the operating conditions panel and tried to include it as a source term in the axial momentum equation. The sample code is as follows: %%%%%%%%%%%%%%%% #include "udf.h"

DEFINE_SOURCE(xmom_source, c, t, dS, eqn) { real temp, source;

source = -9.81*C_R(c,t)* ((C_YI(c,t,0)-C_YI(c,t,1)) dS[eqn] = 0.0;

return source; %%%%%%%%%%%%%%%%5

however, my results are not as expected. I also tried to use M_gravity option, but in vain. Kindly let me know how I can approach the problem of specifying gravity as function of time in a flow problem involving two species.

Thanks Rajani
  Reply With Quote


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
Time step size and max iterations per time step pUl| FLUENT 33 October 23, 2020 23:50
Simulation of sloshing by time varying gravity Manoj Kumar FLUENT 3 June 13, 2011 04:34
PostChannel maka OpenFOAM Post-Processing 5 July 22, 2009 10:15
AMG versus ICCG msrinath80 OpenFOAM Running, Solving & CFD 2 November 7, 2006 16:15
unsteady calcs in FLUENT Sanjay Padhiar Main CFD Forum 1 March 31, 1999 13:32

All times are GMT -4. The time now is 16:10.