【LaTeX Tips】LaTeX 中公式编号括号样式及章节关联的方法
2017-04-02 21:07
579 查看
章节关联
使用 amsmath 宏包的时候,我们可以利用 amsmath 宏包提供的 \numberwithin{<sub-counter>}{<counter>}命令来实现公式与章节关联。效果形如
1.1
demo
1 2 3 4 5 6 7 8 9 | \documentclass{article} \usepackage{amsmath} \numberwithin{equation}{section} \begin{document} \section{Test} \begin{equation} E = mc^2 \end{equation} \end{document} |
demo
1 2 3 4 5 6 7 8 910 | \documentclass{article} \makeatletter \@addtoreset{equation}{section} \makeatother \renewcommand\theequation{\arabic{section}-\arabic{equation}} \begin{document} \section{Test} \begin{equation} E = mc^2 \end{equation} \end{document} |
修改括号的样式
使用 amsmath 宏包的时候,可以借助 mathtools 宏包提供的命令来修改公式编号的括号样式。可以去掉 LaTeX 公式编号的括号,或者变成别的样式——比如方括号/特别的文字。mathtools 宏包提供了两个命令,用于定义和应用公式编号的括号的样式。
demo
1 2 | \newtagform{form-name}[Number-Style]{left}{right} \usetagform{form-name} |
\newtagform来定义样式,用
\usetagform来应用。
demo
1 2 3 4 5 6 7 8 910 | \documentclass{article} \usepackage{amsmath} \usepackage{mathtools} \newtagform{test}[\textbf]{\textbf{\small Equation~}}{} \usetagform{test} \begin{document} \section{Test} \begin{equation} E = mc^2 \end{equation} \end{document} |
相关文章推荐
- LaTeX下如何改变章节标题编号的样式?
- Latex按照章节为公式编号
- LaTeX让公式跟随章节编号
- LaTeX技巧心得210:latex公式加粗方法技巧
- Latex带括号的多行公式问题(转)
- LaTeX之公式及编号
- 科技文献的章节编号方法
- latex 数学符号,段落编号、公式等,随记
- 设置TabWidget的样式的方法、关联Fragment与tabwidget的方法、点击tab显示相应Fragment方法
- 在博客中插入Latex 公式的方法
- Latex数学公式中的空格表示方法
- Latex 公式编号(zz) 转自Lavande de mer的sohu博客
- LaTex 两种给公式加颜色的方法
- LaTeX中子公式编号的问题 ( 子公式编号&联立)
- LaTeX之公式及编号
- LaTeX之公式及编号
- LaTeX之公式及编号
- word中公式居中,编号右对齐的设置方法!
- 【Microsoft Word】Aurora插入公式点击Refresh,提示Problems running LaTex解决方法
- mathtype中删除公式编号中的章序号(1.2)-> (2)的方法