出现错误,提示乳胶中“缺少$插入”

时间:2019-03-31 12:34:24

标签: latex

收到一条错误消息,提示有missing $ inserted

我尝试在n前面添加另一个,在\end{pmatrix}前面添加另一个,但是它不起作用。

\begin{equation} n_1=\begin{pmatrix}2\\1\\-1\end{pmatrix}\times \begin{pmatrix}3\\-1\\0\end{pmatrix} = \begin{vmatrix}$e_1&e_2&e_3$\\2&1&-1\\3&-1&0\end{vmatrix}=\begin{pmatrix}-1\\-3\\-5\end{pmatrix} \end{equation}
\begin{equation}n_2=\begin{pmatrix}1\\1\\-1\end{pmatrix}\times \begin{pmatrix}2\\-1\\0\end{pmatrix} = \begin{vmatrix}$e_1&e_2&e_3$\\1&1&-1\\2&-1&0\end{vmatrix}=\begin{pmatrix}-1\\-2\\-3\end{pmatrix}\end{equation}

1 个答案:

答案 0 :(得分:0)

以下代码段

\documentclass[a4papaer, 11pt]{article}
\usepackage[top=3.5cm, bottom=3.5cm, left=3.0cm, right=3.0cm]{geometry}
\usepackage{amsmath}

\begin{document}

\begin{equation} n_1=
    \begin{pmatrix}
        2\\1\\-1
    \end{pmatrix}\times 
    \begin{pmatrix}
        3\\-1\\0
    \end{pmatrix} = 
    \begin{vmatrix}
        e_1&e_2&e_3 \\
        2&1&-1\\
        3&-1&0
    \end{vmatrix} =
    \begin{pmatrix}
        -1\\-3\\-5
    \end{pmatrix} 
\end{equation}
\begin{equation}
    n_2=
    \begin{pmatrix}
        1\\1\\-1
    \end{pmatrix}\times 
    \begin{pmatrix}
        2\\-1\\0
    \end{pmatrix} = 
    \begin{vmatrix}
        e_1&e_2&e_3\\
        1&1&-1\\
        2&-1&0
    \end{vmatrix}=
    \begin{pmatrix}
        -1\\-2\\-3
    \end{pmatrix}
\end{equation}

\end{document}

产生the matrices from this image。那是您想要的结果吗?