The matrix transpose is the operation that exchanges the rows and columns of a matrix. If has rows and columns, its transpose, written , has rows and columns. Each entry retains its value but exchanges its two indices. Transposition is a fundamental operation in linear algebra, used to express symmetry, relationships between vectors, and properties of matrix products. (ocw.mit.edu)
Definition and notation
For a matrix over a field, the transpose is defined by
Thus, the first row of becomes the first column of , and similarly for every other row. For example,
For a square matrix, this rearrangement can be visualized as reflection across the main diagonal; diagonal entries remain fixed. A column vector becomes a row vector, and conversely. Common notations include , , and . (ocw.mit.edu)
Transposition should not be confused with finding an inverse matrix. Every matrix has a transpose, including rectangular and singular matrices. An inverse, in the usual sense, exists only for an invertible square matrix. (ocw.mit.edu)
Algebraic properties
For matrices of compatible dimensions and a scalar , transposition satisfies
The first identity makes transposition an involution: applying it twice restores the original matrix. The product identity reverses the order of the factors, an essential distinction because matrix multiplication generally does not commute. (ocw.mit.edu)
The product rule follows directly from the entry formula:
For invertible ,
A square matrix and its transpose also have the same determinant. (ocw.mit.edu)
Transposition preserves matrix rank: exchanging rows and columns interchanges row rank and column rank, which are equal. It also preserves the trace, because the diagonal entries do not move. Consequently, and have the same characteristic polynomial and the same eigenvalues, including their algebraic multiplicities, although their eigenvectors need not coincide. (github.com)
Duality and inner products
The transpose has a basis-independent interpretation through dual spaces. If is a linear map between finite-dimensional vector spaces, it induces a map
This map pulls a linear functional on back to one on . If represents relative to chosen bases, then represents relative to the corresponding dual bases. The reversal of direction explains the reversed dimensions and multiplication order. (ocw.mit.edu)
For matrices with real entries, the transpose also expresses the standard Euclidean inner product:
Here and . This identity characterizes as the adjoint of for these inner products; with arbitrary inner products or nonorthonormal bases, the adjoint’s matrix need not be the ordinary transpose. (math.brown.edu)
Symmetry and complex matrices
A square matrix is symmetric when , and skew-symmetric when . Over the real numbers, skew-symmetric matrices have zero diagonal entries. Every real square matrix has the unique decomposition
into symmetric and skew-symmetric parts. (ocw.mit.edu)
A real orthogonal matrix satisfies
where is the identity matrix; therefore . Real symmetric matrices can be diagonalized using an orthonormal basis, as described by the spectral theorem. (ocw.mit.edu)
For matrices containing complex numbers, ordinary transposition does not conjugate the entries. The conjugate transpose, written or , instead satisfies
It is the adjoint for standard complex inner products. Accordingly, Hermitian matrices satisfy , rather than necessarily . (math.brown.edu)
Applications and computation
For a real matrix , the Gram matrix contains inner products between columns. It is symmetric and positive semidefinite because
In ordinary least squares, including linear regression, minimizing yields the normal equations
The solution is unique when has linearly independent columns. Geometrically, these equations state that the residual is orthogonal to every column of . (ocw.mit.edu)
Software distinguishes mathematical transposition from physically rearranging stored entries. NumPy’s transpose operation can return a view sharing the original data rather than a copied array. For multidimensional arrays, it permutes axes; matrix transposition is the two-axis case. A one-dimensional array has no separate row and column axes, so transposing it leaves its shape unchanged. Representing it as a column or row therefore requires an additional axis. (numpy.org)