Fluids

Fluids

ANSYS Fluent udf define_source problem

    • Cosm0
      Subscriber

      Hi everyone,

      I'm trying to use a udf to simulate a heat source all around the walls of a titanium drum (with water inside).
      I attached an image of the CFX simulation showing the heat applied on the walls.

      Now I want to do the same in fluent. So I'm using the udf define_source, in particular I want that the heat is applied only on the external walls (this means when the position is equal to the radius of the wall) and only in the middle of the wall (so when y=-0.04).

      I attach here the udf define_source that I wrote, and that I then "interpret" in fluent (also becuase if I do compile somehow the fluent setup suddenly crashes and closes.


      I'm not sure if x[0]=x and x[1]=y or if it is x[1]=x and x[2]=y, but I tried in both ways and anyway the result is wrong. The heat is not applied on the drum (so probably the if statement doesn't work).


      Maybe I wrote the udf in the wrong way? 

      Thank you in advance for your help!

      Cheers,

      Paride


       

    • Rob
      Ansys Employee

      A source is used to add stuff (energy in this case) to a volume (solid in this case).  If you're trying to add heat to an external wall you'll need a DEFINE_PROFILE. 

    • Cosm0
      Subscriber

      Thanks rwoolhou for your answer.


      In this case though I want to add energy in a volume close to the wall (W/m3), let's say 1cmx1cmxdrumperimeter.


      In the simulation anyway the drum is turning at 63 rad/s, maybe the fact that is turning could be the cause of the wrong if statement?


       


      Best,


       


      P

    • Rob
      Ansys Employee

      Rotation shouldn't matter, the source will apply to the cell zone. 

Viewing 3 reply threads
  • You must be logged in to reply to this topic.