924 views
2 votes
2 votes

What is the minimum number of multiplications required to compute a^27 ? In general, what is the minimum number of multiplications to compute a^n if n is not a power of 2. 

1 Answer

2 votes
2 votes

a27 = a16 * a11

      = a16 * a8 * a3

      = a16 * a8 * a* a

Now for a16 we require log 16 = 4 multiplication

Now this multiplications also include a8 and a2 so dont need to count

So min number of multiplication = 4 + 1 + 1 + 1 = 7

Related questions

0 votes
0 votes
2 answers
2
Sammohan Ganguly asked Apr 20, 2018
458 views
Why does a perfect square number have odd number of factors?
2 votes
2 votes
0 answers
4
ankitgupta.1729 asked Mar 31, 2018
299 views
Using Proof by Contradiction, Show that There are infinite number of prime numbers.