Skip to content

Commit

Permalink
fix catiks
Browse files Browse the repository at this point in the history
  • Loading branch information
nindanaoto committed Aug 14, 2024
1 parent f1524e0 commit 415e998
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/keyswitch.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,13 +112,13 @@ void CatIdentityKeySwitch(
for (int j = 0; j < P::t; j++) {
for (int cat = 0; cat < numcat; cat++) {
const int32_t aij =
((aibar >> (std::numeric_limits<typename P::domainP::T>::digits -
((aibarcat[cat] >> (std::numeric_limits<typename P::domainP::T>::digits -
(j + 1) * P::basebit)) &
mask)-halfbase;
if (aij > 0)
for (int k = 0; k <= P::targetP::k * P::targetP::n; k++)
res[cat][k] -= ksk[i][j][aij - 1][k];
if (aij < 0)
else if (aij < 0)
for (int k = 0; k <= P::targetP::k * P::targetP::n; k++)
res[cat][k] += ksk[i][j][-aij - 1][k];
}
Expand Down

0 comments on commit 415e998

Please sign in to comment.