ForwardDiff.jl
ForwardDiff.jl copied to clipboard
Forward Mode Automatic Differentiation for Julia
It would be great to have the API for directional derivatives for functions from ℝⁿ to ℝⁿ. I keep coming back to this problem and I can only guess that...
Different amounts of computational noise in the value and partials of a dual number has the potential to corrupt even NaN-safe computations. Minimum working example: ```julia using ForwardDiff, LinearAlgebra #...
`norm` is not differentiable at 0, so at best you can return a subgradient. It appears that the subgradient is 1.0 at 0.0 (and -1.0 at -0.0). ```julia julia> ForwardDiff.gradient(norm,...
For the following function A(η::Array) = η[1:2]'*(reshape(η[2+1:end],(2,2))\η[1:2]), I observed a weird behaviour with ForwardDiff. Suppose that we want to evaluate the gradient at x = [2.0, 2.0, 1.0, 0.0, 0.0,...
The documentation currently [describes](http://www.juliadiff.org/ForwardDiff.jl/stable/dev/contributing.html#Adding-New-Derivative-Definitions-1) how to add custom derivative definitions using DiffRules. However, it seems that this only covers basic custom derivatives. For example, I don't know how this approach...
The following should be a simple calculation, but uses 2GB (!) in the compilation process...: ```jl julia> using ForwardDiff, StaticArrays, IntervalArithmetic julia> f(x) = 2 .* x .* x f...
Hi Team, This is my attempt to extend all `SArray` functionality to `FieldVectors`. This resolves issue #305. The basic approach mostly involves replacing `SArray` with `Union{FieldVector, SArray}` in method definitions....
If I understood #157 correctly, ForwardDiff should be able to differentiate a real-valued function with complex arguments. When I try this, I get the following error instead: ``` julia> ForwardDiff.gradient(v...
Is there any plan to support the Laplacian out of the box? I like the simplicity of ForwardDiff.jl, but right now I am defining the Laplacian operator as ```julia laplacian(f::Function,...
The gradient of of the matrix valued function `F(X) = log(X)` or the Hessian of the scalar valued function `f(X) = tr(X * log(X))` has an analytic form e.g. Equation...