Watch this Author's files
hi John, many thanks for the wonderful suite!
I met a problem when I use the function from the m-file. my code is:
H=hessian(@(p) @reg2002, [0.03 3 -5])
??? The following error occurred converting from function_handle to double:
Error using ==> double
Conversion to double from function_handle is not possible.
Error in ==> derivest at 330
f_x0(j) = fun(x0(j));
Error in ==> hessdiag at 59
[HD(ind),err(ind),finaldelta(ind)] = derivest( ...
Error in ==> hessian at 74
[hess,err] = hessdiag(fun,x0);
I don't what is wrong here. is there mistakes I made? many thanks in advance.