bug-gsl
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-gsl] [bug #39369] Nonlinear least squares solver fails when MINPACK


From: Patrick Alken
Subject: [Bug-gsl] [bug #39369] Nonlinear least squares solver fails when MINPACK succeeds
Date: Sun, 30 Jun 2013 08:56:17 +0000
User-agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:20.0) Gecko/20100101 Firefox/20.0

URL:
  <http://savannah.gnu.org/bugs/?39369>

                 Summary: Nonlinear least squares solver fails when MINPACK
succeeds
                 Project: GNU Scientific Library
            Submitted by: psa
            Submitted on: Sun 30 Jun 2013 08:56:15 AM GMT
                Category: None
                Severity: 3 - Normal
        Operating System: 
                  Status: None
             Assigned to: psa
             Open/Closed: Open
                 Release: 
         Discussion Lock: Any

    _______________________________________________________

Details:

Although the GSL implementation of LM nonlinear least squares follows MINPACK,
there are some cases when the GSL method won't converge but MINPACK does. I
believe this is related to the 'xtol' convergence test in MINPACK's lmder
routine which seems to be missing from the GSL implementation.

Attached is a test program and data which illustrate the problem.

Scaling the input data to be close to magnitude 1 allows GSL to find a
solution. However MINPACK finds a solution whether or not the data is scaled.

Sample output:

--- USE_SCALE = 1 ---

> ./test_lm < input.dat
6979 data points read
=== GSL SOLUTION ===
S =       1.0018817       1.0024550       0.9994202
O =     -14.2133707       2.3442451       6.3475414
A =      89.9459953      90.0165637      89.9379515
=== LEVMAR SOLUTION ===
S =       1.0018817       1.0024552       0.9994202
O =     -14.2136590       2.3391624       6.3479131
A =      89.9459872      90.0165636      89.9379575

--- USE_SCALE = 0 ---
>./test_lm < input.dat    
6979 data points read
compute_model: GSL error: s = 27
=== LEVMAR SOLUTION ===
S =       1.0018817       1.0024552       0.9994202
O =     -14.2136530       2.3390507       6.3479175
A =      89.9459871      90.0165636      89.9379577




    _______________________________________________________

File Attachments:


-------------------------------------------------------
Date: Sun 30 Jun 2013 08:56:15 AM GMT  Name: input.dat  Size: 526kB   By: psa

<http://savannah.gnu.org/bugs/download.php?file_id=28452>
-------------------------------------------------------
Date: Sun 30 Jun 2013 08:56:15 AM GMT  Name: test_lm.c  Size: 5kB   By: psa

<http://savannah.gnu.org/bugs/download.php?file_id=28451>

    _______________________________________________________

Reply to this item at:

  <http://savannah.gnu.org/bugs/?39369>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]