Open
Description
Would be nice to have a method for scalar functions, simply by dispatching on scalar initial values. In its simplest form, this could be:
nlsolve(f, initial_x::Number; kwargs...) =
nlsolve(x -> f(x[]), fill(initial_x); kwargs...)
which works by wrapping and unwrapping 0-dimensional arrays. (Note: this requires JuliaNLSolvers/NLSolversBase.jl#141.) That way, for the case of scalar functions you wouldn't have to go to the trouble of wrapping in an array yourself.
Of course, in the longer run you could have optimized methods for the scalar (0-dimensional) case.
Metadata
Metadata
Assignees
Labels
No labels