# How to apply gravity to flow in CFX?

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

 June 29, 2003, 21:48 How to apply gravity to flow in CFX? #1 Miko Guest   Posts: n/a Hi all! I have to consider the effect of gravity, but I don't know how. Can anybody tell me how to put it into practice? Thank you! Best regards! Miko

 June 29, 2003, 22:21 Re: How to apply gravity to flow in CFX? #2 zahid Guest   Posts: n/a Hi Miko In order to incorporate gravity effects you will have to choose the flow to be buoyant. Then you can specify the gravity components.

 June 30, 2003, 00:05 Re: How to apply gravity to flow in CFX? #3 Miko Guest   Posts: n/a Hi Zahid! Yes, but when I want to enable buoyant, it seems that only if domain model is multiphases or the fluid temperature is not constant the option is available. But what I need is only gravity, and I can ignore the change of temperature. What should I do? Thank you! Best regards! Miko

 June 30, 2003, 09:38 Re: How to apply gravity to flow in CFX? #4 Bob Guest   Posts: n/a Miko, what exactly are you trying to model ? If you could give a little more detail then I'm sure people would be able to help. Bob

 June 30, 2003, 11:38 Re: How to apply gravity to flow in CFX? #5 Louwrens Guest   Posts: n/a Because buoyancy is temperature and pressure dependent, you can't enable buoyancy when your fluid is isothermal. unless your flow is high-speed, use the thermal energy heat tranfer model. This will enable you to activate buoyancy and specify the gravity vector. Since you don't care about the temperature of the fluid, just specify the inlet temperature and make sure your boundaries are adiabatic.

 June 30, 2003, 11:43 Re: How to apply gravity to flow in CFX? #6 centaur_ks Guest   Posts: n/a u mean u dont want to solve energy eqn and wants the flow to be isothermal but still u want to specify gravity component. if this is the situation, then when u specify let it take non-isothermal thing, but u can always modify parameter file. like in CFX-TASCflow, if you specify TMPTRE = F in parameter file then inspite of specifying temperature change in GUI during problem specification, solver wont solve temperature and it would assume constant temperature. J-

 June 30, 2003, 22:40 Re: How to apply gravity to flow in CFX? #7 Miko Guest   Posts: n/a Dear Zahid, Bob, Louwrens and Centaur_ks, Thank you all for giving me suggestion. In fact, what I am modeling is duct flow. The fluid is liquil metal, and besides Lorentz force concerned, I have to consider the effect of gravity. Liquid metal is single phase, so I needn't two or more phase. The physical image is as followed: liquid metal whose conductivity (denoted by c) is 2.878E+6 (ohm^-1 m^-1), flows in the insulator duct along Z axle, and the direction of external magnetic field (denoted by B) is X axle. We can know that in the Momentum equation Lorentz force Z component is -c*B^2*w and Y component -c*B^2*v where w and v mean the value of velocity along Z and Y axle, respectively, and B is equal to 1 (T). As for gravity, its form is density*g and direction is -Y axle. In CFX, in order to add body force, I use CEL to creat values and expressions. For instance, I created bodyforce_z=-c*B^2*w and bodyforce_y=-c*B^2*v-density*g with CEL, then I created a Fluid Subdomain named Bodyforce, enabled source of momentum in the subdomain, and specified it in the following way: Momentum: x-comp 0 kg m^-2 s^-2 Momentum: y-comp bodyforce_y Momentum: z-comp bodyforce_z After doing this, I run Solver, but I found it's difficult to converge. Can somebody give me some guideline and tell me how to add body force properly?

 July 4, 2003, 05:03 Nearly the same problem as my one #8 Volker Göke Guest   Posts: n/a Actually, I try to implement gravity to my diffusion-convection problem - without this force, the solver converges - with gravity - no chance at the moment. Let's wait and see - maybe I can give You an advice tomorrow.

 July 4, 2003, 05:10 Re: Nearly the same problem as my one #9 Miko Guest   Posts: n/a Hi Volker! How did you implement the gravity? I think if the gravity is the only body force should be considered, it's easy. The only thing you should do to do is to creat a Fluid Subdomain and enable the Momentum source. You can use CEL or input the value of gravity there directly, I think.

 July 4, 2003, 13:11 Re: How to apply gravity to flow in CFX? #10 Phil Guest   Posts: n/a Miko: If you have a single-phase constant-density flow, gravity is irrelevant and can be excluded from the simulation. The pressure then represents the 'motion pressure' which drives the flow. If for whatever reason you really want to include it, you can trick CFX into doing so by defining your density to be an expression, eg, 'Density = C*T/T', where C is the density you want. This will allow you to activate the buoyancy model. The interpretation of pressure then depends on your choice of buoyancy reference density; if you choose C, then you get exactly the same answer as if you excluded gravity. If you choose something other than C, then pressure will have a hydrostatic variation imposed on it. To get decent convergence, you will need to set pressure initial/boundary conditions which include the effect of this linear gradient.

 July 8, 2003, 06:33 Re: How to apply gravity to flow in CFX? #11 Miko Guest   Posts: n/a Hi Phil! Thank you! I think your suggestion is so useful. If gravity doesn't influence the velocity profile of the fluid when the fluid flows horizontally and gravity is vertical , I can ignore it. Right?

