LaTeX forum ⇒ Document Classes! LaTeX Error: Command \algorithm* already defined.

Information and discussion about specific document classes and how to create your own document classes.
gumel81
Posts: 1
Joined: Tue Sep 17, 2013 2:46 pm

! LaTeX Error: Command \algorithm* already defined.

Postby gumel81 » Tue Sep 17, 2013 2:50 pm

Hello,


currently I’m working on a scientific paper. The publisher provided me with a template (see http://www.worldscientific.com/page/ijc ... -readme-2e). Here is a minimal example:

  1. documentclass{ws-ijcis}
  2. \begin{document}
  3. Test
  4. \end{document}


Now I would like to include the package algorithm2e. The code looks like this:

  1. \documentclass{ws-ijcis}
  2. \usepackage{algorithm2e}
  3. \begin{document}
  4. Test
  5. \end{document}


Unfortunately, I receive an error:

  1. ! LaTeX Error: Command \algorithm* already defined.
  2. Or name \end... illegal, see p.192 of the manual.
  3. See the LaTeX manual or LaTeX Companion for explanation.


How can I solve this issue? Unfortunately I cannot use another package (I have to use algorithm2e)

Thanks for your help.

Tags:

User avatar
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm

Postby localghost » Tue Sep 17, 2013 7:02 pm

Just for information to other users for awareness of possibly already existing solutions. The question has also been posted to MrUnix and goLaTeX (two German LaTeX forums) and already got an answer. Please read what our administrator thinks about that.

Board Rules wrote:A crossposting is always contra-productive. But there is nothing really against it as long as it is mentioned. This means that a direct link has to be added. So other users who want to help are preserved from double efforts and waste of time.


The class defines a theorem-like environment algorithm. Contact the class maintainer(s) and ask for help. There is detailed contact information on the mentioned site for the case of upcoming problems.
LaTeX Community Moderator
How to make a "Minimal Example"
Board Rules
Avoidable Mistakes


¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

david611
Posts: 1
Joined: Thu May 03, 2018 8:30 pm

Postby david611 » Thu May 03, 2018 8:38 pm

I have exactly the same problem. I managed to undefine the algorithm environment as follows:

\makeatletter
\let\algorithm\@undefined
\let\endalgorithm\@undefined
\makeatother

but when I tried the same thing for algorithm* :

\makeatletter
\let\algorithm\@undefined
\let\endalgorithm\@undefined
\let\algorithm*\@undefined
\let\endalgorithm*\@undefined
\makeatother

I got the LaTex error:

Undefined control sequence.
1.6 \let\algorithm*\@undefined

Can anyone tell me how to undefine the algorithm* environment?

User avatar
Johannes_B
Site Moderator
Posts: 3953
Joined: Thu Nov 01, 2012 4:08 pm

Postby Johannes_B » Fri May 04, 2018 6:04 am

Hi and welcome,

please open a new thread. A minimal working example would also be needed in order to help.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.


Return to “Document Classes”

Who is online

Users browsing this forum: No registered users and 3 guests