Fluids

Fluids

Topics related to Fluent, CFX, Turbogrid and more.

Data Transfer

    • David_SY
      Subscriber

      I am going to build surface reactions in UDFs.

      I would like to run Fluent and then, get process parameters (P, T) from Fluent.

      Afterwards, I am going to run my UDF that is able to calculate how much gas species are consumed on the surface (wall).

      For the next time step, I want Fluent to run with the estimated consumption of gas species, thus leading to decrease in the species in gas phase.


      I was wondering if this could be possible. Or are there any other ways that I can build surface reactions in Fluent.

      To be honest, my reactions have several intermediate steps, so it is hard to model them in Fluent.

      Thanks. :- )

    • Rob
      Forum Moderator
      To clarify, a reaction occurs at the surface based on temperature & pressure. You then want to remove this mass from the fluid phase and record the amount removed. Then move onto the next time step and repeat?
      Have a look at the DEFINE_SOURCE functions and User Defined Memory.

      As an aside, please use one thread for a given problem. Otherwise you risk threads being deleted or not answered if we think it's a duplicate.
    • David_SY
      Subscriber
      Let me clarify this.
      I am working on a project that combines CFD of fluid flow to a surface reaction model.
      I am looking for ways that surface coverage data from outside is applied to CFD.
      We run Fluent first at a time step and then, we run our reaction model, which can be defined outside or may be in a UDF as a type of arrays.
      The reaction model calculate the reactant and product changes with time and position.
      The consumption of reactants vary with time and positions.
      We would like to see how the result of the reaction model (consumption of reactants and production of byproducts) affects the next CFD iteration.
      Now that my source term is not a function of time and positions,
      I was wondering if I could approximate our information of the array into the surface in Fluent by using DEFINE_SOURCE functions.
    • Rob
      Forum Moderator
      OK, thanks.
      If the reaction scheme is a UDF and uses some function of what is in a cell (can be a UDM to track how much of something else has been used, and that includes on a wall facet) then the source term will give the value in each cell. It's calculated over the whole volume on a cell basis.
      For an external scheme you'd need some mechanism of getting the values back to locations bearing in mind that the external code won't know about the cells, or if they do their ID.
    • David_SY
      Subscriber
      I think I am not able to build a reaction scheme in a UDF.
      However, I want to be crystal clear.
      =================================================================================================
      The reaction scheme has several steps to complete, which means there are several intermediates.
      (for example, adsorption -> surface reaction -> desorption ...)
      What I want to do is to read pressure and temperature of a cell on the surface after a time step.
      My reaction scheme will determine whether a reaction happens.
      I will save what kind of species is on a cell in UDMs and go back to run CFD.
      After the next iteration, I would like to read my data from UDMs and match each variable to each cell so that reactions can progress.
      I will repeat it until the reaction is complete.
      =================================================================================================
      In summary, my question is that it is possible for variables in UDMs to be allocated on each cell.
      Thanks.

    • Rob
      Forum Moderator
      Yes, the UDM is stored on a cell or facet basis and is available until overwritten when you next re-calculate that value.
    • David_SY
      Subscriber
      Thank your very much.
      Sorry but one quick question.
      I've heard that the UDM is limited to 500 variables.
      However, the number of cells on my surface is around 15,000 or more.
      Do you think there is any way I can use more UDMs up to 15,000 or compress 15,000 variables into 500 variables
      If it is not possible, I am wondering whether I can use a UDM (let's say a variable in A cell) at a different cell (Let's say B cell).
      Thanks again!!
    • Rob
      Forum Moderator
      No, I think there is a limit of 500 unique UDM's but not a limit to the number of cells each one sees. Ie I can have UDM_0 to UDM_499 with 120M cells but not UDM_501 with 10k cells.
    • Shyam Prasad V Atri
      Subscriber
      Is there a way to access a user-defined memory in DEFINE_DPM_INJECTION_INIT(name,I)
      for example, you can access a user defined memory in the scalar update udf as C_UDMI(c,t,abc) right i want to access this memory without going through all the cells just as one number(i cant use a uds as it has the same problem as UDM)..please let me know how to do this
    • Rob
      Forum Moderator
      You want the (for example) mean value of the UDM or just a single value from somewhere else?
Viewing 9 reply threads
  • The topic ‘Data Transfer’ is closed to new replies.