Adding in matrix utilities