Skip to main content

number theory, and matrix operations. The package is designed to simplify calculations for common use cases, including arithmetic, statistical analysis, combinatorics, and linear algebra.

Project description

Math and Matrix Operations

This Python package provides a collection of functions for basic mathematical operations, statistical computations, number theory, and matrix operations. The package is designed to simplify calculations for common use cases, including arithmetic, statistical analysis, combinatorics, and linear algebra.

Features

Basic Operations

  • add(a, b): Returns the sum of a and b.
  • sub(a, b): Returns the difference of a and b.
  • mul(a, b): Returns the product of a and b.
  • div(a, b): Returns the division of a by b. Raises a ValueError if b is zero.

Statistical Operations

  • maximum(a): Returns the maximum value in the array a.
  • minimum(a): Returns the minimum value in the array a.
  • mean(a): Returns the mean (average) of the array a.
  • median(a): Returns the median of the array a.
  • mode(a): Returns the most frequent element in the array a.
  • variance(a): Returns the variance of the array a.

Number Theory

  • gcd(a, b): Returns the greatest common divisor of a and b.
  • lcm(a, b): Returns the least common multiple of a and b.
  • isprime(n): Checks if n is a prime number.
  • primes(n): Returns all prime numbers less than or equal to n.
  • factors(n): Returns the factors of n.
  • factorial(n): Returns the factorial of n.
  • permutation(n, r): Returns the number of permutations of n objects taken r at a time.
  • combination(n, r): Returns the number of combinations of n objects taken r at a time.

Array Operations

  • subarray(arr): Returns all possible subarrays of the array arr.

Matrix Operations

  • transpose(matrix): Returns the transpose of a matrix.
  • determinant(matrix): Returns the determinant of a matrix.
  • inverse(matrix): Returns the inverse of a matrix. Raises a ValueError if the matrix is not invertible.
  • dotproduct(a, b): Returns the dot product of two vectors a and b.

Installation

You can install this package using pip:

pip install easetools

Project details


Release history Release notifications | RSS feed

This version

0.2

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

easetools-0.2.tar.gz (3.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

easetools-0.2-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file easetools-0.2.tar.gz.

File metadata

  • Download URL: easetools-0.2.tar.gz
  • Upload date:
  • Size: 3.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.3

File hashes

Hashes for easetools-0.2.tar.gz
Algorithm Hash digest
SHA256 6873a0db687adf7b55b4466ce7a4862d3c54c0942c7371802fb494e1eb4ecbef
MD5 23f1209073dedda9961c8c22ffe6245e
BLAKE2b-256 0c504a508552b3b7b3b668023a8d45bf312b460e217ae5dc156f6dc74dd25ac8

See more details on using hashes here.

File details

Details for the file easetools-0.2-py3-none-any.whl.

File metadata

  • Download URL: easetools-0.2-py3-none-any.whl
  • Upload date:
  • Size: 3.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.11.3

File hashes

Hashes for easetools-0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 1b6c6d27a02c2f317c8da8d8c2abe6e6703a3bbd8da9a4bac269ca3d5cfaf5d8
MD5 6d96cfcce0087b627a2fc17bc8253bb3
BLAKE2b-256 e12bf6a3dbc16ca923c3023d222348698446c948a295fe2e901a0b9a77308768

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page