I want to control the width of the equations so they don't exceed a predefined width. Firstly I used minipage
environment and put the eqnarray
within that. This does not produce the line breaks before and after the equations. I manually use line break, then there would be extra space between text and equations. Is there any other way to set an specific width for an equation without affecting the line breaks? I specifically want to use eqnarray
and not any other environments like align
for typesetting equations.
\documentclass[]{article}
\newenvironment{myenv}{ \begin{minipage}{5cm}\begin{eqnarray}
}{\end{eqnarray}\end{minipage} }
\begin{document}
dummy text here
\begin{myenv}
a &= s^3-s
\\
b &=s^2+s
\end{myenv}
dummy text here
\end{document}
with added line breaks:
\newenvironment{myenv}{\\ \begin{minipage}{5cm}\begin{eqnarray}
}{\end{eqnarray}\end{minipage} \\}
Best Answer