Can you help me to rename the title of \listofalgorithms (which is 'List of Algorithms') to another text? I don't know how to do that.
2 Answers
Update \listalgorithmcfname:
\documentclass{article}
\usepackage{algorithm2e}
\renewcommand{\listalgorithmcfname}{List of Algorithmus}
\begin{document}
\listofalgorithms
\begin{algorithm}
\caption{An algorithm.}
\end{algorithm}
\end{document}
-
What if I want to list it in contents as section rather than chapter?lRadha– lRadha2025-01-06 08:07:36 +00:00Commented Jan 6 at 8:07
-
@lRadha: Are you using a class that contains
\chapters? Then it should default to setting the LoA as a chapter.2025-01-06 17:08:05 +00:00Commented Jan 6 at 17:08 -
Thanks @Werner, but I found the solution: \usepackage[section]{tocbibind}lRadha– lRadha2025-01-08 02:41:53 +00:00Commented Jan 8 at 2:41
Another option is to use the provided command \SetAlgorithmName, which takes 3 arguments: the new name of algorithms, the name to be used with \autoref, and the name to be used in the list of algorithms.
\documentclass{article}
\usepackage{algorithm2e}
\SetAlgorithmName{Algorithmus}{Al.}{List of Algorithmi}
\begin{document}
\listofalgorithms
\begin{algorithm}
\caption{An algorithm.}
\end{algorithm}
\end{document}
