| gmp_lib Class | 
Namespace: Math.Gmp.Native
The gmp_lib type exposes the following members.
| Name | Description | |
|---|---|---|
| _mpz_realloc | 
            Change the space for integer to new_alloc limbs.
              | |
| allocate | 
            Return a pointer to newly allocated space with at least alloc_size bytes.
              | |
| free(IntPtr) | 
            Free the unmanaged memory at ptr.
              | |
| free(char_ptr) | 
            De-allocate the space pointed to by ptr.
              | |
| free(gmp_randstate_t) | 
            De-allocate the space pointed to by ptr.
              | |
| free(mp_ptr) | 
            De-allocate the space pointed to by ptrs.
              | |
| free(void_ptr) | 
            De-allocate the space pointed to by ptr.
              | |
| free(void_ptr, size_t) | 
            De-allocate the space pointed to by ptr.
              | |
| gmp_asprintf | 
            Form a null-terminated string in a block of memory obtained from the current memory allocation function.
              | |
| gmp_fprintf | 
            Print to the stream fp.
              | |
| gmp_fscanf | 
            Read from the stream fp.
              | |
| gmp_printf | 
             Print to the standard output stdout.
               | |
| gmp_randclear | 
            Free all memory occupied by state.
              | |
| gmp_randinit_default | 
            Initialize state with a default algorithm.
              | |
| gmp_randinit_lc_2exp | 
            Initialize state with a linear congruential algorithm X = (aX + c) mod 2^m2exp.
              | |
| gmp_randinit_lc_2exp_size | 
            Initialize state for a linear congruential algorithm as per gmp_randinit_lc_2exp.
              | |
| gmp_randinit_mt | 
            Initialize state for a Mersenne Twister algorithm.
              | |
| gmp_randinit_set | 
            Initialize rop with a copy of the algorithm and state from op.
              | |
| gmp_randseed | 
            Set an initial seed value into state.
              | |
| gmp_randseed_ui | 
            Set an initial seed value into state.
              | |
| gmp_scanf | 
            Read from the standard input stdin.
              | |
| gmp_snprintf | 
            Form a null-terminated string in buf.
              | |
| gmp_sprintf | 
            Form a null-terminated string in buf.
              | |
| gmp_sscanf | 
            Read from a null-terminated string s.
              | |
| gmp_urandomb_ui | 
            Generate a uniformly distributed random number of n bits, i.e. in the range 0 to 2^n - 1 inclusive.
              | |
| gmp_urandomm_ui | 
            Generate a uniformly distributed random number in the range 0 to n - 1, inclusive.
              | |
| gmp_vasprintf | 
            Form a null-terminated string in a block of memory obtained from the current memory allocation function.
              | |
| gmp_vfprintf | 
            Print to the stream fp.
              | |
| gmp_vfscanf | 
            Read from the stream fp.
              | |
| gmp_vprintf | 
             Print to the standard output stdout.
               | |
| gmp_vscanf | 
            Read from the standard input stdin.
              | |
| gmp_vsnprintf | 
            Form a null-terminated string in buf.
              | |
| gmp_vsprintf | 
            Form a null-terminated string in buf.
              | |
| gmp_vsscanf | 
            Read from a null-terminated string s.
              | |
| mp_get_memory_functions | 
            Get the current allocation functions, storing function pointers to the locations given by the arguments.
              | |
| mp_set_memory_functions | 
            Replace the current allocation functions from the arguments.
              | |
| mpf_abs | 
            Set rop to | op |. 
              | |
| mpf_add | 
            Set rop to op1 + op2.
              | |
| mpf_add_ui | 
            Set rop to op1 + op2.
              | |
| mpf_ceil | 
            Set rop to op rounded to the next higher integer. 
              | |
| mpf_clear | 
            Free the space occupied by x.
              | |
| mpf_clears | 
            Free the space occupied by a NULL-terminated list of mpf_t variables. 
              | |
| mpf_cmp | 
            Compare op1 and op2.
              | |
| mpf_cmp_d | 
            Compare op1 and op2.
              | |
| mpf_cmp_si | 
            Compare op1 and op2.
              | |
| mpf_cmp_ui | 
            Compare op1 and op2.
              | |
| mpf_cmp_z | 
            Compare op1 and op2.
              | |
| mpf_div | 
            Set rop to op1 / op2. 
              | |
| mpf_div_2exp | 
            Set rop to op1 / 2^op2. 
              | |
| mpf_div_ui | 
            Set rop to op1 / op2. 
              | |
| mpf_fits_sint_p | 
            Return non-zero if op fits in a 32-bit integer, when truncated to an integer. 
              | |
| mpf_fits_slong_p | 
            Return non-zero if op fits in a 32-bit integer, when truncated to an integer. 
              | |
| mpf_fits_sshort_p | 
            Return non-zero if op fits in a 16-bit integer, when truncated to an integer. 
              | |
| mpf_fits_uint_p | 
            Return non-zero if op fits in an unsigned 32-bit integer, when truncated to an integer. 
              | |
