Upper triangular matrices have straightforward inverses. The formula still applies: swap diagonal, negate off-diagonal, divide by determinant.
About Inverse Matrix
The inverse of a square matrix A, written Aโ1, is the unique matrix such that AAโ1=Aโ1A=I (the identity matrix). A matrix has an inverse if and only if its determinant is nonzero.