CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   CFX (https://www.cfd-online.com/Forums/cfx/)
-   -   USER_FORTRAN solve iteratively a linear equations system (https://www.cfd-online.com/Forums/cfx/80852-user_fortran-solve-iteratively-linear-equations-system.html)

fipellac October 8, 2010 10:42

USER_FORTRAN solve iteratively a linear equations system
 
Hi,

I implemented already an Additional Variable under the form of a Transport equation. I didnīt get good results and I would like to have full control on the implemented transport equation.
The problem is essentially the presence of the diffusive term in the equation provided by Ansys CFX (I donīt need it) and the presence of the volume fraction in the formulation of each term.

For this reason I decided to implement a new variable linked to User_CEL. Inside the routine then, linearize the system and solve it iteratively.

I would like to receive some information regarding the following aspect:

1) Once obtained a linear equations system I want to solve in an iterative way.
Did someone tried this before in a USER_CEL? Do you have an example of it?

Thank you in advance,

Filippo

ghorrocks October 9, 2010 05:48

If you don't want the diffusive term then can't you just set it to zero? And what are you trying to do anyway?

Before you dive into fortran are you sure you cannot do what you want using additional variables?

fipellac October 11, 2010 04:59

Dear ghorrocks,

"If you don't want the diffusive term then can't you just set it to zero?"

Setting the diffusivity =0 doesnīt help so much. I also set the value to the Schmidt number to a very high value, so that the mu/sc term will be very low.

Even performing this operations the div of such a group will never be zero, but can also have very high value and the software can in some cases become very unstable.

"And what are you trying to do anyway?"

I worked during the last months to implement a one group interfacial area transport equation for the calculation of the interfacial area density. In a gas dispersed liquid continuous simulation. (bubble column D=200mm H= ca. 8 m, experimental data from Research center Dresden Germany).
The MUSIG approach even producing goos results needs really a lot of resources.
Other researcher implemented the same models in their own codes and the results seems to be very good in isothermal and non isothermal condition.

"Before you dive into fortran are you sure you cannot do what you want using additional variables?"

I tried it but this is not producing the expected results. If you want I can send you a document where I explain the implementation of the Additional variable. I documented it already.

Bye,

Filippo

ghorrocks October 11, 2010 05:22

It has been a while since I used additional variables but I seem to remember that one option is "transport equation" where the convective terms are included but the diffusive ones are not. I cannot see how any user fortran is going to have less diffusion than that.

I am also no expert on MUSIG but again it seems like the models you are trying to develop are already in CFX. I guess I have missed something, but I would suggest looking at the full range of options already in CFX before developing new approaches. Fro instance have you looked at the DPMOM approaches? They may be more appropriate for you.

Is this paper something like what you are trying to do? I can only see the abstract but it describes a bit of what they are doing.
http://scitation.aip.org/getabs/serv...ifs=yes&ref=no

fipellac October 11, 2010 05:45

One of the goal of my PhD is the implementation of the Interfacial area transport equation in Ansys CFX. (If interested, You can read something more in the book Thermo-fluid Dynamics of Two-Phase Flow, Hibiki - iShii, Chapter 11).

In the past year I was learning how to use the monodispersed approach and the Musig approach. I already tested them, but they are "STATE OF THE ART". I need to implement something new, in this case the IATE of developed by Hibiki Ishii, with several source terms and cmpare them.

I already tried the additional variable approach and was not bringing the expected results. In user fortran I could implent the equation in the form I need/want.

Thank you for the link, but sorry i canīt open it. I will ask to buy it it seems interesting.

michael_owen October 12, 2010 22:45

You keep claiming that the normal AV transport equation did not give satisfactory results. In what way?

fipellac May 20, 2011 05:42

ANSYS CFX calculates the gradients using the central difference scheme. this leads to numerical instabilities and the results of simulation are full of oscillations.

i developed my own set of subroutines for mapping of the points, calculation of gradient and divergencies. and this is lowering a lot the numerical oscillations. the problem now is that the simulation time increased really a lot.

the other thing is that the procedure is working in series and not yet in parallel and iīm wongin just with 2D approximation (vertical pipe 1degree slice).

stumpy May 20, 2011 10:36

Did you ask support if there's an expert parameter to change the scheme used to calculate the gradients?

fipellac May 20, 2011 10:37

yes, they told me it is not possible.

cscfx June 12, 2019 07:03

Quote:

Originally Posted by fipellac (Post 308537)
ANSYS CFX calculates the gradients using the central difference scheme. this leads to numerical instabilities and the results of simulation are full of oscillations.

i developed my own set of subroutines for mapping of the points, calculation of gradient and divergencies. and this is lowering a lot the numerical oscillations. the problem now is that the simulation time increased really a lot.

the other thing is that the procedure is working in series and not yet in parallel and iīm wongin just with 2D approximation (vertical pipe 1degree slice).

hello, do you finish your fortran program? i recently want to do the same work,but i did not know how to write the soure terms? can you send me a example of your program,thanks a lot!


All times are GMT -4. The time now is 12:38.