![左右边缘的等式小标题](https://linux22.com/image/447547/%E5%B7%A6%E5%8F%B3%E8%BE%B9%E7%BC%98%E7%9A%84%E7%AD%89%E5%BC%8F%E5%B0%8F%E6%A0%87%E9%A2%98.png)
答案1
\marginnote
可以使用以下命令添加边距注释marginnote
,方程周围的框可以添加empheq
来自的环境empheq
。
\documentclass{article}
\usepackage{marginnote}
\usepackage{empheq}
\usepackage{xcolor}
\newcommand*{\bluebox}[1]{\fcolorbox{blue}{white}{#1}}
\reversemarginpar
\begin{document}
This equality implies that it makes sense to introduce the notion of the \emph{electric field} at point \(\mathbf{r}\) (as an entity independent of \(q\)), characterized by the following vector:
\begin{empheq}[box=\bluebox]{equation}
\marginnote{\color{blue}Electric field: definition}[-2mm]
\mathbf{E}(\mathbf{r}) \equiv \frac{\mathbf{F}(\mathbf{r})}{q},
\end{empheq}
formally called the \emph{electric field strength} -- but much more frequently, just the ``electric field''.
\end{document}
答案2
\boxed
(包提供的宏amsmath
) 和\marginnote
(包提供的宏)的组合marginnote
可以完成这项工作。
\documentclass{article}
\usepackage{marginnote} % for '\marginnote' macro
\reversemarginpar
\usepackage{amsmath} % for '\boxed' macro
\usepackage{xcolor} % for '\color' macro
\begin{document}
This equality implies that it makes sense to define an \emph{electric field}
at a point~\(\mathbf{r}\), as an entity that is
independent of~\(q\), as:
\begin{equation}
\boxed{\mathbf{E}(\mathbf{r}) \equiv \frac{\mathbf{F}(\mathbf{r})}{q}\,.}
\marginnote{\color{blue}Electric field: definition}
\end{equation}
\(\mathbf{E}\) is formally called the \emph{electric field
strength} or, far more frequently, just the ``electric field.''
\end{document}