Hello!
Pattern search should evaluate the function for 2*N times in each iteration, right? But it seems that it evaluates 4*N times in some iterations. I cannot figure out why. If you can provide an answer, it will be of great help to me because my function takes lots of time to evaluate. Thanks.
Here is how I set the options:
option=psoptimset('Display','Iter',... 'TolMesh',sqrt(1e-5),... 'Cache','on',... 'CacheTol',sqrt(1e-5),... 'CompletePoll','on',... 'PollMethod','MADSPositiveBasis2N',... 'OutPutFcns',@(a,b,c)Outfcn(a,b,c,'ps'));
Some outputs are below. My N=12. As you can see, whenever it goes from refine mesh to a successful poll, it evaluates the function for 48 times instead of 24… This means that for J iterations, it actually evaluates the function for more than 24*J times.
Iter f-count f(x) MeshSize Method 0 1 18.0938 1 1 49 8.74728 1 Successful Poll 2 97 5.93612 1 Successful Poll 3 121 5.93612 0.25 Refine Mesh 4 145 5.93612 0.0625 Refine Mesh 5 193 3.73289 0.25 Successful Poll 6 217 3.73289 0.0625 Refine Mesh 7 265 3.62688 0.25 Successful Poll 8 313 2.97285 1 Successful Poll 9 337 2.97285 0.25 Refine Mesh 10 361 2.97285 0.0625 Refine Mesh 11 409 2.937 0.25 Successful Poll 12 433 2.937 0.0625 Refine Mesh 13 457 2.937 0.01562 Refine Mesh 14 481 2.937 0.003906 Refine Mesh 15 529 2.68362 0.01562 Successful Poll 16 577 2.65236 0.0625 Successful Poll
Best Answer