CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Fluent UDF and Scheme Programming (https://www.cfd-online.com/Forums/fluent-udf/)
-   -   define source term (https://www.cfd-online.com/Forums/fluent-udf/195823-define-source-term.html)

behzzad93 November 18, 2017 07:33

define source term
 
hi everyone

i have a serious problem in fluent:confused:
what is the udf for permeate flux?...i have to modeling a tube that have an inlet and outlet, but the walls of tube have permeability. indeed i want to model a membrane that fluid enters the inlet and a little bit of fluid passes through the wall(i know the equation for permeability) and rejected fluid is exited from the outlet. so can anyone tell me how can i define a udf for this equation please?..i realized i have to use sink & source method for wall boundary condition, also i have to use "define_source" macro. but i didn't see examples for this section.
i don't know how to write udf for this boundary!!.

thank you

behzzad93 November 18, 2017 07:43

eqn of permeability
 
1 Attachment(s)
the equation of permeability is in attachment

zobekenobe June 25, 2018 11:24

Hey behzzad,



In case you are still figuring the solution, here is what I am doing.


I have defined the membrane as a velocity inlet and written a UDF and used DEFINE_PROFILE to specify the flux through the membrane (-ve in sign as it exits the boundary). The secondary phase could be set as zero to not allow it to flow through.



If you restrict the flow through the boundary, it begins to act a permeable surface. by using DEFINE_SOURCE you can account for the material that leaves the system and probably enters the other phase. for a UDS you would have to define your own else for species it is accounted for in the mass transfer definition.


All times are GMT -4. The time now is 21:32.