========
Overview
========
.. image:: https://img.shields.io/pypi/v/mathslib.svg
:target: https://pypi.python.org/pypi/mathslib
.. image:: https://readthedocs.org/projects/mathslib/badge/?version=latest
:target: https://mathslib.readthedocs.io/en/latest/?badge=latest
:alt: Documentation Status
`mathslib`__ is a compilation of Mathematical Functions and Algorithms. Unless credit was given all
of the functions were written by me. Relevant articles are also linked where the implementation is complex.
I have used most of these for `Project Euler`_.
See my website `ivl-projecteuler.com`_ for their implementation
See the full documentation `here`_
Breakdown
---------
+----------------+------------------------------------------------------------+
|numtheory.py | * phi(x) |
| | * phi_sieve(x) |
| | * phi_sum(x) |
| | * mobius(x) |
| | * mobius_k_sieve(limit, k) |
| | * count_k_free(n, k) |
| | * pythagorean_triples(limit, non_primitive) |
| | * count_primitive_pythagorean_triples(n) |
| | * k_smooth_numbers(max_prime, limit) |
| | * k_powerful(k, limit, count) |
| | * legendre_factorial(x) |
| | * tonelli_shanks(a, p) |
| | * chinese_remainder_theorem(a1, a2, n1, n2) |
| | * generalised_CRT(a1, a2, n1, n2) |
| | * frobenius_number(\*integers) |
| | * continued_fraction(x) |
| | * overall_fraction(x) |
+----------------+------------------------------------------------------------+
|primes.py | * prime_sieve(limit, block_size, segment, values) |
| | * is_prime(x) |
| | * prime_factors(x) |
| | * spf_sieve(x) |
| | * primepi(x) |
| | * primepi_sieve(x) |
| | * sum_of_primes(x) |
| | * fermat_primality_test(x) |
| | * miller_primality_test(n, millerrabin, numoftests) |
+----------------+------------------------------------------------------------+
|divisors.py | * divisors(x, proper) |
| | * divisor(x, n) |
| | * divisor_sieve(x, n) |
+----------------+------------------------------------------------------------+
|linalg.py | * gauss_jordan_elimination(matrix, augmentedpart) |
| | * solve(M, b) |
| | * inverse(matrix) |
| | * determinant(matrix) |
| | * matrix_addition(A, B, subtract) |
| | * identity(l, val) |
| | * concatenate(A, B) |
| | * argmax(alist) |
| | * fillmatrix(size, val) |
| | * matrix_mul(A, B) |
| | * matrix_pow(A, n) |
+----------------+------------------------------------------------------------+
|fib.py | * fibonacci(n, m) |
| | * fib_till(limit) |
| | * zeckendorf_representation(x) |
+----------------+------------------------------------------------------------+
|algorithms.py | * prims_algorithm(matrix) |
| | * dijkstras_algorithm(graph, start_node, INFINITY) |
| | * floyd_warshall_algorithm(graph, INFINITY) |
| | * knap_sack(values, weights, n, W, no_values) |
| | * knap_sack_values(values, weights, n, W, no_values) |
| | * BFS(g, start_node, end_node) |
| | * DFS(g, start_node, end_node) |
| | * convex_hull_gift_wrapping(pts) |
| | * convex_hull_DC(pts) |
+----------------+------------------------------------------------------------+
|simple.py | * bin_exp(a, b, c, n, m) |
| | * number_to_base(n, b) |
| | * extended_euclidean_algorithm(n, b) |
| | * lcm(a_list) |
| | * mod_division(a, b, m) |
| | * bisect(alist, goal) |
| | * is_clockwise(a, b, c) |
+----------------+------------------------------------------------------------+
.. _Project Euler: https://projecteuler.net
.. _ivl-projecteuler.com: https://ivl-projecteuler.com
.. _mathslib1: https://pypi.python.org/pypi/mathslib
.. _here: https://mathslib.readthedocs.io/en/latest/index.html
__ mathslib1_
Raw data
{
"_id": null,
"home_page": "https://github.com/igorvanloo/mathslib",
"name": "mathslib",
"maintainer": "",
"docs_url": null,
"requires_python": ">=3.7, <4",
"maintainer_email": "",
"keywords": "numbertheory,maths,algorithms",
"author": "Igor van Loo",
"author_email": "igorvanloo@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/07/c4/f8e5e18a3b2b8bfdf2df1832edb03b8d177df0f038fdc5541b8154ee5bd6/mathslib-3.1.0.tar.gz",
"platform": null,
"description": "========\r\nOverview\r\n========\r\n\r\n.. image:: https://img.shields.io/pypi/v/mathslib.svg\r\n :target: https://pypi.python.org/pypi/mathslib\r\n\r\n.. image:: https://readthedocs.org/projects/mathslib/badge/?version=latest\r\n :target: https://mathslib.readthedocs.io/en/latest/?badge=latest\r\n :alt: Documentation Status\r\n\r\n`mathslib`__ is a compilation of Mathematical Functions and Algorithms. Unless credit was given all\r\nof the functions were written by me. Relevant articles are also linked where the implementation is complex.\r\n\r\nI have used most of these for `Project Euler`_.\r\n \r\nSee my website `ivl-projecteuler.com`_ for their implementation\r\n\r\nSee the full documentation `here`_\r\n\r\nBreakdown\r\n---------\r\n+----------------+------------------------------------------------------------+\r\n|numtheory.py | * phi(x) |\r\n| | * phi_sieve(x) |\r\n| | * phi_sum(x) |\r\n| | * mobius(x) |\r\n| | * mobius_k_sieve(limit, k) |\r\n| | * count_k_free(n, k) |\r\n| | * pythagorean_triples(limit, non_primitive) |\r\n| | * count_primitive_pythagorean_triples(n) |\r\n| | * k_smooth_numbers(max_prime, limit) |\r\n| | * k_powerful(k, limit, count) |\r\n| | * legendre_factorial(x) |\r\n| | * tonelli_shanks(a, p) |\r\n| | * chinese_remainder_theorem(a1, a2, n1, n2) |\r\n| | * generalised_CRT(a1, a2, n1, n2) |\r\n| | * frobenius_number(\\*integers) |\r\n| | * continued_fraction(x) |\r\n| | * overall_fraction(x) |\r\n+----------------+------------------------------------------------------------+\r\n|primes.py | * prime_sieve(limit, block_size, segment, values) |\r\n| | * is_prime(x) |\r\n| | * prime_factors(x) |\r\n| | * spf_sieve(x) |\r\n| | * primepi(x) |\r\n| | * primepi_sieve(x) |\r\n| | * sum_of_primes(x) |\r\n| | * fermat_primality_test(x) |\r\n| | * miller_primality_test(n, millerrabin, numoftests) |\r\n+----------------+------------------------------------------------------------+\r\n|divisors.py | * divisors(x, proper) |\r\n| | * divisor(x, n) |\r\n| | * divisor_sieve(x, n) |\r\n+----------------+------------------------------------------------------------+\r\n|linalg.py | * gauss_jordan_elimination(matrix, augmentedpart) |\r\n| | * solve(M, b) |\r\n| | * inverse(matrix) |\r\n| | * determinant(matrix) |\r\n| | * matrix_addition(A, B, subtract) |\r\n| | * identity(l, val) |\r\n| | * concatenate(A, B) |\r\n| | * argmax(alist) |\r\n| | * fillmatrix(size, val) |\r\n| | * matrix_mul(A, B) |\r\n| | * matrix_pow(A, n) |\r\n+----------------+------------------------------------------------------------+\r\n|fib.py | * fibonacci(n, m) |\r\n| | * fib_till(limit) |\r\n| | * zeckendorf_representation(x) |\r\n+----------------+------------------------------------------------------------+\r\n|algorithms.py | * prims_algorithm(matrix) |\r\n| | * dijkstras_algorithm(graph, start_node, INFINITY) |\r\n| | * floyd_warshall_algorithm(graph, INFINITY) |\r\n| | * knap_sack(values, weights, n, W, no_values) |\r\n| | * knap_sack_values(values, weights, n, W, no_values) |\r\n| | * BFS(g, start_node, end_node) |\r\n| | * DFS(g, start_node, end_node) |\r\n| | * convex_hull_gift_wrapping(pts) |\r\n| | * convex_hull_DC(pts) |\r\n+----------------+------------------------------------------------------------+\r\n|simple.py | * bin_exp(a, b, c, n, m) | \r\n| | * number_to_base(n, b) |\r\n| | * extended_euclidean_algorithm(n, b) |\r\n| | * lcm(a_list) |\r\n| | * mod_division(a, b, m) |\r\n| | * bisect(alist, goal) |\r\n| | * is_clockwise(a, b, c) |\r\n+----------------+------------------------------------------------------------+\r\n\r\n.. _Project Euler: https://projecteuler.net\r\n.. _ivl-projecteuler.com: https://ivl-projecteuler.com\r\n.. _mathslib1: https://pypi.python.org/pypi/mathslib\r\n.. _here: https://mathslib.readthedocs.io/en/latest/index.html\r\n__ mathslib1_\r\n",
"bugtrack_url": null,
"license": "",
"summary": "Library of Mathematical functions and Algorithms",
"version": "3.1.0",
"project_urls": {
"Bug Reports": "https://github.com/igorvanloo/mathslib/issues",
"Homepage": "https://github.com/igorvanloo/mathslib",
"Source": "https://github.com/igorvanloo/mathslib"
},
"split_keywords": [
"numbertheory",
"maths",
"algorithms"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "0ddd53b47c7e9195baaf96d8d7442a7bbc281082334a4483a5117b6343b5b612",
"md5": "66305968d0ffd67b82f530dcdfd3ef40",
"sha256": "1fc654afc90cf670ce22b5b6e45d31951c773c2e5d0ce4dda2ff5dddb3870f5e"
},
"downloads": -1,
"filename": "mathslib-3.1.0-py3-none-any.whl",
"has_sig": false,
"md5_digest": "66305968d0ffd67b82f530dcdfd3ef40",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.7, <4",
"size": 30311,
"upload_time": "2023-07-30T09:36:21",
"upload_time_iso_8601": "2023-07-30T09:36:21.173060Z",
"url": "https://files.pythonhosted.org/packages/0d/dd/53b47c7e9195baaf96d8d7442a7bbc281082334a4483a5117b6343b5b612/mathslib-3.1.0-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "07c4f8e5e18a3b2b8bfdf2df1832edb03b8d177df0f038fdc5541b8154ee5bd6",
"md5": "00f7222190a018bc3e85a83305f66b8f",
"sha256": "14be475b6094c6b2e10c19a91f054590ca1e902e6bd4323788edde9e71918af4"
},
"downloads": -1,
"filename": "mathslib-3.1.0.tar.gz",
"has_sig": false,
"md5_digest": "00f7222190a018bc3e85a83305f66b8f",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.7, <4",
"size": 24032,
"upload_time": "2023-07-30T09:36:24",
"upload_time_iso_8601": "2023-07-30T09:36:24.051674Z",
"url": "https://files.pythonhosted.org/packages/07/c4/f8e5e18a3b2b8bfdf2df1832edb03b8d177df0f038fdc5541b8154ee5bd6/mathslib-3.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2023-07-30 09:36:24",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "igorvanloo",
"github_project": "mathslib",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "mathslib"
}