From 5aa79cdf5a2fc2644478f19ebc3fba4ff3feac20 Mon Sep 17 00:00:00 2001 From: wizardforcel <562826179@qq.com> Date: Mon, 9 Jan 2017 14:34:33 +0800 Subject: [PATCH] 3.4. --- 3.4.md | 372 ++++++++++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 299 insertions(+), 73 deletions(-) diff --git a/3.4.md b/3.4.md index 55f6f1b..02dbcd1 100644 --- a/3.4.md +++ b/3.4.md @@ -10,7 +10,7 @@ matplotlib 具有优秀的文本支持,包括数学表达式,光栅和向量输出的 truetype 支持,任意旋转的换行分隔文本和 unicode 支持。 因为我们直接在输出文档中嵌入字体,例如 postscript 或 PDF,你在屏幕上看到的也是你在打印件中得到的。 freetype2 可产生非常漂亮,抗锯齿的字体,即使在小光栅尺寸下看起来也不错。 matplotlib 拥有自己的`matplotlib.font_manager`,感谢 Paul Barrett,他实现了一个跨平台,符合 W3C 标准的字体查找算法。 -您可以完全控制每个文本属性(字体大小,字体重量,文本位置和颜色等),并在`rc`文件中设置合理的默认值。 并且对于那些对数学或科学图像感兴趣的人,matplotlib 实现了大量的 TeX 数学符号和命令,来支持你图中任何地方放置数学表达式。 +你可以完全控制每个文本属性(字体大小,字体重量,文本位置和颜色等),并在`rc`文件中设置合理的默认值。 并且对于那些对数学或科学图像感兴趣的人,matplotlib 实现了大量的 TeX 数学符号和命令,来支持你图中任何地方放置数学表达式。 ## 基本的文本命令 @@ -134,7 +134,7 @@ plt.show() | y | 浮点 | | zorder | 任意数值 | -您可以使用对齐参数`horizontalalignment`,`verticalalignment`和`multialignment`来布置文本。 `horizontalalignment`控制文本的`x`位置参数表示文本边界框的左边,中间或右边。 `verticalalignment`控制文本的`y`位置参数表示文本边界框的底部,中心或顶部。 `multialignment`,仅对于换行符分隔的字符串,控制不同的行是左,中还是右对齐。 这里是一个使用`text()`命令显示各种对齐方式的例子。 在整个代码中使用`transform = ax.transAxes`,表示坐标相对于轴边界框给出,其中`0,0`是轴的左下角,`1,1`是右上角。 +你可以使用对齐参数`horizontalalignment`,`verticalalignment`和`multialignment`来布置文本。 `horizontalalignment`控制文本的`x`位置参数表示文本边界框的左边,中间或右边。 `verticalalignment`控制文本的`y`位置参数表示文本边界框的底部,中心或顶部。 `multialignment`,仅对于换行符分隔的字符串,控制不同的行是左,中还是右对齐。 这里是一个使用`text()`命令显示各种对齐方式的例子。 在整个代码中使用`transform = ax.transAxes`,表示坐标相对于轴边界框给出,其中`0,0`是轴的左下角,`1,1`是右上角。 ```py import matplotlib.pyplot as plt @@ -224,11 +224,11 @@ plt.show() 注意,你不需要安装 TeX,因为 matplotlib 提供了自己的 TeX 表达式解析器,布局引擎和字体。 布局引擎是 Donald Knuth 的 TeX 中的布局算法的一种相当直接的适配版,所以质量是相当不错的(matplotlib 还为那些想要调用 TeX 生成文本的人提供一个`usetex`选项(参见[使用 LaTeX 渲染文本](http://matplotlib.org/users/usetex.html#usetex-tutorial) )。 -任何文本元素都可以使用数学文本。 你应该使用原始字符串(在引号前面加一个`'r'`),并用美元符号(`$`)包围数学文本,如 TeX。 常规文本和数学文本可以在同一个字符串内交错。 Mathtext 可以使用 Computer Modern 字体(来自 (La)TeX),STIX 字体(为与 Times 混合使用而设计)或您提供的 Unicode 字体。 可以使用自定义变量`mathtext.fontset`选择 mathtext 字体(请参阅[自定义 matplotlib](http://matplotlib.org/users/customizing.html#customizing-matplotlib)) +任何文本元素都可以使用数学文本。 你应该使用原始字符串(在引号前面加一个`'r'`),并用美元符号(`$`)包围数学文本,如 TeX。 常规文本和数学文本可以在同一个字符串内交错。 Mathtext 可以使用 Computer Modern 字体(来自 (La)TeX),STIX 字体(为与 Times 混合使用而设计)或你提供的 Unicode 字体。 可以使用自定义变量`mathtext.fontset`选择 mathtext 字体(请参阅[自定义 matplotlib](http://matplotlib.org/users/customizing.html#customizing-matplotlib)) > 注意 -> 在Python的 “narrow” 构建中,如果使用 STIX 字体,您还应该将`ps.fonttype`和`pdf.fonttype`设置为 3(默认值),而不是 42。否则一些字符将不可见。 +> 在Python的 『narrow』 构建中,如果使用 STIX 字体,你还应该将`ps.fonttype`和`pdf.fonttype`设置为 3(默认值),而不是 42。否则一些字符将不可见。 下面是个简单的例子: @@ -328,7 +328,7 @@ r'$\sqrt{2}$' ![](http://matplotlib.org/_images/mathmpl/math-f151e9b6c6.png) -方括号内可以(可选地)设置任何基底。 请注意,基数必须是一个简单的表达式,并且不能包含布局命令,如分数或上下标: +方括号内可以(可选地)设置任何底数。 请注意,底数必须是一个简单的表达式,并且不能包含布局命令,如分数或上下标: ```py r'$\sqrt[3]{x}$' @@ -344,7 +344,7 @@ r'$\sqrt[3]{x}$' > 此默认值可以使用`mathtext.default` `rcParam`更改。 这是非常有用的,例如,通过将其设置为`regular`,使用与常规非数学文本相同的字体作为数学文本。 -为了修改字体,例如,以 Roman 字体编写`sin`,在字体命令中闭合文本: +为了修改字体,例如,以 Roman 字体编写`sin`,使用字体命令来闭合文本: ```py r'$s(t) = \mathcal{A}\mathrm{sin}(2 \omega t)$' @@ -353,9 +353,9 @@ r'$s(t) = \mathcal{A}\mathrm{sin}(2 \omega t)$' ![](http://matplotlib.org/_images/mathmpl/math-c8056d47b3.png) -这里`s`和`t`是斜体(默认)的变量,`sin`是罗马字体,振幅`A`是书法字体。 注意在上面的例子中,`A`和`sin`之间的间距被挤压。 您可以使用间距命令在它们之间添加一些空格: +这里`s`和`t`是斜体(默认)的变量,`sin`是罗马字体,振幅`A`是书法字体。 注意在上面的例子中,`A`和`sin`之间的间距被挤压。 你可以使用间距命令在它们之间添加一些空格: -```py +``` s(t) = \mathcal{A}\/\sin(2 \omega t) ``` @@ -363,72 +363,298 @@ s(t) = \mathcal{A}\/\sin(2 \omega t) 所有字体的可用选项为: - ---- - - - - - - - - - - - - - - - - - - - -
CommandResult
\mathrm{Roman}
\mathit{Italic}
\mathtt{Typewriter}
\mathcal{CALLIGRAPHY}
+| 命令 | 结果 | +| --- | --- | +| `\mathrm{Roman}` | ![](../_images/mathmpl/math-89f87a2f0c.png) | +| `\mathit{Italic}` | ![](../_images/mathmpl/math-968de0e26b.png) | +| `\mathtt{Typewriter}` | ![](../_images/mathmpl/math-ca3f612baa.png) | +| `\mathcal{CALLIGRAPHY}` | ![](../_images/mathmpl/math-1f62587cf2.png) | 使用 STIX 字体时,你也可以选择: - ---- - - - - - - - - - - - - - - - - - - - - - - -
CommandResult
\mathbb{blackboard}
\mathrm{\mathbb{blackboard}}
\mathfrak{Fraktur}
\mathsf{sansserif}
\mathrm{\mathsf{sansserif}}
- - ---- - - - - - -
\mathcircled{circled}
+| 命令 | 结果 | +| --- | --- | +| `\mathbb{blackboard}` | ![](../_images/mathmpl/math-a12676f03f.png) | +| `\mathrm{\mathbb{blackboard}}` | ![](../_images/mathmpl/math-014e74dc81.png) | +| `\mathfrak{Fraktur}` | ![](../_images/mathmpl/math-4f55ade322.png) | +| `\mathsf{sansserif}` | ![](../_images/mathmpl/math-e9444fe0c8.png) | +| `\mathrm{\mathsf{sansserif}}` | ![](../_images/mathmpl/math-c3a13bbc63.png) | +| `\mathcircled{circled}` | ![](../_images/mathmpl/math-e82daa3fb7.png) | + +还有三个全局『字体集』可供选择,它们使用`matplotlibrc`中的`mathtext.fontset`参数进行选择。 + +`cm`: Computer Modern (TeX) + +![](http://matplotlib.org/_images/cm_fontset.png) + +`stix`: STIX (为和 Times 混合使用而设计) + +![](http://matplotlib.org/_images/stix_fontset.png) + +`stixsans`: STIX sans-serif + +![](http://matplotlib.org/_images/stixsans_fontset.png) + +此外,你可以使用`\mathdefault{...}`或其别名`\mathregular{...}`来使用用于 mathtext 之外的常规文本的字体。 这种方法有一些限制,最明显的是,可以使用很少的符号,但可用于将数学表达式与图中的其他文本混合。 + +### 自定义字体 + +mathtext 还提供了一种对数学公式使用自定义字体的方法。 这种方法使用起来相当棘手,应该看做为有耐心的用户准备的试验特性。 通过将`rcParam mathtext.fontset`设置为`custom`,你可以设置以下参数,这些参数控制用于特定数学字符集的字体文件。 + +| 参数 | 相当于 | +| --- | --- | +| `mathtext.it` | `\mathit{}` 默认斜体 | +| `mathtext.rm` | `\mathrm{}` Roman (upright) | +| `mathtext.tt` | `\mathtt{}` 打字机(monospace) | +| `mathtext.bf` | `\mathbf{}` 粗体 | +| `mathtext.cal` | `\mathcal{}` 书法 | +| `mathtext.sf` | `\mathsf{}` sans-serif | + +每个参数应该设置为`fontconfig`字体描述符(在尚未编写的字体章节中定义)。 + +所使用的字体应该具有 Unicode 映射,以便找到任何非拉丁字符,例如希腊语。 如果要使用未包含在自定义字体中的数学符号,可以将`rcParam mathtext.fallback_to_cm`设置为`True`,这将导致自定义字体中找不到特定字符时,数学文本系统使用默认的 Computer Modern 字体中的字符。 + +请注意,Unicode 中规定的数学字形随时间而演进,许多字体的字形对于 mathtext 可能不在正确位置。 + +### 重音符号 + +重音命令可以位于任何符号之前,在其上添加重音。 他们中的一些些拥有较长和较短的形式。 + +| 命令 | 结果 | +| --- | --- | +| `\acute a` 或 `\'a` | ![](../_images/mathmpl/math-fac074d098.png) | +| `\bar a` | ![](../_images/mathmpl/math-b7c546c13f.png) | +| `\breve a` | ![](../_images/mathmpl/math-88814f8d66.png) | +| `\ddot a` 或 `\"a` | ![](../_images/mathmpl/math-adb99bedc4.png) | +| `\dot a` 或 `\.a` | ![](../_images/mathmpl/math-b5496f6786.png) | +| `\grave a` 或 `\`a` | ![](../_images/mathmpl/math-54cbc28bce.png) | +| `\hat a` 或 `\^a` | ![](../_images/mathmpl/math-16da2c10a1.png) | +| `\tilde a` 或 `\~a` | ![](../_images/mathmpl/math-3a8b2e99d6.png) | +| `\vec a` | ![](../_images/mathmpl/math-be2ea18bef.png) | +| `\overline{abc}` | ![](../_images/mathmpl/math-75e95f3f2b.png) | + +另外有两个特殊的重音符号,可以自动调整为符号的宽度: + +| 命令 | 结果 | +| --- | --- | +| `\widehat{xyz}` | ![](../_images/mathmpl/math-8e4b9eb82b.png) | +| `\widetilde{xyz}` | ![](../_images/mathmpl/math-bf67fbdaae.png) | + +当把重音放在小写的`i`和`j`上时应该小心。 注意下面的`\imath`用来避免`i`上额外的点: + +```py +r"$\hat i\ \ \hat \imath$" +``` + +![](http://matplotlib.org/_images/mathmpl/math-80117b16d3.png) + +### 符号 + +你也可以使用更大量的 TeX 符号,比如`\infty`,`\leftarrow`,`\sum`,`\int`。 + + +| 小写希腊字母 | +| --- | --- | +| ![](../_images/mathmpl/math-5149852f08.png) `\alpha` | ![](../_images/mathmpl/math-59ed813421.png) `\beta` | ![](../_images/mathmpl/math-7d54d13fc9.png) `\chi` | ![](../_images/mathmpl/math-e15357ad29.png) `\delta` | ![](../_images/mathmpl/math-41188a0c1b.png) `\digamma` | +| ![](../_images/mathmpl/math-21b6ff3aa7.png) `\epsilon` | ![](../_images/mathmpl/math-0fa258552e.png) `\eta` | ![](../_images/mathmpl/math-ae65c1de79.png) `\gamma` | ![](../_images/mathmpl/math-ff6a67483e.png) `\iota` | ![](../_images/mathmpl/math-436efe52d1.png) `\kappa` | +| ![](../_images/mathmpl/math-3642ca147d.png) `\lambda` | ![](../_images/mathmpl/math-3488de1d0a.png) `\mu` | ![](../_images/mathmpl/math-79a0df421c.png) `\nu` | ![](../_images/mathmpl/math-b555ccd28d.png) `\omega` | ![](../_images/mathmpl/math-e22cc525ec.png) `\phi` | +| ![](../_images/mathmpl/math-2c7a9dac6d.png) `\pi` | ![](../_images/mathmpl/math-3fc9142b1d.png) `\psi` | ![](../_images/mathmpl/math-f2e3547a85.png) `\rho` | ![](../_images/mathmpl/math-293c147d21.png) `\sigma` | ![](../_images/mathmpl/math-f970af607c.png) `\tau` | +| ![](../_images/mathmpl/math-5dc8912759.png) `\theta` | ![](../_images/mathmpl/math-ac7cfff3a1.png) `\upsilon` | ![](../_images/mathmpl/math-a88976d8dd.png) `\varepsilon` | ![](../_images/mathmpl/math-67a8f5ca79.png) `\varkappa` | ![](../_images/mathmpl/math-a79325da6f.png) `\varphi` | +| ![](../_images/mathmpl/math-5e94f6d1ef.png) `\varpi` | ![](../_images/mathmpl/math-d6c1d2bb14.png) `\varrho` | ![](../_images/mathmpl/math-92fc1ff85f.png) `\varsigma` | ![](../_images/mathmpl/math-d11bf19a50.png) `\vartheta` | ![](../_images/mathmpl/math-1859062b14.png) `\xi` | +| ![](../_images/mathmpl/math-d51bb4d6d4.png) `\zeta` | + +| 大写希腊字母 | +| --- | --- | +| ![](../_images/mathmpl/math-e3168b0fff.png) `\Delta` | ![](../_images/mathmpl/math-4eacc6ba71.png) `\Gamma` | ![](../_images/mathmpl/math-a57791e0e2.png) `\Lambda` | ![](../_images/mathmpl/math-28d3e90e31.png) `\Omega` | ![](../_images/mathmpl/math-cebfe4186d.png) `\Phi` | ![](../_images/mathmpl/math-3b938a5601.png) `\Pi` | +| ![](../_images/mathmpl/math-d44376b8c3.png) `\Psi` | ![](../_images/mathmpl/math-076bf05243.png) `\Sigma` | ![](../_images/mathmpl/math-98c28d2d1b.png) `\Theta` | ![](../_images/mathmpl/math-43a44ec8e4.png) `\Upsilon` | ![](../_images/mathmpl/math-376450e92a.png) `\Xi` | ![](../_images/mathmpl/math-ab04245089.png) `\mho` | +| ![](../_images/mathmpl/math-9544659959.png) `\nabla` | + +| 希伯来文 | +| --- | --- | +| ![](../_images/mathmpl/math-d115134b0c.png) `\aleph` | ![](../_images/mathmpl/math-b1d46891d0.png) `\beth` | ![](../_images/mathmpl/math-ad0c7d5fd3.png) `\daleth` | ![](../_images/mathmpl/math-4a68c72624.png) `\gimel` | + +| 分隔符 | +| --- | --- | +| ![](../_images/mathmpl/math-9d750cc7d9.png) `/` | ![](../_images/mathmpl/math-1f9db75fdb.png) `[` | ![](../_images/mathmpl/math-0c8ba18b43.png) `\Downarrow` | ![](../_images/mathmpl/math-d00ab41d80.png) `\Uparrow` | ![](../_images/mathmpl/math-2480720752.png) `\Vert` | ![](../_images/mathmpl/math-b6a35dc0d4.png) `\backslash` | +| ![](../_images/mathmpl/math-56b7078922.png) `\downarrow` | ![](../_images/mathmpl/math-46c392f788.png) `\langle` | ![](../_images/mathmpl/math-6c35839641.png) `\lceil` | ![](../_images/mathmpl/math-145ca7a5e7.png) `\lfloor` | ![](../_images/mathmpl/math-554199c05b.png) `\llcorner` | ![](../_images/mathmpl/math-057e1a984d.png) `\lrcorner` | +| ![](../_images/mathmpl/math-ef94320557.png) `\rangle` | ![](../_images/mathmpl/math-cbd4824a55.png) `\rceil` | ![](../_images/mathmpl/math-c8d83de344.png) `\rfloor` | ![](../_images/mathmpl/math-de64de5819.png) `\ulcorner` | ![](../_images/mathmpl/math-f1bfb0bbf7.png) `\uparrow` | ![](../_images/mathmpl/math-4f8107394b.png) `\urcorner` | +| ![](../_images/mathmpl/math-e12e277d39.png) `\vert` | ![](../_images/mathmpl/math-f81f19a962.png) `\{` | ![](../_images/mathmpl/math-ee61bb7cf9.png) `\|` | ![](../_images/mathmpl/math-19097cff83.png) `\}` | ![](../_images/mathmpl/math-d35c7fd4db.png) `]` | ![](../_images/mathmpl/math-dfa04fb947.png) `|` | + +| 大型符号 | +| --- | --- | +| ![](../_images/mathmpl/math-db9b9e0126.png) `\bigcap` | ![](../_images/mathmpl/math-52ee117ecd.png) `\bigcup` | ![](../_images/mathmpl/math-a31bc74ee2.png) `\bigodot` | ![](../_images/mathmpl/math-011efae7a0.png) `\bigoplus` | ![](../_images/mathmpl/math-e8cf7f5844.png) `\bigotimes` | +| ![](../_images/mathmpl/math-8f896d9410.png) `\biguplus` | ![](../_images/mathmpl/math-1de8afe642.png) `\bigvee` | ![](../_images/mathmpl/math-888740ee66.png) `\bigwedge` | ![](../_images/mathmpl/math-1bb3130224.png) `\coprod` | ![](../_images/mathmpl/math-1610e87ea8.png) `\int` | +| ![](../_images/mathmpl/math-ce75170225.png) `\oint` | ![](../_images/mathmpl/math-e661b1289d.png) `\prod` | ![](../_images/mathmpl/math-f6fb720d82.png) `\sum` | + +| 标准函数名称 | +| --- | --- | +| ![](../_images/mathmpl/math-a174a79fa7.png) `\Pr` | ![](../_images/mathmpl/math-c7d2b9a8fd.png) `\arccos` | ![](../_images/mathmpl/math-bab33d6e68.png) `\arcsin` | ![](../_images/mathmpl/math-f8ee41a28a.png) `\arctan` | +| ![](../_images/mathmpl/math-510e2aecba.png) `\arg` | ![](../_images/mathmpl/math-a539c63e58.png) `\cos` | ![](../_images/mathmpl/math-46d99aa165.png) `\cosh` | ![](../_images/mathmpl/math-06c793e494.png) `\cot` | +| ![](../_images/mathmpl/math-993151c5de.png) `\coth` | ![](../_images/mathmpl/math-c72f36312c.png) `\csc` | ![](../_images/mathmpl/math-efdcd0e7c3.png) `\deg` | ![](../_images/mathmpl/math-a4f974e6ac.png) `\det` | +| ![](../_images/mathmpl/math-4ceaca4089.png) `\dim` | ![](../_images/mathmpl/math-9b8a721035.png) `\exp` | ![](../_images/mathmpl/math-705a921d5a.png) `\gcd` | ![](../_images/mathmpl/math-ec200f4f3a.png) `\hom` | +| ![](../_images/mathmpl/math-d78d7b5c1b.png) `\inf` | ![](../_images/mathmpl/math-9c3c23a23d.png) `\ker` | ![](../_images/mathmpl/math-0c0d015405.png) `\lg` | ![](../_images/mathmpl/math-441aa359eb.png) `\lim` | +| ![](../_images/mathmpl/math-2f010c89dd.png) `\liminf` | ![](../_images/mathmpl/math-a9a0109ea9.png) `\limsup` | ![](../_images/mathmpl/math-a5edc7016a.png) `\ln` | ![](../_images/mathmpl/math-e5cdb1d314.png) `\log` | +| ![](../_images/mathmpl/math-fb64cdd50f.png) `\max` | ![](../_images/mathmpl/math-bf7d25e347.png) `\min` | ![](../_images/mathmpl/math-a0b5414d31.png) `\sec` | ![](../_images/mathmpl/math-d8d19f17ef.png) `\sin` | +| ![](../_images/mathmpl/math-fce9663ad9.png) `\sinh` | ![](../_images/mathmpl/math-358f2a2131.png) `\sup` | ![](../_images/mathmpl/math-fb3512b848.png) `\tan` | ![](../_images/mathmpl/math-8e6df07c24.png) `\tanh` | + +| 二元运算符和关系符号 | +| --- | --- | +| ![](../_images/mathmpl/math-f610b8e469.png) `\Bumpeq` | ![](../_images/mathmpl/math-2a327a85e8.png) `\Cap` | ![](../_images/mathmpl/math-0fbbe481d0.png) `\Cup` | +| ![](../_images/mathmpl/math-2303577dee.png) `\Doteq` | ![](../_images/mathmpl/math-70e89758da.png) `\Join` | ![](../_images/mathmpl/math-3d85215bfa.png) `\Subset` | +| ![](../_images/mathmpl/math-191c6ba7fa.png) `\Supset` | ![](../_images/mathmpl/math-219444d8f5.png) `\Vdash` | ![](../_images/mathmpl/math-7db176731c.png) `\Vvdash` | +| ![](../_images/mathmpl/math-c957a5ae9f.png) `\approx` | ![](../_images/mathmpl/math-cf8f5e2275.png) `\approxeq` | ![](../_images/mathmpl/math-4ea8b1e13e.png) `\ast` | +| ![](../_images/mathmpl/math-23c4970a1a.png) `\asymp` | ![](../_images/mathmpl/math-ea0303ad72.png) `\backepsilon` | ![](../_images/mathmpl/math-b1d77626bb.png) `\backsim` | +| ![](../_images/mathmpl/math-af3bc8ac21.png) `\backsimeq` | ![](../_images/mathmpl/math-71771b9385.png) `\barwedge` | ![](../_images/mathmpl/math-937e2c148d.png) `\because` | +| ![](../_images/mathmpl/math-51ae43b24b.png) `\between` | ![](../_images/mathmpl/math-3b72c12de0.png) `\bigcirc` | ![](../_images/mathmpl/math-e98739824f.png) `\bigtriangledown` | +| ![](../_images/mathmpl/math-52ddd6655e.png) `\bigtriangleup` | ![](../_images/mathmpl/math-679967c920.png) `\blacktriangleleft` | ![](../_images/mathmpl/math-2ff97d8581.png) `\blacktriangleright` | +| ![](../_images/mathmpl/math-d2bc160257.png) `\bot` | ![](../_images/mathmpl/math-88c0703f35.png) `\bowtie` | ![](../_images/mathmpl/math-0cc3cb6c41.png) `\boxdot` | +| ![](../_images/mathmpl/math-b5a379f4e8.png) `\boxminus` | ![](../_images/mathmpl/math-3e25be9041.png) `\boxplus` | ![](../_images/mathmpl/math-d3219d7443.png) `\boxtimes` | +| ![](../_images/mathmpl/math-ef7a046183.png) `\bullet` | ![](../_images/mathmpl/math-c5baac4e57.png) `\bumpeq` | ![](../_images/mathmpl/math-f0c7f8f01c.png) `\cap` | +| ![](../_images/mathmpl/math-5a90bc5099.png) `\cdot` | ![](../_images/mathmpl/math-f9b0df773f.png) `\circ` | ![](../_images/mathmpl/math-5af298e692.png) `\circeq` | +| ![](../_images/mathmpl/math-e4d9d4c64b.png) `\coloneq` | ![](../_images/mathmpl/math-b43c061111.png) `\cong` | ![](../_images/mathmpl/math-20b287ac85.png) `\cup` | +| ![](../_images/mathmpl/math-c0df1e9b19.png) `\curlyeqprec` | ![](../_images/mathmpl/math-995f666935.png) `\curlyeqsucc` | ![](../_images/mathmpl/math-615de138a6.png) `\curlyvee` | +| ![](../_images/mathmpl/math-5af1fa6042.png) `\curlywedge` | ![](../_images/mathmpl/math-9b12241d0c.png) `\dag` | ![](../_images/mathmpl/math-9e1beabce9.png) `\dashv` | +| ![](../_images/mathmpl/math-f0fa40854a.png) `\ddag` | ![](../_images/mathmpl/math-765d4eae57.png) `\diamond` | ![](../_images/mathmpl/math-a1903b29fd.png) `\div` | +| ![](../_images/mathmpl/math-3df678db55.png) `\divideontimes` | ![](../_images/mathmpl/math-a5b22dbdac.png) `\doteq` | ![](../_images/mathmpl/math-ff23293ae5.png) `\doteqdot` | +| ![](../_images/mathmpl/math-397b5fc155.png) `\dotplus` | ![](../_images/mathmpl/math-d5242ce585.png) `\doublebarwedge` | ![](../_images/mathmpl/math-a4f1a69c76.png) `\eqcirc` | +| ![](../_images/mathmpl/math-17826fcd24.png) `\eqcolon` | ![](../_images/mathmpl/math-c104febab3.png) `\eqsim` | ![](../_images/mathmpl/math-45eaae26d2.png) `\eqslantgtr` | +| ![](../_images/mathmpl/math-c3fea548da.png) `\eqslantless` | ![](../_images/mathmpl/math-cc1340c453.png) `\equiv` | ![](../_images/mathmpl/math-7965c0c1af.png) `\fallingdotseq` | +| ![](../_images/mathmpl/math-a41c184ca6.png) `\frown` | ![](../_images/mathmpl/math-0bf42a25bb.png) `\geq` | ![](../_images/mathmpl/math-9b14251f65.png) `\geqq` | +| ![](../_images/mathmpl/math-1fca7a951f.png) `\geqslant` | ![](../_images/mathmpl/math-f9990bc9cf.png) `\gg` | ![](../_images/mathmpl/math-a3de1e5b51.png) `\ggg` | +| ![](../_images/mathmpl/math-04c47dcb6e.png) `\gnapprox` | ![](../_images/mathmpl/math-a3f9f1f014.png) `\gneqq` | ![](../_images/mathmpl/math-793d9cedd0.png) `\gnsim` | +| ![](../_images/mathmpl/math-207852189a.png) `\gtrapprox` | ![](../_images/mathmpl/math-9336896bb3.png) `\gtrdot` | ![](../_images/mathmpl/math-4cd21f8ba6.png) `\gtreqless` | +| ![](../_images/mathmpl/math-18a0084a2d.png) `\gtreqqless` | ![](../_images/mathmpl/math-8e388594ad.png) `\gtrless` | ![](../_images/mathmpl/math-9d5e427aeb.png) `\gtrsim` | +| ![](../_images/mathmpl/math-58e3fcf6fd.png) `\in` | ![](../_images/mathmpl/math-0e049fe80b.png) `\intercal` | ![](../_images/mathmpl/math-1a503a50f2.png) `\leftthreetimes` | +| ![](../_images/mathmpl/math-aca311c641.png) `\leq` | ![](../_images/mathmpl/math-d87b34b699.png) `\leqq` | ![](../_images/mathmpl/math-764751dad5.png) `\leqslant` | +| ![](../_images/mathmpl/math-b8571a3cc2.png) `\lessapprox` | ![](../_images/mathmpl/math-6cb5c3c310.png) `\lessdot` | ![](../_images/mathmpl/math-1632a38331.png) `\lesseqgtr` | +| ![](../_images/mathmpl/math-d367d088c6.png) `\lesseqqgtr` | ![](../_images/mathmpl/math-268c486057.png) `\lessgtr` | ![](../_images/mathmpl/math-b53ab799d1.png) `\lesssim` | +| ![](../_images/mathmpl/math-f5e02865f3.png) `\ll` | ![](../_images/mathmpl/math-2303518311.png) `\lll` | ![](../_images/mathmpl/math-c408639f33.png) `\lnapprox` | +| ![](../_images/mathmpl/math-38bf4cf10d.png) `\lneqq` | ![](../_images/mathmpl/math-ad67ff4a6f.png) `\lnsim` | ![](../_images/mathmpl/math-f557917efd.png) `\ltimes` | +| ![](../_images/mathmpl/math-96c9a8ca95.png) `\mid` | ![](../_images/mathmpl/math-b5ae8c62a3.png) `\models` | ![](../_images/mathmpl/math-608c4a02ea.png) `\mp` | +| ![](../_images/mathmpl/math-e0ca686f62.png) `\nVDash` | ![](../_images/mathmpl/math-4d5d5f4ffb.png) `\nVdash` | ![](../_images/mathmpl/math-8aa32761da.png) `\napprox` | +| ![](../_images/mathmpl/math-92306485fb.png) `\ncong` | ![](../_images/mathmpl/math-6e6c5971ad.png) `\ne` | ![](../_images/mathmpl/math-da1122f776.png) `\neq` | +| ![](../_images/mathmpl/math-da1122f776.png) `\neq` | ![](../_images/mathmpl/math-989088989a.png) `\nequiv` | ![](../_images/mathmpl/math-07c03ece9c.png) `\ngeq` | +| ![](../_images/mathmpl/math-c2c43a5762.png) `\ngtr` | ![](../_images/mathmpl/math-7e90b124a8.png) `\ni` | ![](../_images/mathmpl/math-1c2ed5670a.png) `\nleq` | +| ![](../_images/mathmpl/math-c9136df47e.png) `\nless` | ![](../_images/mathmpl/math-4c5d76f523.png) `\nmid` | ![](../_images/mathmpl/math-9afe2d20f8.png) `\notin` | +| ![](../_images/mathmpl/math-e63a2108d5.png) `\nparallel` | ![](../_images/mathmpl/math-201b65e42c.png) `\nprec` | ![](../_images/mathmpl/math-37454f1e25.png) `\nsim` | +| ![](../_images/mathmpl/math-b045970090.png) `\nsubset` | ![](../_images/mathmpl/math-e2dcef116c.png) `\nsubseteq` | ![](../_images/mathmpl/math-0dc1c96f16.png) `\nsucc` | +| ![](../_images/mathmpl/math-0d1363d575.png) `\nsupset` | ![](../_images/mathmpl/math-8963eae853.png) `\nsupseteq` | ![](../_images/mathmpl/math-2eaa265b46.png) `\ntriangleleft` | +| ![](../_images/mathmpl/math-343170b287.png) `\ntrianglelefteq` | ![](../_images/mathmpl/math-813dcf0a93.png) `\ntriangleright` | ![](../_images/mathmpl/math-df6899ad3e.png) `\ntrianglerighteq` | +| ![](../_images/mathmpl/math-a55f718abe.png) `\nvDash` | ![](../_images/mathmpl/math-fefbb15af0.png) `\nvdash` | ![](../_images/mathmpl/math-b8348856ea.png) `\odot` | +| ![](../_images/mathmpl/math-497b831b05.png) `\ominus` | ![](../_images/mathmpl/math-cfcebc2ef8.png) `\oplus` | ![](../_images/mathmpl/math-6fd5eead33.png) `\oslash` | +| ![](../_images/mathmpl/math-3d7ac4bb5c.png) `\otimes` | ![](../_images/mathmpl/math-305e05a6ab.png) `\parallel` | ![](../_images/mathmpl/math-86ea2beb93.png) `\perp` | +| ![](../_images/mathmpl/math-62d5e1ef75.png) `\pitchfork` | ![](../_images/mathmpl/math-813255d42d.png) `\pm` | ![](../_images/mathmpl/math-2a54002803.png) `\prec` | +| ![](../_images/mathmpl/math-6f127405a3.png) `\precapprox` | ![](../_images/mathmpl/math-5686c5a93f.png) `\preccurlyeq` | ![](../_images/mathmpl/math-c6975aea0e.png) `\preceq` | +| ![](../_images/mathmpl/math-53e4edd44d.png) `\precnapprox` | ![](../_images/mathmpl/math-b7c281dd54.png) `\precnsim` | ![](../_images/mathmpl/math-58f182e47e.png) `\precsim` | +| ![](../_images/mathmpl/math-4225d47da8.png) `\propto` | ![](../_images/mathmpl/math-03cbb97a54.png) `\rightthreetimes` | ![](../_images/mathmpl/math-8f609835cb.png) `\risingdotseq` | +| ![](../_images/mathmpl/math-61a5f3fde0.png) `\rtimes` | ![](../_images/mathmpl/math-10ab63f88f.png) `\sim` | ![](../_images/mathmpl/math-f5e3901a47.png) `\simeq` | +| ![](../_images/mathmpl/math-cd5adea2d9.png) `\slash` | ![](../_images/mathmpl/math-11c6bdf228.png) `\smile` | ![](../_images/mathmpl/math-2fc0f7c957.png) `\sqcap` | +| ![](../_images/mathmpl/math-f3f9a5c2b6.png) `\sqcup` | ![](../_images/mathmpl/math-32710445c4.png) `\sqsubset` | ![](../_images/mathmpl/math-32710445c4.png) `\sqsubset` | +| ![](../_images/mathmpl/math-6462f633f1.png) `\sqsubseteq` | ![](../_images/mathmpl/math-b373234f3b.png) `\sqsupset` | ![](../_images/mathmpl/math-b373234f3b.png) `\sqsupset` | +| ![](../_images/mathmpl/math-301349a96f.png) `\sqsupseteq` | ![](../_images/mathmpl/math-3ea081f1d9.png) `\star` | ![](../_images/mathmpl/math-d7ee7c1348.png) `\subset` | +| ![](../_images/mathmpl/math-ab35a80a37.png) `\subseteq` | ![](../_images/mathmpl/math-329584d288.png) `\subseteqq` | ![](../_images/mathmpl/math-26f9e5316b.png) `\subsetneq` | +| ![](../_images/mathmpl/math-d6c1dc73f3.png) `\subsetneqq` | ![](../_images/mathmpl/math-3b5db3b36b.png) `\succ` | ![](../_images/mathmpl/math-29a7c6603c.png) `\succapprox` | +| ![](../_images/mathmpl/math-764af5d0f7.png) `\succcurlyeq` | ![](../_images/mathmpl/math-f083286645.png) `\succeq` | ![](../_images/mathmpl/math-12e9272240.png) `\succnapprox` | +| ![](../_images/mathmpl/math-22a812f02e.png) `\succnsim` | ![](../_images/mathmpl/math-f313a5f9af.png) `\succsim` | ![](../_images/mathmpl/math-7a88315c05.png) `\supset` | +| ![](../_images/mathmpl/math-b15f9f29ec.png) `\supseteq` | ![](../_images/mathmpl/math-2b42f15859.png) `\supseteqq` | ![](../_images/mathmpl/math-0ebac5d490.png) `\supsetneq` | +| ![](../_images/mathmpl/math-7cafbba6d3.png) `\supsetneqq` | ![](../_images/mathmpl/math-21e977e4ec.png) `\therefore` | ![](../_images/mathmpl/math-ae7023d9db.png) `\times` | +| ![](../_images/mathmpl/math-f0fe2a4a9f.png) `\top` | ![](../_images/mathmpl/math-7a5bdaf004.png) `\triangleleft` | ![](../_images/mathmpl/math-3234da3142.png) `\trianglelefteq` | +| ![](../_images/mathmpl/math-5325d825f0.png) `\triangleq` | ![](../_images/mathmpl/math-61187783ee.png) `\triangleright` | ![](../_images/mathmpl/math-229058201e.png) `\trianglerighteq` | +| ![](../_images/mathmpl/math-8c6a0f04b9.png) `\uplus` | ![](../_images/mathmpl/math-8da9245788.png) `\vDash` | ![](../_images/mathmpl/math-7450111856.png) `\varpropto` | +| ![](../_images/mathmpl/math-311d2647c5.png) `\vartriangleleft` | ![](../_images/mathmpl/math-7da885dcbf.png) `\vartriangleright` | ![](../_images/mathmpl/math-d8ad6ecbe6.png) `\vdash` | +| ![](../_images/mathmpl/math-f5af631a03.png) `\vee` | ![](../_images/mathmpl/math-0ca72c02e5.png) `\veebar` | ![](../_images/mathmpl/math-4c229f580d.png) `\wedge` | +| ![](../_images/mathmpl/math-953993beed.png) `\wr` | + +| 箭头符号 | +| --- | --- | +| ![](../_images/mathmpl/math-0c8ba18b43.png) `\Downarrow` | ![](../_images/mathmpl/math-1a6ec6d88f.png) `\Leftarrow` | +| ![](../_images/mathmpl/math-74b9b263f9.png) `\Leftrightarrow` | ![](../_images/mathmpl/math-3ce6141dea.png) `\Lleftarrow` | +| ![](../_images/mathmpl/math-e3d8965f58.png) `\Longleftarrow` | ![](../_images/mathmpl/math-eb3a880058.png) `\Longleftrightarrow` | +| ![](../_images/mathmpl/math-c985be990e.png) `\Longrightarrow` | ![](../_images/mathmpl/math-459d7c5693.png) `\Lsh` | +| ![](../_images/mathmpl/math-0f08e28a07.png) `\Nearrow` | ![](../_images/mathmpl/math-a608a7ae83.png) `\Nwarrow` | +| ![](../_images/mathmpl/math-5e42a40994.png) `\Rightarrow` | ![](../_images/mathmpl/math-317920b703.png) `\Rrightarrow` | +| ![](../_images/mathmpl/math-26fab8f44f.png) `\Rsh` | ![](../_images/mathmpl/math-ba64c5e997.png) `\Searrow` | +| ![](../_images/mathmpl/math-6722d13e60.png) `\Swarrow` | ![](../_images/mathmpl/math-d00ab41d80.png) `\Uparrow` | +| ![](../_images/mathmpl/math-94ff64057f.png) `\Updownarrow` | ![](../_images/mathmpl/math-a59e0fa5ee.png) `\circlearrowleft` | +| ![](../_images/mathmpl/math-ea5765e8b3.png) `\circlearrowright` | ![](../_images/mathmpl/math-68b96a49a5.png) `\curvearrowleft` | +| ![](../_images/mathmpl/math-eb8d6ee4ad.png) `\curvearrowright` | ![](../_images/mathmpl/math-682a5688ef.png) `\dashleftarrow` | +| ![](../_images/mathmpl/math-8bc070eada.png) `\dashrightarrow` | ![](../_images/mathmpl/math-56b7078922.png) `\downarrow` | +| ![](../_images/mathmpl/math-1d11ce50b2.png) `\downdownarrows` | ![](../_images/mathmpl/math-a019dc17a7.png) `\downharpoonleft` | +| ![](../_images/mathmpl/math-16b15cdedd.png) `\downharpoonright` | ![](../_images/mathmpl/math-3db5c70042.png) `\hookleftarrow` | +| ![](../_images/mathmpl/math-580fac9571.png) `\hookrightarrow` | ![](../_images/mathmpl/math-09e354a93e.png) `\leadsto` | +| ![](../_images/mathmpl/math-097464d1cd.png) `\leftarrow` | ![](../_images/mathmpl/math-a2e07eb2ff.png) `\leftarrowtail` | +| ![](../_images/mathmpl/math-792b216977.png) `\leftharpoondown` | ![](../_images/mathmpl/math-3c072a15c0.png) `\leftharpoonup` | +| ![](../_images/mathmpl/math-433174617c.png) `\leftleftarrows` | ![](../_images/mathmpl/math-bce42da457.png) `\leftrightarrow` | +| ![](../_images/mathmpl/math-dec391be07.png) `\leftrightarrows` | ![](../_images/mathmpl/math-8c68333295.png) `\leftrightharpoons` | +| ![](../_images/mathmpl/math-1afd9d2af0.png) `\leftrightsquigarrow` | ![](../_images/mathmpl/math-0a36be904f.png) `\leftsquigarrow` | +| ![](../_images/mathmpl/math-c8fe9fb96c.png) `\longleftarrow` | ![](../_images/mathmpl/math-91b94c6be9.png) `\longleftrightarrow` | +| ![](../_images/mathmpl/math-02ce986a2e.png) `\longmapsto` | ![](../_images/mathmpl/math-80a13771b7.png) `\longrightarrow` | +| ![](../_images/mathmpl/math-3bfe8e8950.png) `\looparrowleft` | ![](../_images/mathmpl/math-64aa42214e.png) `\looparrowright` | +| ![](../_images/mathmpl/math-9a483a288a.png) `\mapsto` | ![](../_images/mathmpl/math-c40f3bc7dc.png) `\multimap` | +| ![](../_images/mathmpl/math-ea5241d5f2.png) `\nLeftarrow` | ![](../_images/mathmpl/math-9119a30630.png) `\nLeftrightarrow` | +| ![](../_images/mathmpl/math-eeabc86e5f.png) `\nRightarrow` | ![](../_images/mathmpl/math-640fa94ebe.png) `\nearrow` | +| ![](../_images/mathmpl/math-f9cc3f8904.png) `\nleftarrow` | ![](../_images/mathmpl/math-1278a024c8.png) `\nleftrightarrow` | +| ![](../_images/mathmpl/math-f11a3eab57.png) `\nrightarrow` | ![](../_images/mathmpl/math-3223454152.png) `\nwarrow` | +| ![](../_images/mathmpl/math-fb1cbbd43f.png) `\rightarrow` | ![](../_images/mathmpl/math-2e03b9e387.png) `\rightarrowtail` | +| ![](../_images/mathmpl/math-41f636a823.png) `\rightharpoondown` | ![](../_images/mathmpl/math-2cdbf2db88.png) `\rightharpoonup` | +| ![](../_images/mathmpl/math-2617106b1e.png) `\rightleftarrows` | ![](../_images/mathmpl/math-2617106b1e.png) `\rightleftarrows` | +| ![](../_images/mathmpl/math-a2eb9bae76.png) `\rightleftharpoons` | ![](../_images/mathmpl/math-a2eb9bae76.png) `\rightleftharpoons` | +| ![](../_images/mathmpl/math-43575c473c.png) `\rightrightarrows` | ![](../_images/mathmpl/math-43575c473c.png) `\rightrightarrows` | +| ![](../_images/mathmpl/math-2aff52a07e.png) `\rightsquigarrow` | ![](../_images/mathmpl/math-93a935b705.png) `\searrow` | +| ![](../_images/mathmpl/math-8d37bd9196.png) `\swarrow` | ![](../_images/mathmpl/math-306ea70acd.png) `\to` | +| ![](../_images/mathmpl/math-ae2fa40b25.png) `\twoheadleftarrow` | ![](../_images/mathmpl/math-8e6cdc7038.png) `\twoheadrightarrow` | +| ![](../_images/mathmpl/math-f1bfb0bbf7.png) `\uparrow` | ![](../_images/mathmpl/math-eb3b3a6d5c.png) `\updownarrow` | +| ![](../_images/mathmpl/math-eb3b3a6d5c.png) `\updownarrow` | ![](../_images/mathmpl/math-bbdf3d8983.png) `\upharpoonleft` | +| ![](../_images/mathmpl/math-5fea7c5657.png) `\upharpoonright` | ![](../_images/mathmpl/math-d831d8aa62.png) `\upuparrows` | + + +| 杂项符号 | +| --- | --- | +| ![](../_images/mathmpl/math-390d3dc75c.png) `\$` | ![](../_images/mathmpl/math-7ffb7d798c.png) `\AA` | ![](../_images/mathmpl/math-38501d21c9.png) `\Finv` | +| ![](../_images/mathmpl/math-be84d4168e.png) `\Game` | ![](../_images/mathmpl/math-3207fff524.png) `\Im` | ![](../_images/mathmpl/math-482297a060.png) `\P` | +| ![](../_images/mathmpl/math-6ea3150bfd.png) `\Re` | ![](../_images/mathmpl/math-a99c89f6e1.png) `\S` | ![](../_images/mathmpl/math-2fcd70072d.png) `\angle` | +| ![](../_images/mathmpl/math-9db5c962c8.png) `\backprime` | ![](../_images/mathmpl/math-8082fb34e8.png) `\bigstar` | ![](../_images/mathmpl/math-4b07b72122.png) `\blacksquare` | +| ![](../_images/mathmpl/math-8f8c0c020c.png) `\blacktriangle` | ![](../_images/mathmpl/math-58162c32f0.png) `\blacktriangledown` | ![](../_images/mathmpl/math-e90d63d41d.png) `\cdots` | +| ![](../_images/mathmpl/math-800bb70468.png) `\checkmark` | ![](../_images/mathmpl/math-762c3b5e9e.png) `\circledR` | ![](../_images/mathmpl/math-52eae78384.png) `\circledS` | +| ![](../_images/mathmpl/math-4d24dff6f8.png) `\clubsuit` | ![](../_images/mathmpl/math-b225b29af4.png) `\complement` | ![](../_images/mathmpl/math-8f454df900.png) `\copyright` | +| ![](../_images/mathmpl/math-dbcc77f1d2.png) `\ddots` | ![](../_images/mathmpl/math-bc54d541fc.png) `\diamondsuit` | ![](../_images/mathmpl/math-923c665edb.png) `\ell` | +| ![](../_images/mathmpl/math-51cd44e108.png) `\emptyset` | ![](../_images/mathmpl/math-19f957fc71.png) `\eth` | ![](../_images/mathmpl/math-cac5abe8bf.png) `\exists` | +| ![](../_images/mathmpl/math-518af824c6.png) `\flat` | ![](../_images/mathmpl/math-92a896986d.png) `\forall` | ![](../_images/mathmpl/math-2525d5d71d.png) `\hbar` | +| ![](../_images/mathmpl/math-eab5c7cdff.png) `\heartsuit` | ![](../_images/mathmpl/math-dcb2243778.png) `\hslash` | ![](../_images/mathmpl/math-f8daa97519.png) `\iiint` | +| ![](../_images/mathmpl/math-14a5baf1f1.png) `\iint` | ![](../_images/mathmpl/math-14a5baf1f1.png) `\iint` | ![](../_images/mathmpl/math-6a5f1c0ebd.png) `\imath` | +| ![](../_images/mathmpl/math-c899412e92.png) `\infty` | ![](../_images/mathmpl/math-cca8605565.png) `\jmath` | ![](../_images/mathmpl/math-ee226905c4.png) `\ldots` | +| ![](../_images/mathmpl/math-d78cd804a4.png) `\measuredangle` | ![](../_images/mathmpl/math-07933b21e0.png) `\natural` | ![](../_images/mathmpl/math-21d4b9ec5e.png) `\neg` | +| ![](../_images/mathmpl/math-a01094061c.png) `\nexists` | ![](../_images/mathmpl/math-fea35fa8ec.png) `\oiiint` | ![](../_images/mathmpl/math-7d9222c03b.png) `\partial` | +| ![](../_images/mathmpl/math-d4d8611cbc.png) `\prime` | ![](../_images/mathmpl/math-0525bc07de.png) `\sharp` | ![](../_images/mathmpl/math-799e766e98.png) `\spadesuit` | +| ![](../_images/mathmpl/math-96aad37e82.png) `\sphericalangle` | ![](../_images/mathmpl/math-e51ac520e2.png) `\ss` | ![](../_images/mathmpl/math-62e1ea5660.png) `\triangledown` | +| ![](../_images/mathmpl/math-91a36bab96.png) `\varnothing` | ![](../_images/mathmpl/math-449680794f.png) `\vartriangle` | ![](../_images/mathmpl/math-0716fbd542.png) `\vdots` | +| ![](../_images/mathmpl/math-6eca465169.png) `\wp` | ![](../_images/mathmpl/math-12713adf78.png) `\yen` | + +如果特定符号没有名称(对于 STIX 字体中的许多较为模糊的符号也是如此),也可以使用 Unicode 字符: + +```py +ur'$\u23ce$' +``` + +### 示例 + +下面是个示例,在上下文中展示了许多这些特性。 + +```py +import numpy as np +import matplotlib.pyplot as plt +t = np.arange(0.0, 2.0, 0.01) +s = np.sin(2*np.pi*t) + +plt.plot(t,s) +plt.title(r'$\alpha_i > \beta_i$', fontsize=20) +plt.text(1, -0.6, r'$\sum_{i=0}^\infty x_i$', fontsize=20) +plt.text(0.6, 0.6, r'$\mathcal{A}\mathrm{sin}(2 \omega t)$', + fontsize=20) +plt.xlabel('time (s)') +plt.ylabel('volts (mV)') +plt.show() +``` + +![](http://matplotlib.org/_images/pyplot_mathtext.png) -- GitLab