| mpf_fits_ulong_p | 
            Return non-zero if op fits in an unsigned 32-bit integer, when truncated to an integer. 
              | |
| mpf_fits_ushort_p | 
            Return non-zero if op fits in an unsigned 16-bit integer, when truncated to an integer. 
              | |
| mpf_floor | 
            Set rop to op rounded to the next lower integer.
              | |
| mpf_get_d | 
            Convert op to a double, truncating if necessary (i.e. rounding towards zero). 
              | |
| mpf_get_d_2exp | 
            Convert op to a double, truncating if necessary (i.e. rounding towards zero), and with an exponent returned separately. 
              | |
| mpf_get_default_prec | 
            Return the default precision actually used. 
              | |
| mpf_get_prec | 
            Return the current precision of op, in bits. 
              | |
| mpf_get_si | 
            Convert op to a 32-bit integer, truncating any fraction part.
              | |
| mpf_get_str(char_ptr, mp_exp_t, Int32, size_t, mpf_t) | 
            Convert op to a string of digits in base base.
              | |
| mpf_get_str(char_ptr, ptrmp_exp_t, Int32, size_t, mpf_t) | 
            Convert op to a string of digits in base base.
              | |
| mpf_get_ui | 
            Convert op to an unsigned 32-bit integer, truncating any fraction part.
              | |
| mpf_init | 
            Initialize x to 0.
              | |
| mpf_init_set | 
            Initialize rop and set its value from op.
              | |
| mpf_init_set_d | 
            Initialize rop and set its value from op.
              | |
| mpf_init_set_si | 
            Initialize rop and set its value from op.
              | |
| mpf_init_set_str | 
            Initialize rop and set its value from the string in str.
              | |
| mpf_init_set_ui | 
            Initialize rop and set its value from op.
              | |
| mpf_init2 | 
            Initialize x to 0 and set its precision to be at least prec bits.
              | |
| mpf_inits | 
            Initialize a NULL-terminated list of mpf_t variables, and set their values to 0.
              | |
| mpf_inp_str | 
            Read a string in base base from stream, and put the read float in rop.
              | |
| mpf_integer_p | 
            Return non-zero if op is an integer.
              | |
| mpf_mul | 
            Set rop to op1 * op2. 
              | |
| mpf_mul_2exp | 
            Set rop to op1 * 2^op2. 
              | |
| mpf_mul_ui | 
            Set rop to op1 * op2. 
              | |
| mpf_neg | 
            Set rop to -op. 
              | |
| mpf_out_str | 
            Print op to stream, as a string of digits.
              | |
| mpf_pow_ui | 
            Set rop to op1^op2.
              | |
| mpf_random2 | 
            Generate a random float of at most max_size limbs, with long strings of zeros and ones in the binary representation.
              | |
| mpf_reldiff | 
            Compute the relative difference between op1 and op2 and store the result in rop. This is | op1 - op2 | / op1. 
              | |
| mpf_set | 
            Set the value of rop from op. 
              | |
| mpf_set_d | 
            Set the value of rop from op. 
              | |
| mpf_set_default_prec | 
            Set the default precision to be at least prec bits.
              | |
| mpf_set_prec | 
            Set the precision of rop to be at least prec bits.
              | |
| mpf_set_prec_raw | 
            Set the precision of rop to be at least prec bits, without changing the memory allocated. 
              | |
| mpf_set_q | 
            Set the value of rop from op. 
              | |
| mpf_set_si | 
            Set the value of rop from op. 
              | |
| mpf_set_str | 
            Set the value of rop from the string in str.
              | |
| mpf_set_ui | 
            Set the value of rop from op. 
              | |
| mpf_set_z | 
            Set the value of rop from op. 
              | |
| mpf_sgn | 
            Return +1 if op > 0, 0 if op = 0, and -1 if op < 0. 
              | |
| mpf_size | 
            Return the number of limbs currently in use.
              | |
| mpf_sqrt | 
            Set rop to the square root of op. 
              | |
| mpf_sqrt_ui | 
            Set rop to the square root of op. 
              | |
| mpf_sub | 
            Set rop to op1 - op2.
              | |
| mpf_sub_ui | 
            Set rop to op1 - op2.
              | |
| mpf_swap | 
            Swap rop1 and rop2 efficiently. 
              | |
| mpf_trunc | 
            Set rop to op rounded to the integer towards zero. 
              | |
| mpf_ui_div | 
            Set rop to op1 / op2. 
              | |
| mpf_ui_sub | 
            Set rop to op1 - op2.
              | |
| mpf_urandomb | 
            Generate a uniformly distributed random float in rop, such that 0 ≤ rop < 1, with nbits significant bits in the mantissa or less if the precision of rop is smaller.
              | |
| mpn_add | 
            Add {s1p, s1n} and {s2p, s2n}, and write the s1n least significant limbs of the result to rp. 
              | |
| mpn_add_1 | 
            Add {s1p, n} and s2limb, and write the n least significant limbs of the result to rp.
              | |
