hgmp-0.1.2.1: Haskell interface to GMP

Safe Haskell | Safe-Inferred
Language | Haskell2010

Numeric.GMP.Raw.Safe

Contents

- Types for Documentation
- Integer Functions
  - Initialization Functions
  - Assignment Functions
  - Combined Initialization and Assignment Functions
  - Conversion Functions
  - Arithmetic Functions
  - Division Functions
  - Exponentiation Functions
  - Root Extraction Functions
  - Number Theoretic Functions
  - Comparison Functions
  - Logical and Bit Manipulation Functions
  - Input and Output Functions
  - Random Number Functions
  - Integer Import and Export
  - Miscellaneous Functions
  - Special Functions
- Rational Number Functions
  - Initialization and Assignment Functions
  - Conversion Functions
  - Arithmetic Functions
  - Comparison Functions
  - Applying Integer Functions to Rationals
  - Input and Output Functions
- Floating-point Functions
  - Initialization Functions
  - Assignment Functions
  - Combined Initialization and Assignment Functions
  - Conversion Functions
  - Arithmetic Functions
  - Comparison Functions
  - Input and Output Functions
  - Miscellaneous Functions
- Random Number Functions
  - Random State Initialization
  - Random State Seeding
  - Random State Miscellaneous
- Low-level Functions

Description

Raw GMP foreign bindings, imported safe.

Synopsis

