Skip to content

Commit 65d6954

Browse files
committed
tidy up
1 parent f17016c commit 65d6954

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

docs/src/examples/suspension.md

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,6 @@ defs = [
170170
display(sort(unknowns(ssys), by=string))
171171
172172
prob = ODEProblem(ssys, defs, (0, 2))
173-
# sol.u[1] = [0.17054946565059462, -0.6015077878288565, 0.274732819217001]
174173
sol = solve(prob, FBDF(autodiff=true))
175174
@test SciMLBase.successful_retcode(sol)
176175
rms(x) = sqrt(sum(abs2, x) / length(x))
@@ -259,7 +258,6 @@ display(sort(unknowns(ssys), by=string))
259258
prob = ODEProblem(ssys, defs, (0, 4))
260259
sol = solve(prob, FBDF(autodiff=true), initializealg = ShampineCollocationInit())
261260
@test SciMLBase.successful_retcode(sol)
262-
# first(Multibody.render(model, sol, 0, show_axis=true, x=-1.5, y=0.0, z=0.0))
263261
```
264262

265263
```@example suspension
@@ -363,7 +361,6 @@ defs = [
363361
# model.body_upright.prismatic_y.s => 0.17
364362
# model.body_upright.prismatic_y.v => 0.14
365363
366-
367364
# vec(ori(model.mass.frame_a).R .=> I(3))
368365
# vec(ori(model.excited_suspension_r.suspension.r123.jointUSR.frame_a).R .=> I(3))
369366
]
@@ -372,6 +369,8 @@ display(sort(unknowns(ssys), by=string))
372369
373370
prob = ODEProblem(ssys, defs, (0, 4))
374371
sol = solve(prob, FBDF(autodiff=false), initializealg = ShampineCollocationInit())#, u0 = prob.u0 .+ 1e-6 .* randn.())
375-
@show SciMLBase.successful_retcode(sol)
376-
first(Multibody.render(model, sol, 0, show_axis=true, x=-1.5, y=0.0, z=0.0))
377-
```
372+
@test SciMLBase.successful_retcode(sol)
373+
Multibody.render(model, sol, show_axis=false, x=-1.5, y=0.3, z=0.0, lookat=[0,0.1,0.0], timescale=3, filename="suspension_halfcar_wheels.gif") # Video
374+
```
375+
376+
![suspension with wheels](suspension_halfcar_wheels.gif)

0 commit comments

Comments
 (0)