https://github.com/certik/minpack
Library for solving nonlinear equations and nonlinear least squares problems
https://github.com/certik/minpack
Last synced: 5 months ago
JSON representation
Library for solving nonlinear equations and nonlinear least squares problems
- Host: GitHub
- URL: https://github.com/certik/minpack
- Owner: certik
- License: other
- Created: 2012-02-25T02:25:56.000Z (over 14 years ago)
- Default Branch: master
- Last Pushed: 2023-01-28T04:36:51.000Z (over 3 years ago)
- Last Synced: 2025-03-27T16:37:05.427Z (over 1 year ago)
- Language: Fortran
- Homepage: http://www.netlib.org/minpack/
- Size: 249 KB
- Stars: 33
- Watchers: 6
- Forks: 10
- Open Issues: 5
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
The modern minpack development has moved to https://github.com/fortran-lang/minpack.
See the issue https://github.com/fortran-lang/minpack/issues/8 for details about the move.
This repository is using Minpack in the original fixed-form, and we use it to test the LFortran compiler with older F77 style code.
Minpack
=======
Information
-----------
This repository contains the original double precision Minpack from netlib.org,
together with CMake makefiles and examples.
About Minpack
-------------
Minpack includes software for solving nonlinear equations and
nonlinear least squares problems. Five algorithmic paths each include
a core subroutine and an easy-to-use driver. The algorithms proceed
either from an analytic specification of the Jacobian matrix or
directly from the problem functions. The paths include facilities for
systems of equations with a banded Jacobian matrix, for least squares
problems with a large amount of data, and for checking the consistency
of the Jacobian matrix with the functions.
Jorge Moré, Burt Garbow, and Ken Hillstrom at Argonne National Laboratory.
Build with `fortran-lang/fpm `_
--------------------------------------------------------------------
Fortran Package Manager (fpm) is a great package manager and build system for Fortran.
You can build using provided ``fpm.toml``:
.. code-block:: bash
fpm build
fpm run --example
To use ``minpack`` within your fpm project, add the following to your ``fpm.toml`` file:
.. code-block:: toml
[dependencies]
minpack = { git="https://github.com/certik/minpack.git" }
Documentation
-------------
Minpack contains 4 subroutines for solution of systems of nonlinear equations:
* ``hybrd``, ``hybrd1``: Jacobian matrix is calculated by a forward difference
approximation
* ``hybrj``, ``hybrj1``: Jacobian matrix is provided by the user
and 6 subroutines for nonlinear least squares problems:
* ``lmdif``, ``lmdif1``: Jacobian matrix is calculated by a forward difference
approximation
* ``lmder``, ``lmder1``: Jacobian matrix is provided by the user
* ``lmstr``, ``lmstr1``: Jacobian matrix is provided by the user, one row per
call (uses less memory)
The routines without ``1`` in the name expose all parameters to the user (`core
subroutines`), routines with ``1`` only expose the essential parameters and set
default values for the rest (`easy-to-use driver`). Finally:
* ``chkder``: checks the consistency of the Jacobian matrix with the functions
More general documentation is given in
the 1980 Argonne technical report written by the authors of Minpack,
`Chapters 1-3 `_.
The `Chapter 4 `_ (also available in
the file ``ex/file06``) contains detailed documentation for all these routines
together with an example of usage. Ready to use examples of usage are in the
``examples`` directory.
Other files in the ``ex`` directory are original examples of usage of various
routines (single and double precision), but are not compiled by default.