Ch-4-Prob-10-New-박종우

1904 days ago by matrix

A=matrix([[0,1,0], [-2,8, 6], [-2,4,7]]) dA=A.det() adjA=A.adjoint() print "inverse of A = (1/dA)*adjA =" print (1/dA)*adjA 
       
inverse of A = (1/dA)*adjA =
[  16 -7/2    3]
[   1    0    0]
[   4   -1    1]
inverse of A = (1/dA)*adjA =
[  16 -7/2    3]
[   1    0    0]
[   4   -1    1]
B=matrix(5,5,[3,7,3,1,3,0,3,0,-5,5,1,10,2,-9,4,-4,-2,-4,-7,0,0,3,0,-6,6]) dB=B.det() adjB=B.adjoint() print "inverse of B = (1/dB)*adjB =" print (1/dB)*adjB 
       
inverse of B = (1/dB)*adjB =
[   34/5  -202/5      -1    23/5  464/15]
[      0       2       0       0    -5/3]
[  -27/5   141/5       1   -19/5 -322/15]
[   -4/5    32/5       0    -3/5  -74/15]
[   -4/5    27/5       0    -3/5  -59/15]
inverse of B = (1/dB)*adjB =
[   34/5  -202/5      -1    23/5  464/15]
[      0       2       0       0    -5/3]
[  -27/5   141/5       1   -19/5 -322/15]
[   -4/5    32/5       0    -3/5  -74/15]
[   -4/5    27/5       0    -3/5  -59/15]