Re: [Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-07-19 Thread Launchpad Janitor
Question #295814 on Yade changed:
https://answers.launchpad.net/yade/+question/295814

Status: Open => Expired

Launchpad Janitor expired the question:
This question was expired because it remained in the 'Open' state
without activity for the last 15 days.

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

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-07-05 Thread Seti
Question #295814 on Yade changed:
https://answers.launchpad.net/yade/+question/295814

Seti posted a new comment:
to be more specific. I need to use MatchMacker to assign different
cohesion value to two materials . would you please just have a look at
defined engine as per below. Thanks

O.engines=[
 ForceResetter(),
 InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Facet_Aabb(),Bo1_Wall_Aabb()]),
   
InteractionLoop([Ig2_Sphere_Sphere_L3Geom(),Ig2_Facet_Sphere_L3Geom(),Ig2_Wall_Sphere_L3Geom()],
   
[Ip2_FrictMat_FrictMat_FrictPhys(),Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(normalCohesion=MatchMaker(matches=((mat1,mat2,50),(mat2,mat2,100))),shearCohesion=MatchMaker(matches=((mat1,mat2,5000),(mat2,mat2,8))),label="cohesiveIp")],
   
[Law2_ScGeom_FrictPhys_CundallStrack(),Law2_ScGeom6D_CohFrictPhys_CohesionMoment(
   label='cohesiveLaw')]

   ),
 #NewtonIntegrator(damping=0.4,gravity=(0,0,-9.81)),
NewtonIntegrator(damping=0.4),
 PyRunner(command='checkUnbalanced()',realPeriod=2,label='checker'),
 PyRunner(command='addPlotData()',iterPeriod=100)
 ]

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

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-07-03 Thread Seti
Question #295814 on Yade changed:
https://answers.launchpad.net/yade/+question/295814

Status: Answered => Open

Seti is still having a problem:
Hi Jerome/Bruno,


Thanks for reply. Lets make it simple. Would you please help me to understand 
why below (simple) script does not work?

Thank you so much for your time.

#

utils.readParamsFromTable(rMean=0.02,rRelFuzz=0.1,maxLoad=10e8,minLoad=10)
from yade.params.table import *
from yade import pack, plot

## Define the material for your facet here
O.bodies.append(utils.geom.facetBox((0.5,0.5,0.5),(0.5,0.5,0.5),wallMask=31))

mat1 = 
O.materials.append(CohFrictMat(young=30e9,poisson=0.3,frictionAngle=radians(30),momentRotationLaw=True,etaRoll=1,density=2600,isCohesive=True,normalCohesion=1e6,
 shearCohesion=80e6,label='spheres1'))
mat2 = 
O.materials.append(CohFrictMat(young=30e9,poisson=0.3,frictionAngle=radians(30),momentRotationLaw=True,etaRoll=1,density=2600,isCohesive=True,normalCohesion=1e6,
 shearCohesion=80e6,label='spheres2'))

sp=pack.SpherePack()
sp.makeCloud((0,0,0),(1,1,1),rMean=rMean,rRelFuzz=rRelFuzz)

# add the sphere pack to the simulation
sp.toSimulation()

# add the sphere pack to the simulation


O.materials.append(FrictMat(young=1e10,poisson=0.1, frictionAngle = radians(0) 
, label='wallmat'))
wallmat = O.materials[-1]

O.engines=[
ForceResetter(),

InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Facet_Aabb(),Bo1_Wall_Aabb()]),
 
InteractionLoop([Ig2_Sphere_Sphere_L3Geom(),Ig2_Facet_Sphere_L3Geom(),Ig2_Wall_Sphere_L3Geom()],

[Ip2_FrictMat_FrictMat_FrictPhys(),Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(normalCohesion=MatchMaker(matches=((mat1,mat2,50),(mat2,mat2,100))),shearCohesion=MatchMaker(matches=((mat1,mat2,5000),(mat2,mat2,8))),label="cohesiveIp")],

[Law2_ScGeom_FrictPhys_CundallStrack(),Law2_ScGeom6D_CohFrictPhys_CohesionMoment(
label='cohesiveLaw')]

 ),
#NewtonIntegrator(damping=0.4,gravity=(0,0,-9.81)),
NewtonIntegrator(damping=0.4),
PyRunner(command='checkUnbalanced()',realPeriod=2,label='checker'), 
PyRunner(command='addPlotData()',iterPeriod=100)
]


O.dt=20*utils.PWaveTimeStep()
O.trackEnergy=True

def checkUnbalanced():

global Forcewall 
if O.iter<5000: return
if utils.unbalancedForce()>.1: return

plot.saveDataTxt('Elaheh3.txt.bz2')


