User Tools

Site Tools


wiki:latex_mathematics

This is an old revision of the document!


LaTeX/数学公式

本页参考了wikibooks的内容1),为使用方便在此重新编辑。

如果文档仅需要一些简单的数学公式,LaTeX 就可以满足需求;如果一个科技文档包含大量复杂公式, amsmath包引入一些新命令,比基础的LaTeX更强大和灵活;mathtools包修正了amsmath包的一些怪诞的地方,并增加了一些有用的设置、符号和环境。要使用这些包,需要在文档的导言中添加以下命令。

  \usepackage{amsmath}

  \usepackage{mathtools}

如果使用mathtools包,它会自动加载amsmath包。

数学环境

LaTeX 需要知道什么时候文本表示数学公式,为此需要声明一些特殊的环境。可分为两类:

  • text —— 文本公式(行内公式),显示在行内;
  • displayed—— 显示公式(行间公式),显示在独立的行。

数学环境及其快捷方式如下表所示:

类型 行内公式 行间公式 自动编号的行间公式
环境 mathdisplaymathequation
LaTeX 快捷方式\(…\) \[…\]
TeX 快捷方式$…$$$…$$

注意:数学环境与文本模式有所不同

  1. 所有空格与换行都会失去作用,要在数学模式里使用空格, 使用 \quad 输入一个标准宽度的空格,或者使用 \ 或 \; 或 \, 等输入宽度不同的空格;
  2. 不允许出现空行, 每个公式占一行;
  3. 所有字母都会按变量(var)格式排版, 如果需要排版普通文本, 请使用特定的命令;
  4. 百分号 % 后面的内容都表示注释,如果要输入百分号,使用\%

在行内插入显示公式样式

一些算符,如$\lim$或$\sum$,在行内会被压缩,为使其能够在行内美观显示,需要在行内环境中使用\displaystyle类。 例如,使用$\displaystyle \sum$,显示行间样式的符号$\displaystyle \sum$。

符号

这些符号可以直接输入: + - = ! / ( ) [ ] < > | ' : *

其他的符号只能使用特定的命令输入,如希腊字母、集合、关系运算符、箭头等。

公式\forall x \in X, \quad \exists y \leq \epsilon 输出: $$ \forall x \in X, \quad \exists y \leq \epsilon $$

特殊符号

一些符号,如#,$, %, &, {, }, ~, \, _, ^,在Tex中有特殊的用途,需要使用反斜杠转义。

