Metadata-Version: 2.3
Name: approxscimate
Version: 0.0.4
Summary: A package for approximating SciPy functions
Project-URL: Homepage, https://github.com/MissingCurlyBracket/ApproxSciMate
Project-URL: Issues, https://github.com/MissingCurlyBracket/ApproxSciMate/issues
Author-email: Lucian Negru <l.negru@student.tudelft.nl>, Eleni Papadopoulou <e.papadopoulou@student.tudelft.nl>, Yang Li <yli59@tudelft.nl>
License-Expression: LGPL-3.0-only
License-File: LICENSE
Classifier: Operating System :: OS Independent
Classifier: Programming Language :: Python :: 3
Requires-Python: >=3.8
Requires-Dist: scipy>=1.12.0
Description-Content-Type: text/markdown

# 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.
