Skip to main content

A package for approximating SciPy functions

Project description

ApproxSciMate

A python library for approximating SciPy functions with different levels of accuracy. The library is intended to bring awareness to the energy usage of computer systems, and to give users a choice in how much they consume.

Read the descriptions of the functions and their levels of approximation below, pick what is best for your use case.

Functions

cbrt(n, level=0)

Calculates the cube root of the provided number n with the accuracy specified at the level.

  • level = 0 : The default SciPy cbrt function providing maximum accuracy.
  • level = 1 : Halley's method for approximating cube roots, for moderate accuracy.
  • level = 2 : Newton's method for approximating cube roots, for low accuracy.

comb(n, k, level=0)

Calculates the amount of possible selections of k items from a set of size n where the order of selection does not matter. Approximates the value based on the defined level of accuracy.

  • level = 0 : The default SciPy comb function providing maximum accuracy.
  • level = 1 : The approximated lower bound of the calculation.
  • level = 2 : The approximated upper bound of the calculation.
  • level = 3 : Uses Stirling's method of approximating factorials which converges to the real value when n is very large.

perm(n, k, level=0)

Calculates the amount of possible selections of k items from a set of size n where the order of selection does matter. Approximates the value based on the defined level of accuracy.

  • level = 0 : The default SciPy perm function providing maximum accuracy.
  • level = 1 : The approximated lower bound of the calculation.
  • level = 2 : The approximated upper bound of the calculation.
  • level = 3 : Uses Stirling's method of approximating factorials which converges to the real value when n is very large.

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

approxscimate-0.0.2.tar.gz (15.6 kB view details)

Uploaded Source

Built Distribution

approxscimate-0.0.2-py3-none-any.whl (16.0 kB view details)

Uploaded Python 3

File details

Details for the file approxscimate-0.0.2.tar.gz.

File metadata

  • Download URL: approxscimate-0.0.2.tar.gz
  • Upload date:
  • Size: 15.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.4

File hashes

Hashes for approxscimate-0.0.2.tar.gz
Algorithm Hash digest
SHA256 b216120c891417ba938fb9e1a9ac178a4afed15b615ea9789e5f34f1c67605af
MD5 4e5b16fbd38b048757823887f43898c7
BLAKE2b-256 910d94e55a8efcd75ab2d10242c10dacce3e6034f291e190d38790c71f1bbbd9

See more details on using hashes here.

File details

Details for the file approxscimate-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for approxscimate-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 d9233086b1fffaf8cf5f91d6731b7e3c58132ee02ad8cf2ff9a5dd743bf9d571
MD5 7fd545b955e031131f1e6e7281f888b7
BLAKE2b-256 ee0f1d9fde7f01aa74c6b0403272a960b1ad129707d585e93febd2384b68608d

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