November 21, 2017, 13:03
#12
Member

VB
Join Date: Jul 2016
Posts: 35
Rep Power: 4
Quote:
 Originally Posted by Phil ;66806 Miko: If you have a single-phase constant-density flow, gravity is irrelevant and can be excluded from the simulation. The pressure then represents the 'motion pressure' which drives the flow. If for whatever reason you really want to include it, you can trick CFX into doing so by defining your density to be an expression, eg, 'Density = C*T/T', where C is the density you want. This will allow you to activate the buoyancy model. The interpretation of pressure then depends on your choice of buoyancy reference density; if you choose C, then you get exactly the same answer as if you excluded gravity. If you choose something other than C, then pressure will have a hydrostatic variation imposed on it. To get decent convergence, you will need to set pressure initial/boundary conditions which include the effect of this linear gradient.

Hi Phil, In the case of my fluid density varying over temperature, How do I avoid hydrostatic variation imposed when activating buoyancy model? I can give only one value for ref. buoyancy density but my fluid density is temperature dependent. I see (rho - rho_ref)g as the formula of the source term when we activate buoyancy model.

 November 22, 2017, 23:43 #13 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 15,228 Rep Power: 116 This thread is 14 years old. Phil is long since deceased. But I can answer your question. If you have variable density then you inherently will have issues dealing with the hydrostatic component as the reference density cannot remove it. This is a fundamental implication of using variable density in a buoyant simulation. You are going to have to ensure that your simulation can handle the fact that the hydrostatic component will remain to some extent. This may affect your choice of boundary conditions.

November 23, 2017, 04:05
#14
Member

VB
Join Date: Jul 2016
Posts: 35
Rep Power: 4
Quote:
 Originally Posted by ghorrocks This thread is 14 years old. Phil is long since deceased. But I can answer your question. If you have variable density then you inherently will have issues dealing with the hydrostatic component as the reference density cannot remove it. This is a fundamental implication of using variable density in a buoyant simulation. You are going to have to ensure that your simulation can handle the fact that the hydrostatic component will remain to some extent. This may affect your choice of boundary conditions.
Sorry, I did not know about Phil. "This may affect your choice of boundary conditions" - I think it is. My simulation works well without buoyancy with BC at outlet to relative static pressure to '0' but when I activate buoyancy the simulation has issues with the velocity streamlines at 'outlet'. Does static pressure at outlet not a good consideration when activating buoyancy? I use mass flow at Inlet BC for either case.

 November 24, 2017, 05:09 #15 Super Moderator   Glenn Horrocks Join Date: Mar 2009 Location: Sydney, Australia Posts: 15,228 Rep Power: 116 Oh yes, you posted on that other thread on the streamlines at the outlet. You had not correctly implemented the buoyancy reference condition if I remember correctly, so the hydrostatic component was not removed properly and was causing the strange streamlines. If you corrected your buoyancy model it should work.

 November 29, 2017, 16:17 #16 Member   VB Join Date: Jul 2016 Posts: 35 Rep Power: 4 Hi. Update: I could'nt fully resolve or remove the hydrostatic terms influence on the streamline. I could not adapt the reference buoyancy density to neutralize this term (rho - rho_ref)g. However I tried the simulation with deactivating it and it dosent have problem so I reduced my fluid region in a way it does not influence the result. Thank you for the suggestions. I appreciate it

 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 saii CFX 12 March 19, 2018 06:21 AirS OpenFOAM 0 January 12, 2010 08:08 Zhihua Xie CFX 0 September 3, 2007 10:49 Sadhna FLUENT 9 May 30, 2005 13:41 Dejun Jing CFX 3 July 16, 2002 05:45

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