- type SrcPtr = Ptr
- type VolatilePtr = Ptr
- type VolatileSrcPtr = Ptr
- mpz_init :: Ptr MPZ -> IO ()
- mpz_init2 :: Ptr MPZ -> MPBitCnt -> IO ()
- mpz_clear :: Ptr MPZ -> IO ()
- mpz_realloc2 :: Ptr MPZ -> MPBitCnt -> IO ()
- mpz_set :: Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_set_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_set_si :: Ptr MPZ -> CLong -> IO ()
- mpz_set_d :: Ptr MPZ -> CDouble -> IO ()
- mpz_set_q :: Ptr MPZ -> SrcPtr MPQ -> IO ()
- mpz_set_f :: Ptr MPZ -> SrcPtr MPF -> IO ()
- mpz_set_str :: Ptr MPZ -> SrcPtr CChar -> CInt -> IO CInt
- mpz_swap :: Ptr MPZ -> Ptr MPZ -> IO ()
- mpz_init_set :: Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_init_set_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_init_set_si :: Ptr MPZ -> CLong -> IO ()
- mpz_init_set_d :: Ptr MPZ -> CDouble -> IO ()
- mpz_init_set_str :: Ptr MPZ -> SrcPtr CChar -> CInt -> IO CInt
- mpz_get_ui :: SrcPtr MPZ -> IO CLong
- mpz_get_si :: SrcPtr MPZ -> IO CLong
- mpz_get_d :: SrcPtr MPZ -> IO CDouble
- mpz_get_d_2exp :: Ptr CLong -> SrcPtr MPZ -> IO CDouble
- mpz_get_str :: Ptr CChar -> CInt -> SrcPtr MPZ -> IO CChar
- mpz_add :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_add_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_sub :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_sub_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_ui_sub :: Ptr MPZ -> CULong -> SrcPtr MPZ -> IO ()
- mpz_mul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_mul_si :: Ptr MPZ -> SrcPtr MPZ -> CLong -> IO ()
- mpz_mul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_addmul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_addmul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_submul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_submul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_mul_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_cdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_cdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_cdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_cdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_cdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_cdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_cdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong
- mpz_cdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_cdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_fdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_fdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_fdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_fdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_fdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_fdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_fdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong
- mpz_fdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_fdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_tdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_tdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_tdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_tdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_tdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_tdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_tdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong
- mpz_tdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_tdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO ()
- mpz_mod :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_divexact :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_divexact_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_divisible_p :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_divisible_ui_p :: SrcPtr MPZ -> CULong -> IO CInt
- mpz_divisible_2exp_p :: SrcPtr MPZ -> MPBitCnt -> IO CInt
- mpz_congruent_p :: SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_congruent_ui_p :: SrcPtr MPZ -> CULong -> CULong -> IO CInt
- mpz_congruent_2exp_p :: SrcPtr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO CInt
- mpz_powm :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_powm_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> SrcPtr MPZ -> IO ()
- mpz_powm_sec :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_pow_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_ui_pow_ui :: Ptr MPZ -> CULong -> CULong -> IO ()
- mpz_root :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CInt
- mpz_rootrem :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_sqrt :: Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_sqrtrem :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_perfect_power_p :: SrcPtr MPZ -> IO CInt
- mpz_probab_prime_p :: SrcPtr MPZ -> CInt -> IO CInt
- mpz_nextprime :: Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_gcd :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_gcd_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong
- mpz_gcdext :: Ptr MPZ -> Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_lcm :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_lcm_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_invert :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_jacobi :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_kronecker_si :: SrcPtr MPZ -> CLong -> IO CInt
- mpz_kronecker_ui :: SrcPtr MPZ -> CULong -> IO CInt
- mpz_si_kronecker :: CLong -> SrcPtr MPZ -> IO CInt
- mpz_ui_kronecker :: CULong -> SrcPtr MPZ -> IO CInt
- mpz_remove :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO MPBitCnt
- mpz_fac_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_2fac_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_mfac_uiui :: Ptr MPZ -> CULong -> CULong -> IO ()
- mpz_primorial_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_bin_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO ()
- mpz_bin_uiui :: Ptr MPZ -> CULong -> CULong -> IO ()
- mpz_fib_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_fib2_ui :: Ptr MPZ -> Ptr MPZ -> CULong -> IO ()
- mpz_lucnum_ui :: Ptr MPZ -> CULong -> IO ()
- mpz_lucnum2_ui :: Ptr MPZ -> Ptr MPZ -> CULong -> IO ()
- mpz_cmp :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_cmp_d :: SrcPtr MPZ -> CDouble -> IO CInt
- mpz_cmp_si :: SrcPtr MPZ -> CLong -> IO CInt
- mpz_cmp_ui :: SrcPtr MPZ -> CULong -> IO CInt
- mpz_cmpabs :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt
- mpz_cmpabs_d :: SrcPtr MPZ -> CDouble -> IO CInt
- mpz_cmpabs_ui :: SrcPtr MPZ -> CULong -> IO CInt
- mpz_and :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_ior :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_xor :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO ()
- mpz_com :: Ptr MPZ -> SrcPtr MPZ -> IO ()
- mpz_hamdist :: SrcPtr MPZ -> SrcPtr MPZ -> IO MPBitCnt
- mpz_scan0 :: SrcPtr MPZ -> MPBitCnt -> IO MPBitCnt
- mpz_scan1 :: SrcPtr MPZ -> MPBitCnt -> IO MPBitCnt
- mpz_setbit :: Ptr MPZ -> MPBitCnt -> IO ()
- mpz_clrbit :: Ptr MPZ -> MPBitCnt -> IO ()
- mpz_combit :: Ptr MPZ -> MPBitCnt -> IO ()
- mpz_tstbit :: SrcPtr MPZ -> MPBitCnt -> IO CInt
- mpz_out_str :: Ptr CFile -> CInt -> SrcPtr MPZ -> IO CSize
- mpz_inp_str :: Ptr MPZ -> Ptr CFile -> CInt -> IO CSize
- mpz_out_raw :: Ptr CFile -> SrcPtr MPZ -> IO CSize
- mpz_inp_raw :: Ptr MPZ -> Ptr CFile -> IO CSize
- mpz_urandomb :: Ptr MPZ -> Ptr GMPRandState -> MPBitCnt -> IO ()
- mpz_urandomm :: Ptr MPZ -> Ptr GMPRandState -> SrcPtr MPZ -> IO ()
- mpz_rrandomb :: Ptr MPZ -> Ptr GMPRandState -> MPBitCnt -> IO ()
- mpz_import :: Ptr MPZ -> CSize -> CInt -> CSize -> CInt -> CSize -> Ptr a -> IO ()
- mpz_export :: Ptr a -> Ptr CSize -> CInt -> CSize -> CInt -> CSize -> SrcPtr MPZ -> IO ()
- mpz_fits_slong_p :: SrcPtr MPZ -> IO CInt
- mpz_fits_sint_p :: SrcPtr MPZ -> IO CInt
- mpz_fits_sshort_p :: SrcPtr MPZ -> IO CInt
- mpz_sizeinbase :: SrcPtr MPZ -> CInt -> IO CSize
- mpz_realloc :: Ptr MPZ -> MPSize -> IO ()
- mpz_limbs_read :: SrcPtr MPZ -> IO (SrcPtr MPLimb)
- mpz_limbs_write :: Ptr MPZ -> MPSize -> IO (Ptr MPLimb)
- mpz_limbs_modify :: Ptr MPZ -> MPSize -> IO (Ptr MPLimb)
- mpz_limbs_finish :: Ptr MPZ -> MPSize -> IO ()
- mpz_roinit_n :: Ptr MPZ -> SrcPtr MPLimb -> MPSize -> IO (SrcPtr MPZ)
- mpq_canonicalize :: Ptr MPQ -> IO ()
- mpq_init :: Ptr MPQ -> IO ()
- mpq_clear :: Ptr MPQ -> IO ()
- mpq_set :: Ptr MPQ -> SrcPtr MPQ -> IO ()
- mpq_set_z :: Ptr MPQ -> SrcPtr MPZ -> IO ()
- mpq_set_ui :: Ptr MPQ -> CULong -> CULong -> IO ()
- mpq_set_si :: Ptr MPQ -> CLong -> CULong -> IO ()
- mpq_set_str :: Ptr MPQ -> SrcPtr CChar -> CInt -> IO CInt
- mpq_swap :: Ptr MPQ -> Ptr MPQ -> IO ()
- mpq_get_d :: SrcPtr MPQ -> IO CDouble
- mpq_set_d :: Ptr MPQ -> CDouble -> IO ()
- mpq_set_f :: Ptr MPQ -> SrcPtr MPF -> IO ()
- mpq_get_str :: Ptr CChar -> CInt -> SrcPtr MPQ -> IO (Ptr CChar)
- mpq_add :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO ()
- mpq_sub :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO ()
- mpq_mul :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO ()
- mpq_mul_2exp :: Ptr MPQ -> SrcPtr MPQ -> MPBitCnt -> IO ()
- mpq_div :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO ()
- mpq_div_2exp :: Ptr MPQ -> SrcPtr MPQ -> MPBitCnt -> IO ()
- mpq_inv :: Ptr MPQ -> SrcPtr MPQ -> IO ()
- mpq_cmp :: SrcPtr MPQ -> SrcPtr MPQ -> IO CInt
- mpq_cmp_z :: SrcPtr MPQ -> SrcPtr MPZ -> IO CInt
- mpq_cmp_ui :: SrcPtr MPQ -> CULong -> CULong -> IO CInt
- mpq_cmp_si :: SrcPtr MPQ -> CLong -> CULong -> IO CInt
- mpq_equal :: SrcPtr MPQ -> SrcPtr MPQ -> IO CInt
- mpq_get_num :: Ptr MPZ -> SrcPtr MPQ -> IO ()
- mpq_get_den :: Ptr MPZ -> SrcPtr MPQ -> IO ()
- mpq_set_num :: Ptr MPQ -> SrcPtr MPZ -> IO ()
- mpq_set_den :: Ptr MPQ -> SrcPtr MPZ -> IO ()
- mpq_out_str :: Ptr CFile -> CInt -> SrcPtr MPQ -> IO CSize
- mpq_inp_str :: Ptr MPQ -> Ptr CFile -> CInt -> IO CSize
- mpf_init2 :: Ptr MPF -> MPBitCnt -> IO ()
- mpf_clear :: Ptr MPF -> IO ()
- mpf_get_prec :: SrcPtr MPF -> IO MPBitCnt
- mpf_set_prec :: Ptr MPF -> MPBitCnt -> IO ()
- mpf_set_prec_raw :: Ptr MPF -> MPBitCnt -> IO ()
- mpf_set :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_set_ui :: Ptr MPF -> CULong -> IO ()
- mpf_set_si :: Ptr MPF -> CLong -> IO ()
- mpf_set_d :: Ptr MPF -> CDouble -> IO ()
- mpf_set_z :: Ptr MPF -> SrcPtr MPZ -> IO ()
- mpf_set_q :: Ptr MPF -> SrcPtr MPQ -> IO ()
- mpf_set_str :: Ptr MPF -> SrcPtr CChar -> CInt -> IO CInt
- mpf_swap :: Ptr MPF -> Ptr MPF -> IO ()
- mpf_init_set :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_init_set_ui :: Ptr MPF -> CULong -> IO ()
- mpf_init_set_si :: Ptr MPF -> CLong -> IO ()
- mpf_init_set_d :: Ptr MPF -> CDouble -> IO ()
- mpf_init_set_str :: Ptr MPF -> SrcPtr CChar -> CInt -> IO CInt
- mpf_get_d :: SrcPtr MPF -> IO CDouble
- mpf_get_d_2exp :: Ptr CLong -> SrcPtr MPF -> IO CDouble
- mpf_get_si :: SrcPtr MPF -> IO CLong
- mpf_get_ui :: SrcPtr MPF -> IO CULong
- mpf_get_str :: Ptr CChar -> Ptr MPExp -> CInt -> CSize -> SrcPtr MPF -> IO (Ptr CChar)
- mpf_add :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO ()
- mpf_add_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO ()
- mpf_sub :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO ()
- mpf_sub_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO ()
- mpf_ui_sub :: Ptr MPF -> CULong -> SrcPtr MPF -> IO ()
- mpf_mul :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO ()
- mpf_mul_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO ()
- mpf_div :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO ()
- mpf_ui_div :: Ptr MPF -> CULong -> SrcPtr MPF -> IO ()
- mpf_div_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO ()
- mpf_sqrt :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_sqrt_ui :: Ptr MPF -> CULong -> IO ()
- mpf_pow_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO ()
- mpf_neg :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_abs :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_mul_2exp :: Ptr MPF -> SrcPtr MPF -> MPBitCnt -> IO ()
- mpf_div_2exp :: Ptr MPF -> SrcPtr MPF -> MPBitCnt -> IO ()
- mpf_cmp :: SrcPtr MPF -> SrcPtr MPF -> IO CInt
- mpf_cmp_z :: SrcPtr MPF -> SrcPtr MPZ -> IO CInt
- mpf_cmp_d :: SrcPtr MPF -> CDouble -> IO CInt
- mpf_cmp_ui :: SrcPtr MPF -> CULong -> IO CInt
- mpf_cmp_si :: SrcPtr MPF -> CLong -> IO CInt
- mpf_reldiff :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO ()
- mpf_out_str :: Ptr CFile -> CInt -> CSize -> SrcPtr MPF -> IO CSize
- mpf_inp_str :: Ptr MPF -> Ptr CFile -> CInt -> IO CSize
- mpf_ceil :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_floor :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_trunc :: Ptr MPF -> SrcPtr MPF -> IO ()
- mpf_integer_p :: SrcPtr MPF -> IO CInt
- mpf_fits_ulong_p :: SrcPtr MPF -> IO CInt
- mpf_fits_slong_p :: SrcPtr MPF -> IO CInt
- mpf_fits_uint_p :: SrcPtr MPF -> IO CInt
- mpf_fits_sint_p :: SrcPtr MPF -> IO CInt
- mpf_fits_ushort_p :: SrcPtr MPF -> IO CInt
- mpf_fits_sshort_p :: SrcPtr MPF -> IO CInt
- mpf_urandomb :: Ptr MPF -> Ptr GMPRandState -> MPBitCnt -> IO ()
- mpf_random2 :: Ptr MPF -> MPSize -> MPExp -> IO ()
- gmp_randinit_default :: Ptr GMPRandState -> IO ()
- gmp_randinit_mt :: Ptr GMPRandState -> IO ()
- gmp_randinit_lc_2exp :: Ptr GMPRandState -> SrcPtr MPZ -> CULong -> MPBitCnt -> IO ()
- gmp_randinit_lc_2exp_size :: Ptr GMPRandState -> MPBitCnt -> IO CInt
- gmp_randinit_set :: Ptr GMPRandState -> SrcPtr GMPRandState -> IO ()
- gmp_randclear :: Ptr GMPRandState -> IO ()
- gmp_randseed :: Ptr GMPRandState -> SrcPtr MPZ -> IO ()
- gmp_randseed_ui :: Ptr GMPRandState -> CULong -> IO ()
- gmp_urandomb_ui :: Ptr GMPRandState -> CULong -> IO CULong
- gmp_urandomm_ui :: Ptr GMPRandState -> CULong -> IO CULong
- mpn_add_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_addmul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_divexact_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO ()
- mpn_divexact_by3c :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_divrem :: Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_divrem_1 :: Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_divrem_2 :: Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> IO MPLimb
- mpn_div_qr_1 :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_div_qr_2 :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> IO MPLimb
- mpn_gcd :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> IO MPSize
- mpn_gcd_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_gcdext_1 :: Ptr MPLimbSigned -> Ptr MPLimbSigned -> MPLimb -> MPLimb -> IO MPLimb
- mpn_gcdext :: Ptr MPLimb -> Ptr MPLimb -> Ptr MPSize -> Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> IO MPSize
- mpn_get_str :: Ptr CUChar -> CInt -> Ptr MPLimb -> MPSize -> IO CSize
- mpn_hamdist :: SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPBitCnt
- mpn_lshift :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> CUInt -> IO MPLimb
- mpn_mod_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_mul :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_mul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_mul_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_sqr :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_com :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_perfect_square_p :: SrcPtr MPLimb -> MPSize -> IO CInt
- mpn_perfect_power_p :: SrcPtr MPLimb -> MPSize -> IO CInt
- mpn_popcount :: SrcPtr MPLimb -> MPSize -> IO MPBitCnt
- mpn_pow_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPSize
- mpn_preinv_mod_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> MPLimb -> IO MPLimb
- mpn_random :: Ptr MPLimb -> MPSize -> IO ()
- mpn_random2 :: Ptr MPLimb -> MPSize -> IO ()
- mpn_rshift :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> CUInt -> IO MPLimb
- mpn_scan0 :: SrcPtr MPLimb -> MPBitCnt -> IO MPBitCnt
- mpn_scan1 :: SrcPtr MPLimb -> MPBitCnt -> IO MPBitCnt
- mpn_set_str :: Ptr MPLimb -> SrcPtr CChar -> CSize -> CInt -> IO MPSize
- mpn_sizeinbase :: SrcPtr MPLimb -> MPSize -> CInt -> IO CSize
- mpn_sqrtrem :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPSize
- mpn_sub_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_submul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb
- mpn_tdiv_qr :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_and_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_andn_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_nand_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_ior_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_iorn_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_nior_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_xor_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_xnor_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_copyi :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_copyd :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO ()
- mpn_zero :: Ptr MPLimb -> MPSize -> IO ()
- mpn_cnd_add_n :: MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_cnd_sub_n :: MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb
- mpn_sec_add_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPLimb
- mpn_sec_add_1_itch :: MPSize -> IO MPSize
- mpn_sec_sub_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPLimb
- mpn_sec_sub_1_itch :: MPSize -> IO MPSize
- mpn_cnd_swap :: MPLimb -> VolatilePtr MPLimb -> VolatilePtr MPLimb -> MPSize -> IO ()
- mpn_sec_mul :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO ()
- mpn_sec_mul_itch :: MPSize -> MPSize -> IO MPSize
- mpn_sec_sqr :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO ()
- mpn_sec_sqr_itch :: MPSize -> IO MPSize
- mpn_sec_powm :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPBitCnt -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO ()
- mpn_sec_powm_itch :: MPSize -> MPBitCnt -> MPSize -> IO MPSize
- mpn_sec_tabselect :: VolatilePtr MPLimb -> VolatileSrcPtr MPLimb -> MPSize -> MPSize -> MPSize -> IO ()
- mpn_sec_div_qr :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO MPLimb
- mpn_sec_div_qr_itch :: MPSize -> MPSize -> IO MPSize
- mpn_sec_div_r :: Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO ()
- mpn_sec_div_r_itch :: MPSize -> MPSize -> IO MPSize
- mpn_sec_invert :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPBitCnt -> Ptr MPLimb -> IO CInt
- mpn_sec_invert_itch :: MPSize -> IO MPSize

