如何对齐公式的符号解释/含义?

如何对齐公式的符号解释/含义?

在此处输入图片描述

首先,我不知道显示/表示方程式中使用的符号的含义的最佳方法是什么?

其次,如果我显示像上面的幻灯片那样的内容,我该如何对齐等号?

我的工作代码是-

\documentclass{beamer}
\usepackage{tikz}
\usepackage{amsmath}
\usetheme{Madrid}
\logo{%
  %\includegraphics[width=1cm,height=1.5cm,keepaspectratio]{DUlogo}%
  \includegraphics[width=1cm,height=1.5cm,keepaspectratio]{example-image-a}
  \hspace{\dimexpr\paperwidth-2cm-5pt}%
  %\includegraphics[width=1cm,height=1cm,keepaspectratio]{GNR.png}%
  \includegraphics[width=1cm,height=1cm,keepaspectratio]{example-image-b}
}
\begin{document}
\begin{frame}
  \frametitle{Delay equation}
  \begin{exampleblock}{}
    \[
      d_{i} = \frac{1}{\mu_{i}- \lambda_{i}} + \frac{1}{c_{i} - \lambda_{i}}
    \]
  \end{exampleblock}
  \centering
  $d = \text{total delay}$\\
  $\mu_{i} = \text{service rate}$\\
  $\lambda_{i} = \text{arival rate}$\\
  $c_{i} = \text{transmission rate}$\\
\end{frame}
\end{document}

更新
当符号长度不同时,这个是什么?

\documentclass{beamer}
\usepackage{tikz}
\usepackage{amsmath}
\usetheme{Madrid}
\logo{%
  \includegraphics[width=1cm,height=1.5cm,keepaspectratio]{example-image-a}%
  \hspace{\dimexpr\paperwidth-2cm-5pt}%
  \includegraphics[width=1cm,height=1cm,keepaspectratio]{example-image-b}%
}
\begin{document}
\begin{frame}
  \frametitle{Equation}
  \begin{exampleblock}{}
   \[
     \hat{x_{i}} = \sum_{j\in{\mathcal{A}}}^{}h_{ij}^{H}w_{ij}x_{i} + \sum_{k\neq i}^{N}\sum_{j\in{A}}^{}h_{ij}^{H}w_{kj}x_{k} + \delta_{i}
   \]
  \end{exampleblock}
  \begin{itemize}
    \item $\mathcal{A}$\qquad set of active RRHs
    \item $x_{i}$\qquad data symbol for $i$th user
    \item $w_{ij}\in\mathbb{C}^{k}$\quad Complex number set
  \end{itemize}
\end{frame}
\end{document}

在此处输入图片描述

答案1

你可以说我老派,但是我认为注释根本不应该居中(也可以不居中=,因为这个符号在数学上是错误的)。

公式应该突出,注释则不必。

\documentclass{beamer}
\usetheme{Madrid}

\logo{%
  \makebox[\dimexpr\textwidth+0.57cm]{%
    \includegraphics[width=1cm]{../duck}%
    \hfill
    \includegraphics[width=1cm]{../duck}%
  }%
}

\begin{document}

\begin{frame}
\frametitle{Delay equation}
\begin{exampleblock}{}
\centering
$\displaystyle
  d_{i} = \frac{1}{\mu_{i}- \lambda_{i}} + \frac{1}{c_{i} - \lambda_{i}}
$
\end{exampleblock}

\begin{itemize}
\item $d_{i}$\quad total delay
\item $\lambda_{i}$\quad arrival rate
\item $\mu_{i}$\quad service rate
\item $c_{i}$\quad transmission rate
\end{itemize}

\end{frame}

\end{document} 

(应该有更好的方法来了解主题放置徽标的位置,以便无需反复试验即可设置框宽度。)

在此处输入图片描述

答案2

如果将内容设置在宽度相同的框中,则可以实现对齐;使用eqparbox

在此处输入图片描述

\documentclass{beamer}

\usetheme{Madrid}

\usepackage{eqparbox,amsmath,xparse}

% https://tex.stackexchange.com/a/34412/5764
\makeatletter
\NewDocumentCommand{\eqmathbox}{o O{c} m}{%
  \IfValueTF{#1}
    {\def\eqmathbox@##1##2{\eqmakebox[#1][#2]{$##1##2$}}}
    {\def\eqmathbox@##1##2{\eqmakebox{$##1##2$}}}
  \mathpalette\eqmathbox@{#3}
}

\begin{document}

\begin{frame}
  \frametitle{Delay equation}
  \begin{exampleblock}{}
    \[
      \eqmathbox[LHS][r]{d_i} = 
        \eqmathbox[RHS][l]{\frac{1}{\mu_i - \lambda_i} + \frac{1}{c_i - \lambda_i}}
    \]
  \end{exampleblock}
  \centering
  $\eqmathbox[LHS][r]{d} = \eqmakebox[RHS][l]{total delay}$ \\
  $\eqmathbox[LHS][r]{\mu_i} = \eqmakebox[RHS][l]{service rate}$ \\
  $\eqmathbox[LHS][r]{\lambda_i} = \eqmakebox[RHS][l]{arrival rate}$ \\
  $\eqmathbox[LHS][r]{c_i} = \eqmakebox[RHS][l]{transmission rate}$
\end{frame}

\end{document}

您必须在第一次编译时编译两次(或对LHSRHS组件进行任何更改)。


如果您不关心的对齐问题exampleblock,您只需在里面设置项目描述即可align*

在此处输入图片描述

\documentclass{beamer}

\usetheme{Madrid}

\usepackage{amsmath}

\begin{document}

\begin{frame}
  \frametitle{Delay equation}
  \begin{exampleblock}{}
    \[
      d_i = \frac{1}{\mu_i - \lambda_i} + \frac{1}{c_i - \lambda_i}
    \]
  \end{exampleblock}

  \vspace{-\baselineskip}

  \begin{align*}
            d &= \text{total delay} \\
        \mu_i &= \text{service rate} \\
    \lambda_i &= \text{arrival rate} \\
          c_i &= \text{transmission rate}
  \end{align*}
\end{frame}

\end{document}

这种方法更加方便,具有更多的视觉吸引力空间。跨 对齐不会带来太多好处exampleblock

答案3

我还建议使用这个变体alignat*

\documentclass{beamer}
\usepackage{tikz}
\usepackage{amsmath, nccmath}
\usetheme{Madrid}
\logo{%
  %\includegraphics[width=1cm,height=1.5cm,keepaspectratio]{DUlogo}%
  \includegraphics[width=1.1cm,height=1.8cm,keepaspectratio]{bugs-bunny}
  \hspace{\dimexpr\paperwidth-2cm-5pt}%
  %\includegraphics[width=1cm,height=1cm,keepaspectratio]{GNR.png}%
  \includegraphics[width=1cm,height=1cm,keepaspectratio]{hare-blazon}
}

\begin{document}

\begin{frame}
  \frametitle{Delay equation}
  \begin{exampleblock}{}
    \[
      d_{i} = \frac{1}{\mu_{i}- \lambda_{i}} + \frac{1}{c_{i} - \lambda_{i}}
    \]
  \end{exampleblock}
\useshortskip
\begin{alignat*}{2}
 d_{i} & = \text{total delay} & \qquad \lambda_{i} & = \text{arrival rate} \\
 \mu_{i} & = \text{service rate} & c_{i} & = \text{transmission rate}
\end{alignat*}
\end{frame}

\end{document} 

在此处输入图片描述

相关内容