yade-users team mailing list archive
-
yade-users team
-
Mailing list archive
-
Message #26103
[Question #698498]: How to use cellRepeat
New question #698498 on Yade:
https://answers.launchpad.net/yade/+question/698498
Hi,
I'd like to ask how to use cellRepeat[1] function to stack several copies of a cell along one direction. One illustration can be found in Fig. 3 in [2].
I use the following MWE (from[3]) to make a sample in a cell, the MWE pauses after the sample reaches the target isotropic state. I'd like to reproduce several of the cell at that state, and stack them together along one direction, but I didn't make it after some attempts. Here is the MWE, it may take around 50 seconds for running.
############ MWE begins ###############
from __future__ import print_function
sigmaIso = -100e3
from yade import pack, qt, plot
mn,mx=Vector3(0,0,0),Vector3(0.07,0.14,0.07)
O.periodic = True
O.cell.setBox(.07,.14,.07)
sp = pack.SpherePack()
sp.makeCloud(mn,mx,-1,0.3333,num=7000, periodic=True)
sp.toSimulation()
O.engines = [
ForceResetter(),
InsertionSortCollider([Bo1_Sphere_Aabb()]),
InteractionLoop([Ig2_Sphere_Sphere_ScGeom()], [Ip2_FrictMat_FrictMat_FrictPhys()], [Law2_ScGeom_FrictPhys_CundallStrack()]),
PeriTriaxController(
label='triax',
goal=(sigmaIso, sigmaIso, sigmaIso),
stressMask=7,
dynCell=True,
maxStrainRate=(10, 10, 10),
maxUnbalanced=.1,
relStressTol=1e-3,
doneHook='compactionFinished()'
),
NewtonIntegrator(damping=.2),
]
O.dt = .5 * PWaveTimeStep()
O.trackEnergy = True
def compactionFinished():
print('stage1 finished','sxx',triax.stress[0],'syy',triax.stress[1],'szz',triax.stress[2])
O.cell.trsf=Matrix3.Identity
triax.goal = (sigmaIso, -0.1, sigmaIso)
triax.stressMask = 5
triax.maxStrainRate = (1., 0.5, 1.)
triax.maxUnbalanced = 10
O.pause()
# here I want to repeat the current cell
def triaxFinished():
print('Finished')
O.pause()
############ MWE finish ###############
Thanks very much!
Leonard
[1]https://yade-dev.gitlab.io/trunk/yade.pack.html?highlight=cell#yade._packSpheres.SpherePack.cellRepeat
[2]Cheng, Hongyang, Stefan Luding, Kuniyasu Saitoh, and Vanessa Magnanimo. "Elastic wave propagation in dry granular media: effects of probing characteristics and stress history." International journal of solids and structures 187 (2020): 85-99.
[3]https://gitlab.com/yade-dev/trunk/blob/master/doc/sphinx/tutorial/06-periodic-triaxial-test.py
--
You received this question notification because your team yade-users is
an answer contact for Yade.