Skip to content

Commit

Permalink
use endpoint component for initial and final boundary constraints in …
Browse files Browse the repository at this point in the history
…radau new
  • Loading branch information
robfalck committed Nov 19, 2024
1 parent 1b597b7 commit 287dd7c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions dymos/utils/introspection.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ def _configure_constraint_introspection(phase):
con['shape'] = control_shape
con['units'] = get_rate_units(control_units, time_units, deriv=1) \
if con['units'] is None else con['units']
if birkhoff and constraint_type in ('initial', 'final'):
if (birkhoff or radau_new) and constraint_type in ('initial', 'final'):
con['constraint_path'] = f'boundary_vals.{var}'
else:
con['constraint_path'] = f'timeseries.{prefix}{var}'
Expand All @@ -241,7 +241,7 @@ def _configure_constraint_introspection(phase):
con['shape'] = control_shape
con['units'] = get_rate_units(control_units, time_units, deriv=2) \
if con['units'] is None else con['units']
if birkhoff and constraint_type in ('initial', 'final'):
if (birkhoff or radau_new) and constraint_type in ('initial', 'final'):
con['constraint_path'] = f'boundary_vals.{var}'
else:
con['constraint_path'] = f'timeseries.{prefix}{var}'
Expand All @@ -260,7 +260,7 @@ def _configure_constraint_introspection(phase):
con['shape'] = meta['shape']
con['units'] = meta['units']

if birkhoff and constraint_type in ('initial', 'final'):
if (birkhoff or radau_new) and constraint_type in ('initial', 'final'):
con['constraint_path'] = f'boundary_vals.{var}'
else:
con['constraint_path'] = f'timeseries.{con["constraint_name"]}'
Expand Down

0 comments on commit 287dd7c

Please sign in to comment.