| mpn_add_n | 
            Add {s1p, n} and {s2p, n}, and write the n least significant limbs of the result to rp. 
              | |
| mpn_addmul_1 | 
            Multiply {s1p, n} and s2limb, and add the n least significant limbs of the product to {rp, n} and write the result to rp. 
              | |
| mpn_and_n | 
            Perform the bitwise logical and of {s1p, n} and {s2p, n}, and write the result to {rp, n}. 
              | |
| mpn_andn_n | 
            Perform the bitwise logical and of {s1p, n} and the bitwise complement of {s2p, n}, and write the result to {rp, n}.
              | |
| mpn_cmp | 
            Compare {s1p, n} and {s2p, n}.
              | |
| mpn_cnd_add_n | 
            If cnd is non-zero, it produces the same result as a regular mpn_add_n, and if cnd is zero, it copies {s1p, n} to the result area and returns zero.
              | |
| mpn_cnd_sub_n | 
            If cnd is non-zero, it produces the same result as a regular mpn_sub_n, and if cnd is zero, it copies {s1p, n} to the result area and returns zero.
              | |
| mpn_cnd_swap | 
            If cnd is non-zero, swaps the contents of the areas {ap, n} and {bp, n}. Otherwise, the areas are left unmodified.
              | |
| mpn_com | 
            Perform the bitwise complement of {sp, n}, and write the result to {rp, n}.
              | |
| mpn_copyd | 
            Copy from {s1p, n} to {rp, n}, decreasingly. 
              | |
| mpn_copyi | 
            Copy from {s1p, n} to {rp, n}, increasingly. 
              | |
| mpn_divexact_1 | 
            Divide {sp, n} by d, expecting it to divide exactly, and writing the result to {rrp, n}.
              | |
| mpn_divexact_by3 | 
            Divide {sp, n} by 3, expecting it to divide exactly, and writing the result to {rp, n}. 
              | |
| mpn_divexact_by3c | 
            Divide {sp, n} by 3, expecting it to divide exactly, and writing the result to {rp, n}. 
              | |
| mpn_divmod_1 | 
            Divide {s2p, s2n} by s3limb, and write the quotient at r1p.
              | |
| mpn_divrem_1 | 
            Divide {s2p, s2n} by s3limb, and write the quotient at r1p.
              | |
| mpn_gcd | 
            Set {rp, retval} to the greatest common divisor of {xp, xn} and {yp, yn}.
              | |
| mpn_gcd_1 | 
            Return the greatest common divisor of {xp, xn} and ylimb.
              | |
| mpn_gcdext(mp_ptr, mp_ptr, mp_size_t, mp_ptr, mp_size_t, mp_ptr, mp_size_t) | 
            Compute the greatest common divisor G of U and V. Compute a cofactor S such that G = US + VT.
              | |
| mpn_gcdext(mp_ptr, mp_ptr, ptrmp_size_t, mp_ptr, mp_size_t, mp_ptr, mp_size_t) | 
            Compute the greatest common divisor G of U and V. Compute a cofactor S such that G = US + VT.
              | |
| mpn_get_str | 
            Convert {s1p, s1n} to a raw unsigned char array at str in base base, and return the number of characters produced.
              | |
| mpn_hamdist | 
            Compute the hamming distance between {s1p, n} and {s2p, n}, which is the number of bit positions where the two operands have different bit values. 
              | |
| mpn_ior_n | 
            Perform the bitwise logical inclusive or of {s1p, n} and {s2p, n}, and write the result to {rp, n}. 
              | |
| mpn_iorn_n | 
            Perform the bitwise logical inclusive or of {s1p, n} and the bitwise complement of {s2p, n}, and write the result to {rp, n}. 
              | |
| mpn_lshift | 
            Shift {sp, n} left by count bits, and write the result to {rp, n}. 
              | |
| mpn_mod_1 | 
            Divide {s1p, s1n} by s2limb, and return the remainder. 
              | |
| mpn_mul | 
            Multiply {s1p, s1n} and {s2p, s2n}, and write the (s1n + s2n)-limb result to rp.
              | |
| mpn_mul_1 | 
            Multiply {s1p, n} by s2limb, and write the n least significant limbs of the product to rp.
              | |
| mpn_mul_n | 
            Multiply {s1p, n} and {s2p, n}, and write the (2 * n)-limb result to rp.
              | |
| mpn_nand_n | 
            Perform the bitwise logical and of {s1p, n} and {s2p, n}, and write the bitwise complement of the result to {rp, n}. 
              | |
| mpn_neg | 
            Perform the negation of {sp, n}, and write the result to {rp, n}.
              | |
| mpn_nior_n | 
            Perform the bitwise logical inclusive or of {s1p, n} and {s2p, n}, and write the bitwise complement of the result to {rp, n}.
              | |
| mpn_perfect_power_p | 
            Return non-zero iff {sp, n} is a perfect power.
              | |
| mpn_perfect_square_p | 
            Return non-zero iff {s1p, n} is a perfect square.
              | |
| mpn_popcount | 
            Count the number of set bits in {s1p, n}. 
              | |
