1

I am using algorithm2e and I wrote a Procedure and an Algorithm. I want to call the procedure in the algorithm. All I have to reference the procedure is its \label{proc:myproc}.

\begin{procedure}
\DontPrintSemicolon
\tcc*[l]{Procedure}
 \SetAlgoLined
 \KwIn{Input}
 \KwOut{Output}
Initial step 1\;
Initial step 2\;
    \ForEach{}{
    \ForEach{}{
    \tcc*[l]{Do this}\;
    }
    }
%
\caption{Compute this()} \label{proc:myproc}
\end{procedure}

So I can do this in the algorithm: \ref{proc:myproc}. But this referencing gives me the plain text Compute this. Is there another kind of referencing that I am missing?

Thanks in advance!

  • 1
    Which kind of reference are you looking for? If you want to call the procedure, isn't it the name of the procedure that you want to use? – gernot May 3 '17 at 15:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.