Why my iteration speed is so low?
Hi, i try to do some simulation about particle packing behavior in a rotating drum. However the iteration speed is so low as about 30 iterations per second. Nevertheless, at the beginning when the particles are far from each, the iteration speed is 500 iter/s, no matter with -j2 or without prescribed -j parameter.
## Below is my code,
from yade import pack,geom,utils
import numpy as np
from yade import qt
### the unit in the simulation is UI, like kg m s Pa
### the particle has diameter below 100 microns
muS = 0.57
muF = 0.9
FricAngleS = math.atan(muS)
FricAngleF = math.atan(muF)
density = 8150
yongmodu = 195e5 ## scaled by 1e-4, normal value is 195Gpa
poisn = 0.3
Dsph = 80e-6 ## particle max diameter
angvelsw = -25 ## rotation speed rad/s
nrot = 6 ## rotation times
matSph = CohFrictMat(
SMat = O.materials.
matFacet = CohFrictMat(
FMat = O.materials.
### geometry ###
radiusSweeper = 10*Dsph
radiusSweeper0 = 9*Dsph
lengthSweeper = 12*Dsph
numSweeperParts = int(round(
## spheres ##
O.bodies.clear()
sp = pack.SpherePack()
x1, y1, z1 = -radiusSweeper, 0, 0
x2, y2, z2 = radiusSweeper, lengthSweeper, 2*radiusSweeper
sp.makeCloud((x1, y1, z1), (x2, y2, z2), psdSizes=
sp.toSimulation
## drum ##
Sweeper=[]
for i in np.linspace(0, 2*pi, num=numSweeperP
Sweeper.
SweeperP=[Sweeper, [p+Vector3(
SweeperPoly = pack.sweptPolyl
sweeperid = O.bodies.
boxid = O.bodies.
## remove the spheres out of the drum ##
for eb in O.bodies:
if isinstance(
xi,yi,zi = eb.state.pos
lengi = np.sqrt(xi**2 + (zi-radiusSweep
if lengi > 0.96*radiusSweeper:
## total sphere is 6691, facet is 2020
### define engines functions ###
t1 = 0.1
t2 = t1+nrot*
t3 = t2+0.1
def change_motion():
if O.time > t1:
if O.time > t2:
O.engines=[
ForceResetter(),
InsertionSortC
InteractionLoop(
),
PyRunner(
RotationEng
NewtonInteg
]
O.dt = 0.85*utils.
O.run()
## the hardware ##
Ubuntu 18.04 on VMware 14.0 with 8 processors 32 GB memory
Main system: Win10-64
Processor: AMD Ryzen Threadripper 1950X 16-Core Porcessor, 3.40 GHz
## Yade version
2018.02b
## some yade --performance test
## 4k 20k 40k spherical particles with yade -j 1 *.py
https:/
https:/
https:/
## 4k 20k 40k spherical particles with yade -j 2 *.py
https:/
https:/
https:/
Very appreciated.
Xuesong
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Yade Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask gaoxuesong for more information if necessary.