@@ -230,13 +230,13 @@ void ArbitraryLUT(BigInteger QBFVInit, BigInteger PInput, BigInteger POutput, Bi
230230 std::cerr << " ]" << std::endl;
231231
232232 auto exact (x);
233- std::transform (x.begin (), x.end (), exact.begin (), [&](const int64_t & elem) {
233+ std::transform (x.begin (), x.end (), exact.begin (), [&](int64_t elem) {
234234 return (func (elem) > POutput.ConvertToDouble () / 2 .) ? func (elem) - POutput.ConvertToInt () : func (elem);
235235 });
236236
237237 std::transform (exact.begin (), exact.end (), computed.begin (), exact.begin (), std::minus<int64_t >());
238238 std::transform (exact.begin (), exact.end (), exact.begin (),
239- [&](const int64_t & elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
239+ [&](int64_t elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
240240 auto max_error_it = std::max_element (exact.begin (), exact.end ());
241241 std::cerr << " Max absolute error obtained: " << *max_error_it << std::endl << std::endl;
242242}
@@ -393,12 +393,12 @@ void MultiValueBootstrapping(BigInteger QBFVInit, BigInteger PInput, BigInteger
393393 Ciphertext<DCRTPoly> ctxtAfterFBT1, ctxtAfterFBT2;
394394
395395 auto exact (x);
396- std::transform (x.begin (), x.end (), exact.begin (), [&](const int64_t & elem) {
396+ std::transform (x.begin (), x.end (), exact.begin (), [&](int64_t elem) {
397397 return (func1 (elem) > POutput.ConvertToDouble () / 2 .) ? func1 (elem) - POutput.ConvertToInt () : func1 (elem);
398398 });
399399
400400 auto exact2 (x);
401- std::transform (x.begin (), x.end (), exact2.begin (), [&](const int64_t & elem) {
401+ std::transform (x.begin (), x.end (), exact2.begin (), [&](int64_t elem) {
402402 return (func2 (elem) > POutput.ConvertToDouble () / 2 .) ? func2 (elem) - POutput.ConvertToInt () : func2 (elem);
403403 });
404404
@@ -459,7 +459,7 @@ void MultiValueBootstrapping(BigInteger QBFVInit, BigInteger PInput, BigInteger
459459
460460 std::transform (exact.begin (), exact.end (), computed.begin (), exact.begin (), std::minus<int64_t >());
461461 std::transform (exact.begin (), exact.end (), exact.begin (),
462- [&](const int64_t & elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
462+ [&](int64_t elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
463463 auto max_error_it = std::max_element (exact.begin (), exact.end ());
464464 std::cerr << " Max absolute error obtained in the first LUT: " << *max_error_it << std::endl << std::endl;
465465
@@ -473,7 +473,7 @@ void MultiValueBootstrapping(BigInteger QBFVInit, BigInteger PInput, BigInteger
473473
474474 std::transform (exact2.begin (), exact2.end (), computed.begin (), exact2.begin (), std::minus<int64_t >());
475475 std::transform (exact2.begin (), exact2.end (), exact2.begin (),
476- [&](const int64_t & elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
476+ [&](int64_t elem) { return (std::abs (elem)) % (POutput.ConvertToInt ()); });
477477 max_error_it = std::max_element (exact2.begin (), exact2.end ());
478478 std::cerr << " Max absolute error obtained in the second LUT: " << *max_error_it << std::endl << std::endl;
479479}
@@ -514,7 +514,7 @@ void MultiPrecisionSign(BigInteger QBFVInit, BigInteger PInput, BigInteger PDigi
514514
515515 auto exact (x);
516516 std::transform (x.begin (), x.end (), exact.begin (),
517- [&](const int64_t & elem) { return (elem >= PInput.ConvertToDouble () / 2 .); });
517+ [&](int64_t elem) { return (elem >= PInput.ConvertToDouble () / 2 .); });
518518
519519 /* 4. The case of Boolean LUTs using the first order Trigonometric Hermite Interpolation
520520 * supports an optimized implementation.
@@ -691,7 +691,7 @@ void MultiPrecisionSign(BigInteger QBFVInit, BigInteger PInput, BigInteger PDigi
691691
692692 std::transform (exact.begin (), exact.end (), computed.begin (), exact.begin (), std::minus<int64_t >());
693693 std::transform (exact.begin (), exact.end (), exact.begin (),
694- [&](const int64_t & elem) { return (std::abs (elem)) % (pOrig.ConvertToInt ()); });
694+ [&](int64_t elem) { return (std::abs (elem)) % (pOrig.ConvertToInt ()); });
695695 auto max_error_it = std::max_element (exact.begin (), exact.end ());
696696 std::cerr << " \n Max absolute error obtained: " << *max_error_it << std::endl << std::endl;
697697 }
0 commit comments