← Back to team overview

yade-users team mailing list archive

[Question #645958]: creating a cloud of compressed aggregates/clumps

 

New question #645958 on Yade:
https://answers.launchpad.net/yade/+question/645958

Hi There,
I am working on generating a compressed packing of aggregates. I am currently using /examples/agglomerate as a basis.
I am using makeClumpCloud to fill a cuboid with clumps which I generated. Then I would like to run them through /examples/agglomerate/compress.py and generate a dense packing of these aggregates.

I would like the method to work for just a few aggregates as well as for a larger number.
The result using just a few looks like http://pasteall.org/pic/index.php?id=116894
(When I generate a larger number of particles things look better http://pasteall.org/pic/index.php?id=116816)

There is quite a bit of empty space left. I was hoping by compressing I could end up with a cuboid of packed aggregates, however I dont see the compression doing anything at all... 

Is there something missing for the TriaxialStressController to work? 

thanks in advance
Jesse


code here:
	from yade import export,ymport
	import random
	random.seed(1)

	# add walls first
	#dim = (15,15,15)
	#dim = (1.5e-6,1.5e-6,1.5e-6)
	dim = (1e-6,1e-6,1e-6)
	walls = aabbWalls(((0,0,0),(dim)))
	wallIds = O.bodies.append(walls)

	# load spheres from file, including information of their agglomerates ids
	attrs = []
	sp = ymport.textExt('/tmp/divided.txt',format='x_y_z_r_attrs',attrs=attrs)
	n = max(int(a[0]) for a in attrs)+1
	colors = [randomColor() for _ in xrange(n)]
	agglomerates = [[] for _ in xrange(n)]
	for s,a in zip(sp,attrs):
		aa = int(a[0])
		s.agglomerate = aa
		s.shape.color = colors[aa]
		agglomerates[aa].append(s)
	for a in agglomerates:
		O.bodies.appendClumped(a)

	#getClumpInfo()
	
	print('Number of particles = ' , len(O.bodies))


	O.engines = [
		ForceResetter(),
		InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb()]),
		InteractionLoop(
			[Ig2_Sphere_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()],
			[Ip2_FrictMat_FrictMat_FrictPhys()],
			[Law2_ScGeom_FrictPhys_CundallStrack()]
		),
		TriaxialStressController(
			thickness = 0,
			stressMask = 7,
			internalCompaction = False,
			label = 'compressor',
		),
		NewtonIntegrator(damping=.6),
	]
	factor = 0.001
	print('factor = ', factor)
	O.dt = factor * PWaveTimeStep()
	
	print('Number of particles = ' , len(O.bodies))
	
	### Debug disappearing particles
	#ids = set(b.id for b in O.bodies)
	#sames = []
	
	#while ids:
		#i = ids.pop()
		#b = O.bodies[i]
		#p = b.state.pos
		#same = [i]
		#iis = set(ids)
		##if len(ids) < 1	
		#for ii in iis:
			#bb = O.bodies[ii]
		#if bb.state.pos == p:
			#same.append(ii)
			#ids.discard(ii)
		#if len(same)>1:
			#print "bodies {} has identical pos".format(same)
			#sames.append(same)
	#for i in sames[-1]:
		#print O.bodies[i].state.pos
	#######

	# compress the sample
	compressor.goal1 = compressor.goal2 = compressor.goal3 = -1e-100
	#compressor.goal1 = compressor.goal2 = compressor.goal3 = 1e-10
	
	
	input("Press Enter to continue...")
	
	O.run(50000,True)
	#compressor.goal1 = compressor.goal2 = compressor.goal3 = -1e-5
	#O.run(30000,True)

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