added barrett reductions and removed karatsuba