4

I get the following error message when compiling for a journal article:

Runaway argument?
\relax \ifmmode \@badmath \else \bgroup \let \eqnnum \relax \let \refstepeqcnt 
\ETC.
! Paragraph ended before \@tempa was complete.
<to be read again> 
               \par 
l.435 \newenvironment{proof}[1][\proofname]{\par

See the sample code below. The same file with exactly the same packages works properly with any other class (e.g. article).

\documentclass{ws-ijcis}
\usepackage{amsthm}
\usepackage{algorithm}
\usepackage{algorithmic}
\usepackage{fullpage}
\usepackage{graphicx}
\usepackage{amsmath}
\usepackage{subfig}
\begin{document}
dfdfd
\end{document}

The journal class file can be found here.

  • The AMS packages are not compatible with the class. Neither is the caption package, so you should say \usepackage[caption=false]{subfig}. Why the class doesn't want to be compatible with amsmath is a mystery. – egreg Mar 11 '14 at 12:21
4

The ws-ijcis is not compatible with amsmath; it defines its own equation* environment. It's not compatible with amsthm either, because it defines a proof environment.

The weird error is due to the fact that you don't load amsmath prior to amsthm, so following a branch in a conditional where a wrong assumption is made on \[ (which is again redefined by the class).

A workaround could be

\documentclass{ws-ijcis}

\expandafter\let\csname equation*\endcsname\relax
\expandafter\let\csname endequation*\endcsname\relax
\let\proof\relax
\let\endproof\relax

\usepackage{amsmath}
\usepackage{amsthm}
\usepackage{algorithm}
\usepackage{algorithmic}
\usepackage{fullpage}
\usepackage{graphicx}
\usepackage[caption=false]{subfig} % also caption is incompatible
\begin{document}
dfdfd
\end{document}

but I guess the journal copy editors will not be happy with it. Looking at the class you're supposed to use equation or equation* for one line equations and eqnarray or eqnarray* for multiline displays (the environment is redefined too).

  • 1
    my paper has few algorithms as well. ws-ijcis has algorithm environment defined but i am getting no idea on how to use it. – user961708 Mar 11 '14 at 18:29
  • @user961708 I don't think there should be problems about that. – egreg Mar 11 '14 at 18:37

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.