# Types for Documentation

type SrcPtr = Ptr Source #

type VolatilePtr = Ptr Source #

type VolatileSrcPtr = Ptr Source #

# Integer Functions

## Initialization Functions

mpz_init :: Ptr MPZ -> IO () Source #

mpz_init2 :: Ptr MPZ -> MPBitCnt -> IO () Source #

mpz_clear :: Ptr MPZ -> IO () Source #

mpz_realloc2 :: Ptr MPZ -> MPBitCnt -> IO () Source #

## Assignment Functions

mpz_set :: Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_set_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_set_si :: Ptr MPZ -> CLong -> IO () Source #

mpz_set_d :: Ptr MPZ -> CDouble -> IO () Source #

mpz_set_q :: Ptr MPZ -> SrcPtr MPQ -> IO () Source #

mpz_set_f :: Ptr MPZ -> SrcPtr MPF -> IO () Source #

mpz_set_str :: Ptr MPZ -> SrcPtr CChar -> CInt -> IO CInt Source #

mpz_swap :: Ptr MPZ -> Ptr MPZ -> IO () Source #

## Combined Initialization and Assignment Functions

mpz_init_set :: Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_init_set_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_init_set_si :: Ptr MPZ -> CLong -> IO () Source #

mpz_init_set_d :: Ptr MPZ -> CDouble -> IO () Source #

