2

Consider the following MWE:

\documentclass[12pt,a4paper]{article}

\usepackage[fleqn]{amsmath}
\usepackage{amssymb}
\usepackage{amsthm}
\usepackage{enumitem}

\newcommand{\C}{\mathbb{C}}
\begin{document}

\begin{enumerate}[label=(\roman*)]
\itemsep -0.2em
\item \begin{equation*}
    e^z =  \sum_{n=0} z^n / n!
\end{equation*}
\item \begin{equation*}
    \sin z = \sum_{n=0} (-1)^n z^{2n+1}/ (2n+1)!
\end{equation*}
\item \begin{equation*}
    \cos z = \sum_{n=0} (-1)^n z^{2n}/ 2n! \\
    \text{which converges } \forall \ z \in \C 
\end{equation*}
\item \begin{equation*}
    \log_e (1 - z) = - \sum_{n=1} z^n/n
\end{equation*}
\item \begin{equation*}
    (1 - z)^{-1} = \sum_{n=0} z^n \\
    \text{which converges for } |z| < 1 
\end{equation*}
\end{enumerate}

\end{document}

How can I get the enumeration numbers (i, ii, etc) on the same line as the equations?

Img1

6
  • 1
    Why do you use equation* if you want the behavior of equation?
    – TeXnician
    Apr 21, 2017 at 17:32
  • I want the enumeration to do the labeling on the left, equation won't do that. Further, I don't want the equations labeled as such, but enumerated. Apr 21, 2017 at 17:43
  • 2
    It will do it! LaTeX is very flexible. Btw: If you use enumitem never mess with \itemsep manually.
    – TeXnician
    Apr 21, 2017 at 17:44
  • 1
    @AthenaWidget And now please admit that equation will do it :) Apr 21, 2017 at 17:51
  • 1
    potential duplicate: Vertical alignment of align* in enumerate Apr 21, 2017 at 18:02

3 Answers 3

6

I don't see anything in your questions, which couldn't be done using equation.

\documentclass[12pt,a4paper]{article}

\usepackage[fleqn]{amsmath}
\usepackage{amssymb}
\usepackage{amsthm}
\newcommand{\C}{\mathbb{C}}

\newcounter{dummy}

\makeatletter
\newcommand{\leqnomode}{\tagsleft@true}
\makeatother

\begin{document}

\begin{equation}
   normalequation
\end{equation}

\bgroup
    \leqnomode
    \setcounter{dummy}{\theequation}
    \renewcommand{\theequation}{\roman{equation}}%

    \begin{equation}
        e^z =  \sum_{n=0} z^n / n!
    \end{equation}
    \begin{equation}
        \sin z = \sum_{n=0} (-1)^n z^{2n+1}/ (2n+1)!
    \end{equation}
    \begin{equation}
        \cos z = \sum_{n=0} (-1)^n z^{2n}/ 2n! \\
        \text{which converges } \forall \ z \in \C 
    \end{equation}
    \begin{equation}
        \log_e (1 - z) = - \sum_{n=1} z^n/n
    \end{equation}
    \begin{equation}
        (1 - z)^{-1} = \sum_{n=0} z^n \\
        \text{which converges for } |z| < 1 
    \end{equation}

    \setcounter{equation}{\thedummy}
\egroup

\bgroup
    \leqnomode
    \setcounter{dummy}{\theequation}
    \renewcommand{\theequation}{\roman{equation}}%

    \begin{equation}
        e^z =  \sum_{n=0} z^n / n!
    \end{equation}
    \begin{equation}
        \sin z = \sum_{n=0} (-1)^n z^{2n+1}/ (2n+1)!
    \end{equation}
    \begin{equation}
        \cos z = \sum_{n=0} (-1)^n z^{2n}/ 2n! \\
        \text{which converges } \forall \ z \in \C 
    \end{equation}
    \begin{equation}
        \log_e (1 - z) = - \sum_{n=1} z^n/n
    \end{equation}
    \begin{equation}
        (1 - z)^{-1} = \sum_{n=0} z^n \\
        \text{which converges for } |z| < 1 
    \end{equation}

    \setcounter{equation}{\thedummy}
\egroup

\begin{equation}
   normal equation
\end{equation}

\end{document}

enter image description here


\leqnomode is borrowed from Tag placing with amsmath

3
  • Probably the spacing would be better with gather or align.
    – Bernard
    Apr 21, 2017 at 19:00
  • @Bernard Probably. Would you like to add an answer? Apr 21, 2017 at 19:24
  • 1
    No, I think I'll add a ‘real’ enumerate answer instead. You can update your answer if you wish. Perhaps you might add details on how to maintain the current equation counter.
    – Bernard
    Apr 21, 2017 at 19:28
3

A solution with the enumerate environment:

\documentclass[12pt, a4paper]{article}

\usepackage[fleqn]{mathtools}
\usepackage{amssymb}
\usepackage{amsthm}
\usepackage{enumitem}

\newcommand{\C}{\mathbb{C}}

\begin{document}

\begin{enumerate}[label=(\roman*), leftmargin=*, itemsep=0.4ex, before={\everymath{\displaystyle}}]%
  \item $ e^z = \sum_{n=0} z^n / n! $ \label{eq-1}
  \item $ \sin z = \sum_{n=0} (-1)^n z^{2n+1}/ (2n+1)! $\label{eq-2}
  \item $ \begin{aligned}[t]
        & \cos z = \sum_{n=0} (-1)^n z^{2n}/ 2n!\\
        & \text{which converges $ \forall \ z \in \C $} \label{eq-3}
  \end{aligned}
  $
  \item $ \log_e (1 - z) = - \sum_{n=1} z^n/n $ \label{eq-4}
  \item $\begin{aligned}[t] & (1 - z)^{-1} = \sum_{n=0} z^n ,\\
        &\text{which converges for $ |z| < 1 $} \end{aligned}$ \label{eq-5}
\end{enumerate}
 It is easy to prove eq. \ref{eq-3}. 

\end{document} 

enter image description here

2

A solution based on the TeXnician's comment.

\documentclass[12pt,a4paper]{article}

\usepackage[leqno, fleqn]{amsmath}
\usepackage{amssymb}
\usepackage{ mathtools }

\newcommand{\C}{\mathbb{C}}

\makeatletter
\newcommand{\leqnomode}{\tagsleft@true}
\newcommand{\reqnomode}{\tagsleft@false}
\makeatother

\newtagform{Alph}[\renewcommand{\theequation}{\Alph{equation}}]()
\newtagform{roman}[\renewcommand{\theequation}{\roman{equation}}]()
\newtagform{scroman}[\renewcommand{\theequation}{\scshape\roman{equation}}]
[]

\begin{document}

\usetagform{roman}
\begin{align}
   &e^z =  \sum_{n=0} z^n / n! \\
   &\sin z = \sum_{n=0} (-1)^n z^{2n+1}/ (2n+1)! \\
   &\cos z = \sum_{n=0} (-1)^n z^{2n}/ 2n! \text{   which converges } 
   \forall \ z \in \C  \\
   &\log_e (1 - z) = - \sum_{n=1} z^n/n \\
   &(1 - z)^{-1} = \sum_{n=0} z^n  \text{   which converges for } |z| < 1 
\end{align}

%\setcounter{equation}{0}
\end{document}

References:

Switch between leqno and reqno options (of amsmath) in the same document

How to change numbers to roman numerals in align environment

Equations

1
  • Something occurred to me, what if I wanted the equations enumerated and labeled. I think @samcarter has the better answer. Apr 24, 2017 at 15:05

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.