CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

CCL, FORTRAN and water hammer

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   May 12, 2010, 13:31
Default CCL, FORTRAN and water hammer
  #1
New Member
 
Join Date: May 2010
Posts: 9
Rep Power: 16
pingub is on a distinguished road
Hello!
I need to perform some transient simulations regarding the interaction between a turbomachine and a pipe in water-hammer conditions.
In such a simulation the boundary conditions of the turbomachine depend on time, but i cannot use CEL expressions to define them, because they are solutions of the hydraulic problem inside the pipe.

For some reasons i wouldn't insert the pipe in the cfx computation as a mesh, but i'd like to solve the hydraulic problem inside the pipe with the 2 differential equations of motion of the water in transient condition with a characteristic lines method (it's a numerical method used to solve a pair of differential equations).

In this way the boundary conditions of the pump (Head downstream and Discharge upstream) would be the solutions of the interaction between the water hammer problem and the machine behaviour.

Now my question is:
- Can I use CCL to implement the characteristic lines method? How can I do?
- I'm pretty sure that the answer to my first question will be negative, so:
- Can I use FORTRAN to implement the characteristic lines method? How can I do?

I've never used fortran with CFX, and i did'nt any advice on CFX12 documentation.

I hope someone could help me.
Thanks,
pingub
pingub is offline   Reply With Quote

Old   May 12, 2010, 19:51
Default
  #2
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,871
Rep Power: 144
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
You can do this using a fortran routine connected to the boundary condition.

But I recommend you instead model the pipe with a coarse mesh and eliminate the need for the interface. I did lots of work on IC engine manifolds where it was tempting to do as you suggest, but by far the easiest (and most accurate) way forwards was just to model the manifolds as well and then there is no requirement to develop the boundary condition. It is much easier to do a slightly larger CFD simulation than develop a custom solver in a BC.
ghorrocks is offline   Reply With Quote

Old   May 13, 2010, 17:21
Default CCL, FORTRAN and water hammer
  #3
New Member
 
Join Date: May 2010
Posts: 9
Rep Power: 16
pingub is on a distinguished road
Hey, thank for your answer!!

Quote:
It is much easier to do a slightly larger CFD simulation than develop a custom solver in a BC.
I know, but the problem is that the lenght of my pipe is 200 meters. How coarse will be the mesh to let the simulation work on my workstation?

Quote:
You can do this using a fortran routine connected to the boundary condition.
I miss only learning FORTRAN and the connection between FORTRAN and CFX...
Unlikely i can only use MATLAB. But i think it could be the right time to learn FORTRAN!!!

Anyway, I will see...
Thank you again!!!
pingub is offline   Reply With Quote

Old   May 13, 2010, 20:15
Default
  #4
Super Moderator
 
Glenn Horrocks
Join Date: Mar 2009
Location: Sydney, Australia
Posts: 17,871
Rep Power: 144
ghorrocks is just really niceghorrocks is just really niceghorrocks is just really niceghorrocks is just really nice
Quote:
the problem is that the lenght of my pipe is 200 meters. How coarse will be the mesh to let the simulation work on my workstation?
You will have to work that out, but you may well be able to mesh this with a coarse mesh which captures the hammer effects but does not add too much to the simulation size. If you make the walls slip walls that means you don't need to worry about boundary layer prisms, and if you make it an extruded mesh you can make the elements quite long in the pipe length dimension. You would only need to put 2 or 3 elements across the width of the flow to keep the element count down. Don't use the default tet mesh technique - you will need an extruded mesh so you keep the element count down.

Don't bother with fortran until you have shown this technique is not appropriate. I have used it many times so I can assure you it works.
ghorrocks is offline   Reply With Quote

Reply


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 Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
water hammer solution by finite volume method A.Maleki Main CFD Forum 1 January 20, 2010 21:46
water line Ciro Cannavacciuolo CFX 0 February 13, 2009 06:28
codes for water hammer on pipe flow park Main CFD Forum 0 September 28, 2008 02:43
Water Hammer Abdul Aziz Main CFD Forum 0 January 28, 2004 13:25


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