| mpn_random | 
            Generate a random number of length r1n and store it at r1p.
              | |
| mpn_random2 | 
            Generate a random number of length r1n and store it at r1p.
              | |
| mpn_rshift | 
            Shift {sp, n} right by count bits, and write the result to {rp, n}. 
              | |
| mpn_scan0 | 
            Scan s1p from bit position bit for the next clear bit.
              | |
| mpn_scan1 | 
            Scan s1p from bit position bit for the next set bit.
              | |
| mpn_sec_add_1 | 
            Set R to A + b, where R = {rp, n}, A = {ap, n}, and b is a single limb.
              | |
| mpn_sec_add_1_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_add_1.
              | |
| mpn_sec_div_qr | 
            Set Q to the truncated quotient N / D and R to N modulo D, where N = {np, nn}, D = {dp, dn}, Q’s most significant limb is the function return value and the remaining limbs are {qp, nn - dn}, and R = {np, dn}. 
              | |
| mpn_sec_div_qr_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_div_qr.
              | |
| mpn_sec_div_r | 
            Set R to N modulo D, where N = {np, nn}, D = {dp, dn}, and R = {np, dn}. 
              | |
| mpn_sec_div_r_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_div_r.
              | |
| mpn_sec_invert | 
            Set R to the inverse of A modulo M, where R = {rp, n}, A = {ap, n}, and M = {mp, n}. This function’s interface is preliminary. 
              | |
| mpn_sec_invert_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_invert.
              | |
| mpn_sec_mul | 
            Set R to A * B, where A = {ap, an}, B = {bp, bn}, and R = {rp, an + bn}. 
              | |
| mpn_sec_mul_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_mul.
              | |
| mpn_sec_powm | 
            Set R to (B^E) modulo M, where R = {rp, n}, M = {mp, n}, and E = {ep, ceil(enb / mp_bits_per_limb)}. 
              | |
| mpn_sec_powm_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_powm.
              | |
| mpn_sec_sqr | 
            Set R to A^2, where A = {ap, an}, and R = {rp, 2 * an}. 
              | |
| mpn_sec_sqr_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_sqr.
              | |
| mpn_sec_sub_1 | 
            Set R to A - b, where R = {rp, n}, A = {ap, n}, and b is a single limb.
              | |
| mpn_sec_sub_1_itch | 
            Return the scratch space in number of limbs required by the function mpn_sec_sub_1.
              | |
| mpn_sec_tabselect | 
            Select entry which from table tab, which has nents entries, each n limbs. Store the selected entry at rp.
              | |
| mpn_set_str | 
            Convert bytes {str, strsize} in the given base to limbs at rp. 
              | |
| mpn_sizeinbase | 
            Return the size of {xp, n} measured in number of digits in the given base.
              | |
| mpn_sqr | 
            Compute the square of {s1p, n} and write the (2 * n)-limb result to rp.
              | |
| mpn_sqrtrem | 
            Compute the square root of {sp, n} and put the result at {r1p, ceil(n / 2)} and the remainder at {r2p, retval}.
              | |
| mpn_sub | 
            Subtract {s2p, s2n} from {s1p, s1n}, and write the s1n least significant limbs of the result to rp.
              | |
| mpn_sub_1 | 
            Subtract s2limb from {s1p, n}, and write the n least significant limbs of the result to rp.
              | |
| mpn_sub_n | 
            Subtract {s2p, n} from {s1p, n}, and write the n least significant limbs of the result to rp.
              | |
| mpn_submul_1 | 
            Multiply {s1p, n} and s2limb, and subtract the n least significant limbs of the product from {rp, n} and write the result to rp.
              | |
| mpn_tdiv_qr | 
            Divide {np, nn} by {dp, dn} and put the quotient at {qp, nn - dn + 1} and the remainder at {rp, dn}.
              | |
| mpn_xnor_n | 
            Perform the bitwise logical exclusive or of {s1p, n} and {s2p, n}, and write the bitwise complement of the result to {rp, n}. 
              | |
| mpn_xor_n | 
            Perform the bitwise logical exclusive or of {s1p, n} and {s2p, n}, and write the result to {rp, n}. 
              | |
| mpn_zero | 
            Zero {rp, n}.
              | |
| mpn_zero_p | 
            Test {sp, n} and return 1 if the operand is zero, 0 otherwise.
              | |
| mpq_abs | 
            Set rop to the absolute value of op.
              | |
| mpq_add | 
            Set sum to addend1 + addend2. 
              | |
| mpq_canonicalize | 
            Remove any factors that are common to the numerator and denominator of op, and make the denominator positive.
              | |
| mpq_clear | 
            Free the space occupied by x.
              | |
| mpq_clears | 
            Free the space occupied by a NULL-terminated list of mpq_t variables. 
              | |
| mpq_cmp | 
            Compare op1 and op2.
              | |
| mpq_cmp_si | 
            Compare op1 and num2 / den2.
              | |
| mpq_cmp_ui | 
            Compare op1 and num2 / den2.
              | |
