gmp_libmpz_clrbit Method |
Namespace: Math.Gmp.Native
public static void mpz_clrbit( mpz_t rop, mp_bitcnt_t bit_index )
Public Shared Sub mpz_clrbit ( rop As mpz_t, bit_index As mp_bitcnt_t )
public: static void mpz_clrbit( mpz_t^ rop, mp_bitcnt_t bit_index )
static member mpz_clrbit : rop : mpz_t * bit_index : mp_bitcnt_t -> unit
The function behaves as if twos complement arithmetic were used (although sign-magnitude is the actual implementation). The least significant bit is number 0.
// Create, initialize, and set the value of rop to 70. mpz_t rop = new mpz_t(); gmp_lib.mpz_init_set_si(rop, 70); // Clear bit 3 of rop. gmp_lib.mpz_clrbit(rop, 3U); // Assert that rop is 70. Assert.IsTrue(gmp_lib.mpz_get_si(rop) == 70); // Release unmanaged memory allocated for rop. gmp_lib.mpz_clear(rop);
' Create, initialize, and set the value of rop to 70. Dim rop As New mpz_t() gmp_lib.mpz_init_set_si(rop, 70) ' Clear bit 3 of rop. gmp_lib.mpz_clrbit(rop, 3UI) ' Assert that rop is 70. Assert.IsTrue(gmp_lib.mpz_get_si(rop) = 70) ' Release unmanaged memory allocated for rop. gmp_lib.mpz_clear(rop)
No code example is currently available or this language may not be supported.
No code example is currently available or this language may not be supported.