This only works if A is an orthogonal matrix.
For example
A = .707 - .707 0
.707 .707 0
0 0 1
However it does not work is A is not orthogonal
For example
A = 2 0 0
0 2 0
0 0 2
The inverse is
A-1 = .5 0 0
0 .5 0
0 0 .5
which is not the transpose of A.