# Fluent UDF in CFX

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

 October 21, 2008, 09:24 Fluent UDF in CFX #1 CFX User Guest   Posts: n/a Hello All I have a UDF written in C for use in Fluent Now I began to work on CFX and I am new to using CFX and writing subroutines in it. Is there a way where CFX can compile codes written for Fluent or do I have to write a Fortran code all over again for CFX Thank you Sandilya

 October 21, 2008, 17:18 Re: Fluent UDF in CFX #2 CycLone Guest   Posts: n/a No, you'll need to reproduce it for CFX. What does the UDF do? Most of what you would do with a UDF in Fluent you can do directly in CFX with CEL. -CycLone

 October 21, 2008, 18:23 Re: Fluent UDF in CFX #3 CFX User Guest   Posts: n/a The UDF adds two new scalar transport equations, one for solving for electric potential in the domain and the other for calculating the ion transport in the domain. These equations are as follows 1) Poisson Equation with space charge source term Del^2(phi) = -ion density/epsilon 2) Ion Transport equation Del.( A*rho + B*rho + C*rho ) = Diff Coeff * [Del^2 (rho)] rho is ion density A , B, C are functions of velocity, phi etc i.e. the two scalar transport equations are coupled and inturn they are both coupled to flow equations What is CEL in CFX and how to include above scalar transport equations in CFX Thank you

 October 22, 2008, 05:42 Re: Fluent UDF in CFX #4 underGroundMan Guest   Posts: n/a Its easy to do that in CFX using CEL. Have a read about CEL in documentation. Regards

 October 22, 2008, 10:15 Re: Fluent UDF in CFX #5 CycLone Guest   Posts: n/a Firstly, CFX does not require a user to code additional variable transport equations. In CFX-Pre, just create a new "Additional Variable" for each scalar. You can create these as Volumetric (per unit volume) or Specific (per unit mass) variables and specify their units accordingly. Once you have create the AV's, return to the Fluids Tab on the domain object to define how these are solved. Options include: Transport Equation (Advection + Diffusion) Diffusive Transport Equation (Diffusion including transient term) Poisson Equation (Diffusion without transient term) Algebraic Equation (Local algebraic equation, no transport) Have a look at Additional Variables in the documentation to see the form of the equations. The CFX Expression Language (CEL) is a unit aware algebraic expression language that is used to interpret all floating point values entered by the user (you are already using it when you enter boundary conditions, fluid properties etc.). You'll note a blue icon with the square root of alpha beside the dialog box when you enter a value. If you click on this, you can enter an algebraic expression instead. CEL expressions can vary in space (X,Y,Z), time (t), with temperature (T, or Temperature), or any other variable available from the solver or in your results (in Post). You can even refer to values at other boundary regions, points in the domain, volumetric averages and so-on. There are some limitations which are imposed to prevent unphysical conditions, for instance you cannot make density a function of space or time. See the help for more details. If CEL does not include a function you need, you can write one in FORTRAN and use it in your expressions. That said, CFX v11 already includes electromagnetics as a beta feature. You can enable beta features from Edit>Options. Add electromagnetic properties to your materials and return to your domain to enable electromagnetic effects. This will be a released feature in version 12, but you can contact technical support for more information in the interim. Basically, the vast majority of things you would do with UDF in FLUENT you can do in CFX directly. CFX users rarely need to write User Fortran routines. -CycLone

 October 22, 2008, 11:55 Re: Fluent UDF in CFX #6 CFX-User Guest   Posts: n/a Thank you very much for the detailed response CFX-User

 October 22, 2008, 17:21 Re: Fluent UDF in CFX *NM* #7 CFX-user Guest   Posts: n/a

 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 Jade M Main CFD Forum 4 August 28, 2012 02:54 eric_wang FLUENT 0 April 18, 2011 13:14 Rick FLUENT 0 May 7, 2008 10:16 Omer CFX 9 June 28, 2007 04:13 jobman Main CFD Forum 6 July 5, 2006 15:02

All times are GMT -4. The time now is 02:20.