tfhe-rs icon indicating copy to clipboard operation
tfhe-rs copied to clipboard

(G)lweCiphertextList::from_fn methods

Open leonardohn opened this issue 2 months ago • 3 comments

What is the problem you want to solve and can not with the current version? There is no straightforward way of arbitrarily initializing (G)lweCiphertextList structs.

Describe the solution you'd like Implement methods named (G)lweCiphertextList::from_fn, that instead of receiving a fixed initialization value for the whole list, receives a closure with an usize parameter (the index) and returns the plaintext initialization value, so the user is able to initialize and encrypt the list arbitrarily, similar to std::array::from_fn methods.

Describe alternatives you've considered None.

Additional context None.

leonardohn avatar Apr 27 '24 01:04 leonardohn