gmp.z

Multiple precision integers (Z).

Members

Aliases

CZ
alias CZ = _MpZ!true
Undocumented in source.
CopyableMpZ
alias CopyableMpZ = _MpZ!true

Copyable MpZ.

MpZ
alias MpZ = _MpZ!false

Non-copyable MpZ.

Z
alias Z = MpZ
Undocumented in source.
__mp_limb_t
alias __mp_limb_t = ulong
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
mp_bitcnt_t
alias mp_bitcnt_t = ulong
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
mpz_ptr
alias mpz_ptr = __mpz_struct*
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
mpz_srcptr
alias mpz_srcptr = const(__mpz_struct)*
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.

Enums

WordEndianess
enum WordEndianess

WordEndianess of serialization in MpZ.serialize and unserialization-construction from integer array.

WordOrder
enum WordOrder

Word-order of serialization in MpZ.serialize and unserialization-construction from integer array.

isLazyMpZExpr
eponymoustemplate isLazyMpZExpr(T)

Is true if type T is lazy (not yet evaluated) MpZ-expression.

isMpZExpr
eponymoustemplate isMpZExpr(T)

Call unittests taking long to execute. Is true if type T can be evaluated to a MpZ value.

Functions

__gmpz_abs
void __gmpz_abs(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_add
void __gmpz_add(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_add_ui
void __gmpz_add_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_addmul
void __gmpz_addmul(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_addmul_ui
void __gmpz_addmul_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_and
void __gmpz_and(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cdiv_q_ui
void __gmpz_cdiv_q_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cdiv_qr_ui
void __gmpz_cdiv_qr_ui(mpz_ptr , mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cdiv_r_ui
ulong __gmpz_cdiv_r_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cdiv_ui
void __gmpz_cdiv_ui(mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_clear
void __gmpz_clear(mpz_ptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_clrbit
void __gmpz_clrbit(mpz_ptr , mp_bitcnt_t )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmp
int __gmpz_cmp(mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmp_d
int __gmpz_cmp_d(mpz_srcptr , double )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmp_si
int __gmpz_cmp_si(mpz_srcptr , long )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmp_ui
int __gmpz_cmp_ui(mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmpabs
int __gmpz_cmpabs(mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmpabs_d
int __gmpz_cmpabs_d(mpz_srcptr , double )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_cmpabs_ui
int __gmpz_cmpabs_ui(mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_com
void __gmpz_com(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_combit
void __gmpz_combit(mpz_ptr , mp_bitcnt_t )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_export
void* __gmpz_export(void* , size_t* , int , size_t , int , size_t , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fdiv_q_ui
void __gmpz_fdiv_q_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fdiv_qr_ui
void __gmpz_fdiv_qr_ui(mpz_ptr , mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fdiv_r_ui
ulong __gmpz_fdiv_r_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fdiv_ui
void __gmpz_fdiv_ui(mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_sint_p
int __gmpz_fits_sint_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_slong_p
int __gmpz_fits_slong_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_sshort_p
int __gmpz_fits_sshort_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_uint_p
int __gmpz_fits_uint_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_ulong_p
int __gmpz_fits_ulong_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_fits_ushort_p
int __gmpz_fits_ushort_p(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_gcd
void __gmpz_gcd(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_gcd_ui
ulong __gmpz_gcd_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_get_d
double __gmpz_get_d(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_get_si
long __gmpz_get_si(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_get_str
char* __gmpz_get_str(char* , int , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_get_ui
ulong __gmpz_get_ui(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_import
void __gmpz_import(mpz_ptr , size_t , int , size_t , int , size_t , void* )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init
void __gmpz_init(mpz_ptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init_set
void __gmpz_init_set(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init_set_d
void __gmpz_init_set_d(mpz_ptr , double )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init_set_si
void __gmpz_init_set_si(mpz_ptr , long )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init_set_str
int __gmpz_init_set_str(mpz_ptr , char* , int )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_init_set_ui
void __gmpz_init_set_ui(mpz_ptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_invert
int __gmpz_invert(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_ior
void __gmpz_ior(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_lcm
void __gmpz_lcm(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_lcm_ui
void __gmpz_lcm_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_mod
void __gmpz_mod(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_mul
void __gmpz_mul(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_mul_2exp
void __gmpz_mul_2exp(mpz_ptr , mpz_srcptr , mp_bitcnt_t )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_mul_si
void __gmpz_mul_si(mpz_ptr , mpz_srcptr , long )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_mul_ui
void __gmpz_mul_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_neg
void __gmpz_neg(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_nextprime
void __gmpz_nextprime(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_perfect_power_p
void __gmpz_perfect_power_p(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_popcount
mp_bitcnt_t __gmpz_popcount(mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_pow_ui
void __gmpz_pow_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_powm
void __gmpz_powm(mpz_ptr , mpz_srcptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_powm_ui
void __gmpz_powm_ui(mpz_ptr , mpz_srcptr , ulong , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_root
void __gmpz_root(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_rootrem
void __gmpz_rootrem(mpz_ptr , mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_set
void __gmpz_set(mpz_ptr rop, mpz_srcptr op)
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_set_d
void __gmpz_set_d(mpz_ptr rop, double op)
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_set_si
void __gmpz_set_si(mpz_ptr rop, long op)
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_set_str
int __gmpz_set_str(mpz_ptr , char* , int )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_set_ui
void __gmpz_set_ui(mpz_ptr rop, ulong op)
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_setbit
void __gmpz_setbit(mpz_ptr , mp_bitcnt_t )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_sizeinbase
size_t __gmpz_sizeinbase(mpz_srcptr , int )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_sqrt
void __gmpz_sqrt(mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_sqrtrem
void __gmpz_sqrtrem(mpz_ptr , mpz_ptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_sub
void __gmpz_sub(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_sub_ui
void __gmpz_sub_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_swap
void __gmpz_swap(mpz_ptr , mpz_ptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_q
void __gmpz_tdiv_q(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_q_ui
void __gmpz_tdiv_q_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_qr_ui
void __gmpz_tdiv_qr_ui(mpz_ptr , mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_r
void __gmpz_tdiv_r(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_r_ui
ulong __gmpz_tdiv_r_ui(mpz_ptr , mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tdiv_ui
void __gmpz_tdiv_ui(mpz_srcptr , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_tstbit
int __gmpz_tstbit(mpz_srcptr , mp_bitcnt_t )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_ui_pow_ui
void __gmpz_ui_pow_ui(mpz_ptr , ulong , ulong )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_ui_sub
void __gmpz_ui_sub(mpz_ptr , ulong , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
__gmpz_xor
void __gmpz_xor(mpz_ptr , mpz_srcptr , mpz_srcptr )
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.
abs
_MpZ!copyable abs(_MpZ!copyable x)

Get absolute value of x.

absUnsign
Unsigned!T absUnsign(_MpZ!copyable x)

Get the absolute value of x converted to the corresponding unsigned type.

add
_MpZ!copyable add(_MpZ!copyable x, _MpZ!copyable y)

Get sum of x and y (x + y).

cmpabs
int cmpabs(_MpZ!copyable x, _MpZ!copyable y)
int cmpabs(_MpZ!copyable x, double y)
int cmpabs(_MpZ!copyable x, ulong y)

Comparison of the absolute values of x and y.

gcd
_MpZ!copyable gcd(_MpZ!copyable x, _MpZ!copyable y)
_MpZ!copyable gcd(_MpZ!copyable x, ulong y)

Get greatest common divisor (gcd) of x and y.

invert
_MpZ!copyable invert(_MpZ!copyable base, _MpZ!copyable mod)

Get base ^^ -1 (modulo mod).

lcm
_MpZ!copyable lcm(_MpZ!copyable x, _MpZ!copyable y)
_MpZ!copyable lcm(_MpZ!copyable x, ulong y)

Get least common multiple (lcm) of x and y.

mpz
_MpZ!copyable mpz(Args args)

Instantiator for MpZ.

mul
_MpZ!copyable mul(_MpZ!copyable x, _MpZ!copyable y)

Get product of x and y (x + y).

nextPrime
_MpZ!copyable nextPrime(_MpZ!copyable x)

Get next prime greater than x.

onesComplement
_MpZ!copyable onesComplement(_MpZ!copyable x)

Get one's complement of value of x.

powm
_MpZ!copyable powm(_MpZ!copyable base, _MpZ!copyable exp, _MpZ!copyable mod)
_MpZ!copyable powm(_MpZ!copyable base, ulong exp, _MpZ!copyable mod)

Get base ^^ exp (modulo mod).

sub
_MpZ!copyable sub(_MpZ!copyable x, _MpZ!copyable y)

Get difference of x and y (x - y).

swap
void swap(_MpZ!copyable x, _MpZ!copyable y)

Swap contents of x with contents of y.

toDecimalString
string toDecimalString(_MpZ!copyable x)

Get x as a string in decimal base.

toHex
string toHex(_MpZ!copyable x)

Get x as a uppercased string in hexadecimal base without any base prefix (0x).

Structs

__mpz_struct
struct __mpz_struct
Undocumented in source but is binding to C. You might be able to learn more by searching the web for its name.

Meta