2

I am using algorithm2e package, but I want to remove Algorithm 1 in the figure and just say the name in my case as just appear only "The procedure". How we can do that?

\begin{algorithm}
\DontPrintSemicolon
a=1\;
b=2\;
c=2\;
\caption{The procedure}
\label{algo:sj2}
\end{algorithm}

enter image description here

3

I found the anaswer by my self thanks all. by adding \NoCaptionOfAlgo we can remove the name Algorithm1.

\begin{algorithm}
\DontPrintSemicolon
a=1\;
b=2\;
c=2\;
\NoCaptionOfAlgo
\caption{The procedure}
\label{algo:sj2}
\end{algorithm}

enter image description here

0

Use \SetAlCapSty{} to reset the default \textbf styling:

\documentclass{article}

\usepackage[ruled,linesnumbered]{algorithm2e}
\SetAlCapSty{}

\begin{document}

\begin{algorithm}
    \DontPrintSemicolon

    a=1\;
    b=2\;
    c=2\;

    \caption{The procedure} \label{algo:sj2}
\end{algorithm}

\end{document}

enter image description here

From the documentation:

\SetAlCapSty{<commandname>}: sets the command that will be used by \AlCapSty to defines tyle of Algorithm #: in caption. The argument is a name of a command (without \). This command have to take one argument, the text to be formatted. Default is set to: \SetAlCapSty{textbf}.

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.