Skip to content

Commit

Permalink
Minor adjustments.
Browse files Browse the repository at this point in the history
  • Loading branch information
moorepants committed Jul 6, 2024
1 parent 5350d54 commit 657cdf2
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions examples-gallery/plot_one_legged_time_trial.py
Original file line number Diff line number Diff line change
Expand Up @@ -698,7 +698,6 @@ def plot_configuration(q_vals, p_vals, ax=None):
knee_top_mus.e: (0.0, 1.0),
h: (0.0, 0.1),
}
sm.pprint(bounds)

# %%
# Instantiate the Optimal Control Problem
Expand Down Expand Up @@ -746,7 +745,7 @@ def plot_configuration(q_vals, p_vals, ax=None):
xs, us, ps, h_val= parse_free(solution, len(state_vars),
4, num_nodes,
variable_duration=True)
print('Optimal value h:', solution[-1])
print('Optimal value h:', h_val)
print(info['status_msg'])

# %%
Expand Down Expand Up @@ -829,7 +828,7 @@ def plot_sim_compact():
# Animation
# ---------
ax, fig, bike_lines, leg_lines, mus_lines, knee_circle, title_text = \
plot_configuration(q_0, p_vals)
plot_configuration(xs[:4, 0], p_vals)


def animate(i):
Expand Down

0 comments on commit 657cdf2

Please sign in to comment.