problem in drag force using

Asked by Ricardo Lorenzoni

We are trying to implement the drag force in a simulation with two different density materials, but when simulating the both spheres fall in the same velocity. Anyone knows what is wrong in our code?

from yade import pack, plot, qt, utils, ymport
import numpy

Styrofoam=CohFrictMat(density=23)
idStyrofoam=O.materials.append(Styrofoam)

steel=CohFrictMat(density=7900,young=1.96e11)
idsteel=O.materials.append(steel)

O.bodies.append([
   sphere(center=(0,2,100),radius=.5,material=idStyrofoam,color=(1,1,0)),
   sphere((0,0,100),.5, material=idsteel,color=(1,0,1))
])

O.engines=[
   ForceResetter(),
   InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Facet_Aabb()]),
   InteractionLoop(
      [Ig2_Sphere_Sphere_L3Geom(),Ig2_Facet_Sphere_L3Geom()],
      [Ip2_FrictMat_FrictMat_FrictPhys()],
      [Law2_L3Geom_FrictPhys_ElPerfPl()]
   ),
   NewtonIntegrator(gravity=(0,0,-9.81),damping=0.05),
   DragEngine(ids=[0,1],Cd=0.2, Rho=1.225),
]

O.dt=.05*PWaveTimeStep()

thank's for helping

Question information

Language:
English Edit question
Status:
Solved
For:
Yade Edit question
Assignee:
No assignee Edit question
Solved by:
Klaus Thoeni
Solved:
Last query:
Last reply:
Revision history for this message
Best Klaus Thoeni (klaus.thoeni) said :
#1

Hi,

you need to call the DragEngine before the NewtonIntegrator.

HTH
Klaus

Revision history for this message
Ricardo Lorenzoni (ricolorenzoni) said :
#2

Thanks Klaus Thoeni, that solved my question.