Karatsuba algorithm: Difference between revisions

Content deleted Content added
m Algorithm: typos
No edit summary
Line 26:
::= ''x''<sub>1</sub>''y''<sub>2</sub> + ''x''<sub>2</sub>''y''<sub>1</sub>
 
Thus ''xy'' = ''X'' ''bB''<sup>2m</sup> + ''Y'' + ''Z'' ''bB''<sup>m</sup>; we have cut down the number of multiplications from four to three.
 
To compute these three products of ''m''-digit numbers, we can employ Karatsuba multiplication again, effectively using [[recursion]]. The shifts, additions and subtractions take linear time respectively, and can be considered negligible.