答案1
你介意这样的事情吗:
\documentclass{article}
\usepackage{mathtools,array}
% for show equation only
\usepackage[active,tightpage]{preview}
\PreviewEnvironment{equation}
\setlength\PreviewBorder{1em}
\begin{document}
\begin{equation}
\left[\begin{tabular}{@{}>{$}c<{$}@{}}
\dfrac{\left(\vec{A} - \dfrac{b}{c}\vec{D}\right)}{E^2}
\end{tabular}\right]^{1/2}
\end{equation}
\end{document}
附录:更简单的代码是,如果使用tabular
环境的 话:array
\begin{equation}
\left[\begin{array}{@{} c @{}
}
\dfrac{\left(\vec{A} - \dfrac{b}{c}\vec{D}\right)}{E^2}
\end{array}\right]^{1/2}
\end{equation}
结果和以前一样。
答案2
您可以使用来完成此操作delarray
,但我认为我建议的第二种方法更好。
\documentclass{article}
\usepackage{amsmath}
\usepackage{delarray}
\begin{document}
Here's a fraction with very large numerator
\begin{equation*}
\begin{array}\lbrack{@{}c@{}}\rbrack
\dfrac{\left(\vec{A} - \dfrac{b}{c} \vec{D} \right)^2}{E^2}
\end{array}^{1/2}
\end{equation*}
but it's much better to write it in a different way
\begin{equation*}
\left[\frac{1}{E^2}\left(\vec{A} - \frac{b}{c} \vec{D} \right)^2\right]^{1/2}
\end{equation*}
so the terms are better aligned with the formula axis.
\end{document}