Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm learning math mode and having an issue here with the prime symbol.


In this inline math formula, the prime symbol is supposed to be superscript, but it shows up at the regular text level and size.

share|improve this question
If you provide a fuller example showing which files and packages you're loading, we could help you better –  A.Ellett Feb 3 '13 at 0:51
Informative (and a little bit related): What is the advantage of using $f^\prime$ instead of $f'$? –  Qrrbrbirlbel Feb 3 '13 at 1:01

2 Answers 2

up vote 34 down vote accepted

It is not clear what you want the output to be


the \prime is in the superscript along with d. If you want the prime to be on d then just use


which is equivalent to

share|improve this answer
Thank you. I needed the extra explanation as well as the answer. I'm not up to speed on this language. –  Nathan Feb 3 '13 at 0:54
+1 for noting apostrophe (') is, in math mode, the same as ^{\prime} –  Alex Nelson Feb 3 '13 at 16:11

\prime is by default on the same level as normal text. (Just as \circ - used as symbol for degrees for example.) Instead you need to specify that \prime is a superscript:


EDIT: This might be marginal to the question, but I think it's a useful addition. The ' is a shorthand for ^\prime. Thus, if you type in LaTeX:


the output will be:

double superscript

As you can see, LaTeX interprets it as a double superscript. Now suppose you don't want that, but instead something like:

no double superscript

If you try to do it by typing: $y\in[0,1]^{d^{\circ}'}$, you'll summon up an error:

! Double superscript.
<recently read> ^
l.4 $y\in[0,1]^{d^{\circ}'

To avoid this, \prime comes handy. Just do: $y\in[0,1]^{d^{\circ\prime}}$ and everything will be fine. :)

share|improve this answer

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.