← Back to team overview

yade-users team mailing list archive

Re: [Question #661926]: REFD method with clumps, but maintaining the proportion of clumps

 

Question #661926 on Yade changed:
https://answers.launchpad.net/yade/+question/661926

    Status: Answered => Open

Marcus Moravia is still having a problem:
Hi Bruno,

Thank you for your reply. The script below is in the format of the
tutorial script. As the number of particles increases, the overlap of
the clumps' spheres begins to be more similar to the original geometry.
But even with the maximum number of particles supported by the model
(i.e., 500 particles), the geometry of the clumps is not the same as
that defined in the model. I have no idea about the logic behind the
number of particles in this case. Could you help me, please?

### Script ###

from yade import pack


nRead=readParamsFromTable(
  num_particles=100,# number of spheres
  compFricDegree = 30, # contact friction during the confining phase
  key='_triax_base_', # put you simulation's name here
  unknownOk=True
)

from yade.params import table

## Particles
mn,mx = Vector3(0,0,0),Vector3(1,1,1)
key=table.key
num_particles = table.num_particles
radius = .1
damp = 0.2
compFricDegree = table.compFricDegree
young = 5e6
stabilityThreshold = 0.01

## REFD Parameters
targetPorosity = 0.44
finalFricDegree = 30

## Triaxial teste parameters
rate = - 0.02


O.materials.append(FrictMat(young=young,poisson=0.5,frictionAngle=radians(compFricDegree),density=2600,label='sphereMat'))
O.materials.append(FrictMat(young=young,poisson=0.5,frictionAngle=0,density=0,label='wallMat'))

walls=aabbWalls([mn,mx],thickness=0,material='wallMat')
wallIds=O.bodies.append(walls)

sp=pack.SpherePack()

c1=pack.SpherePack([((0,0,0),.03),((.04,0,0),.025),((.025,.03,0),.02),((.025,.01,.03),.02)])
c2=pack.SpherePack([((0,0,0),.036),((.048,0,0),.03),((.03,.036,0),.024),((.03,.012,.036),.024)])
c3=pack.SpherePack([((0,0,0),.024),((.032,0,0),.02),((.02,.024,0),.016),((.02,.008,.024),.016)])
c4=pack.SpherePack([((0,0,0),.042),((.056,0,0),.035),((.035,.042,0),.028),((.035,.014,.042),.028)])
c5=pack.SpherePack([((0,0,0),.018),((.024,0,0),.015),((.015,.018,0),.012),((.015,.006,.018),.012)])
sp=pack.SpherePack()
print 'Generated # of clumps:',sp.makeClumpCloud((0,0,0),(1,1,1),[c1,c2,c3,c4,c5],num=num_particles,periodic=False,seed=1)
sp.toSimulation(material='sphereMat')
O.bodies.updateClumpProperties(discretization=50)

triax=TriaxialStressController(
  maxMultiplier = 1. + 2e4 / young,
  finalMaxMultiplier = 1. + 2e3 / young,
  thickness = 0,
  stressMask = 7,
  internalCompaction = True,
)

newton = NewtonIntegrator(damping=damp)

O.engines=[
  ForceResetter(),
  InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb()]),
  InteractionLoop(
    [Ig2_Sphere_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()], ## collision geometry
    [Ip2_FrictMat_FrictMat_FrictPhys()], ## collision "physics"
    [Law2_ScGeom_FrictPhys_CundallStrack()] ## set contact law to apply forces
),

GlobalStiffnessTimeStepper(active=1,timeStepUpdateInterval=100,timestepSafetyCoefficient=0.8),
  triax,
  TriaxialStateRecorder(iterPeriod=100,file='WallStresses'+table.key),
  newton,
]

triax.goal1=triax.goal2=triax.goal3 = - 10000

while 1:
  O.run(1000, True)
  unb=unbalancedForce()
  print 'unbalanced force:',unb,' mean stress: ',triax.meanStress
  if unb<stabilityThreshold and abs(- 10000 - triax.meanStress) / 10000 < 0.001:
    break

import sys
while triax.porosity>targetPorosity:
  compFricDegree = 0.95 * compFricDegree
  setContactFriction(radians(compFricDegree))
  print "\r Friction: ",compFricDegree," porosity:",triax.porosity,
  sys.stdout.flush()
  O.run(500,True)
  
triax.internalCompaction=False
setContactFriction(radians(finalFricDegree))
triax.stressMask = 5
triax.goal2 = rate
triax.goal1 = - 10000
triax.goal3 = - 10000
newton.damping = 0.1

rr=yade.qt.Renderer()
Gl1_Sphere.stripes=True
yade.qt.View()
O.saveTmp()

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.