update: continuum snake timestep and damping const.
@@ -28,10 +28,6 @@ def run_snake(
# Simulation parameters
period = 2
final_time = (11.0 + 0.01) * period
- time_step = 8e-6
- total_steps = int(final_time / time_step)
- rendering_fps = 60
- step_skip = int(1.0 / (rendering_fps * time_step))
# setting up test params
n_elem = 50
@@ -103,13 +99,21 @@ def run_snake(
)
# add damping
+ # old damping model (deprecated in v0.3.0) values
+ # damping_constant = 2e-3
+ # time_step = 8e-6
damping_constant = 2e-3
+ time_step = 1e-4
snake_sim.dampen(shearable_rod).using(
ExponentialDamper,
damping_constant=damping_constant,
time_step=time_step,
)
+ total_steps = int(final_time / time_step)
+ rendering_fps = 60
+ step_skip = int(1.0 / (rendering_fps * time_step))
+
# Add call backs
class ContinuumSnakeCallBack(CallBackBaseClass):
"""
