Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Convergence of SAMIN is converted to non-convergence. #1100

Open
sgaure opened this issue Jul 22, 2024 · 0 comments
Open

Convergence of SAMIN is converted to non-convergence. #1100

sgaure opened this issue Jul 22, 2024 · 0 comments

Comments

@sgaure
Copy link

sgaure commented Jul 22, 2024

using Optim

f(x) = cos(prod(x)) + (sum(x)-0.5)^2

opt = Optim.optimize(f, [-pi,-pi], [pi,pi], [0.3,0.4], SAMIN(verbosity=1),
               Optim.Options(iterations=1000000))

yields "normal convergence" from SAMIN, but convergence failure from optimize:

================================================================================
SAMIN results
==> Normal convergence <==
total number of objective function evaluations: 15001

     Obj. value:     -1.0000000000

       parameter      search width
        -1.54000           0.00000 
         2.04000           0.00000 
================================================================================

 * Status: failure

 * Candidate solution
    Final objective value:     -1.000000e+00

 * Found with
    Algorithm:     SAMIN

 * Convergence measures
    |x - x'|               = 8.88e-07 ≤ 1.0e-06
    |x - x'|/|x'|          = NaN ≰ 0.0e+00
    |f(x) - f(x')|         = 5.83e-13 ≤ 1.0e-12
    |f(x) - f(x')|/|f(x')| = NaN ≰ 0.0e+00
    |g(x)|                 = NaN ≰ 0.0e+00

 * Work counters
    Seconds run:   0  (vs limit Inf)
    Iterations:    15001
    f(x) calls:    15001
    ∇f(x) calls:   0
[429524aa] Optim v1.9.4
v"1.11.0-beta2"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant