Unable to set optimset
Show older comments
Hello,
I am using R2011b (7.13.0.564), 32-bit (glnx86) on Ubuntu 12.04LTS (since I installed my Ubuntu at 32 bit).
I try to set the options through optimset as follows:
x0 = 3e-7;
options = optimset('Display','iter','TolX',1e-5);
options.TolX = 1.000000e-07;
[x, resnorm] = lsqnonlin(@test18062014,x0);
x, resnorm
Here the function test18062014 yields a vector of size 4 with a minimum sum of squares around 2.67e-7. Thee output is as follows:
Local minimum possible.
lsqnonlin stopped because the size of the current step is less than
the default value of the step size tolerance.
<stopping criteria details>
x =
3.0904e-07
resnorm =
8.4427
Optimization stopped because the norm of the current step, 3.094088e-09,
is less than options.TolX = 1.000000e-06.
Optimization Metric Options
norm(step) = 3.09e-09 TolX = 1e-06 (default)
>>
There are two things I don't understand.
1. Why is TolX not changed? I even changed it twice, just to make sure.
2. How come I end up at 3.09e-7, which is further away (but rather close to) the minimum at 2.67e-7?
I am mainly worried about the first one (including why I don't get to see any iterations, despite asking for it).
Thank you in advance!
Accepted Answer
More Answers (0)
Categories
Find more on Programming in Help Center and File Exchange
Products
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!