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

 January 16, 2020, 10:29 The problem about add body force（physical external forcing）using CFX #1 New Member   jinzhihui Join Date: Oct 2017 Posts: 12 Rep Power: 8 Hi I'm trying to add a body force to momentum source through CFX. I have a constant body force f(fx fy 0) which Located in a specific area（such as x1

 January 16, 2020, 10:38 #2 Senior Member   Join Date: Jun 2009 Posts: 1,803 Rep Power: 32 You have shown the UserFortran code, but not the context on how it is used. Please show how it is accessed in the setup, i.e. MOMENTUM SOURCE: Option = Cartesian Components X Component = Y Component = Z Component = END

January 17, 2020, 01:31
#3
New Member

jinzhihui
Join Date: Oct 2017
Posts: 12
Rep Power: 8
Quote:
 Originally Posted by Opaque You have shown the UserFortran code, but not the context on how it is used. Please show how it is accessed in the setup, i.e. MOMENTUM SOURCE: Option = Cartesian Components X Component = Y Component = Z Component = END
this UserFortran code is used to define one User Routine whose Option is User CEL Function, in CFX Pre.The Function which has three Arguments and onlu one return variavle is defined as below,for this routine structure of User CEL Functions only have one renturn variable :

So do you have some suggestions....

 January 17, 2020, 03:35 #4 Senior Member   Gert-Jan Join Date: Oct 2012 Location: Europe Posts: 1,827 Rep Power: 27 Are you convinced that function 2 is working properly? Did you for example try running only function 2? Or using functions 2 twice, for x and y component?

January 17, 2020, 04:16
#5
New Member

jinzhihui
Join Date: Oct 2017
Posts: 12
Rep Power: 8
Quote:
 Originally Posted by Gert-Jan Are you convinced that function 2 is working properly? Did you for example try running only function 2? Or using functions 2 twice, for x and y component?
Yes,I have already run only function 2 for X ,for X and Y component both,It's OK.

I guess the reason for error is the two User Function for X and Y component come from two different User Routines, and CFX need to call two different User CEL Function Routines(Both of these two Routines can run independently,and the Structure of Routines same as the first Fig) .This means CFX call the Function using the same Routine(only one) for x and y component, It can run.

 January 17, 2020, 05:14 #6 Senior Member   Gert-Jan Join Date: Oct 2012 Location: Europe Posts: 1,827 Rep Power: 27 I would like know what ANSYS says........

January 19, 2020, 22:45
#7
New Member

jinzhihui
Join Date: Oct 2017
Posts: 12
Rep Power: 8
Quote:
 Originally Posted by Gert-Jan I would like know what ANSYS says........
ANSYS prompt this error message

I don't get what you mean....

 January 20, 2020, 03:16 #8 Senior Member   Gert-Jan Join Date: Oct 2012 Location: Europe Posts: 1,827 Rep Power: 27 I mean the ANSYS support help desk

 Tags body force, cel function, cfx, momentum sources