23*d = 1mod66
Because gcd(23,66) = 1 we can calculate the modulo inverse:
23⋅d≡1(mod66)d≡123(mod66)d≡23−1(mod66)
We use the Extended Euclidean Algorithm to get d:
66=23⋅2+20or(4)[66−23⋅2]=2023=20⋅1+3or(3)[23−20]=320=3⋅6+2or(2)[20−18]=23=2⋅1+1or(1)[3−2]=1(1)3−2=1|(2)2=[20−18]3−[20−18]=13−20+18=13(1+6)−20=13⋅7−20=1|(3)3=[23−20][23−20]⋅7−20=123⋅7−20⋅7−20=123⋅7−20⋅8=1|(4)20=[66−23⋅2]23⋅7−[66−23⋅2]⋅8=123⋅7−66⋅8+23⋅16=123⋅23−66⋅8=1|(mod66)23⋅23≡1(mod66)23−1(mod66)≡2323⋅d≡1(mod66)d=23
All Solutions: d≡23(mod66)ord−23=n⋅66d=23±n⋅66n∈N