The first thing you should see in this case is that the triangles are proportional.
We have then that:
((a) / (c)) = ((d) / (a))
Step 1:
Go a multiplying:
((a) / (c)) * (a) = (d)
Step 2:
Pass c multiplying:
(a) * (a) = (d) * (c)
Step 3:
Same basis, exponents are added:
a ^ (1 + 1) = (d) * (c)
Step 4:
a ^ 2 = c * d
Finally
((a) / (c)) = ((d) / (a)) -------> a ^ 2 = c * d