[Yade-users] [Question #680689]: time for reaching a static equilibrium

2019-05-07 Thread Cloud
New question #680689 on Yade:
https://answers.launchpad.net/yade/+question/680689

Hi,

I want to ask a question I have encountered, every time I change box size, it 
becomes very difficult to reach equilibrium. for 
example,mn,mx=Vector3(0,0,0),Vector3(1e-3,1e-3,1e-3) is Ok, but I change it to  
mn,mx=Vector3(0,0,0),Vector3(1e-2,1e-2,1e-2), it will take a long time or hard 
to reach equilibrium.

MWE:

from yade import pack
import math
nRead=utils.readParamsFromTable(
young = 0.858e9, 
poisson = 0.3,
compFricDegree = 8, 
finalFricDegree = 30.0,
num_spheres = 1,
#young_wall=3.0e7
confiningS = 100e3,   
isoconfining = 5e3,
AxialStrainLimit = 0.3,  
rate = -0.02,  
damp = 0.2,   
unknownOk = True   
)
from yade.params import table

mn,mx=Vector3(0,0,0),Vector3(1e-2,1e-2,1e-2) # corners of the initial packing
young = table.young
poisson = table.poisson
compFricDegree = table.compFricDegree
finalFricDegree = table.finalFricDegree
num_spheres = table.num_spheres
confiningS = table.confiningS
isoconfining = table.isoconfining
damp = table.damp
rate = table.rate
AxialStrainLimit=table.AxialStrainLimit
key='_cf-'+str(compFricDegree)+'_ff-'+str(finalFricDegree)+'_Y-'+str(young/1e6)+'_p-'+str(poisson)+'_S-'+str(confiningS/1000)
cd = 1 # cd=1 - consolidate drained  cd=0- undrained
porosity = 0.72
stabilityThreshold = 0.001
thick = 0.01
d_limit = 0.15  # (d_limit/dmin = 0.25)
roll_stiff = 0.01
targetPorosity = 0.43

O.materials.append(FrictMat(
young=young,
poisson=poisson,
density=2650,
frictionAngle=radians(compFricDegree),
label='spheres')
)

O.materials.append(FrictMat(
young=young/10,
poisson=poisson,
frictionAngle=0,
density=0,
label='walls')
)
# create walls around the packing
walls=aabbWalls([mn,mx],thickness=0,material='walls')
wallIds=O.bodies.append(walls)

sp=pack.SpherePack()

sp.makeCloud(mn,mx,-1,1.0/7.0,num_spheres,False,porosity,seed=1)# porosity=0.65 
is the default value
O.bodies.append([sphere(center,rad,material='spheres') for center,rad in sp])


triax=TriaxialStressController(
## TriaxialStressController will be used to control stress and strain. It 
controls particles size and plates positions. (Documention p290)
maxMultiplier=1.001,   # spheres growing factor (fast growth)
finalMaxMultiplier=1.1,  # spheres growing factor (slow growth)
thickness = thick,
stressMask = 7, # 1*1 + 1*2 + 1*3 = 7 means x,y,z are on
internalCompaction=True, # if true the confining pressure is generated by 
growing particles.
)

newton = NewtonIntegrator(damping=damp)

O.engines=[
ForceResetter(),
InsertionSortCollider([Bo1_Sphere_Aabb(),Bo1_Box_Aabb()]),
InteractionLoop(
[Ig2_Sphere_Sphere_ScGeom(),Ig2_Box_Sphere_ScGeom()],
[Ip2_FrictMat_FrictMat_MindlinPhys()],
[Law2_ScGeom_MindlinPhys_Mindlin()]
),

GlobalStiffnessTimeStepper(active=1,timeStepUpdateInterval=100,timestepSafetyCoefficient=0.8),
triax,

TriaxialStateRecorder(iterPeriod=1000,file='TriaxialRecorder'+key,truncate=1),
newton,
]


triax.goal1=triax.goal2=triax.goal3=-isoconfining #(5kpa)
timing.reset()
while 1:
O.run(1000, True)
unb=unbalancedForce()
print 'unbalanced force:',unb,' mean stress: ',triax.meanStress
if unb < stabilityThreshold and 
abs(-isoconfining-triax.meanStress)/isoconfining<0.001:
break

O.save('InitialState'+key+'.yade.gz')
print "###   Initial state saved   ###"

Thank you in advance!

-- 
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 #680642]: Segmentation fault(core dumped)

2019-05-07 Thread Cloud
Question #680642 on Yade changed:
https://answers.launchpad.net/yade/+question/680642

Status: Needs information => Solved

Cloud confirmed that the question is solved:
It may be a time-step problem. After making some modification to time-
step, it runs normally.

-- 
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 #679544]: Best way to fix typos in documentation: source edit + git push?

2019-05-07 Thread Gael Lorieul
Question #679544 on Yade changed:
https://answers.launchpad.net/yade/+question/679544

Status: Answered => Open

Gael Lorieul is still having a problem:
Hi all!

On Fri, 3 May 2019 at 23:58, Gael Lorieul
 > First of all, Bruno Chareyre asked me for my GitLab.com user name,
 > [...] So I assume he was considering adding me to the list of team
 > members, possibly with reduced permissions?

El 03-05-19 a las 18:20, Bruno Chareyre escribió:
 > Done, sorry for delay!

El 06-05-19 a las 10:46, Janek Kozicki escribió:
 > Oh good. Now you are part of yade-dev team. Welcome:)
 > You will push to a branch on gitlab and make merge requests.

Awesome, thanks!
I will push something small soon to test all works as it should ;)


El 03-05-19 a las 18:20, Bruno Chareyre escribió:>
 > Please note that you sent reply to yade-users, feel free to use
 > yade-dev for any communication.

I will do so for future conversations, I just wanted to avoid a mess 
where the present conversation would be half in yade-users and half in 
yade-dev ;) .
Now I think the thread has reached to an end (hopefully, if all works as 
expected… XD ), so it does not matter very much anymore.

 > Are you french? Your name sounds so.

I am ;) but living on the other side of the planet for now!

Many thanks for your help!

Gaël

-- 
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 #680662]: Small density sphere in micron size makes segment fault (core dumped)

2019-05-07 Thread Jan Stránský
Question #680662 on Yade changed:
https://answers.launchpad.net/yade/+question/680662

Status: Needs information => Answered

Jan Stránský proposed the following answer:
Hello, just running your code and waiting for the result. However, the
changeValues() function should not be used in this form (!)

You are adding new TranslationEngine every 100 iterations. Now I have
O.iter=288300 and if I print len(O.engines), I got 2893.. Furthermore,
what is the meaning of the TranslationEngine with velocity=0.0?

A proper way could be something like:
###
O.engines = [
   ...
   TranslationEngine(...,dead=False,label='transEngine'), # just one engine
   HarmonicMotionEngine(...,dead=True,label='harmEngine'), # just one engine
   NewtonIntegrator(...), # consider pacing it after kinematic engines [1]
   PyRunner(iterPeriod=100,command='changeValues()'),
]

def changeValues():
   if O.time < 0.2:
  pass # probably initialized above
   elif O.time < 0.4: # no need of 0.2 <= O.time, because if so, it would have 
finished in above branch
  transEngine.dead = True
  harmEngine.dead = False
  harmEngine.A = ...
  harmEngine.f = ...
   elif ...
###

could you modify your code and test if it works?

cheers
Jan

[1] https://yade-dev.gitlab.io/trunk/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 #680371]: Question about dynamic timescale

2019-05-07 Thread Launchpad Janitor
Question #680371 on Yade changed:
https://answers.launchpad.net/yade/+question/680371

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