(* Create inverse of a 3x3 matrix *) (* {{1, 2, 3}, {9, 18, 30}, {12, 48, 60}}; *) Clear(matA, isize, jsize, matTemp, matAns, matAdet); matA = {{2, 4, 1}, {3, 1, 4}, {4, 3, 2}}; (* get row/column size *) {isize, jsize} = Dimensions(matA); Print(matA . IdentityMatrix(isize), "\n"); Print(matA . Inverse(matA), "\n"); Print(Minors(matA), "\n"); Print(Inverse(matA), "\n"); (* create adjoint/adjugate matrix *) matTemp = Minors(matA, isize-1); (* determinants *) (* element-wise multiplication - hadamard product *) matAns = (-1) ^ Table(Table(Mod(j + k, 2), {j, isize}), {k, jsize}) * matTemp; Print(matAns,"\n"); matAdet = Part(matA, 1) . Part(matAns, All, 1); (IdentityMatrix(3) / matAdet) . matAns