Skip to content

Commit

Permalink
Merge pull request #613 from frankschae/bb_docs
Browse files Browse the repository at this point in the history
Update note on sensitivity analysis for hybrid DEs
  • Loading branch information
ChrisRackauckas authored Aug 27, 2021
2 parents c4f2ddb + 36fc6f7 commit 4bcfc23
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 10 deletions.
15 changes: 10 additions & 5 deletions docs/src/examples/bouncing_ball.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,13 @@ an optimal drag coefficient.

## Note on Sensitivity Methods

Only some continuous adjoint sensitivities are compatible with callbacks, namely
`BacksolveAdjoint` and `InterpolatingAdjoint`. All methods based on discrete sensitivity
analysis via automatic differentiation, like `ReverseDiffAdjoint`, `TrackerAdjoint`, or
`ForwardDiffAdjoint` are the methods to use (and `ReverseDiffAdjoint` is demonstrated above),
are compatible with events. This applies to SDEs, DAEs, and DDEs as well.
The continuous adjoint sensitivities `BacksolveAdjoint`, `InterpolatingAdjoint`,
and `QuadratureAdjoint` are compatible with events for ODEs. `BacksolveAdjoint` and
`InterpolatingAdjoint` can also handle events for SDEs. Use `BacksolveAdjoint` if
the event terminates the time evolution and several states are saved. Currently,
the continuous adjoint sensitivities do not support multiple events per time point.

All methods based on discrete sensitivity analysis via automatic differentiation,
like `ReverseDiffAdjoint`,m`TrackerAdjoint`, or `ForwardDiffAdjoint` are the methods
to use (and `ReverseDiffAdjoint` is demonstrated above), are compatible with events.
This applies to SDEs, DAEs, and DDEs as well.
15 changes: 10 additions & 5 deletions docs/src/examples/hybrid_diffeq.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,13 @@ Flux.train!(loss_n_ode, ps, data, ADAM(0.05), cb = cba)

## Note on Sensitivity Methods

Only some continuous adjoint sensitivities are compatible with callbacks, namely
`BacksolveAdjoint` and `InterpolatingAdjoint`. All methods based on discrete sensitivity
analysis via automatic differentiation, like `ReverseDiffAdjoint`, `TrackerAdjoint`, or
`ForwardDiffAdjoint` are the methods to use (and `ReverseDiffAdjoint` is demonstrated above),
are compatible with events. This applies to SDEs, DAEs, and DDEs as well.
The continuous adjoint sensitivities `BacksolveAdjoint`, `InterpolatingAdjoint`,
and `QuadratureAdjoint` are compatible with events for ODEs. `BacksolveAdjoint` and
`InterpolatingAdjoint` can also handle events for SDEs. Use `BacksolveAdjoint` if
the event terminates the time evolution and several states are saved. Currently,
the continuous adjoint sensitivities do not support multiple events per time point.

All methods based on discrete sensitivity analysis via automatic differentiation,
like `ReverseDiffAdjoint`,m`TrackerAdjoint`, or `ForwardDiffAdjoint` are the methods
to use (and `ReverseDiffAdjoint` is demonstrated above), are compatible with events.
This applies to SDEs, DAEs, and DDEs as well.

0 comments on commit 4bcfc23

Please sign in to comment.