Labmath3

Latest version: v3.0.0

Safety actively analyzes 724927 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 2 of 2

2.0.2

Improved README file.

---

2.0.1

Improved docstrings and README file.

---

2.0.0

Various improvements to various docstrings.

Modified function: nextprime and prevprime now have an optional argument to specify the primality test. Default == isprime.

Modified function: if fed a finite parameter sequence, and if this fails to produce a factor, then ecm will return None. This requires that nproc == 1. The parameter sequence for the case where nprocs > 1 must still be infinite.

Improved function: primegen has been sped up by as much as 15%.

Deprecation: iterprod and binomial will be replaced with "from math import prod, comb" in some future version, and modinv will be removed since it can now be computed via pow(x, -1, y).

Removed function: mpqs
Removed function: fermat_prp

New function: siqs, as a replacement for the buggy mpqs.

---

1.2.0

Various improvements to various docstrings.

New function: polyval
New function: cbrtmod_prime
New function: polyroots_prime
New function: hensel
New function: polyrootsmod
New function: polyaddmodp
New function: polysubmodp
New function: polymulmodp
New function: polydivmodmodp
New function: gcmd
New function: polypowmodpmodpoly
New function: frobenius_prp

Deleted function: hensel_lift
Deleted function: hensel_lift_2
Deleted function: sqrtmod_primepow
This technically breaks backwards compatibility, suggesting that the new version number should be 2.0.0, but those were helper functions for sqrtmod and not intended to be called by the user, so I'm only incrementing the version to 1.2.0.

Bugfix: Docstrings claim that sqrtmod's output would be sorted. It wasn't always so. It is now.

---

1.1.0

New data: labmathversion

New function: liouville
New function: egypt_short
New function: egypt_greedy
New function: randomfactored
New function: secm
New function: ecmparams

Altered behavior: randprime's output is now uniformly sampled among all primes of the indicated size, and the primality test used is user-selectable. Full backwards compatibility is preserved.
Altered behavior: ecm is now a shell function that calls secm repeatedly (which is where the factoring now happens) using parameters pulled from ecmparams. Backwards compatibility is preserved in the positional arguments; backwards compatibility is broken for the keyword arguments.

---

1.0.8

Improved credits and a few docstrings.
Fixed a bug in which product was not imported from itertools.

---

Versions 1.0.0 through 1.0.7: fumbling around with PyPI.

Page 2 of 2

© 2025 Safety CLI Cybersecurity Inc. All Rights Reserved.