GlobalStiffnessTimestepper gives dt of 0.0 when the saved file is restored
As noted in the previous question (https:/
I have encountered similar situations.
The program code consists of three Yade sccript.
The first one (CBT_T1.py) makes boxes and walls using facets and generate save file "CDSS_box_1.yade"
The second one (CBT_T2.py) generate spheres using free falling procedures
at this stage, the critical time step is calculated using "GlobalStiffnes
The problem occurs when running the third stage script (CBT_T3.py)
At this stage, the saved file (CDSS_ball_2.yade) is restored and the critical time step is calculated using "GlobalStiffnes
The simulation goes well until it reaches the iteration of 1000 which re-calculate critical time step using c
The "GlobalStiffnes
What is the problem?
Thanks in advance.
====
Working environment :
Ubuntu 22.10 kinetic
Yade 2022.01a
Intel Xeon Gold 6252 2EA
====
The MWE contains local path
==== 1st script, CBT_T1.py
from yade import pack, plot
import sys
sys.path.
def setGeomVars (): # initialize variables
width = 0.05
height = 0.03
margin = 30
# Calculate extra length
dx = width/100/2*margin
dy = width/100/2*margin
dz = height/100/2*margin
saveVars(
setGeomVars ()
from yade.params.geoms import * # load initilized variables
# side pannel
p1s = (-width/
p5s = (-width/
p6s = (-width/
p2s = (-width/
side1_1 = utils.facet(
side1_2 = utils.facet(
O.bodies.
O.bodies.
p4s = (width/
p8s = (width/
p7s = (width/
p3s = (width/
side2_1 = utils.facet(
side2_2 = utils.facet(
O.bodies.
O.bodies.
# front pannel
p1f = (-width/
p5f = (-width/
p4f = (width/
p8f = (width/
front1 = utils.facet(
front2 = utils.facet(
O.bodies.
O.bodies.
# back pannel
p2b = (-width/
p6b = (-width/
p3b = (width/
p7b = (width/
back1 = utils.facet(
back2 = utils.facet(
O.bodies.
O.bodies.
#bottom pannel
p1bt = (-width/
p2bt = (-width/
p3bt = (width/
p4bt = (width/
bot1 = utils.facet(
bot2 = utils.facet(
O.bodies.
O.bodies.
collar = geom.facetBox(
O.bodies.
#save
O.save(
==== 2nd script, CBT_T2.py
from yade import pack, plot
import sys
sys.path.
O.load(
loadVars('geoms')
from yade.params.geoms import * # load initilized variables
O.materials.
#O.materials.
cp1 = (-width/
cp2 = (width/
radius_mean = 0.002
sp = pack.SpherePack()
sp.makeCloud(cp1, cp2, rMean=radius_mean, rRelFuzz=0.0, num = 10000)
sp.toSimulation
O.engines = [
ForceResett
InsertionSo
Interaction
),
# Apply gravity force to particles. damping: numerical dissipation of energy.
GlobalStiff
NewtonInteg
PyRunner(
PyRunner(
PyRunner(
# DomainLimiter(
]
def addData():
for b in O.bodies:
elapsed_time=0.0
def checkUnbalanced():
# print(unbalance
global elapsed_time
if (O.time-
print("The highest ball position is = ", ball_highest_z)
if ball_highest_z < height/2:
else:
# plotting
def addPlotData():
plot.
plot.plots=
plot.plot()
O.dt=0.
O.run() #; O.wait()
==== 3rd script, CBT_T3.py
from yade import pack, plot
import sys
sys.path.
O.load(
loadVars('geoms')
from yade.params.geoms import * # load initilized variables
for i in range(10, 18):
O.bodies.
# create topcap
p5t = (-width/
p6t = (-width/
p7t = (width/
p8t = (width/
topcap1 = utils.facet(
topcap2 = utils.facet(
O.bodies.
O.bodies.
topcap_area = width**2
target_press = 100000 # unit in Pa
mass = target_
target_force = target_press * topcap_area
O.bodies[
O.bodies[
print('Each facet mass is', mass)
print('Each facet target force is', mass)
#O.engines=
O.engines = [
ForceResett
InsertionSo
Interaction
),
# Apply gravity force to particles. damping: numerical dissipation of energy.
GlobalStiff
NewtonInteg
PyRunner(
# PyRunner(
PyRunner(
# DomainLimiter(
]
def addData():
for b in O.bodies:
def cal_stress(listup):
for i in listup:
i+=1
return i
# plotting
i_times=0
def addPlotData():
topcap_
topcap_
topcap_
#Calculate shear stress
global Box_Vol
Box_Vol = (height + dz + O.bodies[
Force_
Cauchy_
for i in O.interactions:
if isinstance(
f = i.phys.normalForce + i.phys.shearForce
l = O.bodies[
Cauchy_
#Plot data
plot.
global i_times
servo_
if servo_error < 0.1:
i_times += 1
if i_times > 100:
else:
i_times = 0 # zero setting
O.bodies[
O.bodies[
O.bodies[
O.bodies[
O.bodies[
O.bodies[
plot.plots=
plot.plot()
O.dt=0.
O.run()
Question information
- Language:
- English Edit question
- Status:
- Solved
- For:
- Yade Edit question
- Assignee:
- No assignee Edit question
- Solved by:
- JINSUN LEE
- Solved:
- Last query:
- Last reply: