Skip to main content

Library of Mathematical functions and Algorithms

Project description

https://img.shields.io/pypi/v/mathslib.svg Documentation Status

mathslib is a compilation of Mathematical Functions and Algorithms I have made or come across. 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

  • divisors_of(x, include_x)

  • divisors(x, n)

  • continued_fraction(x)

  • overall_fraction(x)

  • phi(x)

  • Mobius(x)

  • ppt(limit, non_primitive)

  • legendre_factorial(x)

  • tonelli_shanks(a, p)

  • ChineseRemainderTheorem(a1, a2, n1, n2)

prime.py

  • Prime_Sieve(limit, block_size, segment, values)

  • is_prime(x)

  • prime_factors(x)

fib.py

  • fibonacci(n)

  • fib_till(limit)

  • ZeckendorfRepresentation(x)

algorithms.py

  • PrimsAlgorithm(matrix)

  • DijkstrasAlgorithm(matrix, start_node, end_node)

  • KnapSack(values, weights, n, W, no_values)

  • KnapSackValues(values, weights, n, W, no_values)

simple.py

  • n_choose_r(n, r)

  • numberToBase(n, b)

  • lcm(a_list)

  • ModDivision(a, b, m)

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

mathslib-2.0.1.tar.gz (12.0 kB view details)

Uploaded Source

Built Distribution

mathslib-2.0.1-py3-none-any.whl (16.1 kB view details)

Uploaded Python 3

File details

Details for the file mathslib-2.0.1.tar.gz.

File metadata

  • Download URL: mathslib-2.0.1.tar.gz
  • Upload date:
  • Size: 12.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.7

File hashes

Hashes for mathslib-2.0.1.tar.gz
Algorithm Hash digest
SHA256 e22363c9ccf9c42554fbd49646de68414a35694f76a093310a52890f078e9b24
MD5 4aa2aaf576c762d2cbbc921a614e9539
BLAKE2b-256 17be5e04dc2725727225fcf2f531e9cee936668b5a31cc2ff1c1c840fb450d51

See more details on using hashes here.

File details

Details for the file mathslib-2.0.1-py3-none-any.whl.

File metadata

  • Download URL: mathslib-2.0.1-py3-none-any.whl
  • Upload date:
  • Size: 16.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.9.7

File hashes

Hashes for mathslib-2.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 784cfe2e66c0acf2f6bbfdd94d2eeef799ab3f43df98b9fc5e941525a7b8db61
MD5 b44245d33b0039e7966dafa6e021f72b
BLAKE2b-256 8559ceddab208f81d5126b5e32283ea940cd06ed56543d385c478b1647e61840

See more details on using hashes here.

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