带有部分文本的多个单行方程

带有部分文本的多个单行方程

我无法正确对齐它们。

我怎样才能拥有多条线方程,并且每条方程都有正确的标记。

以下是一个例子:

\documentclass{article}
\usepackage{amsmath} % for 'align*' environment

\begin{document}
  \begin{equation} \label{eq:sr}
\mbox{Inductive reactance as:} X_L = 2 \pi f L = \omega L \\
\mbox{Capacitive reactance as:} X_c = \frac{1}{2 \pi f C} = \frac{1}{\omega C} \\
\mbox{Total circuit reactance:} X_T = X_L - X_C or X_C - X_L \\
\mbox{Total circuit impedance:} Z = \sqrt{R^2 + X_T^2} = R + jX \\
\mbox{When} X_L = X_C \rightarrow 2 \pi f L  = \frac{1}{2 \pi f C} \\
f_r = \frac{1}{2 \pi \sqrt{L C}} (Hz) or \omega_r = \frac{1}{L C} (rads) \\
 \end{equation}

\end{document}

答案1

最好使用类似以下方法实现枚举的多重比alignatamsmath

在此处输入图片描述

\documentclass{article}

\usepackage{amsmath}

\begin{document}

\begin{alignat}{2}
  \text{Inductive reactance as:}  & \quad & X_L &= 2 \pi f L = \omega L \\
  \text{Capacitive reactance as:} &       & X_c &= \frac{1}{2 \pi f C} = \frac{1}{\omega C} \\
  \text{Total circuit reactance:} &       & X_T &= X_L - X_C or X_C - X_L \\
  \text{Total circuit impedance:} &       &   Z &= \sqrt{R^2 + X_T^2} = R + jX \\
                      \text{When} &       & X_L &= X_C \rightarrow 2 \pi f L = \frac{1}{2 \pi f C} \\
                                  &       & f_r &= \frac{1}{2 \pi \sqrt{L C}} \text{ (Hz) or }
                                                   \omega_r = \frac{1}{L C} \text{ (rads)}
\end{alignat}

\end{document}

相关内容