# variation of gravity with time

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

 February 16, 2005, 03:45 variation of gravity with time #1 rajani Guest   Posts: n/a Sponsored Links hi 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

 Thread Tools Display Modes Linear Mode

 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 OffTrackbacks are On Pingbacks are On Refbacks are On Forum Rules

 Similar Threads Thread Thread Starter Forum Replies Last Post pUl| FLUENT 31 August 21, 2015 04:46 Manoj Kumar FLUENT 3 June 13, 2011 03:34 maka OpenFOAM Post-Processing 5 July 22, 2009 09:15 msrinath80 OpenFOAM Running, Solving & CFD 2 November 7, 2006 16:15 Sanjay Padhiar Main CFD Forum 1 March 31, 1999 12:32