CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

WenYu drag model code implimentation

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 18, 2015, 22:25
Default WenYu drag model code implimentation
  #1
New Member
 
Thien Xuan Dinh
Join Date: Jul 2014
Location: Japan
Posts: 8
Rep Power: 12
dinh is on a distinguished road
Dear Foamer,
Taking a look to ErgunWenYu drag model for the lagrangian tracking, OF 2.3.0 with alphac > 0.8, I think something wrong there, where the factor (1 - alphac) disappears.
Furthermore, can someone explain why alphac appears in the denominator?

Best,
dinh is offline   Reply With Quote

Old   November 25, 2015, 09:21
Default
  #2
New Member
 
César Augusto Corrêa Miguéis
Join Date: Nov 2013
Location: Rio de Janeiro, Brasil
Posts: 26
Rep Power: 12
cmigueis is on a distinguished road
dinh, I'm stucked in the very same question, did you have sucess about this thread? The Ergun part seems correct, but I agree with you that something looks bad in the Wen and Yu part.
__________________
César Miguéis
Mechanical Engineer
MSc. Student at COPPE/UFRJ
cmigueis is offline   Reply With Quote

Old   April 8, 2016, 08:53
Default
  #3
New Member
 
Li Linmin
Join Date: Nov 2015
Location: China
Posts: 27
Rep Power: 10
lilinmin is on a distinguished road
Quote:
Originally Posted by dinh View Post
Dear Foamer,
Taking a look to ErgunWenYu drag model for the lagrangian tracking, OF 2.3.0 with alphac > 0.8, I think something wrong there, where the factor (1 - alphac) disappears.
Furthermore, can someone explain why alphac appears in the denominator?

Best,
I think that is right because it returns the force not the coefficient, but I think it should be :
(mass/p.rho())*(150.0*(1.0 - alphac)+1.75*Re)*muc/(alphac*sqr(p.d()))
because alphac is divided with (alphac*sqr(p.d())).

does anyone find the same question?
lilinmin is offline   Reply With Quote

Old   September 10, 2017, 21:42
Default
  #4
New Member
 
QuocThien
Join Date: Apr 2013
Posts: 16
Rep Power: 13
neiht is on a distinguished road
I believe that the formula should be:
(mass/p.rho())*(150.0*(1.0 - alphac)/alphac+1.75*Re)*muc/(sqr(p.d()))

Because Sp = V*beta/(1.0 - alphac)

where beta = F*18*(1.0 - alphac)*alphac*muc/sqr(q.d())

Then there is no /alphac in the end in Ergun approximation.

When I run Single particle sedimentation in openfoam, the velocity of particle is smaller than the result by numerical analysis.
neiht is offline   Reply With Quote

Old   August 2, 2023, 18:28
Default
  #5
Member
 
Shah Akib Sarwar
Join Date: Mar 2021
Posts: 41
Rep Power: 5
Shah Akib Sarwar is on a distinguished road
Quote:
Originally Posted by neiht View Post
I believe that the formula should be:
(mass/p.rho())*(150.0*(1.0 - alphac)/alphac+1.75*Re)*muc/(sqr(p.d()))

Because Sp = V*beta/(1.0 - alphac)

where beta = F*18*(1.0 - alphac)*alphac*muc/sqr(q.d())

Then there is no /alphac in the end in Ergun approximation.

When I run Single particle sedimentation in openfoam, the velocity of particle is smaller than the result by numerical analysis.
Can you explain where in the source code you found the definition of Sp and beta?
Shah Akib Sarwar is offline   Reply With Quote

Old   May 23, 2024, 02:56
Default
  #6
Senior Member
 
Josh Williams
Join Date: Feb 2021
Location: Scotland
Posts: 113
Rep Power: 5
joshwilliams is on a distinguished road
1-\alpha_c should not appear in the Lagrangian formulation of the model (only the two-fluid model version of the drag law).
If 1-\alpha_c is there, then the drag force will decay to 0 as the solid volume fraction approaches zero (e.g. a single small isolated sphere). However, it should not happen. The drag force should decay to stokes drag.


I attached this figure showing drag force with varying \alpha_p and Re_p.


Script to reproduce is below


Code:
import numpy as np 
from numpy import pi
import matplotlib.pyplot as plt

def coeff_drag(Re):
# if Re > 1000.0:
#     return 0.44*Re
# else:
   return24.0*(1.0+0.15*Re**0.687)