O.bodies.append(utils.wall((0.5,0.5,1.0),2,sense = -1, material = 
'wallmat')) 
Forcewall = O.bodies[-1]


Forcewall.state.vel = (0,0,-0.01) ### applying the velocity to the wall 
(0,0,-1)=(u,v,w)

O.engines=O.engines+[PyRunner(command='addPlotData()',iterPeriod=200)]
  
checker.command='unloadPlate()'
def unloadPlate():
   # if the force on Forcewall exceeds maximum load, start unloading
   if abs(O.forces.f(Forcewall.id)[2])>maxLoad:
  Forcewall.state.vel = (0,0,0) ##you hadn't defined Forcewall before. so 
it gave you an error
  # next time, do not call this function anymore, but the next one 
(stopUnloading) instead
  checker.command='stopUnloading()'

def stopUnloading():
   if abs(O.forces.f(Forcewall.id)[2])https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-06-30 Thread Jérôme Duriez
Question #295814 on Yade changed:
https://answers.launchpad.net/yade/+question/295814

Jérôme Duriez proposed the following answer:
Hi,

The above link suggests to ask concise questions, and I think it's also
good to try to write yade scripts that are as concise as possible..

The small piece of script you provided is enough to show that your
script does not follow this guideline. It seems you tried to stuff as
many "Engine things" as possible into it, in a maybe desperate attempt
to have something that works ;-)

In particular, your InteractionLoop definition is a mess, honestly.. The
doc [1] says it has been defined "from 3 lists of Ig2, Ip2, Law
functors": there should be three lists (between brackets "[..]") inside
the parenthesis of InteractionLoop(...), see for instance [2]. Here, you
have six of them...

As a general remark, I would suggest to give a very close look to [3] as
a whole

[1] https://yade-dem.org/doc/yade.wrapper.html#yade.wrapper.InteractionLoop
[2] https://yade-dem.org/doc/user.html#basic-dem-model
[3] https://yade-dem.org/doc/user.html#base-engines

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

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


Re: [Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-06-30 Thread Bruno Chareyre
Question #295814 on Yade changed:
https://answers.launchpad.net/yade/+question/295814

Status: Open => Answered

Bruno Chareyre proposed the following answer:
Hi Seti,
I suggest having a look at those guidelines, especially points 2,3 and 6:
https://yade-dem.org/wiki/Howtoask
Bruno

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

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp


[Yade-users] [Question #295814]: MatchTracker for Cohesion

2016-06-30 Thread Seti
New question #295814 on Yade:
https://answers.launchpad.net/yade/+question/295814

Hi All,

As you may know the "iAdhesion" is computed from the minima of "iCohesion".

However I need to change this logic, I was told  "MatchMaker" in 
Ip2_CohFrictMat_CohFrictMat_CohFrictPhys should do what I am looking for. I 
have tried below engine, however it does not work.

O.engines=[
ForceResetter(),

InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb(),Bo1_Facet_Aabb(),Bo1_Wall_Aabb()]),
InteractionLoop(

[Ig2_Sphere_Sphere_ScGeom6D(),Ig2_Box_Sphere_ScGeom(),Ig2_Wall_Sphere_ScGeom(),Ig2_Facet_Sphere_ScGeom()],[Ip2_FrictMat_FrictMat_FrictPhys()],

[Ip2_FrictMat_FrictMat_MindlinPhys(en=MatchMaker(matches=((mat1,mat2,.6),(mat2,mat2,.9))),es=MatchMaker(matches=((mat1,mat2,.6),(mat2,mat2,.9))),krot=3)],
   

[Ip2_CohFrictMat_CohFrictMat_CohFrictPhys(normalCohesion=MatchMaker(matches=((mat1,mat2,500),(mat2,mat2,1e6))),shearCohesion=MatchMaker(matches=((mat1,mat2,50e6),(mat2,mat2,80e6))),label="cohesiveIp")],
 [Law2_ScGeom_MindlinPhys_Mindlin(includeMoment=True,includeAdhesion=True)],

[Law2_ScGeom_FrictPhys_CundallStrack(),Law2_ScGeom6D_CohFrictPhys_CohesionMoment(
useIncrementalForm=True, #useIncrementalForm is turned 
on as we want plasticity on the contact moments
always_use_moment_law=False,  #if we want "rolling" 
friction even if the contact is not cohesive (or cohesion is broken), we will 
have to turn this true somewhere
label='cohesiveLaw')]

Would you please advise?

Thanks 

Seti

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

___
Mailing list: https://launchpad.net/~yade-users
Post to : yade-users@lists.launchpad.net
Unsubscribe : https://launchpad.net/~yade-users
More help   : https://help.launchpad.net/ListHelp