The template that I use for this kind of request, and for bug reports, is:
What I did
What I expected to happen when I did that
What actually happened
You’ve told us 1. To help you, we need to know 2 and 3 as well. Did Optim throw an error? Does this function have a known minimum that Optim didn’t find? Or is there some other reason that you suspect there is an error in the code?
Oh right. I think you’re trying to optimise a multivariate function, but using the syntax for a univariate one. Here’s the relevant part of the manual. I haven’t used Fminbox myself, and I don’t know if it works with Nelder-Mead.
Hello man … i cannot post my entire code because needs a .dat files …
a link from google drive in the beggining have my entire code.
i use interpolate, so i have .dat files
I am just guessing but it seems that you did not use the correct syntax for Fminbox, which should be Fminbox(GradientDescent()), not Fminbox{GradientDescent}()