| 3678 | } |
| 3679 | |
| 3680 | void ModularArithmetic::SimultaneousExponentiate(Integer *results, |
| 3681 | const Integer &base, const Integer *exponents, |
| 3682 | unsigned int exponentsCount) const |
| 3683 | { |
| 3684 | if (modulus.IsOdd()) |
| 3685 | { |
| 3686 | MontgomeryRepresentation dr(modulus); |
| 3687 | dr.SimultaneousExponentiate(results, dr.ConvertIn(base), exponents, |
| 3688 | exponentsCount); |
| 3689 | for (unsigned int i=0; i<exponentsCount; i++) |
| 3690 | results[i] = dr.ConvertOut(results[i]); |
| 3691 | } |
| 3692 | else |
| 3693 | AbstractRing::SimultaneousExponentiate(results, base, |
| 3694 | exponents, exponentsCount); |
| 3695 | } |
| 3696 | |
| 3697 | |
| 3698 | // ******************************************************** |
nothing calls this directly
no test coverage detected