Skip to content

Move sys._update_params(params) before TimeResponseData return when nstate == 0 #774

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 9, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions control/iosys.py
Original file line number Diff line number Diff line change
Expand Up @@ -1779,6 +1779,9 @@ def input_output_response(
else:
noutputs = sys.noutputs

# Update the parameter values
sys._update_params(params)

#
# Define a function to evaluate the input at an arbitrary time
#
Expand Down Expand Up @@ -1816,9 +1819,6 @@ def ufun(t):
output_labels=sys.output_index, input_labels=sys.input_index,
transpose=transpose, return_x=return_x, squeeze=squeeze)

# Update the parameter values
sys._update_params(params)

# Create a lambda function for the right hand side
def ivp_rhs(t, x):
return sys._rhs(t, x, ufun(t))
Expand Down