2

I have to use iopart document class. One of major problems which I came across is aligning multiple equations. For example, for reach

\begin{align}
  a & = b \label{eq1} \\
    c & = d \label{eq2}
\end{align}

we must use either amsmath package or other ones. Unfortunately, iopart does not coincide with it. In this situation how can I align my equations that have gotten me to stack?

  • 1
    Could you please provide a complete (compilable) minimal example? – CarLaTeX Jun 29 at 7:27
  • 4
    Then try with older format, \begin{eqnarray}...\end{eqnarray} – MadyYuvi Jun 29 at 7:30
6

You can use \usepackage{IEEEtrantools} to align multiple equations without to use amsmath package.

enter image description here

\documentclass[a4paper,12pt]{article}
\usepackage{IEEEtrantools}
\begin{document}
\begin{IEEEeqnarray}{lCr}
 a & = b \label{eq1} \\
c & = d \label{eq2}
\end{IEEEeqnarray}
\end{document}
  • 1
    Can you help me to understand that the difference between general eqnarray and IEEEeqnarray? – MadyYuvi Jul 1 at 7:11
  • @MadyYuvi Hi. Your question is correct and I'll give you the correct explanations. If you go to pag. 8, you can read that The eqnarray-environment, however, has a few very severe disadvantages:; The spaces around the equality signs are too big. Particularly, they are not the same as in the multline-and equation-environments; The expression sometimes overlaps with the equation number even though there would be enough room on the left, etc.I suggest the tutorial guide. – Sebastiano Jul 1 at 19:24
  • 1
    Thanks a lot... – MadyYuvi Jul 2 at 4:29
4

You can use the package witharrows which provides an environment DispWithArrows which has by default exactly the same behaviour as the environment align of amsmath.

\documentclass{iopart}
\usepackage{witharrows}
\begin{document}
\begin{DispWithArrows}
  a & = b \label{eq1} \\
    c & = d \label{eq2}
\end{DispWithArrows}
\end{document}

Compilation of the code above

With DispWithArrows, you have the ability to add arrows on the right for explanations (hence the name):

\documentclass{iopart}
\usepackage{witharrows}
\begin{document}
\begin{DispWithArrows}
  a & = b \Arrow{explanation} \label{eq1} \\
    c & = d \label{eq2}
\end{DispWithArrows}
\end{document}

Compilation of the code above

2

With mathenv (good old) package which significantly improve eqnarray environment (package is based on mdwtab's table handling macros).

\documentclass[a4paper,12pt]{article}
\usepackage{mathenv}

\begin{document}
    \begin{eqnarray}[rl]
a   & = b \label{eq1} \\
c   & = d \label{eq2}
    \end{eqnarray}
\end{document}

enter image description here

  • My compliments for using an old but efficient package :-) – Sebastiano Jul 3 at 21:38

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.