I know I need to use the extended euclidean algorithm, but I\'m not sure exactly what calculations I need to do. I have huge numbers. Thanks
Simply use this formula,
d = (1+K(phi))/e. (Very useful when e and phi are small numbers)
Lets say, e = 3 and phi = 40 we assume K = 0, 1, 2... until your d value is not a decimal
assume K = 0, then d = (1+0(40))/3 = 0. (if it is a decimal increase the K value, don't bother finding the exact value of the decimal)
assume K = 2, then d = (1+2(40)/3) = 81/3 = 27
d = 27.
Assuming K will become exponentially easy with practice.