Skip to main content

Brent''s method for univariate function optimization

Project description

brent-search

Brent's method for univariate function optimization.

Example

from brent_search import brent

def func(x, s):
  return (x - s)**2 - 0.8

r = brent(lambda x: func(x, 0), -10, 10)
print(r)

The output should be

(0.0, -0.8, 6)

Install

From command line, enter

pip install brent-search

Testing

python -c "import brent_search; brent_search.test()"

Documentation

Documentation

Authors

Acknowledgements

License

This project is licensed under the MIT License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

brent-search-2.0.1.tar.gz (8.8 kB view hashes)

Uploaded Source

Built Distribution

brent_search-2.0.1-py2.py3-none-any.whl (10.1 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page