mpz_init_set_str :: Ptr MPZ -> SrcPtr CChar -> CInt -> IO CInt Source #

## Conversion Functions

mpz_get_ui :: SrcPtr MPZ -> IO CLong Source #

mpz_get_si :: SrcPtr MPZ -> IO CLong Source #

mpz_get_d :: SrcPtr MPZ -> IO CDouble Source #

mpz_get_d_2exp :: Ptr CLong -> SrcPtr MPZ -> IO CDouble Source #

mpz_get_str :: Ptr CChar -> CInt -> SrcPtr MPZ -> IO CChar Source #

## Arithmetic Functions

mpz_add :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_add_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_sub :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_sub_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_ui_sub :: Ptr MPZ -> CULong -> SrcPtr MPZ -> IO () Source #

mpz_mul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_mul_si :: Ptr MPZ -> SrcPtr MPZ -> CLong -> IO () Source #

mpz_mul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_addmul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_addmul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_submul :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_submul_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_mul_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

## Division Functions

mpz_cdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_cdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_cdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_cdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_cdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_cdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_cdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_cdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_cdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_fdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_fdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_fdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_fdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_fdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_fdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_fdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_fdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_fdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_tdiv_q :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_tdiv_r :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_tdiv_qr :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_tdiv_q_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_tdiv_r_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_tdiv_qr_ui :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_tdiv_ui :: SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_tdiv_q_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_tdiv_r_2exp :: Ptr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO () Source #

