CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   OpenFOAM Running, Solving & CFD (https://www.cfd-online.com/Forums/openfoam-solving/)
-   -   Drag Model for twoPhaseEulerFoam (https://www.cfd-online.com/Forums/openfoam-solving/230426-drag-model-twophaseeulerfoam.html)

lollico September 23, 2020 03:21

Drag Model for twoPhaseEulerFoam
 
Good morning everyone,
I would like to know if it is possibile to use the "PlessisMasliyahDrag particleForce" in an eulerian-eulerian solver like twophaseeulerfoam. The goal is to find the best drag model to match experimental data of metal particle injected in a convergent divergent supersonic nozzle (the continuum media is gas).
Otherwise are there other suggestions about other drag model?
Thank you.
Patrizio

geth03 September 29, 2020 05:19

if you go to
solvers -> multiphase -> twoPhaseEulerFoam -> interfacialModels ->
dragModels,
you will see all the available drag models for the twoPhaseEulerFoam solver.

The Plessis Masliyah Drag Model is not available, but you could create a copy of the Ergun drag model and then replace the constants (150 and 1.75) with the mathematical expressions of the Plessis-Masliyah Model.

lollico September 29, 2020 05:56

Quote:

Originally Posted by geth03 (Post 783994)
if you go to
solvers -> multiphase -> twoPhaseEulerFoam -> interfacialModels ->
dragModels,
you will see all the available drag models for the twoPhaseEulerFoam solver.

The Plessis Masliyah Drag Model is not available, but you could create a copy of the Ergun drag model and then replace the constants (150 and 1.75) with the mathematical expressions of the Plessis-Masliyah Model.


Thank you very much, I will try this!

lollico October 1, 2020 08:58

Drag Model for twoPhaseEulerFoam
 
Hi,
Following your suggestion (I am not an expert in C++) I changed Ergun.c from :
________________________________

(4.0/3.0)
*(
150
*max
(
scalar(1) - pair_.continuous(),
pair_.continuous().residualAlpha()
)/max(pair_.continuous(), pair_.continuous().residualAlpha())
+ 1.75
*pair_.Re()
);
_____________________________________
to:

return
(4.0/3.0)
*(
( 26.8*pow3(pair_.continuous())
/(
sqr(cbrt(scalar(1) - pair_.continuous()))
*(1.0 - cbrt(scalar(1) - pair_.continuous()))
*sqr(1.0 - sqr(cbrt(scalar(1) - pair_.continuous())))))

*max
(
scalar(1) - pair_.continuous(),
pair_.continuous().residualAlpha()
)/max(pair_.continuous(), pair_.continuous().residualAlpha())
+ (sqr(pair_.continuous())
/sqr(1.0 - sqr(cbrt(scalar(1) - pair_.continuous()))))

*pair_.Re()
);



where A=
(26.8*pow3(pair_.continuous())
/(
sqr(cbrt(scalar(1) - pair_.continuous()))
*(1.0 - cbrt(scalar(1) - pair_.continuous()))
*sqr(1.0 - sqr(cbrt(scalar(1) - pair_.continuous())))
))

And B=

sqr(pair_.continuous())
/sqr(1.0 - sqr(cbrt(scalar(1) - pair_.continuous())));


__________________________________________________ ____


I don't know if I well understood the variables, but it should work.
There is something I should change in the .H files too ?
Many thanks.
Cordially,
Patrizio

geth03 October 2, 2020 03:51

you can't just change the equation and expect the code to work.

to make it clear i will write down the steps you need to follow:

1. create a copy of the solver you want to modify and make changes only there.
if you don't know how to do it, check out the 3 weeks series, there is a tutorial on how to do that.

2. if you want to add a drag model, copy one and change
i) the name of the directory, the names in the .C and .H - files.
ii) change the equation

3. add your new model to the files-file in the Make-directory. look how it is done for other models and add your model.

4. compile your modified stuff whether it is the solver or the library.

lollico November 23, 2020 04:57

Thank you, following your instructions I succeeded to extend the lagrangian model to the twophaseeulerfoam euler-euler model.
Have a nice day!





Quote:

Originally Posted by geth03 (Post 784267)
you can't just change the equation and expect the code to work.

to make it clear i will write down the steps you need to follow:

1. create a copy of the solver you want to modify and make changes only there.
if you don't know how to do it, check out the 3 weeks series, there is a tutorial on how to do that.

2. if you want to add a drag model, copy one and change
i) the name of the directory, the names in the .C and .H - files.
ii) change the equation

3. add your new model to the files-file in the Make-directory. look how it is done for other models and add your model.

4. compile your modified stuff whether it is the solver or the library.



All times are GMT -4. The time now is 04:55.