With respect to the maths behind the Diffie Hellman Key exchange algorithm.
Why does:
(ga mod p)b mod p = gab mod p
It might be fairly obvious, but what basic maths guarantees this? Why does the first modulo p expression disappear from the LHS in the expression on the RHS.
Apologies if it's not the right forum to ask it in. Maybe I should try the Stack Exchange Mathematics forum instead.