Fluids

Fluids

Topics related to Fluent, CFX, Turbogrid and more.

Problem with the coupling of ANSYS Fluent and Rocky DEM using a UDF

    • jarmouni
      Subscriber

      Hi everyone,
      I am currently working on a simulation where I connect ANSYS Fluent with Rocky DEM in a 2-way coupling.
      In order to be able to represent certain physical phenomena in the simulation, I have implemented a UDF in ANSYS Fluent. This UDF works perfectly in ANSYS Fluent alone and delivers correct results. However, as soon as I activate the coupling with Rocky DEM, a problem occurs: The simulation aborts with an error message.
      As this simulation is of great importance for my master thesis, I would be very grateful if you could help me to solve this problem. Are there any known restrictions or special settings that need to be considered when coupling ANSYS Fluent and Rocky DEM using a UDF?

       

       

    • victor.garbe
      Ansys Employee

       

      There are a few requirements in order to make use of UDFs:

       

      1. You must place all UDF files in the same folder in which your Fluent CAS (CAS.H5 or CAS.GZ)
        file is located. Rocky will then copy those files to the simulation folder and use them during
        the 2-Way coupling simulation.
      2. You must provide the UDF files via one of the following two methods:
        a. By providing the source files. (E.g., the .c, .h, and .cpp source and header files.) In this
        case, you must launch Rocky from an environment that has all the necessary variables
        for UDF compilation. Tip: An easy way to accomplish this is to open a command prompt
        and then call the udf.bat file, which in Windows, is usually located in the following
        folder C:\Program Files\ANSYS Inc {version}\fluent\ntbin\win64 Following this step, you can then launch Rocky from the command prompt. (See also Appendix
        G: Perform Tasks from the Command Line or Journal)
        b. (Recommended) By providing the folder containing the UDF binary files. In this case,
        you must have already compiled the UDF and there are no requirements in terms of
        the environment variables.

       

      What kind of UDF are you trying to use in the Fluent case?

       

    • jarmouni
      Subscriber

      Hi Victor,

      Thank you so much for your feedback.
       
      It is about a DEFINE_PROPERTY. I am trying to model a magnetorheological fluid whose properties, especially viscosity, can be changed under the influence of a magnetic field. I followed the steps you recommended, but I got an error message saying that Ansys needs a C++ compiler. I will look into fixing this error message and go through the steps again. I will keep you posted on the outcome.
       
      I also have a question: Is it possible to implement the magnetic field using the MHD model?
       
       


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