Skip to content

Commit

Permalink
tests for some control rate issues
Browse files Browse the repository at this point in the history
  • Loading branch information
robfalck committed Jul 26, 2023
1 parent 14a28af commit 8480d65
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -126,6 +126,7 @@ def test_brachistochrone_control_rate_targets_gauss_lobatto(self):

p.model.add_subsystem('phase0', phase)

phase.timeseries_options['include_control_rates'] = True
phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))

phase.add_state('x', rate_source='xdot',
Expand Down Expand Up @@ -411,6 +412,7 @@ def test_brachistochrone_control_rate_targets_radau(self):
phase = dm.Phase(ode_class=BrachistochroneRateTargetODE,
transcription=dm.Radau(num_segments=10))

phase.timeseries_options['include_control_rates'] = True
p.model.add_subsystem('phase0', phase)

phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ def test_brachistochrone_vector_state_path_constraints_radau_partial_indices(sel

p.model.add_subsystem('phase0', phase)

phase.timeseries_options['include_control_rates'] = True
phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))

phase.add_state('pos', fix_initial=True, fix_final=True)
Expand Down Expand Up @@ -144,6 +145,7 @@ def test_brachistochrone_vector_ode_path_constraints_radau_partial_indices(self)
phase = dm.Phase(ode_class=BrachistochroneVectorStatesODE,
transcription=dm.Radau(num_segments=20, order=3))

phase.timeseries_options['include_control_rates'] = True
p.model.add_subsystem('phase0', phase)

phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))
Expand Down Expand Up @@ -257,6 +259,7 @@ def test_brachistochrone_vector_ode_path_constraints_radau_no_indices(self):
transcription=dm.Radau(num_segments=20, order=3))

p.model.add_subsystem('phase0', phase)
phase.timeseries_options['include_control_rates'] = True

phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))

Expand Down Expand Up @@ -369,6 +372,7 @@ def test_brachistochrone_vector_state_path_constraints_gl_partial_indices(self):
phase = dm.Phase(ode_class=BrachistochroneVectorStatesODE,
transcription=dm.GaussLobatto(num_segments=20, order=3))

phase.timeseries_options['include_control_rates'] = True
p.model.add_subsystem('phase0', phase)

phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))
Expand Down Expand Up @@ -598,6 +602,7 @@ def test_brachistochrone_vector_ode_path_constraints_gl_no_indices(self):
phase = dm.Phase(ode_class=BrachistochroneVectorStatesODE,
transcription=dm.GaussLobatto(num_segments=20, order=3))

phase.timeseries_options['include_control_rates'] = True
p.model.add_subsystem('phase0', phase)

phase.set_time_options(fix_initial=True, duration_bounds=(.5, 10))
Expand Down

0 comments on commit 8480d65

Please sign in to comment.