| mpq_cmp_z | 
            Compare op1 and op2.
              | |
| mpq_denref | 
            Return a reference to the denominator op.
              | |
| mpq_div | 
            Set quotient to dividend / divisor. 
              | |
| mpq_div_2exp | 
            Set rop to op1 / 2^op2.
              | |
| mpq_equal | 
            Return non-zero if op1 and op2 are equal, zero if they are non-equal. 
              | |
| mpq_get_d | 
            Convert op to a double, truncating if necessary (i.e. rounding towards zero). 
              | |
| mpq_get_den | 
            Set denominator to the denominator of rational.
              | |
| mpq_get_num | 
            Set numerator to the numerator of rational.
              | |
| mpq_get_str | 
            Convert op to a string of digits in base base.
              | |
| mpq_init | 
            Initialize x and set it to 0/1.
              | |
| mpq_inits | 
            Initialize a NULL-terminated list of mpq_t variables, and set their values to 0/1. 
              | |
| mpq_inp_str | 
            Read a string of digits from stream and convert them to a rational in rop.
              | |
| mpq_inv | 
            Set inverted_number to 1 / number.
              | |
| mpq_mul | 
            Set product to multiplier * multiplicand. 
              | |
| mpq_mul_2exp | 
            Set rop to op1 * 2*op2.
              | |
| mpq_neg | 
            Set negated_operand to -operand.
              | |
| mpq_numref | 
            Return a reference to the numerator op.
              | |
| mpq_out_str | 
            Output op on stdio stream stream, as a string of digits in base base.
              | |
| mpq_set | 
            Assign rop from op.
              | |
| mpq_set_d | 
            Set rop to the value of op. There is no rounding, this conversion is exact. 
              | |
| mpq_set_den | 
            Set the denominator of rational to denominator.
              | |
| mpq_set_f | 
            Set rop to the value of op. There is no rounding, this conversion is exact. 
              | |
| mpq_set_num | 
            Set the numerator of rational to numerator.
              | |
| mpq_set_si | 
            Set the value of rop to op1 / op2.
              | |
| mpq_set_str | 
            Set rop from a null-terminated string str in the given base.
              | |
| mpq_set_ui | 
            Set the value of rop to op1 / op2.
              | |
| mpq_set_z | 
            Assign rop from op.
              | |
| mpq_sgn | 
            Return +1 if op > 0, 0 if op = 0, and -1 if op < 0. 
              | |
| mpq_sub | 
            Set difference to minuend - subtrahend.
              | |
| mpq_swap | 
            Swap the values rop1 and rop2 efficiently. 
              | |
| mpz_2fac_ui | 
            Set rop to the double-factorial n!!.
              | |
| mpz_abs | 
            Set rop to the absolute value of op.
              | |
| mpz_add | 
            Set rop to op1 + op2.
              | |
| mpz_add_ui | 
            Set rop to op1 + op2.
              | |
| mpz_addmul | 
            Set rop to rop + op1 * op2.
              | |
| mpz_addmul_ui | 
            Set rop to rop + op1 * op2.
              | |
| mpz_and | 
            Set rop to op1 bitwise-and op2. 
              | |
| mpz_bin_ui | 
            Compute the binomial coefficient n over k and store the result in rop.
              | |
| mpz_bin_uiui | 
            Compute the binomial coefficient n over k and store the result in rop.
              | |
| mpz_cdiv_q | 
            Set the quotient q to ceiling(n / d).
              | |
| mpz_cdiv_q_2exp | 
            Set the quotient q to ceiling(n / 2^b).
              | |
| mpz_cdiv_q_ui | 
            Set the quotient q to ceiling(n / d), and return the remainder r = | n - q * d |.
              | |
| mpz_cdiv_qr | 
            Set the quotient q to ceiling(n / d), and set the remainder r to n - q * d.
              | |
| mpz_cdiv_qr_ui | 
            Set quotient q to ceiling(n / d), set the remainder r to n - q * d, and return | r |.
              | |
| mpz_cdiv_r | 
            Set the remainder r to n - q * d where q = ceiling(n / d).
              | |
| mpz_cdiv_r_2exp | 
            Set the remainder r to n - q * 2^b where q = ceiling(n / 2^b).
              | |
| mpz_cdiv_r_ui | 
            Set the remainder r to n - q * d where q = ceiling(n / d), and return | r |.
              | |
| mpz_cdiv_ui | 
            Return the remainder | r | where r = n - q * d, and where q = ceiling(n / d).
              | |
| mpz_clear | 
            Free the space occupied by x.
              | |
| mpz_clears | 
            Free the space occupied by a NULL-terminated list of mpz_t variables.
              | |
| mpz_clrbit | 
            Clear bit bit_index in rop.
              | |
| mpz_cmp | 
            Compare op1 and op2.
              | |
| mpz_cmp_d | 
            Compare op1 and op2.
              | |
| mpz_cmp_si | 
            Compare op1 and op2.
              | |
| mpz_cmp_ui | 
            Compare op1 and op2.
              | |