def dragmodel_current(alpha_p, Re, d_p=10e-6, rho_p=1207, muc=1.5e-5):
    alpha_c =1-alpha_p
    vol_p =4./3. * pi * (d_p/2)**3
   return vol_p *0.75* coeff_drag(alpha_c*Re)*muc*pow(alpha_c, -2.65) / (alpha_c * np.square(d_p))

def dragmodel_literature(alpha_p, Re, d_p=10e-6, rho_p=1207, muc=1.5e-5):
    alpha_c =1-alpha_p
    vol_p =4./3. * pi * (d_p/2)**3
   return vol_p *0.75* alpha_p * coeff_drag(alpha_c*Re)*muc*pow(alpha_c, -2.65) / (alpha_c * np.square(d_p))

def dragmodel_oneway(alpha_p, Re, d_p=10e-6, rho_p=1207, muc=1.5e-5):
# alpha_p is unused
    num_vals = alpha_p.size
    alpha_p =None
    vol_p =4./3. * pi * (d_p/2)**3
   return vol_p *0.75* coeff_drag(Re)*muc / np.square(d_p) * np.ones(num_vals)

def stokes_drag(alpha_p, Re, d_p=10e-6, rho_p=1207, muc=1.5e-5):
# alpha_p is unused
    num_vals = alpha_p.size
    alpha_p =None
    Re =None
    vol_p =4./3. * pi * (d_p/2)**3
# return vol_p * 0.75 * coeff_drag(Re)*muc / np.square(d_p) * np.ones(alpha_p.size)
    Cd =24
   return vol_p *0.75* Cd * muc / np.square(d_p) * np.ones(num_vals)

alpha_p = np.array([0] + (10**np.linspace(-4, -1, 6)).tolist() + np.linspace(0.1, 0.6, 10).tolist())

Re =10
# print(dragmodel_current(0.1, Re=10), dragmodel_literature(0.1, Re=10))
ls_list = ["-", "--", "dotted", "-."]

fig, ax = plt.subplots()
ax.scatter(alpha_p, stokes_drag(alpha_p, Re), label=f"Stokes drag", c="black")
# plot drag force models at varying Reynolds numbers
for i, Re inenumerate([0, 0.1, 100]):
    ax.plot(alpha_p, dragmodel_current(alpha_p, Re), label=f"Wen-Yu (OF), Re = {Re}", ls=ls_list[i], c="orange", lw=2)
for i, Re inenumerate([0, 0.1, 100]):
    ax.plot(alpha_p, dragmodel_literature(alpha_p, Re), label=fr"Wen-Yu (with 1-$\alpha_f$), Re = {Re}", ls=ls_list[i], c="blue", lw=2)
for i, Re inenumerate([0, 0.1, 100]):
    ax.plot(alpha_p, dragmodel_oneway(alpha_p, Re), label=f"Schiller-Nauman, Re = {Re}", ls=ls_list[i], c="green", lw=2)
ax.set_yscale("log")
ax.set_xscale("log")
ax.set_ylabel(r"$\mathbf{f}_d$ [kg m / $s^2$]")
ax.set_xlabel(r"$\alpha_p$ [-]")
ax.set_title(r"Drag models at $d_p = 10^{-6} m$, $\rho_p = 1000$")

# format plot for legend outside of plot
box = ax.get_position()
ax.set_position([box.x0, box.y0, box.width *0.6, box.height])

# tidy up
for spine_i in ["top", "right"]:
    ax.spines[spine_i].set_visible(False)
ax.legend(frameon=False,loc="center left", bbox_to_anchor=(1.,0.5))
plt.savefig("drag_forces.png", dpi=300)
plt.show()
Attached Images
File Type: jpg drag_forces.jpg (91.7 KB, 5 views)
joshwilliams is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Drag model implementation vbchris OpenFOAM Running, Solving & CFD 1 March 31, 2015 08:28
Applying drag force in the fluid model CanadaFlanker CFX 7 May 5, 2014 23:13
parallel code samiam1000 SU2 3 March 25, 2013 04:55
multiphase flow modelling, Drag model Anant CFX 1 February 4, 2008 04:18
Use of an hydrodynamic model integrated in the vertical by the PHOENICS code Hafsia Zouhaier Main CFD Forum 2 March 15, 1999 08:23


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