Re: [julia-users] Re: Vector Field operators (gradient, divergence, curl) in Julia

2016-09-16 Thread Matjaz Licer
Thank you all!

On 14 September 2016 at 00:41, Steven G. Johnson 
wrote:

> Both ForwardDiff and ReverseDiff source solve a different problem (taking
> the derivative of a user-supplied function f(x)).  The Matlab and NumPy
> gradient functions, instead, take an array (not a function) and compute
> differences of adjacent elements of the array, returning a new array.
>


[julia-users] Re: Vector Field operators (gradient, divergence, curl) in Julia

2016-09-13 Thread Steven G. Johnson
Both ForwardDiff and ReverseDiff source solve a different problem (taking 
the derivative of a user-supplied function f(x)).  The Matlab and NumPy 
gradient functions, instead, take an array (not a function) and compute 
differences of adjacent elements of the array, returning a new array.


[julia-users] Re: Vector Field operators (gradient, divergence, curl) in Julia

2016-09-13 Thread Christoph Ortner
Fast to implement, only moderately fast for execution; I switch to 
ReverseDiffSource


[julia-users] Re: Vector Field operators (gradient, divergence, curl) in Julia

2016-09-13 Thread Chris Rackauckas
For gradients, check out ForwardDiff. It'll give you really fast 
calculations.

On Tuesday, September 13, 2016 at 4:29:59 AM UTC-7, MLicer wrote:
>
> Dear all,
>
> i am wondering if there exists Julia N-dimensional equivalents to Numpy 
> vector field operators like gradient, divergence and curl, for example:
>
> np.gradient(x)
>
> Thanks so much,
>
> Cheers!
>


[julia-users] Re: Vector Field operators (gradient, divergence, curl) in Julia

2016-09-13 Thread Steven G. Johnson
See https://github.com/JuliaLang/julia/issues/16113