To toggle to the math mode, you must use the tag. The math commands must be separated by a space character or surrounded by {}.
Syntax : matrix{num of lines}{num of columns}{first_element … last_element}
Syntax : tabular{lines description}{columns description}{first_element … last_element}
lines : sequence of 1 (draw the horizontal line) or 0 (don't draw the horizontal line) - the length of the sequence=num of lines+1
columns : sequence of 1 (draw the vertical line) or 0 (don't draw the vertical line) - the length of the sequence=num of columns+1