|
tesseract++ 0.0.1
N-dimensional tensor library for embedded systems
|
Inverse of 4×4 homogeneous transformation matrices. More...

Go to the source code of this file.
Namespaces | |
| namespace | matrix_algorithms |
Functions | |
| template<typename T > | |
| FusedMatrix< T, 4, 4 > | matrix_algorithms::homogeneous_inverse (const FusedMatrix< T, 4, 4 > &H) |
| Compute the inverse of a 4×4 homogeneous transformation matrix. | |
Inverse of 4×4 homogeneous transformation matrices.
A homogeneous transform encodes a rigid-body transformation in SE(3):
T = [ R | t ]
[ 0 | 1 ]
where R ∈ SO(3) is a 3×3 rotation and t ∈ ℝ³ is a translation.
The inverse exploits the orthogonality of R (R⁻¹ = Rᵀ):
T⁻¹ = [ Rᵀ | -Rᵀ·t ]
[ 0 | 1 ]
This avoids the general 4×4 inverse (which requires cofactor expansion or LU decomposition) and uses only a 3×3 transpose + 3×3·3×1 matmul.
Complexity: O(1) — 9 copies (transpose) + 9 multiplies + 6 adds (matmul).
The caller is responsible for ensuring T has valid homogeneous form:
No runtime validation is performed. Passing a non-homogeneous matrix produces a mathematically meaningless result.