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

Add summation example #12

Merged
merged 2 commits into from
Mar 12, 2021
Merged

Add summation example #12

merged 2 commits into from
Mar 12, 2021

Conversation

jvsg
Copy link
Contributor

@jvsg jvsg commented Mar 9, 2021

This adds an example where two clients wish to add their bit vectors using two servers.

examples/sum.rs Outdated
let (share2_1, share2_2) = client2.encode_simple(&data2).unwrap();
let eval_at = Field::from(12313);

let mut server1 = Server::new(dim, true, priv_key.clone());
Copy link
Collaborator

@tlepoint tlepoint Mar 9, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It may be preferable to use different public and private keys for the servers, to get a more representative example.

(Nit: You may also get the public key from the private key instead of specifying both)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the suggestion. Latest commit should fix that.

@tgeoghegan tgeoghegan merged commit 48e2c9e into divviup:main Mar 12, 2021
@tgeoghegan
Copy link
Contributor

Thank you for your contribution!

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

Successfully merging this pull request may close these issues.

3 participants