| mpz_cmpabs | 
            Compare the absolute values of op1 and op2.
              | |
| mpz_cmpabs_d | 
            Compare the absolute values of op1 and op2.
              | |
| mpz_cmpabs_ui | 
            Compare the absolute values of op1 and op2.
              | |
| mpz_com | 
            Set rop to the one’s complement of op.
              | |
| mpz_combit | 
            Complement bit bit_index in rop. 
              | |
| mpz_congruent_2exp_p | 
            Return non-zero if n is congruent to c modulo 2^b.
              | |
| mpz_congruent_p | 
            Return non-zero if n is congruent to c modulo d.
              | |
| mpz_congruent_ui_p | 
            Return non-zero if n is congruent to c modulo d.
              | |
| mpz_divexact | 
            Set q to n / d when it is known in advance that d divides n. 
              | |
| mpz_divexact_ui | 
            Set q to n / d when it is known in advance that d divides n. 
              | |
| mpz_divisible_2exp_p | 
            Return non-zero if n is exactly divisible by 2^b.
              | |
| mpz_divisible_p | 
            Return non-zero if n is exactly divisible by d.
              | |
| mpz_divisible_ui_p | 
            Return non-zero if n is exactly divisible by d.
              | |
| mpz_even_p | 
            Determine whether op is even.
              | |
| mpz_export(void_ptr, ptrsize_t, Int32, size_t, Int32, size_t, mpz_t) | 
            Fill rop with word data from op.
              | |
| mpz_export(void_ptr, size_t, Int32, size_t, Int32, size_t, mpz_t) | 
            Fill rop with word data from op.
              | |
| mpz_fac_ui | 
            Set rop to the factorial n!.
              | |
| mpz_fdiv_q | 
            Set the quotient q to floor(n / d).
              | |
| mpz_fdiv_q_2exp | 
            Set the quotient q to floor(n / 2^b).
              | |
| mpz_fdiv_q_ui | 
            Set the quotient q to floor(n / d), and return the remainder r = | n - q * d |.
              | |
| mpz_fdiv_qr | 
            Set the quotient q to floor(n / d), and set the remainder r to n - q * d.
              | |
| mpz_fdiv_qr_ui | 
            Set quotient q to floor(n / d), set the remainder r to n - q * d, and return | r |.
              | |
| mpz_fdiv_r | 
            Set the remainder r to n - q * d where q = floor(n / d).
              | |
| mpz_fdiv_r_2exp | 
            Set the remainder r to n - q * 2^b where q = floor(n / 2^b).
              | |
| mpz_fdiv_r_ui | 
            Set the remainder r to n - q * d where q = floor(n / d), and return | r |.
              | |
| mpz_fdiv_ui | 
            Return the remainder | r | where r = n - q * d, and where q = floor(n / d).
              | |
| mpz_fib_ui | 
            Sets fn to to F[n], the n’th Fibonacci number. 
              | |
| mpz_fib2_ui | 
            Sets fn to F[n], and fnsub1 to F[n - 1]. 
              | |
| mpz_fits_sint_p | 
            Return non-zero iff the value of op fits in a signed 32-bit integer. Otherwise, return zero.
              | |
| mpz_fits_slong_p | 
            Return non-zero iff the value of op fits in a signed 32-bit integer. Otherwise, return zero.
              | |
| mpz_fits_sshort_p | 
            Return non-zero iff the value of op fits in a signed 16-bit integer. Otherwise, return zero.
              | |
| mpz_fits_uint_p | 
            Return non-zero iff the value of op fits in an unsigned 32-bit integer. Otherwise, return zero.
              | |
| mpz_fits_ulong_p | 
            Return non-zero iff the value of op fits in an unsigned 32-bit integer. Otherwise, return zero.
              | |
| mpz_fits_ushort_p | 
            Return non-zero iff the value of op fits in an unsigned 16-bit integer. Otherwise, return zero.
              | |
| mpz_gcd | 
            Set rop to the greatest common divisor of op1 and op2.
              | |
| mpz_gcd_ui | 
            Compute the greatest common divisor of op1 and op2. If rop is not null, store the result there. 
              | |
| mpz_gcdext | 
            Set g to the greatest common divisor of a and b, and in addition set s and t to coefficients satisfying a * s + b * t = g.
              | |
| mpz_get_d | 
            Convert op to a double, truncating if necessary (i.e. rounding towards zero).
              | |
| mpz_get_d_2exp | 
            Convert op to a double, truncating if necessary (i.e. rounding towards zero), and returning the exponent separately.
              | |
| mpz_get_si | 
            Return the value of op as an signed long.
              | |
| mpz_get_str | 
            Convert op to a string of digits in base base.
              | |
| mpz_get_ui | 
            Return the value of op as an unsigned long.
              | |
| mpz_getlimbn | 
            Return limb number n from op.
              | |
| mpz_hamdist | 
            Return the hamming distance between the two operands.
              | |
| mpz_import | 
            Set rop from an array of word data at op.
              | |
| mpz_init | 
            Initialize x, and set its value to 0.
              | |
| mpz_init_set | 
            Initialize rop with limb space and set the initial numeric value from op.
              | |
| mpz_init_set_d | 
            Initialize rop with limb space and set the initial numeric value from op.
              | |
| mpz_init_set_si | 
            Initialize rop with limb space and set the initial numeric value from op.
              | |
| mpz_init_set_str | 
            Initialize rop and set its value like mpz_set_str.
              | |
| mpz_init_set_ui | 
            Initialize rop with limb space and set the initial numeric value from op.
              | |
| mpz_init2 | 
            Initialize x, with space for n-bit numbers, and set its value to 0.
              | |
| mpz_inits | 
            Initialize a NULL-terminated list of mpz_t variables, and set their values to 0.
              | |
| mpz_inp_raw | ||
| mpz_inp_str | 
            Input a possibly white-space preceded string in base base from stdio stream stream, and put the read integer in rop. 
              | |
| mpz_invert | 
            Compute the inverse of op1 modulo op2 and put the result in rop.
              | |
| mpz_ior | 
            Set rop to op1 bitwise inclusive-or op2. 
              | |
| mpz_jacobi | 
            Calculate the Jacobi symbol (a/b).
              | |
| mpz_kronecker | 
            Calculate the Jacobi symbol (a/b) with the Kronecker extension (a/2) = (2/a) when a odd, or (a/2) = 0 when a even. 
              | |
| mpz_kronecker_si | 
            Calculate the Jacobi symbol (a/b) with the Kronecker extension (a/2) = (2/a) when a odd, or (a/2) = 0 when a even. 
              | |
| mpz_kronecker_ui | 
            Calculate the Jacobi symbol (a/b) with the Kronecker extension (a/2) = (2/a) when a odd, or (a/2) = 0 when a even. 
              | |
| mpz_lcm | 
            Set rop to the least common multiple of op1 and op2.
              | |
| mpz_lcm_ui | 
            Set rop to the least common multiple of op1 and op2.
              | |
| mpz_legendre | 
            Calculate the Legendre symbol (a/p).
              | |
| mpz_limbs_finish | 
            Updates the internal size field of x.
              | |
| mpz_limbs_modify | 
            Return a pointer to the limb array of x, intended for write access.
              | |
| mpz_limbs_read | 
            Return a pointer to the limb array representing the absolute value of x.
              | |
| mpz_limbs_write | 
            Return a pointer to the limb array of x, intended for write access.
              | |
| mpz_lucnum_ui | 
            Sets ln to to L[n], the n’th Lucas number. 
              | |
| mpz_lucnum2_ui | 
            Sets ln to L[n], and lnsub1 to L[n - 1]. 
              | |
| mpz_mfac_uiui | 
            Set rop to the m-multi-factorial n!^(m)n.
              | |
| mpz_millerrabin | 
            An implementation of the probabilistic primality test found in Knuth's Seminumerical Algorithms book.
              | |
| mpz_mod | 
            Set r to n mod d.
              | |
| mpz_mod_ui | 
            Set r to n mod d.
              | |
| mpz_mul | 
            Set rop to op1 * op2.
              | |
| mpz_mul_2exp | 
            Set rop to op1 * 2^op2.
              | |
| mpz_mul_si | 
            Set rop to op1 * op2.
              | |
| mpz_mul_ui | 
            Set rop to op1 * op2.
              | |
| mpz_neg | 
            Set rop to -op.
              | |
| mpz_nextprime | 
            Set rop to the next prime greater than op.
              | |
| mpz_odd_p | 
            Determine whether op is odd.
              | |
| mpz_out_raw | 
            Output op on stdio stream stream, in raw binary format.
              | |
| mpz_out_str | 
            Output op on stdio stream stream, as a string of digits in base base.
              | |
| mpz_perfect_power_p | 
            Return non-zero if op is a perfect power, i.e., if there exist integers a and b, with b > 1, such that op = a^b. 
              | |
| mpz_perfect_square_p | 
            Return non-zero if op is a perfect square, i.e., if the square root of op is an integer.
              | |
| mpz_popcount | 
            Return the population count of op.
              | |
| mpz_pow_ui | 
            Set rop to base^exp. The case 0^0 yields 1. 
              | |
| mpz_powm | 
            Set rop to (base^exp) modulo mod. 
              | |
| mpz_powm_sec | 
            Set rop to (base^exp) modulo mod.
              | |
| mpz_powm_ui | 
            Set rop to (base^exp) modulo mod. 
              | |
| mpz_primorial_ui | 
            Set rop to the primorial of n, i.e. the product of all positive prime numbers ≤ n. 
              | |
| mpz_probab_prime_p | 
            Determine whether n is prime.
              | |
| mpz_random | 
            Generate a random integer of at most max_size limbs.
              | |
| mpz_random2 | 
            Generate a random integer of at most max_size limbs, with long strings of zeros and ones in the binary representation.
              | |
| mpz_realloc2 | 
            Change the space allocated for x to n bits.
              | |
