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/)
-   -   Momentum source term UDF to simulate anisotropic porous media (https://www.cfd-online.com/Forums/fluent-udf/238173-momentum-source-term-udf-simulate-anisotropic-porous-media.html)

Roscoe341 August 27, 2021 07:34

Momentum source term UDF to simulate anisotropic porous media
 
Hi. I am trying to simulate the flow of air though a packed rock bed in ANSYS Fluent. The flow resistance in the bed is anisotropic. As far as i understand the best way to simulate an anisotrpic porous media is by adding a momentum source term to the standard fluid flow equations. I have the resistance tensor but am not sure how to implement it in Ansys with a UDF. My resistance tensor is below.

𝑆𝑥 = 𝜇𝑢𝑥𝐷𝑥𝑥 + 𝜇𝑢𝑦𝐷𝑥𝑦 + 𝜇𝑢𝑧𝐷𝑥𝑧 + 1 2 𝜌|𝑢|{𝑢𝑥𝐶𝑥𝑥 + 𝑢𝑦𝐶𝑥𝑦 + 𝑢𝑧𝐶𝑥𝑧}

𝑆𝑦 = 𝜇𝑢𝑥𝐷𝑦𝑥 + 𝜇𝑢𝑦𝐷𝑦𝑦 + 𝜇𝑢𝑧𝐷𝑦𝑧 + 1 2 𝜌|𝑢|{𝑢𝑥𝐶𝑥𝑦 + 𝑢𝑦𝐶𝑦𝑦 + 𝑢𝑧𝐶𝑦𝑧}

𝑆𝑧 = 𝜇𝑢𝑥𝐷𝑧𝑥 + 𝜇𝑢𝑦𝐷𝑧𝑦 + 𝜇𝑢𝑧𝐷𝑧𝑧 + 1 2 𝜌|𝑢|{𝑢𝑥𝐶𝑧𝑥 + 𝑢𝑦𝐶𝑧𝑦 + 𝑢𝑧𝐶𝑧𝑧 }

I also have the values for the D and C matrix.

Any assistance in setting up this problem would be much appreciated.

Thanks

AlexanderZ August 30, 2021 00:16

you may try to use this link to make your code
https://www.cfd-online.com/Forums/fl...ductivity.html

to make define momentum source you need define_source macro, not DEFINE_ANISOTROPIC_CONDUCTIVITY


All times are GMT -4. The time now is 12:06.