Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thin Slots to Coeff does not work for p=257? #506

Open
AYANG005 opened this issue Mar 16, 2024 · 0 comments
Open

Thin Slots to Coeff does not work for p=257? #506

AYANG005 opened this issue Mar 16, 2024 · 0 comments

Comments

@AYANG005
Copy link

Hi everyone,

Does anyone have experience with using the "thin" slots to coefficients transformation in HElib for the p=257 case? It doesn't seem to output the sparsely packed slot elements as the coefficients of the plaintext polynomial for some reason. When I run it with p=127 however, it works. Would anyone know why this might be the case, and perhaps know anyway around it?

Here's what I am running for that portion, with the sparse entires of encoded_ptxt not corresponding to my previous slots:
//Slots to Coeff map
NTL::Vec mvec;
mvec.append(65536);
ThinEvalMap tested = ThinEvalMap(ea, false, mvec, false, false);
tested.apply(ctxt);
ZZX encoded_ptxt;
ZZX unmoded_ptxt;
secret_key.Decrypt(encoded_ptxt, ctxt, unmoded_ptxt);
cout << "Second encoded ptxt: " << encoded_ptxt << endl;
cout << ctxt.isCorrect() << endl;

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant