gmpy icon indicating copy to clipboard operation
gmpy copied to clipboard

General Multi-Precision arithmetic for Python 2.6+/3+ (GMP, MPIR, MPFR, MPC)

Results 78 gmpy issues
Sort by recently updated
recently updated
newest added

``` In the attached patch there is _mpmath_mpf_mul; defining in mpmath rev843 in libmpf.py gmpy_mpf_mul = gmpy._mpmath_mpf_mul mpf_mul is 2x faster at mp.dps = 100 In the patch there is...

Priority-Medium
auto-migrated
Type-Enhancement

``` In the attached patch there is mpz_bitcount, which is an optimized version of bit_length which accepts only mpz; in mpmath bitcount has almost always mpz as argument, so this...

Priority-Medium
auto-migrated
Type-Enhancement

``` Is it a good idea to use Cython for the wrappers? I think it'd be much easier to maintain it, than hand written wrappers. Just a thought. ``` Original...

Priority-Medium
auto-migrated
Type-Enhancement

* consistently use "floating-point" * correct return type for ``mpfr.__floor__``, ``__ceil__`` and ``__trunc__``, closes #143 * correct ``mpq.__float__()``, closes #498 * mark fallthroughs, closes #501 I'll mark also additional issues...

I use Gmpy2 in several projects, and I've found it difficult to integrate the library with type checking and linting tools such as Ruff or Pyright. The main issue is...

Are these fallthroughs intentional? If so, can we mark them with `__attribute__((fallthrough))` so that `-Wimplicit-fallthrough` will pass with them. If not, can we add `break` to fix the bug(s)? https://github.com/aleaxit/gmpy/blob/30f6ef6d3f600efb46516844bc098d682f8833d2/src/gmpy2_mpmath.c#L290...

I tried (unsuccessfully) to find a next term for https://oeis.org/A348651 Using GMP: ``` #include #include #include #define _FAC_13 6227020800 void f1 (uint64_t x) { mpz_t tmp; mpz_init (tmp); mpz_fac_ui (tmp,...

Consider following example: ```pycon >>> from gmpy2 import mpq >>> from fractions import Fraction >>> float(Fraction(9, 5)) 1.8 >>> float(mpq(9, 5)) 1.7999999999999998 ``` It seems, gmpy2 uses mpq_get_d(), which "Convert...

Looks like with recent version has been changed tagging convention from 'gmpy2-` to `gmpy2_`. Is it only mistake or from now it will be new tagging convention? I'm asking because...

This is to test new import/export API, please don't merge! See https://github.com/capi-workgroup/decisions/issues/35. Once finished, this should solve #467.