Skip to content

Commit

Permalink
explicit g again
Browse files Browse the repository at this point in the history
  • Loading branch information
baggepinnen committed Jun 24, 2024
1 parent 2b26236 commit 6c543c6
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions test/runtests.jl
Original file line number Diff line number Diff line change
Expand Up @@ -708,7 +708,7 @@ eqs = [connect(world.frame_b, freeMotion.frame_a)
ssys = structural_simplify(IRSystem(model))
@test length(unknowns(ssys)) == 12

prob = ODEProblem(ssys, [collect(body.w_a .=> [0, 0, 0]); collect(body.v_0 .=> [0, 0, 0]); ], (0, 10))
prob = ODEProblem(ssys, [world.g=>9.81; collect(body.w_a .=> [0, 0, 0]); collect(body.v_0 .=> [0, 0, 0]); ], (0, 10))

sol = solve(prob, Rodas4())
doplot() && plot(sol, idxs = body.r_0[2], title = "Free falling body")
Expand All @@ -732,7 +732,7 @@ eqs = [connect(world.frame_b, freeMotion.frame_a)
ssys = structural_simplify(IRSystem(model))
@test length(unknowns(ssys)) == 12

prob = ODEProblem(ssys, [collect(body.w_a .=> [0, 1, 0]); collect(body.v_0 .=> [0, 0, 0]); ], (0, 10))
prob = ODEProblem(ssys, [world.g=>9.81; collect(body.w_a .=> [0, 1, 0]); collect(body.v_0 .=> [0, 0, 0]); ], (0, 10))

sol = solve(prob, Rodas4())
doplot() && plot(sol, idxs = body.r_0[2], title = "Free falling body")
Expand All @@ -752,6 +752,7 @@ ssys = structural_simplify(IRSystem(model))
@test length(unknowns(ssys)) == 12

prob = ODEProblem(ssys, [
world.g=>9.81;
collect(body.w_a .=> [0, 1, 0]);
collect(body.v_0 .=> [0, 0, 0]);
], (0, 10))
Expand Down

0 comments on commit 6c543c6

Please sign in to comment.