-
Notifications
You must be signed in to change notification settings - Fork 71
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
ForwardDiff with min, max, and clamp #640
Comments
Thx for opening an issue. What version of IntervalArithmetic are you using? On 0.22.11 the example you gave returns an error, as it should since no one implemented the functions you describe. That being said, it would be nice it improve support for ForwardDiff. Then we must also address the question of decorations. |
Thanks for the quick reply! I was using an old version of IntervalArithmetic. I updated and confirmed that I now get an error when running that code. In terms of adding support for these functions, do you want us to submit a pull request? What are your recommendations for decorations? |
A PR would be great :) We'll review the PR in more details, but there is a bunch of subtleties to take into account:
I hope this is not overwhelming, please let us know if you need help or advice about anything. |
Hi! We are working on a textbook chapter on reachability analysis and are interested in support for intervals when using ForwardDiff.jl to compute gradients and hessians of functions that use the
min
,max
, andclamp
. The current behavior with these functions does not cause an error but is incorrect. We have written the functions below to correct for this. These functions could be added toIntervalArithmeticForwardDiffExt.jl
.Example:
Current output:
Correct output using code above:
The text was updated successfully, but these errors were encountered: