Dejar
B:=[−a1−a1−a−a]
whose inverse is
B−1=11−2a[a1−a1−aa]
We would like to compute the inverse of
M:=a161⊤6+(I3⊗B)
where otimes denotes the Kronecker product. Using Sherman-Morrison,
M−1=(I3⊗B−1)−(I3⊗B−1)a161⊤6(I3⊗B−1)1+a1⊤6(I3⊗B−1)16
where
(I3⊗B−1)16=(I3⊗B−1)(13⊗12)=13⊗(B−112)=(11−2a)16
and
1⊤6(I3⊗B−1)=((I3⊗B−⊤)16)⊤=((I3⊗B−1)16)⊤=(11−2a)1⊤6
Hence,
M−1=(I3⊗B−1)−1(1−2a)2(a1+(6a1−2a))161⊤6=(I3⊗B−1)−a(1−2a)(1+4a)161⊤6
Using SymPy:
>>> from sympy import *
>>> a = Symbol('a', real=True, positive=True)
>>> M = Matrix([[0,1,a,a,a,a],
[1,0,a,a,a,a],
[a,a,0,1,a,a],
[a,a,1,0,a,a],
[a,a,a,a,0,1],
[a,a,a,a,1,0]])
>>> B = Matrix([[ -a,1-a],
[1-a, -a]])
>>> M_inv = TensorProduct(eye(3), B**-1) - (a / ((1+4*a) * (1-2*a))) * ones(6,6)
Verifying if the inverse was computed correctly:
>>> simplify(M * M_inv)
Matrix([
[1, 0, 0, 0, 0, 0],
[0, 1, 0, 0, 0, 0],
[0, 0, 1, 0, 0, 0],
[0, 0, 0, 1, 0, 0],
[0, 0, 0, 0, 1, 0],
[0, 0, 0, 0, 0, 1]])
Indeed, it was. Factoring out 1−2a and 1+4a:
>>> simplify((1-2*a) * (1+4*a) * M_inv)
Matrix([
[ 4*a**2, -a - (a - 1)*(4*a + 1), -a, -a, -a, -a],
[-a - (a - 1)*(4*a + 1), 4*a**2, -a, -a, -a, -a],
[ -a, -a, 4*a**2, -a - (a - 1)*(4*a + 1), -a, -a],
[ -a, -a, -a - (a - 1)*(4*a + 1), 4*a**2, -a, -a],
[ -a, -a, -a, -a, 4*a**2, -a - (a - 1)*(4*a + 1)],
[ -a, -a, -a, -a, -a - (a - 1)*(4*a + 1), 4*a**2]])
Hence,
$$\mathrm M^{-1} = \frac{1}{(1 - 2 a) (1 + 4 a)} [4a2g(a)−a−a−a−ag(a)4a2−a−a−a−a−a−a4a2g(a)−a−a−a−ag(a)4a2−a−a−a−a−a−a4a2g(a)−a−a−a−ag(a)4a2]$ PS