Learn R Programming

openfhe.R (version 1.6.1)

get_modulus: The ciphertext modulus

Description

The modulus of an object, as a string of decimal digits, because it normally exceeds what an R number holds exactly.

Usage

get_modulus(x, ...)

Value

A character string of decimal digits.

Arguments

x

A CryptoContext or an ElementParams object.

...

Reserved for future method-specific arguments.

Details

For a CryptoContext or an ElementParams object it is the composite ciphertext modulus Q, the product of the RNS moduli. openfhe-python returns this value for a CryptoContext as a floating-point number; R returns it exactly.

See Also

get_modulus_ckks(), get_root_of_unity(), get_element_modulus()

Examples

Run this code
cc <- fhe_context("BFV", plaintext_modulus = 65537, multiplicative_depth = 1)
get_modulus(cc)

Run the code above in your browser using DataLab