# how to insert a 3*3 matrix in latex?

• Jun 9th 2008, 06:33 AM
szpengchao
how to insert a 3*3 matrix in latex?
as title.
• Jun 9th 2008, 06:46 AM
bobak
$$\left(\begin{array}{ccc}a & b & c \\d & e & f \\g & h & i\end{array}\right)$$

Gives $\left(\begin{array}{ccc}a & b & c \\d & e & f \\g & h & i\end{array}\right)$
• Jun 9th 2008, 07:16 AM
topsquark
Or
$$\left ( \begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix} \right )$$

gives
$\left ( \begin{matrix} a & b & c \\ d & e & f \\ g & h & i \end{matrix} \right )$

-Dan
• Jun 9th 2008, 12:17 PM
Opalg
If you use pmatrix, you don't have to insert the parentheses "by hand".

$$\begin{pmatrix} a & b & c \\ d & e & f \\ g & h & i \end{pmatrix}$$ gives $\begin{pmatrix} a & b & c \\ d & e & f \\ g & h & i \end{pmatrix}$.

For a bracketed matrix, use bmatrix. For a determinant, use vmatrix.

$$\begin{bmatrix} a & b & c \\ d & e & f \\ g & h & i \end{bmatrix}$$ gives $\begin{bmatrix} a & b & c \\ d & e & f \\ g & h & i \end{bmatrix}$.

$$\begin{vmatrix} a & b & c \\ d & e & f \\ g & h & i \end{vmatrix}$$ gives $\begin{vmatrix} a & b & c \\ d & e & f \\ g & h & i \end{vmatrix}$.