3

Writing

\begin{enumerate}
\item $$math1$$
\item $$math2$$
\end{enumerate}

the math is not set exactly beside the numeration, but a bit lower instead. If I use

\begin{enumerate}
\item \begin{center}$math1$\end{center}
\item \begin{center}$math2$\end{center}
\end{enumerate}

instead, the the numeration is also centered and I don't want this. How can I set centered math beside the numeration? enter image description here

4

You could surround the inline math expressions with \hfil and \hfill directives.

enter image description here

\documentclass{article}
\begin{document}
\hrule  % just to illustrate width of textblock
\begin{enumerate}
\item \hfil$a^2+b^2=c^2$\hfill
\item \hfil$1+1=2$\hfill
\end{enumerate}
\end{document}

Remark: If you need the math expressions to be typeset in displaymath-style rather than in inline-math style, simply insert the instruction \displaystyle after the opening $ symbol.

0

If you want it to be display math, you could do the following. Note that this will centre the equation in the free space between the numbers and the right border. This will appear a bit more to the right than normal equations.

% arara: pdflatex

\documentclass{article}
\usepackage{mathtools}
\newenvironment{itemequation}{\hfill$\begin{aligned}[t]}{\end{aligned}$\hfill\null}

\begin{document}
    \begin{equation*}
    \text{math0}
    \end{equation*} 
\begin{enumerate}
    \item \begin{itemequation}\text{math2}\end{itemequation}
    \item \begin{itemequation}\text{math2}\end{itemequation}
\end{enumerate}
\end{document}

Off-topic: You should not use $$\dots$$ in LaTeX. This is plain TeX.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.