TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to format names of algorithms just as they appear inside the algorithmic environment. For an example, see the title "An unsuccessful attempt: Flip-and-Match" of this paper. So far I've been using \Call{MyFunc}{}, but guts tell me this is not the right thing to do, and more importantly, it doesn't work if I want to use it in section titles. What is the proper command to use for such cases?

share|improve this question
I couldn't see anything that resembled an algorithm in the work you cite. I think we could help better if you gave us a minimum complete document that illustrates your problem, plus a description or picture shewing what's wrong with it. – Brent.Longborough Mar 16 '12 at 17:23
Perhaps you are looking for a way to use small caps in the argument of a sectional unit? If this is so, you can use something like \section{An unsuccessful attempt: {\normalfont\scshape Flip-and-Match}} – Gonzalo Medina Mar 16 '12 at 17:45
up vote 2 down vote accepted

Define a macro for your specially formatted names: for example


will produce the result you want when called as

\section{An unsuccessful attempt: \algoname{Flip-and-Match}}
Let us warm up by considering the mechanism \algoname{Flip-and-Match} proposed ...
share|improve this answer
Thank you, that was exactly what I was looking for. – blubb Mar 19 '12 at 10:12

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.