| mpz_remove | 
            Remove all occurrences of the factor f from op and store the result in rop.
              | |
| mpz_roinit_n | 
            Special initialization of x, using the given limb array and size.
              | |
| mpz_root | 
            Set rop to the truncated integer part of the nth root of op.
              | |
| mpz_rootrem | 
            Set root to the truncated integer part of the nth root of u. Set rem to the remainder, u - root^n. 
              | |
| mpz_rrandomb | 
            Generate a random integer with long strings of zeros and ones in the binary representation.
              | |
| mpz_scan0 | 
            Scan op for 0 bit.
              | |
| mpz_scan1 | 
            Scan op for 1 bit.
              | |
| mpz_set | 
            Set the value of rop from op.
              | |
| mpz_set_d | 
            Set the value of rop from op.
              | |
| mpz_set_f | 
            Set the value of rop from op.
              | |
| mpz_set_q | 
            Set the value of rop from op.
              | |
| mpz_set_si | 
            Set the value of rop from op.
              | |
| mpz_set_str | 
            Set the value of rop from str, a null-terminated C string in base base.
              | |
| mpz_set_ui | 
            Set the value of rop from op.
              | |
| mpz_setbit | 
            Set bit bit_index in rop.
              | |
| mpz_sgn | 
            Return +1 if op > 0, 0 if op = 0, and -1 if op < 0.
              | |
| mpz_si_kronecker | 
            Calculate the Jacobi symbol (a/b) with the Kronecker extension (a/2) = (2/a) when a odd, or (a/2) = 0 when a even. 
              | |
| mpz_size | 
             Return the size of op measured in number of limbs.
               | |
| mpz_sizeinbase | 
            Return the size of op measured in number of digits in the given base.
              | |
| mpz_sqrt | 
            Set rop to the truncated integer part of the square root of op.
              | |
| mpz_sqrtrem | 
            Set rop1 to the truncated integer part of the square root of op, like mpz_sqrt. Set rop2 to the remainder op - rop1 * rop1, which will be zero if op is a perfect square.
              | |
| mpz_sub | 
            Set rop to op1 - op2.
              | |
| mpz_sub_ui | 
            Set rop to op1 - op2.
              | |
| mpz_submul | 
            Set rop to rop - op1 * op2.
              | |
| mpz_submul_ui | 
            Set rop to rop - op1 * op2.
              | |
| mpz_swap | 
            Swap the values rop1 and rop2 efficiently.
              | |
| mpz_tdiv_q | 
            Set the quotient q to trunc(n / d).
              | |
| mpz_tdiv_q_2exp | 
            Set the quotient q to trunc(n / 2^b).
              | |
| mpz_tdiv_q_ui | 
            Set the quotient q to trunc(n / d), and return the remainder r = | n - q * d |.
              | |
| mpz_tdiv_qr | 
            Set the quotient q to trunc(n / d), and set the remainder r to n - q * d.
              | |
| mpz_tdiv_qr_ui | 
            Set quotient q to trunc(n / d), set the remainder r to n - q * d, and return | r |.
              | |
| mpz_tdiv_r | 
            Set the remainder r to n - q * d where q = trunc(n / d).
              | |
| mpz_tdiv_r_2exp | 
            Set the remainder r to n - q * 2^b where q = trunc(n / 2^b).
              | |
| mpz_tdiv_r_ui | 
            Set the remainder r to n - q * d where q = trunc(n / d), and return | r |.
              | |
| mpz_tdiv_ui | 
            Return the remainder | r | where r = n - q * d, and where q = trunc(n / d).
              | |
| mpz_tstbit | 
            Test bit bit_index in op and return 0 or 1 accordingly. 
              | |
| mpz_ui_kronecker | 
            Calculate the Jacobi symbol (a/b) with the Kronecker extension (a/2) = (2/a) when a odd, or (a/2) = 0 when a even. 
              | |
| mpz_ui_pow_ui | 
            Set rop to base^exp. The case 0^0 yields 1.
              | |
| mpz_ui_sub | 
            Set rop to op1 - op2.
              | |
| mpz_urandomb | 
            Generate a uniformly distributed random integer in the range 0 to 2^n - 1, inclusive.
              | |
| mpz_urandomm | 
            Generate a uniform random integer in the range 0 to n - 1, inclusive.
              | |
| mpz_xor | 
            Set rop to op1 bitwise exclusive-or op2. 
              | |
| reallocate | 
            Resize a previously allocated block ptr of old_size bytes to be new_size bytes.
              | |
| ZeroMemory | 
            The ZeroMemory routine fills a block of memory with zeros, given a pointer to the block and the length, in bytes, to be filled.
              | 
| Name | Description | |
|---|---|---|
| gmp_version | 
            The GMP version number in the form “i.j.k”. This release is "6.1.2".
              | |
| mp_bits_per_limb | 
            The number of bits per limb.
              | |
| mp_bytes_per_limb | 
            The number of bytes per limb.
              | |
| mp_uint_per_limb | 
            The number of 32-bit, unsigned integers per limb.
              |