An iteration history printer
Project description
IterPrinter: A simple iteration history printer
When using iterative numerical algorithms it is common to print after each iteration a message so that a user can monitor convergence and catch any bugs. For example, in the demo.py file
iter │ b - a │ f(c) │ a │ b │
──────┼────────────┼────────────┼──────────────────┼──────────────────┤
0 │ 4.000e+00 │ 2.000e+00 │ 0.0000000000e+00 │ 4.0000000000e+00 │
1 │ 2.000e+00 │ -1.000e+00 │ 0.0000000000e+00 │ 2.0000000000e+00 │
2 │ 1.000e+00 │ 2.500e-01 │ 1.0000000000e+00 │ 2.0000000000e+00 │
3 │ 5.000e-01 │ -4.375e-01 │ 1.0000000000e+00 │ 1.5000000000e+00 │
4 │ 2.500e-01 │ -1.094e-01 │ 1.2500000000e+00 │ 1.5000000000e+00 │
5 │ 1.250e-01 │ 6.641e-02 │ 1.3750000000e+00 │ 1.5000000000e+00 │
6 │ 6.250e-02 │ -2.246e-02 │ 1.3750000000e+00 │ 1.4375000000e+00 │
7 │ 3.125e-02 │ 2.173e-02 │ 1.4062500000e+00 │ 1.4375000000e+00 │
8 │ 1.562e-02 │ -4.272e-04 │ 1.4062500000e+00 │ 1.4218750000e+00 │
9 │ 7.812e-03 │ 1.064e-02 │ 1.4140625000e+00 │ 1.4218750000e+00 │
10 │ 3.906e-03 │ 5.100e-03 │ 1.4140625000e+00 │ 1.4179687500e+00 │
11 │ 1.953e-03 │ 2.336e-03 │ 1.4140625000e+00 │ 1.4160156250e+00 │
A simple iteration history printer
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
iterprinter-0.1.tar.gz
(2.4 kB
view details)
Built Distribution
File details
Details for the file iterprinter-0.1.tar.gz
.
File metadata
- Download URL: iterprinter-0.1.tar.gz
- Upload date:
- Size: 2.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 695de5fc676c7e3bb65feb0d2d4e8d204c5be6b66570adadba5a9fc157134ef4 |
|
MD5 | a0774382ef9061845c04ce33445b43d0 |
|
BLAKE2b-256 | 548f7f879d42b56d6feb0848179839ef06ec83825b7ebdd4d3e5d775f05fcd15 |
File details
Details for the file iterprinter-0.1-py3-none-any.whl
.
File metadata
- Download URL: iterprinter-0.1-py3-none-any.whl
- Upload date:
- Size: 2.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.30.0 CPython/3.7.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4b311231b2a3d676be5abfdd1a4cfc57b6e2f35bdfacfa1800b005821b7fc589 |
|
MD5 | cc02cef8fbee9c2f039f5d125fc7d24a |
|
BLAKE2b-256 | 74be22199ab6541ca299544ce5727e1c76c0495c8bd307969105f9b2040f99a4 |