mpz_mod :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_divexact :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_divexact_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_divisible_p :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_divisible_ui_p :: SrcPtr MPZ -> CULong -> IO CInt Source #

mpz_divisible_2exp_p :: SrcPtr MPZ -> MPBitCnt -> IO CInt Source #

mpz_congruent_p :: SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_congruent_ui_p :: SrcPtr MPZ -> CULong -> CULong -> IO CInt Source #

mpz_congruent_2exp_p :: SrcPtr MPZ -> SrcPtr MPZ -> MPBitCnt -> IO CInt Source #

## Exponentiation Functions

mpz_powm :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_powm_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> SrcPtr MPZ -> IO () Source #

mpz_powm_sec :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_pow_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_ui_pow_ui :: Ptr MPZ -> CULong -> CULong -> IO () Source #

## Root Extraction Functions

mpz_root :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CInt Source #

mpz_rootrem :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_sqrt :: Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_sqrtrem :: Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_perfect_power_p :: SrcPtr MPZ -> IO CInt Source #

## Number Theoretic Functions

mpz_probab_prime_p :: SrcPtr MPZ -> CInt -> IO CInt Source #

mpz_nextprime :: Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_gcd :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_gcd_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO CULong Source #

mpz_gcdext :: Ptr MPZ -> Ptr MPZ -> Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_lcm :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_lcm_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_invert :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_jacobi :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_kronecker_si :: SrcPtr MPZ -> CLong -> IO CInt Source #

mpz_kronecker_ui :: SrcPtr MPZ -> CULong -> IO CInt Source #

mpz_si_kronecker :: CLong -> SrcPtr MPZ -> IO CInt Source #

mpz_ui_kronecker :: CULong -> SrcPtr MPZ -> IO CInt Source #

mpz_remove :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO MPBitCnt Source #

mpz_fac_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_2fac_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_mfac_uiui :: Ptr MPZ -> CULong -> CULong -> IO () Source #

mpz_primorial_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_bin_ui :: Ptr MPZ -> SrcPtr MPZ -> CULong -> IO () Source #

mpz_bin_uiui :: Ptr MPZ -> CULong -> CULong -> IO () Source #

mpz_fib_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_fib2_ui :: Ptr MPZ -> Ptr MPZ -> CULong -> IO () Source #

mpz_lucnum_ui :: Ptr MPZ -> CULong -> IO () Source #

mpz_lucnum2_ui :: Ptr MPZ -> Ptr MPZ -> CULong -> IO () Source #

## Comparison Functions

mpz_cmp :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_cmp_d :: SrcPtr MPZ -> CDouble -> IO CInt Source #

mpz_cmp_si :: SrcPtr MPZ -> CLong -> IO CInt Source #

mpz_cmp_ui :: SrcPtr MPZ -> CULong -> IO CInt Source #

mpz_cmpabs :: SrcPtr MPZ -> SrcPtr MPZ -> IO CInt Source #

mpz_cmpabs_d :: SrcPtr MPZ -> CDouble -> IO CInt Source #

mpz_cmpabs_ui :: SrcPtr MPZ -> CULong -> IO CInt Source #

## Logical and Bit Manipulation Functions

mpz_and :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_ior :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_xor :: Ptr MPZ -> SrcPtr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_com :: Ptr MPZ -> SrcPtr MPZ -> IO () Source #

