I’m using BFVRNS to encrypt a plaintext encoded by coefficient packing. After some operations, I only need to decrypt the ciphertext coefficients at several specific positions (e.g., the 10th coefficient). Can I only send those coefficients in the ciphertext I’m interested in to reduce communication costs? Or can I set the unused coefficients (e.g., the 1st to the 9th) in the ciphertext to 0 to compress the ciphertext?
@narger is correct, You won’t be able to compress the ciphertext by setting ciphertext coefficients to 0, but you can multiply by a mask vector. However, multiplying by a mask vector will not compress the ciphertext. It is possible to compress the ciphertext with other methods, but we have not added support for this yet for BFVRNS. We just created the issue on GitHub. Add BFV support for Compress · Issue #341 · openfheorg/openfhe-development · GitHub
If we only need part of the coefficients in pt, I think we can simply set the unused coefficients in ciphertext cv[0] to zero, or just drop those to reduce communication. I agree that we cannot change ciphertext cv[1]. Please correct me if I make anything wrong here.
I think you are assuming that each coefficient is somehow correlated to each value in the ciphertext (as value = f(coefficient) ), but I don’t think is like that
What do you mean by “value in the ciphertext” here? I’m using coefficient packing and I just need to get the 10th coefficient of the pt above. I don’t think I’m making any unreasonable assumptions. I know that this is doable in seal (OpenCheetah/hom_fc_ss.cc at main · Alibaba-Gemini-Lab/OpenCheetah · GitHub) and I’m trying to switch to openfhe to get better performance.