OpenMDAO / dymos

Open Source Optimization of Dynamic Multidisciplinary Systems
Apache License 2.0
202 stars 65 forks source link

Fixed an issue where applying DirectSolver to StateIndependentsComp was breaking when used with other linear solvers under MPI. #1020

Closed robfalck closed 9 months ago

robfalck commented 9 months ago

Summary

Previously dymos automatically assigned a DirectSolver to StateIndependentsComp when necessary, but this was problematic depending on the layout of the systems on MPI (mostly due to the presence of distributed systems within the ODE.

Dymos needs solvers on phases in the following conditions:

Furthermore, if a Trajectory has its phases under a ParallelGroup and there are explicit connections between these phases, some form of solver is required to ensure that the inputs/ouputs between the phases are consistent. By default, Dymos will add NonlinearBlockJac and PETScKrylov as the default solvers in trajectory.phases when this is the case.

The user can bypass this behavior by assigning some other solver to the phase or Trajectory.phases. If the user really truly wants to use a RunOnce solver in these situations, then the new Trajectory and Phase option auto_solvers should be set to False.

Adds new options to Trajectory:

New options for Phase

Related Issues

Backwards incompatibilities

None

New Dependencies

None

review-notebook-app[bot] commented 9 months ago

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

coveralls commented 9 months ago

Coverage Status

coverage: 92.025%. first build when pulling 0e041db215e088975907f9ebdad5b7543514f8d7 on robfalck:i1009_2 into 10c2df0ba7e498d155890814f82ddee70c7bec66 on OpenMDAO:master.