You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
sol = solve(prob, Rodas4(autodiff=false); u0 = prob.u0 .+ 0.5);
57
+
prob = ODEProblem(ssys, [], (0, 8))
58
+
sol = solve(prob, Rodas4(autodiff=false));
66
59
@test SciMLBase.successful_retcode(sol)
67
60
68
61
Multibody.render(flexible_rope, sol, y = -3, x = -6, z = -6, lookat=[0, -3, 0], filename = "flexible_rope.gif") # May take long time for n>=10
@@ -73,7 +66,7 @@ Multibody.render(flexible_rope, sol, y = -3, x = -6, z = -6, lookat=[0, -3, 0],
73
66
74
67
75
68
## A chain suspended in two points
76
-
When a [`Rope`](@ref) component is used to model a chain that is suspended between two fixed points, a kinematic loop (kinematic chain) is formed. To break this loop, we introduce a spring in one end.
69
+
When a [`Rope`](@ref) component is used to model a chain that is suspended between two fixed points, a kinematic loop is formed. To break this loop, we introduce a spring in one end.
Copy file name to clipboardExpand all lines: src/components.jl
+9-1Lines changed: 9 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -414,8 +414,14 @@ There are three different methods of adding damping to the rope:
414
414
- Damping in the stretching direction of the rope, controlled by the parameter `d`.
415
415
- Damping in flexing of the rope, modeled as viscous friction in the joints between the links, controlled by the parameter `d_joint`.
416
416
- Air resistance to the rope moving through the air, controlled by the parameter `air_resistance`. This damping is quadratic in the velocity (``f_d ~ -||v||v``) of each link relative to the world frame.
417
+
418
+
## Rendering
419
+
- `color = [255, 219, 120, 255]./255`
420
+
- `radius = 0.05f0`
421
+
- `jointradius=0`
422
+
- `jointcolor=color`
417
423
"""
418
-
functionRope(; name, l =1, dir = [0,-1, 0], n =10, m =1, c =0, d=0, air_resistance=0, d_joint =0, cutspherical =false, cutprismatic=false, color = [255, 219, 120, 255]./255, radius =0.05f0, kwargs...)
424
+
functionRope(; name, l =1, dir = [0,-1, 0], n =10, m =1, c =0, d=0, air_resistance=0, d_joint =0, cutspherical =false, cutprismatic=false, color = [255, 219, 120, 255]./255, radius =0.05f0, jointradius=0, jointcolor=color, kwargs...)
419
425
420
426
@assert n >=1
421
427
systems =@namedbegin
@@ -433,6 +439,8 @@ function Rope(; name, l = 1, dir = [0,-1, 0], n = 10, m = 1, c = 0, d=0, air_res
0 commit comments