mpz_hamdist :: SrcPtr MPZ -> SrcPtr MPZ -> IO MPBitCnt Source #

mpz_scan0 :: SrcPtr MPZ -> MPBitCnt -> IO MPBitCnt Source #

mpz_scan1 :: SrcPtr MPZ -> MPBitCnt -> IO MPBitCnt Source #

mpz_setbit :: Ptr MPZ -> MPBitCnt -> IO () Source #

mpz_clrbit :: Ptr MPZ -> MPBitCnt -> IO () Source #

mpz_combit :: Ptr MPZ -> MPBitCnt -> IO () Source #

mpz_tstbit :: SrcPtr MPZ -> MPBitCnt -> IO CInt Source #

## Input and Output Functions

mpz_out_str :: Ptr CFile -> CInt -> SrcPtr MPZ -> IO CSize Source #

mpz_inp_str :: Ptr MPZ -> Ptr CFile -> CInt -> IO CSize Source #

mpz_out_raw :: Ptr CFile -> SrcPtr MPZ -> IO CSize Source #

mpz_inp_raw :: Ptr MPZ -> Ptr CFile -> IO CSize Source #

## Random Number Functions

mpz_urandomb :: Ptr MPZ -> Ptr GMPRandState -> MPBitCnt -> IO () Source #

mpz_urandomm :: Ptr MPZ -> Ptr GMPRandState -> SrcPtr MPZ -> IO () Source #

mpz_rrandomb :: Ptr MPZ -> Ptr GMPRandState -> MPBitCnt -> IO () Source #

## Integer Import and Export

mpz_import :: Ptr MPZ -> CSize -> CInt -> CSize -> CInt -> CSize -> Ptr a -> IO () Source #

mpz_export :: Ptr a -> Ptr CSize -> CInt -> CSize -> CInt -> CSize -> SrcPtr MPZ -> IO () Source #

## Miscellaneous Functions

mpz_fits_slong_p :: SrcPtr MPZ -> IO CInt Source #

mpz_fits_sint_p :: SrcPtr MPZ -> IO CInt Source #

mpz_fits_sshort_p :: SrcPtr MPZ -> IO CInt Source #

mpz_sizeinbase :: SrcPtr MPZ -> CInt -> IO CSize Source #

## Special Functions

mpz_realloc :: Ptr MPZ -> MPSize -> IO () Source #

mpz_limbs_read :: SrcPtr MPZ -> IO (SrcPtr MPLimb) Source #

mpz_limbs_write :: Ptr MPZ -> MPSize -> IO (Ptr MPLimb) Source #

mpz_limbs_modify :: Ptr MPZ -> MPSize -> IO (Ptr MPLimb) Source #

mpz_limbs_finish :: Ptr MPZ -> MPSize -> IO () Source #

mpz_roinit_n :: Ptr MPZ -> SrcPtr MPLimb -> MPSize -> IO (SrcPtr MPZ) Source #

# Rational Number Functions

mpq_canonicalize :: Ptr MPQ -> IO () Source #

## Initialization and Assignment Functions

mpq_init :: Ptr MPQ -> IO () Source #

mpq_clear :: Ptr MPQ -> IO () Source #

mpq_set :: Ptr MPQ -> SrcPtr MPQ -> IO () Source #

mpq_set_z :: Ptr MPQ -> SrcPtr MPZ -> IO () Source #

mpq_set_ui :: Ptr MPQ -> CULong -> CULong -> IO () Source #

mpq_set_si :: Ptr MPQ -> CLong -> CULong -> IO () Source #

mpq_set_str :: Ptr MPQ -> SrcPtr CChar -> CInt -> IO CInt Source #

mpq_swap :: Ptr MPQ -> Ptr MPQ -> IO () Source #

## Conversion Functions

mpq_get_d :: SrcPtr MPQ -> IO CDouble Source #

mpq_set_d :: Ptr MPQ -> CDouble -> IO () Source #

mpq_set_f :: Ptr MPQ -> SrcPtr MPF -> IO () Source #

mpq_get_str :: Ptr CChar -> CInt -> SrcPtr MPQ -> IO (Ptr CChar) Source #

## Arithmetic Functions

mpq_add :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO () Source #

mpq_sub :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO () Source #

mpq_mul :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO () Source #

mpq_mul_2exp :: Ptr MPQ -> SrcPtr MPQ -> MPBitCnt -> IO () Source #

mpq_div :: Ptr MPQ -> SrcPtr MPQ -> SrcPtr MPQ -> IO () Source #

mpq_div_2exp :: Ptr MPQ -> SrcPtr MPQ -> MPBitCnt -> IO () Source #

mpq_inv :: Ptr MPQ -> SrcPtr MPQ -> IO () Source #

## Comparison Functions

mpq_cmp :: SrcPtr MPQ -> SrcPtr MPQ -> IO CInt Source #

mpq_cmp_z :: SrcPtr MPQ -> SrcPtr MPZ -> IO CInt Source #

mpq_cmp_ui :: SrcPtr MPQ -> CULong -> CULong -> IO CInt Source #

mpq_cmp_si :: SrcPtr MPQ -> CLong -> CULong -> IO CInt Source #

mpq_equal :: SrcPtr MPQ -> SrcPtr MPQ -> IO CInt Source #

## Applying Integer Functions to Rationals

mpq_get_num :: Ptr MPZ -> SrcPtr MPQ -> IO () Source #

