% Playing with inverse matrices
clear all; format short;
B=(1/8)*[  1 -1  2
    -2  1  1
    -1  2  1];
BI=inv(B),
[LB,UB]=LU_factor(B,3),
C=(1/12)*[  1  4  5
            4 20 32
            5 32 64];
 CI=inv(C),
 LC=Cholesky(C),
 A=[ 1 2 3; 4 5 6; 7 8 9],
 b=[1; 1; -1]/8;
 x=BI*(2*A+eye(3))*(CI+A)*b