Problem C26

build the matrix

m <- matrix(c(2, 0, 3, 2, 5, 1, 2, 4, 3, 0, 1, 2, 5, 3, 2, 1),ncol = 4, byrow = TRUE)
m
##      [,1] [,2] [,3] [,4]
## [1,]    2    0    3    2
## [2,]    5    1    2    4
## [3,]    3    0    1    2
## [4,]    5    3    2    1

solve ‘by hand’

since there are two zero’s in the second column, I will expand that column

m1 <- 1 * (2 * (1 * 1 - 2 * 2) - 3 * (3 * 1 - 5 * 2) + 2 * (3*2 - 5 * 1)) + 
  3 * (((2 * (2 * 2) - 4 * 1) - 4 * 1) - 3 * ((5 * 2) - (4 * 3)) + 2 * ((5 * 1) - (3 * 2)))
m1
## [1] 29

checking with computer

det(m)
## [1] 29

same answer!