项目符号与公式不对齐

项目符号与公式不对齐

我想将项目符号与公式对齐,但由于某种原因,公式在项目符号下方呈现一条线。这是我的代码

\begin{itemize} 
       \item[\textcolor{blue}{\textbullet}]
         \begin{equation*}%blue
             (w^{\dagger_1})^{\dagger_0} = (\overline{x}+\overline{y}\varepsilon)^{\dagger_0} = \overline{x}+\overline{y}\varepsilon = (x+y\varepsilon)^{\dagger_1} = (w^{\dagger_0})^{\dagger_1} = w^{\dagger_1}
        \end{equation*}
         
         \item[\textcolor{red}{\textbullet}]
         \begin{equation*}%red
             (w^{\dagger_2})^{\dagger_0} = (x-y\varepsilon)^{\dagger_0} = x-y\varepsilon = (x+y\varepsilon)^{\dagger_2} = (w^{\dagger_0})^{\dagger_2} = w^{\dagger_2}
        \end{equation*}
\end{itemize}

这是图片 输出

这是所需的输出 在此处输入图片描述

答案1

您需要使用内联数学模式而不是显示数学模式。

另一件事:我也会使用\bar{x}而不是\overline{x}

在此处输入图片描述

\documentclass{article} 
\usepackage{xcolor,amsmath}
\begin{document}
\begin{itemize} 
\item[\textcolor{blue}{\textbullet}] \quad
       $(w^{\dagger_1})^{\dagger_0} 
       = (\bar{x}+\bar{y}\varepsilon)^{\dagger_0} 
       = \bar{x}+\bar{y}\varepsilon 
       = (x+y\varepsilon)^{\dagger_1} 
       = (w^{\dagger_0})^{\dagger_1} = w^{\dagger_1}$
         
\item[\textcolor{red}{\textbullet}] \quad
       $(w^{\dagger_2})^{\dagger_0} 
       = (x-y\varepsilon)^{\dagger_0} 
       = x-y\varepsilon 
       = (x+y\varepsilon)^{\dagger_2} 
       = (w^{\dagger_0})^{\dagger_2} = w^{\dagger_2}$
\end{itemize}
\end{document}

答案2

我相信您更喜欢使用gather\tag

\documentclass{article}
\usepackage[leqno]{amsmath}
\usepackage{xcolor}

\begin{document}

These are tagged equations, with some more text to emulate
some real text, which this isn't
\begin{gather}
\tag*{\textcolor{blue}{\textbullet}}
(w^{\dagger_1})^{\dagger_0}
= (\overline{x}+\overline{y}\varepsilon)^{\dagger_0} 
= \overline{x}+\overline{y}\varepsilon 
= (x+y\varepsilon)^{\dagger_1}
= (w^{\dagger_0})^{\dagger_1} = w^{\dagger_1}
\\
\tag*{\textcolor{red}{\textbullet}}
(w^{\dagger_2})^{\dagger_0}
= (x-y\varepsilon)^{\dagger_0}
= x-y\varepsilon
= (x+y\varepsilon)^{\dagger_2}
= (w^{\dagger_0})^{\dagger_2}
= w^{\dagger_2}
\end{gather}
These are standard equations, with some more text to emulate
some real text, which this isn't
\begin{equation}
1+1=2
\end{equation}
These are standard equations, with some more text to emulate
some real text, which this isn't

\end{document}

在此处输入图片描述

相关内容