[][src]Function concrete_lib::operators::crypto::rlwe::get_sign_decompose_mask_size

pub fn get_sign_decompose_mask_size(
    dimension: usize,
    polynomial_size: usize,
    level: usize
) -> usize

Encrypts a message with a public key (to be implemented)

Arguments

  • result a slice where the ciphertext will be stored
  • public_key the public key under which to encrypt the message
  • mu the encoded message to be encrypted return the needed size for a vector of i32 to contain the mask of a signed decomposition of an RLWE

Arguments

  • dimension - size of the mask
  • polynomial_size - max degree of the polynomials + 1
  • level - number of blocks of the gadget matrix

Output

  • the desired size as a usize

Example

use concrete_lib::operators::crypto::rlwe;

// settings
let dimension: usize = 128;
let polynomial_size: usize = 256;
let level: usize = 3;

let mask_size: usize = rlwe::get_sign_decompose_mask_size(dimension, polynomial_size, level);