4

I am using beamer for making slides. In one of my slides, equations appear in bullets. I would like the equations to be aligned. Since these appear in different bullets, I can't use the align option.

Here is my MWE

\documentclass{beamer}

\begin{document}
\begin{frame}
\frametitle{\color{blue}{Observations}}
\begin{itemize} 
    \item 1. This bullet has 3 sub-bullets
        \begin{itemize}
            \item Only Text
            \item Text and Equation1 
               \begin{equation}
               f^{r}(\cdot): \{0,1\}\rightarrow\mathbb{Q^r}
               \end{equation}
            \item Text and Equation2 
               \begin{equation}
                f^{c}(\cdot): \mathbb{Q^r}\rightarrow\mathbb{Q^c}
               \end{equation}
        \end{itemize} 
     \end{itemize}    
\end{frame}
\end{document}
NAASI
  • 2,809

1 Answers1

5

It's not a general fix because it allows only one align point (I chose to align around the : character, was that the desired point?), and the horizontal centering will be impacted, but if you\mathllap and \mathrlap the two portions around the align point, then you might get something satisfactory. (I also added \medskip to restore some of the lost vertical spacing)

If needed, leftward shift of such equations can be achieved by adding a fixed space after the \mathrlap{}.

\documentclass{beamer}
\usepackage{mathtools}
\begin{document}
\begin{frame}
\frametitle{\color{blue}{Observations}}
\begin{itemize} 
    \item 1. This bullet has 3 sub-bullets
        \begin{itemize}
            \item Only Text
            \item Text and Equation1 \medskip
               \begin{equation}
               \mathllap{f^{r}(\cdot):{}}\mathrlap{ \{0,1\}\rightarrow\mathbb{Q^r}}
               \end{equation}
            \item Text and Equation2 \medskip
               \begin{equation}
                \mathllap{f^{c}(\cdot):{}}\mathrlap{ \mathbb{Q^r}\rightarrow\mathbb{Q^c}}
               \end{equation}
        \end{itemize} 
     \end{itemize}    
\end{frame}
\end{document}

enter image description here