The Transpose
Reflecting a matrix across its main diagonal turns rows into columns and reverses the order of products.
Definition
The transpose of a matrix A, written A^T, is formed by swapping rows and columns: the entry in row i, column j of A^T equals the entry in row j, column i of A. An m-by-n matrix becomes n-by-m. Transposing twice returns the original: (A^T)^T = A.
Algebraic rules
- (A + B)^T = A^T + B^T
- (cA)^T = c A^T for a scalar c
- (AB)^T = B^T A^T, note the reversed order
- (A^T)^{-1} = (A^{-1})^T when A is invertible
The reversal rule for products is the one most often misremembered. It follows directly from the definition and mirrors the reversal that appears when taking the inverse of a product.
Symmetry
A matrix equal to its own transpose, A = A^T, is symmetric; it must be square and its entries mirror across the diagonal. A matrix with A^T = -A is skew-symmetric and has zeros on its diagonal. Symmetric matrices have exceptionally clean structure: real eigenvalues and orthogonal eigenvectors, the content of the spectral theorem.
The transpose and inner products
The transpose is the discrete form of the adjoint. For real vectors, the dot product x . y equals x^T y. More generally,
import numpy as np
A = np.array([[1, 2, 3], [4, 5, 6]])
print(A.T) # 3x2
S = A @ A.T # always symmetric
print(np.allclose(S, S.T)) # True
Products of the form A^T A appear constantly: they are square, symmetric, and positive semidefinite, which is why they anchor least-squares fitting of experimental data against model predictions.