符号 命令 符号 命令 符号 命令 符号 命令 符号 命令
$ \%\, $ \% $ \#\, $ \# $ \\$\, $ | '' \$ | $ \&\, $ | \& | $ \backslash\, $ | \backslash | | $ \{\, $ | \{ | $ >}\, $ | \} | $ \~{}\, $ | \~{} | $ \_\, $ | \_ | $ \^{}\, $ | \{} | ===== 希腊字母 ===== 输入希腊字母:反斜杠+字母名称。如果首字母小写,输出小写字母;如果首字母(只有首字母)大写,输出大写字母。一些大写希腊字母与拉丁字母相似,所以 LaTeX 没有提供,如大写 Alpha and Beta 就是 A and B。小写的 epsilon, theta, kappa, phi, pi, rho, and sigma 提供了两个版本,另一个版本在名字前加var( variant)。 希腊字母 \alpha, \Alpha, \beta, \Beta, \gamma, \Gamma, \pi, \Pi, \phi, \varphi, \mu, \Phi输出: $$ \alpha, \Alpha, \beta, \Beta, \gamma, \Gamma, \pi, \Pi, \phi, \varphi, \mu, \Phi $$ 下面的 数学符号列表 可以获得完整的希腊字母列表。 ===== 运算符 ===== 运算符就是一个函数,如三角函数 (sin, cos, tan),对数和指数函数 (log, exp), 极限 (lim)。 例如 \cos (2\theta) = \cos2 \theta - \sin2 \theta 输出: $$ \cos (2\theta) = \cos^2 \theta - \sin^2 \theta $$ 某些运算符,如极限,其下标置于运算符下,如 \lim_{x \to \infty} \exp(-x) = 0 输出: $$ \lim_{x \to \infty} \exp(-x) = 0 $$ 对于求模运算符,有两种命令 \bmod \pmod,如 a \bmod b x \equiv a \pmod b,分别输出: $$ a \, \bmod \, b $$ $$ x \equiv a \pmod b \,$$ ===== 指数和索引 ===== 指数和索引类似于文本模式的上标和下表。^符号用于指数,_符号用于索引,多个字符需要用花括号括起来。例如 k_{n+1} = n2 + k_n2 - k_{n-1} 输出: $$ k_{n+1} = n^2 + k_n^2 - k_{n-1} \,$$ _可以和|一起使用,如公式 f(n) = n5 + 4n2 + 2 _{n=17} ,输出: $$ f(n) = n^5 + 4n^2 + 2 |_{n=17} \,$$ ===== 分数和二项式 ===== 分数使用命令:\frac{numerator}{denominator},二项式使用命令:\binom{}{},例如, \frac{n!}{k!(n-k)!} = \binom{n}{k}输出: $$ \frac{n!}{k!(n-k)!} = \binom{n}{k} $$ 可以在分数中嵌套分数,例如, \frac{\frac{1}{x}+\frac{1}{y}{y-z} 输出: $$ \frac{\frac{1}{x}+\frac{1}{y}}{y-z} $$ 注意: - 嵌套分数或行内分数 $ \tfrac{a}{b} $会明显比行间分数小,\tfrac}}\dfrac 命令会强制使用 \textstyle\displaystyle,同样二项式也有\tbinom\dbinom命令。 - 命令 \over 是一个 TeX 和 LaTeX 中的原始命令,而 \frac 是 LaTeX 中独有的命令,这个命令建立在 \over 宏之上,提供了较高的容错能力。所以推荐使用 \frac 而非 \over。 对于简单公式,使用指数下标或许更美观,例如 3/_7,显示为 $ ^3/_7 $。 如果显得太松散,可以插入负空格,例如3\!/_7,显示为 $^3\!/_7$。 ==== 繁分数 ==== 繁分数使用\cfrac命令,例如: <code latex> \begin{equation} x = a_0 + \cfrac{1}{a_1 + \cfrac{1}{a_2 + \cfrac{1}{a_3 + \cfrac{1}{a_4} } } } \end{equation} </code> 输出: $$ x = a_0 + \cfrac{1}{a_1 + \cfrac{1}{a_2 + \cfrac{1}{a_3 + \cfrac{1}{a_4}}}} $$ ===== 根 ===== \sqrt 命令输出平方根,使用可选的参数(方括号)指定次数。例如 \sqrt[n]{1+x+x2+x3+\dots+xn}输出: $$ \sqrt[n]{1+x+x^2+x^3+\dots+x^n} $$ ===== 和与积分 ===== \sum\int分别输出和号与积分号,使用^, _指示上下限。例如 \textstyle\sum_{i=1}{10} t_i\displaystyle\sum_{i=1}

