MCPcopy Create free account
hub / github.com/data61/MP-SPDZ / sub

Function sub

FHE/Ciphertext.cpp:50–57  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

48
49
50void sub(Ciphertext& ans,const Ciphertext& c0,const Ciphertext& c1)
51{
52 if (c0.params!=c1.params) { throw params_mismatch(); }
53 if (ans.params!=c1.params) { throw params_mismatch(); }
54 ans.pk_id = check_pk_id(c0.pk_id, c1.pk_id);
55 sub(ans.cc0,c0.cc0,c1.cc0);
56 sub(ans.cc1,c0.cc1,c1.cc1);
57}
58
59
60void mul(Ciphertext& ans,const Ciphertext& c0,const Ciphertext& c1,

Callers

nothing calls this directly

Calls 2

params_mismatchClass · 0.85
check_pk_idFunction · 0.85

Tested by

no test coverage detected