mpq_get_den :: Ptr MPZ -> SrcPtr MPQ -> IO () Source #

mpq_set_num :: Ptr MPQ -> SrcPtr MPZ -> IO () Source #

mpq_set_den :: Ptr MPQ -> SrcPtr MPZ -> IO () Source #

## Input and Output Functions

mpq_out_str :: Ptr CFile -> CInt -> SrcPtr MPQ -> IO CSize Source #

mpq_inp_str :: Ptr MPQ -> Ptr CFile -> CInt -> IO CSize Source #

# Floating-point Functions

## Initialization Functions

mpf_init2 :: Ptr MPF -> MPBitCnt -> IO () Source #

mpf_clear :: Ptr MPF -> IO () Source #

mpf_get_prec :: SrcPtr MPF -> IO MPBitCnt Source #

mpf_set_prec :: Ptr MPF -> MPBitCnt -> IO () Source #

mpf_set_prec_raw :: Ptr MPF -> MPBitCnt -> IO () Source #

## Assignment Functions

mpf_set :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_set_ui :: Ptr MPF -> CULong -> IO () Source #

mpf_set_si :: Ptr MPF -> CLong -> IO () Source #

mpf_set_d :: Ptr MPF -> CDouble -> IO () Source #

mpf_set_z :: Ptr MPF -> SrcPtr MPZ -> IO () Source #

mpf_set_q :: Ptr MPF -> SrcPtr MPQ -> IO () Source #

mpf_set_str :: Ptr MPF -> SrcPtr CChar -> CInt -> IO CInt Source #

mpf_swap :: Ptr MPF -> Ptr MPF -> IO () Source #

## Combined Initialization and Assignment Functions

mpf_init_set :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_init_set_ui :: Ptr MPF -> CULong -> IO () Source #

mpf_init_set_si :: Ptr MPF -> CLong -> IO () Source #

mpf_init_set_d :: Ptr MPF -> CDouble -> IO () Source #

mpf_init_set_str :: Ptr MPF -> SrcPtr CChar -> CInt -> IO CInt Source #

## Conversion Functions

mpf_get_d :: SrcPtr MPF -> IO CDouble Source #

mpf_get_d_2exp :: Ptr CLong -> SrcPtr MPF -> IO CDouble Source #

mpf_get_si :: SrcPtr MPF -> IO CLong Source #

mpf_get_ui :: SrcPtr MPF -> IO CULong Source #

mpf_get_str :: Ptr CChar -> Ptr MPExp -> CInt -> CSize -> SrcPtr MPF -> IO (Ptr CChar) Source #

## Arithmetic Functions

mpf_add :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO () Source #

mpf_add_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO () Source #

mpf_sub :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO () Source #

mpf_sub_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO () Source #

mpf_ui_sub :: Ptr MPF -> CULong -> SrcPtr MPF -> IO () Source #

mpf_mul :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO () Source #

mpf_mul_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO () Source #

mpf_div :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO () Source #

mpf_ui_div :: Ptr MPF -> CULong -> SrcPtr MPF -> IO () Source #

mpf_div_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO () Source #

mpf_sqrt :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_sqrt_ui :: Ptr MPF -> CULong -> IO () Source #

mpf_pow_ui :: Ptr MPF -> SrcPtr MPF -> CULong -> IO () Source #

mpf_neg :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_abs :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_mul_2exp :: Ptr MPF -> SrcPtr MPF -> MPBitCnt -> IO () Source #

mpf_div_2exp :: Ptr MPF -> SrcPtr MPF -> MPBitCnt -> IO () Source #

## Comparison Functions

mpf_cmp :: SrcPtr MPF -> SrcPtr MPF -> IO CInt Source #

mpf_cmp_z :: SrcPtr MPF -> SrcPtr MPZ -> IO CInt Source #

mpf_cmp_d :: SrcPtr MPF -> CDouble -> IO CInt Source #

mpf_cmp_ui :: SrcPtr MPF -> CULong -> IO CInt Source #

mpf_cmp_si :: SrcPtr MPF -> CLong -> IO CInt Source #

mpf_reldiff :: Ptr MPF -> SrcPtr MPF -> SrcPtr MPF -> IO () Source #

## Input and Output Functions

mpf_out_str :: Ptr CFile -> CInt -> CSize -> SrcPtr MPF -> IO CSize Source #

mpf_inp_str :: Ptr MPF -> Ptr CFile -> CInt -> IO CSize Source #

## Miscellaneous Functions

mpf_ceil :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_floor :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_trunc :: Ptr MPF -> SrcPtr MPF -> IO () Source #

mpf_integer_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_ulong_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_slong_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_uint_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_sint_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_ushort_p :: SrcPtr MPF -> IO CInt Source #

mpf_fits_sshort_p :: SrcPtr MPF -> IO CInt Source #

mpf_urandomb :: Ptr MPF -> Ptr GMPRandState -> MPBitCnt -> IO () Source #

mpf_random2 :: Ptr MPF -> MPSize -> MPExp -> IO () Source #

# Random Number Functions

## Random State Initialization

gmp_randinit_default :: Ptr GMPRandState -> IO () Source #

gmp_randinit_mt :: Ptr GMPRandState -> IO () Source #

gmp_randinit_lc_2exp :: Ptr GMPRandState -> SrcPtr MPZ -> CULong -> MPBitCnt -> IO () Source #

gmp_randinit_lc_2exp_size :: Ptr GMPRandState -> MPBitCnt -> IO CInt Source #

gmp_randinit_set :: Ptr GMPRandState -> SrcPtr GMPRandState -> IO () Source #

gmp_randclear :: Ptr GMPRandState -> IO () Source #

## Random State Seeding

gmp_randseed :: Ptr GMPRandState -> SrcPtr MPZ -> IO () Source #

gmp_randseed_ui :: Ptr GMPRandState -> CULong -> IO () Source #

## Random State Miscellaneous

gmp_urandomb_ui :: Ptr GMPRandState -> CULong -> IO CULong Source #

gmp_urandomm_ui :: Ptr GMPRandState -> CULong -> IO CULong Source #

# Low-level Functions

mpn_add_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_addmul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_divexact_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO () Source #

mpn_divexact_by3c :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_divrem :: Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_divrem_1 :: Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_divrem_2 :: Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> IO MPLimb Source #

mpn_div_qr_1 :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_div_qr_2 :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> IO MPLimb Source #

mpn_gcd :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> IO MPSize Source #

mpn_gcd_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_gcdext_1 :: Ptr MPLimbSigned -> Ptr MPLimbSigned -> MPLimb -> MPLimb -> IO MPLimb Source #

mpn_gcdext :: Ptr MPLimb -> Ptr MPLimb -> Ptr MPSize -> Ptr MPLimb -> MPSize -> Ptr MPLimb -> MPSize -> IO MPSize Source #

mpn_get_str :: Ptr CUChar -> CInt -> Ptr MPLimb -> MPSize -> IO CSize Source #

mpn_hamdist :: SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPBitCnt Source #

mpn_lshift :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> CUInt -> IO MPLimb Source #

mpn_mod_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_mul :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_mul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_mul_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_sqr :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_com :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_perfect_square_p :: SrcPtr MPLimb -> MPSize -> IO CInt Source #

mpn_perfect_power_p :: SrcPtr MPLimb -> MPSize -> IO CInt Source #

mpn_popcount :: SrcPtr MPLimb -> MPSize -> IO MPBitCnt Source #

mpn_pow_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPSize Source #

mpn_preinv_mod_1 :: SrcPtr MPLimb -> MPSize -> MPLimb -> MPLimb -> IO MPLimb Source #

mpn_random :: Ptr MPLimb -> MPSize -> IO () Source #

mpn_random2 :: Ptr MPLimb -> MPSize -> IO () Source #

mpn_rshift :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> CUInt -> IO MPLimb Source #

mpn_scan0 :: SrcPtr MPLimb -> MPBitCnt -> IO MPBitCnt Source #

mpn_scan1 :: SrcPtr MPLimb -> MPBitCnt -> IO MPBitCnt Source #

mpn_set_str :: Ptr MPLimb -> SrcPtr CChar -> CSize -> CInt -> IO MPSize Source #

mpn_sizeinbase :: SrcPtr MPLimb -> MPSize -> CInt -> IO CSize Source #

mpn_sqrtrem :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPSize Source #

mpn_sub_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_submul_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> IO MPLimb Source #

mpn_tdiv_qr :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_and_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_andn_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_nand_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_ior_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_iorn_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_nior_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_xor_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_xnor_n :: Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_copyi :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_copyd :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> IO () Source #

mpn_zero :: Ptr MPLimb -> MPSize -> IO () Source #

mpn_cnd_add_n :: MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_cnd_sub_n :: MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> SrcPtr MPLimb -> MPSize -> IO MPLimb Source #

mpn_sec_add_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPLimb Source #

mpn_sec_add_1_itch :: MPSize -> IO MPSize Source #

mpn_sec_sub_1 :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPLimb -> Ptr MPLimb -> IO MPLimb Source #

mpn_sec_sub_1_itch :: MPSize -> IO MPSize Source #

mpn_cnd_swap :: MPLimb -> VolatilePtr MPLimb -> VolatilePtr MPLimb -> MPSize -> IO () Source #

mpn_sec_mul :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO () Source #

mpn_sec_mul_itch :: MPSize -> MPSize -> IO MPSize Source #

mpn_sec_sqr :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO () Source #

mpn_sec_sqr_itch :: MPSize -> IO MPSize Source #

mpn_sec_powm :: Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> SrcPtr MPLimb -> MPBitCnt -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO () Source #

mpn_sec_powm_itch :: MPSize -> MPBitCnt -> MPSize -> IO MPSize Source #

mpn_sec_tabselect :: VolatilePtr MPLimb -> VolatileSrcPtr MPLimb -> MPSize -> MPSize -> MPSize -> IO () Source #

mpn_sec_div_qr :: Ptr MPLimb -> Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO MPLimb Source #

mpn_sec_div_qr_itch :: MPSize -> MPSize -> IO MPSize Source #

mpn_sec_div_r :: Ptr MPLimb -> MPSize -> SrcPtr MPLimb -> MPSize -> Ptr MPLimb -> IO () Source #

mpn_sec_div_r_itch :: MPSize -> MPSize -> IO MPSize Source #

mpn_sec_invert :: Ptr MPLimb -> Ptr MPLimb -> SrcPtr MPLimb -> MPSize -> MPBitCnt -> Ptr MPLimb -> IO CInt Source #

mpn_sec_invert_itch :: MPSize -> IO MPSize Source #