分别输出: $$\textstyle\sum_{i=1}^{10} t_i \,$$ $$\displaystyle\sum_{i=1}^{10} t_i $$ 积分号的格式也类似,其中的积分变量d要直立显示,需要使用 \mathrm{}命令,并使用 \, 命令与积分表达式保持一个小间隔。例如: \int_0^\infty \mathrm{e}^{-x}\,\mathrm{d}x 输出: $$\int_0^\infty \mathrm{e}^{-x}\,\mathrm{d}x \,$$ 下面的命令有类似的用法: | \sum | $\sum \,$ | \prod | $\prod$ | \coprod | $\coprod$ | | \bigoplus | $\bigoplus$ | \bigotimes | $\bigotimes$ | \bigodot | $\bigodot$ | | \bigcup | $\bigcup$ | \bigcap | $\bigcap$ | \biguplus | $\biguplus$ | | \bigsqcup | $\bigsqcup$ | \bigvee | $\bigvee$ | \bigwedge | $\bigwedge$ | | \int | $\int$ | \oint | $\oint$ | \iint | $\iint$ | | \iiint | $\iiint$ | \iiiint | $\iiiint$ | \idotsint | $\idotsint$ | \substack命令可以使用\\将上下限写在多行中。如 <code latex> \sum_{\substack{ 0<i<m
0<j<n } } P(i,j) </code> 输出: $$ \sum_{\overset{\scriptstyle 0<i<m} {\scriptstyle 0<j<n}} P(i,j) $$ 如果要把上下限写在积分号上边和下边,使用
\limits命令,如 \int\limits_a^b输出: $$ \int\limits_a^b $$ ===== 括号与限定符 ===== LaTeX中有许多限定符:( a ), [ b ], \{ c \}, | d |, \| e \|, \langle f \rangle, \lfloor g \rfloor, \lceil h \rceil, \ulcorner i \urcorner,分别输出: $$ ( a ), [ b ], \{ c \}, | d |, \| e \|, \langle f \rangle, \lfloor g \rfloor, \lceil h \rceil, \ulcorner i \urcorner $$ 其中 \lbrack , \rbrack可以代替 [, ]。 ==== 自适应大小 ==== 使用\left, \right, \middle命令可以使限定符随公式大小自动变化。例如, P\left(A=2\middle|\frac{A^2}{B}>4\right)输出: $$P\left(A=2\middle|\frac{A^2}{B}>4\right)$$ 花括号使用\left\{, \right\}。 如果只在表达式一边有限定符,则另一边看不见的限定符使用句号声明。如 \left.\frac{x^3}{3}\right|_0^1输出: $$ \left.\frac{x^3}{3}\right|_0^1 \,$$ ==== 手动指定大小 ==== 手动指定大小时,使用\big, \Big, \bigg, \Bigg修饰命令,分别输出: $$ \big( \Big( \bigg( \Bigg( $$ 这些命令对嵌套的限定符特别有用。如,\frac{\mathrm d}{\mathrm d x} \big( k g(x) \big)输出: $$ \frac{\mathrm d}{\mathrm d x} \big( k g(x) \big) $$ ===== 矩阵与数列 ===== 一个基础的矩阵使用matrix环境:类似于表格,行使用\\分隔,列使用&分隔。例如: <code latex> \[ \begin{matrix} a & b & c
d & e & f
g & h & i \end{matrix} \] </code> 输出: $$ \begin{matrix} a & b & c
d & e & f
g & h & i \end{matrix} $$ 如果指定对齐方式,使用带*号的环境。缺省对齐为c,但是可以使用任何array环境中有效的对齐。 <code latex> \begin{matrix} -1 & 3
2 & -4 \end{matrix} = \begin{matrix*}[r] -1 & 3
2 & -4 \end{matrix*} </code> 输出: $$ \begin{matrix} -1 & 3
2 & -4 \end{matrix} = \begin{matrix} -1 & \,\;\;3
\,\;\;2 & -4 \end{matrix} $$ 矩阵一般会使用限定符,可以使用
\left, \right命令,也可以使用预定义的环境。 ^环境名称 ^限定符 ^ | pmatrix | $( \, ) $ | | bmatrix | $[ \, ] $ | | Bmatrix | $\{ \, \} $ | | vmatrix | $| \, | $ | | Vmatrix | $\| \, \| $ | 注:缺省为中间对齐,加星号的版本可以指定对齐方式。 当书写任意大小的矩阵时,会用到水平、垂直、对角的点号,分别有\cdots, \vdots, \ddots命令。例如 <code latex> A_{m,n} = \begin{pmatrix} a_{1,1} & a_{1,2} & \cdots & a_{1,n}
a_{2,1} & a_{2,2} & \cdots & a_{2,n}
\vdots & \vdots & \ddots & \vdots
a_{m,1} & a_{m,2} & \cdots & a_{m,n} \end{pmatrix} </code> 输出: $$ A_{m,n} = \begin{pmatrix} a_{1,1} & a_{1,2} & \cdots & a_{1,n}
a_{2,1} & a_{2,2} & \cdots & a_{2,n}
\vdots & \vdots & \ddots & \vdots
a_{m,1} & a_{m,2} & \cdots & a_{m,n} \end{pmatrix} $$ 如果需要单独控制每列的对齐,或在行、列间插入分隔线,可以使用
array环境,实质上是一个数学模式的表格。例如 <code latex> \begin{array}{c|c} 1 & 2
\hline 3 & 4 \end{array} </code> 输出: $$ \begin{array}{c|c} 1 & 2
\hline 3 & 4 \end{array} $$ 对于矩阵中包含分数的情况,AMS 的矩阵环境没有留下足够的空间,可以在
\\命令后使用可选参数指定留空大小。例如 <code letax> M = \begin{bmatrix} \frac{5}{6} & \frac{1}{6} & 0 \\[0.3em] \frac{5}{6} & 0 & \frac{1}{6} \\[0.3em] 0 & \frac{5}{6} & \frac{1}{6} \end{bmatrix} </code> 输出: $$ M = \begin{bmatrix} \frac{5}{6} & \frac{1}{6} & 0 \\[0.3em] \frac{5}{6} & 0 & \frac{1}{6} \\[0.3em] 0 & \frac{5}{6} & \frac{1}{6} \end{bmatrix} $$ ==== 文本行中插入矩阵 ==== 要在文本行中插入矩阵,又不会增加行间,使用smallmatrix环境。例如 A matrix in text must be set smaller: $\bigl(\begin{smallmatrix} a & b
c & d \end{smallmatrix} \bigr)$ to not increase leading in a portion of text. ===== 在公式中插入文本 ===== 数学环境中直接输入文本会出现一些问题:空格被忽略;字母为斜体;字符间距过大等。一般的解决方法是使用
\text{…}命令(数字和文本之间的空格最好加在文本命令内)。例如 <code latex> 50 \text{ apples} \times 100 \text{ apples} = \text{lots of apples}^2 </code> 输出: $$ 50 \text{ apples} \times 100 \text{ apples} = \text{lots of apples}^2 $$ ==== 格式化文本 ==== 可以对文本进行简单的格式,使用\textrm输出罗马字体,\textit输出斜体,\textbf输出粗体。例如 <code latex> 50 \textrm{ apples} \times 100 \textbf{ apples} = \textit{lots of apples}^2 </code> 输出: $$ 50 \;\textrm{ apples} \times 100 \;\textbf{ apples} = \textit{lots of apples}^2 $$ ===== 格式化数学符号 ===== 与格式化文本类似,下面的命令可以格式化数学表达式。 ^ LaTeX 命令 ^ 实例 ^ 描述 ^ 使用方式 ^ | \mathnormal{…}
(或者简单的不使用任何命令) | $ABCDEF~abcdef~123456\,$ | 缺省的数学字体 | 大部分的数学表达式 | |
\mathrm{…} | $\mathrm{ABCDEF~abcdef~123456}\,$ | 缺省的数学字体 | 单位符号,单词函数名 | | \mathit{…} | $\mathit{ABCDEF~abcdef~123456}\,$ | 斜体 | 多词函数名,变量名。相比\mathnormal,单词间排列更自然,数字也斜体。| | \mathbf{…} | $\mathbf{ABCDEF~abcdef~123456}\,$ | 粗体 | 矢量 | | \mathsf{…} | $\mathsf{ABCDEF~abcdef~123456}\,$ | Sans-serif字体 | 类别 | | \mathtt{…} | $\mathtt{ABCDEF~abcdef~123456}\,$ | 固定宽度字体 | | | \mathfrak{…} | $\mathfrak{ABCDEF~abcdef~123456}\,$ | Fraktur字体 | 李代数,环论 | | \mathcal{…} | $\mathcal{ABCDEF}\,$ | 书法字体(仅有大写)| Often used for sheaves/schemes and categories | | \mathbb{…} | $\mathbb{ABCDEF}\,$ | 黑边粗体(仅有大写)| 特定集合(如,实数)| | \mathscr{…} | $\mathscr{ABCDEF}\,$ | Script字体(仅有大写)| An alternative font for categories and sheaves. | 这些命令可以放在整个数学表达式里,他们只格式化字母、数字、大写希腊字母,对数学命令不起作用。 粗体的小写希腊字母或其他符号,使用\boldsymbol,这个命令只有在当前字符集中有粗体时显示粗体,另一个办法是使用\pmb,他会显示多个字符集中的粗体。例如 \boldsymbol{\beta} = (\beta_1,\beta_2,\dotsc,\beta_n) ,输出: $$ \boldsymbol{\beta} = (\beta_1,\beta_2,\dotsc,\beta_n) $$ ==== 字母修饰符号 ==== 除了符号和字体,还有字母修饰符: ^ LaTeX 命令 ^ 实例 ^ LaTeX 命令 ^ 实例 ^ | <code>a' or a^{\prime}</code> | $a'\,$ | <code>a</code> | $a''\,$ |

a'''
$a'''\,$
a''''
$a''''\,$
\hat{a}
$\hat{a} \,$
\bar{a}
$\bar{a} \,$
\grave{a}
$\grave{a} \,$
\acute{a}
$\acute{a} \,$
\dot{a}
$\dot{a} \,$
\ddot{a}
$\ddot{a} \,$
\dddot{a}
$\dddot{a} \,$
\ddddot{a}
$\ddddot{a} \,$
\not{a}
$\not{a} \,$
\mathring{a}
$\mathring{a} \,$
\overrightarrow{AB}
$\overrightarrow{AB} \,$
\overleftarrow{AB}
$\overleftarrow{AB} \,$
\overline{aaa}
$\overline{aaa} \,$
\check{a}
$\check{a} \,$
\breve{a}
$\breve{a} \,$
\vec{a}
$\vec{a} \,$
\tilde{a}
$\tilde{a} \,$
\underline{a}
$\underline{a} \,$
\widehat{AAA}
$\widehat{AAA} \,$
\widetilde{AAA}
$\widetilde{AAA}$
\stackrel\frown{AAA}
$\stackrel\frown{AAA}$

颜色

xcolor允许为公式添加颜色。例如 k = {\color{red}x}{\color{blue}-} 2 ,输出:

$$ k = {\color{red}x}{\color{blue}-} 2 $$

加减号

LaTeX 处理 + 、− 号有两种方式,一个二项运算符,符号两边都有数学元素,在运算符两边会留出一定的空间;二是正负号, 这种情况下符号与后边的元素更近一些。如果符号前边没有元素而希望作为二项运算符,则需在前面加一个不可见元素{}

正负号写作: \pm ,输出:$ \pm $。负正号写作: \mp ,输出:$ \mp $。

控制水平间距

实例1

\[ f(n) =
  \begin{cases}
    n/2       & \quad \text{if } n \text{ is even}\\
    -(n+1)/2  & \quad \text{if } n \text{ is odd}
  \end{cases}
\]

输出:

\[ f(n) = \begin{cases} n/2 & \quad \text{if } n \text{ is even}\\ -(n+1)/2 & \quad \text{if } n \text{ is odd} \end{cases} \]

LaTeX 定义了两种命令来插入水平间隔:\quad, \qquad,前者等于当前字符宽度,后者为前者两倍。

实例2

\int y \mathrm{d}x 

输出:

$$ \int y \mathrm{d}x $$

其中的 y 和 dx 并没有被单独的分开,而是粘在一起。此处插入. \quad又太大,需要一些更细小的间距调整:

命令 描述 大小
\, small space 3/18 of a quad
\: medium space 4/18 of a quad
\; large space 5/18 of a quad
\! negative space -3/18 of a quad

对上例进行微调。

 \int y\, \mathrm{d}x 

输出:

$$\int y\, \mathrm{d}x$$

 \int y\: \mathrm{d}x 

输出:

$$\int y\;\;\!\! \mathrm{d}x$$

 \int y\; \mathrm{d}x 

输出: $$\int y\; \mathrm{d}x$$

负间距的应用如下例,二项式的括号与内容间距太大,插入几个负间距更美观。

  \left(\!
    \begin{array}{c}
      n \\
      r
    \end{array}
  \!\right) = \frac{n!}{r!(n-r)!}

输出:

$$ \left(\! \begin{matrix} n \\ r \end{matrix} \!\right) = \frac{n!}{r!(n-r)!} $$

手动指定公式样式

要手动指定一段公式使用文本样式,使用\textstyle,并用花括号括起来以限定样式的范围。 如果输出显示格式,使用\displaystyle命令。例如

\begin{equation}
   C^i_j = {\textstyle \sum_k} A^i_k B^k_j
\end{equation}

输出:

$$ \begin{equation} C^i_j = {\textstyle \sum_k} A^i_k B^k_j \end{equation} $$

高级数学公式: AMS 数学包

AMS 包是 LaTeX 语言的一个高级抽象层,他引入的一些命令会使普通的 LaTeX 命令失效,尽可能使用此包。

在公式中引入点

amsmath同样定义了\dots,是继承了原有的\ldots命令,输出三个点,但是会根据上下文决定显示在底部\ldots,或中间\cdots

连点

LaTeX 定义了几个连点(省略号)命令,常用在矩阵中省略元素。

命令 输出 注释
\dots $\dots$ 能够根据上下文自动管理前后的间距,是一个高层命令
\ldots $\ldots$ 与前面的类似,但不会自动调整前后的间距, 是一个低层命令
\cdots $\cdots$ 处于字符高度中间
\vdots $\vdots$ 垂直连点
\ddots $\ddots$ 对角连点(diagonal)
\iddots $\iddots$ 反对角连点(inverse diagonal)(需要mathdots包)
\hdotsfor{n} $\ldots \ldots$ 使用在矩阵中,输出跨n列的一行点

除了\ldots, \cdots等命令,可以使用语义相关的省略号,以适应不同的文档环境。

命令 输出 注释
A_1,A_2,\dotsc, $A_1,A_2,\dotsc,$ 与逗号连用
A_1+\dotsb+A_N $ A_1+\dotsb+A_N $ 与二项运算符连用
A_1 \dotsm A_N $ A_1 \dotsm A_N $ 与乘连用
\int_a^b \dotsi $ \int_a^b \dotsi $ 与积分连用
A_1\dotso A_N $ A_1\dotso A_N $ 其他情况,非上所列

数学符号列表

关系符号

符号 命令 符号 命令 符号 命令 符号 命令 符号 命令
$ <\, $ < $ >\, $ > $ =\, $ = $ \parallel\, $ \parallel $ \nparallel\, $ \nparallel
$ \leq\, $ \leq $ \geq\, $ \geq $ \doteq\, $ \doteq $ \asymp\, $ \asymp $ \bowtie\, $ \bowtie
$ \ll\, $ \ll $ \gg\, $ \gg $ \equiv\, $ \equiv $ \vdash\, $ \vdash $ \dashv\, $ \dashv
$ \subset\, $ \subset $ \supset\, $ \supset $ \approx\, $ \approx $ \in\, $ \in $ \ni\, $ \ni
$ \subseteq\, $ \subseteq $ \supseteq\, $ \supseteq $ \cong\, $ \cong $ \smile\, $ \smile $ \frown\, $ \frown
$ \nsubseteq\, $ \nsubseteq $ \nsupseteq\, $ \nsupseteq $ \simeq\, $ \simeq $ \models\, $ \models $ \notin\, $ \notin
$ \sqsubset\, $ \sqsubset $ \sqsupset\, $ \sqsupset $ \sim\, $ \sim $ \perp\, $ \perp $ \mid\, $ \mid
$ \sqsubseteq\, $ \sqsubseteq $ \sqsupseteq\, $ \sqsupseteq $ \propto\, $ \propto $ \prec\, $ \prec $ \succ\, $ \succ
$ \preceq\, $ \preceq $ \succeq\, $ \succeq $ \neq\, $ \neq $ \sphericalangle\, $ \sphericalangle $ \measuredangle\, $ \measuredangle

二元运算符

符号 命令 符号 命令 符号 命令 符号 命令
$ \pm\, $ \pm $ \cap\, $ \cap $ \diamond\, $ \diamond $ \oplus\, $ \oplus
$ \mp\, $ \mp $ \cup\, $ \cup $ \bigtriangleup\, $ \bigtriangleup $ \ominus\, $ \ominus
$ \times\, $ \times $ \uplus\, $ \uplus $ \bigtriangledown\, $ \bigtriangledown $ \otimes\, $ \otimes
$ \div\, $ \div $ \sqcap\, $ \sqcap $ \triangleleft\, $ \triangleleft $ \oslash\, $ \oslash
$ \ast\, $ \ast $ \sqcup\, $ \sqcup $ \triangleright\, $ \triangleright $ \odot\, $ \odot
$ \star\, $ \star $ \vee\, $ \vee $ \bigcirc\, $ \bigcirc $ \circ\, $ \circ
$ \dagger\, $ \dagger $ \wedge\, $ \wedge $ \bullet\, $ \bullet $ \setminus\, $ \setminus
$ \ddagger\, $ \ddagger $ \cdot\, $ \cdot $ \wr\, $ \wr $ \amalg\, $ \amalg

集合与逻辑声明

符号 命令 符号 命令
$ \exists\, $ \exists $ \rightarrow\, $ \rightarrow or \to
$ \nexists\, $ \nexists $ \leftarrow\, $ \leftarrow or \gets
$ \forall\, $ \forall $ \mapsto\, $ \mapsto
$ \neg\, $ \neg $ \implies\, $ \implies
$ \subset\, $ \subset $ \Rightarrow\, $ \Rightarrow or \implies
$ \supset\, $ \supset $ \leftrightarrow\, $ \leftrightarrow
$ \in $ \in $ \iff\, $ \iff
$ \notin\, $ \notin $ \Leftrightarrow\, $ \Leftrightarrow (preferred for equivalence (iff))
$ \ni\, $ \ni $ \top\, $ \top
$ \land\, $ \land $ \bot\, $ \bot
$ \lor\, $ \lor $ \emptyset\, $ and $ \varnothing\, $ \emptyset and \varnothing

限定符

符号 命令 符号 命令 符号 命令 符号 命令
$ |\, $ | or \mid (difference in spacing) $ \|\, $ \| $ /\, $ / $ \backslash\, $ \backslash
$ \{\, $ \{ $ \}\, $ \} $ \langle\, $ \langle $ \rangle\, $ \rangle
$ \uparrow\, $ \uparrow $ \Uparrow\, $ \Uparrow $ \lceil\, $ \lceil $ \rceil\, $ \rceil
$ \downarrow\, $ \downarrow $ \Downarrow\, $ \Downarrow $ \lfloor\, $ \lfloor $ \rfloor\, $ \rfloor

希腊字母

注意:与拉丁字母相同的希腊字母,直接使用拉丁字母,如 A 代替 Alpha, B 代替 Beta等。

符号 命令 符号 命令
$ \Alpha\, $ and $ \alpha\, $ A and \alpha $ \Nu\, $ and $ \nu\, $ N and \nu
$ \Beta\, $ and $ \beta\, $ B and \beta $ \Xi\, $ and $ \xi\, $ \Xi and \xi
$ \Gamma\, $ and $ \gamma\, $ \Gamma and \gamma $ \Omicron\, $ and $ \omicron\, $ O and o
$ \Delta\, $ and $ \delta\, $ \Delta and \delta $ \Pi\, $ , $ \pi\, $ and $ \varpi $ \Pi , \pi and \varpi
$ \Epsilon\, $ , $ \epsilon\, $ and $ \varepsilon\, $ E , \epsilon and \varepsilon $ \Rho\, $ , $ \rho\, $ and $ \varrho\, $ P , \rho and \varrho
$ \Zeta\, $ and $ \zeta\, $ Z and \zeta $ \Sigma\, $ , $ \sigma\, $ and $ \varsigma\, $ \Sigma , \sigma and \varsigma
$ \Eta\, $ and $ \eta\, $ H and \eta $ \Tau\, $ and $ \tau\, $ T and \tau
$ \Theta\, $ , $ \theta\, $ and $ \vartheta\, $ \Theta , \theta and \vartheta $ \Upsilon\, $ and $ \upsilon\, $ \Upsilon and \upsilon
$ \Iota\, $ and $ \iota\, $ I and \iota $ \Phi\, $ , $ \phi\, $ , and $ \varphi\, $ \Phi , \phi and \varphi
$ \Kappa\, $ , $ \kappa\, $ and $ \varkappa\, $ K , \kappa and \varkappa $ \Chi\, $ and $ \chi\, $ X and \chi
$ \Lambda\, $ and $ \lambda\, $ \Lambda and \lambda $ \Psi\, $ and $ \psi\, $ \Psi and \psi
$ \Mu\, $ and $ \mu\, $ M and \mu $ \Omega\, $ and $ \omega\, $ \Omega and \omega

其他符号

符号 命令 符号 命令 符号 命令 符号 命令 符号 命令
$ \partial\, $ \partial $ \imath\, $ \imath $ \Re\, $ \Re $ \nabla\, $ \nabla $ \aleph\, $ \aleph
$ \eth\, $ \eth $ \jmath\, $ \jmath $ \Im\, $ \Im $ \Box\, $ \Box $ \beth\, $ \beth
$ \hbar\, $ \hbar $ \ell\, $ \ell $ \wp\, $ \wp $ \infty\, $ \infty $ \gimel\, $ \gimel

三角函数

符号 命令 符号 命令 符号 命令 符号 命令
$ \sin\, $ \sin $ \arcsin\, $ \arcsin $ \sinh\, $ \sinh $ \sec\, $ \sec
$ \cos\, $ \cos $ \arccos\, $ \arccos $ \cosh\, $ \cosh $ \csc\, $ \csc
$ \tan\, $ \tan $ \arctan\, $ \arctan $ \tanh\, $ \tanh
$ \cot\, $ \cot $ \arccot\, $ \arccot $ \coth\, $ \coth
wiki/latex_mathematics.1558245133.txt.gz · Last modified: 2019/05/19 01:52 by zhwiki