I need to typset a series of fractions with no line inside some paragraphs of text (they were used as proportional symbols). It is very simple, actually:
$^2_1$, $^4_2$,$^8_4$
But when it comes to $^{12}_{6}$, the two numbers are not aligned vertically.
If I use a fraction $\frac{12}{6}$ the alignment is good, but the horizontal line shouldn't be there.
Any suggestions?
Thank you, A
\documentclass{article}
\begin{document}
I need this $^{12}_{6}$ aligned vertically like this $\frac{12}{6}$.
\end{document}
Following all answers, I have to say all of them work fine, but they do not produce a result which is identical to $^{12}_{6}$. The problem arises when you have more than one instance in the same context, and I believe the $^{12}_{6}$ spacing is the optimal one. See the picture:
\documentclass{article}
\newcommand{\myfrac}% % macro with LaTeX-style syntax
[2]{\begin{array}{@{}c@{}}\scriptstyle #1 \\[-1.2ex]\scriptstyle #2\end{array}}
\begin{document}
\noindent Myfrac plus smash as by the example by Harish and Harold compared with optimal vertical spacing: $^{1}_{2}$, \smash{$\myfrac{22}{6}$}, $^{4}_{2}$, $^{2}_{1}$; can you see the difference? My proofreader will kill me, my proofreader will kill me, my proofreader will kill me :-).
\end{document}










\documentclass{...}and ending with\end{document}. You might also want to add to your question how you're including the pdfs etc. – Aradnix Sep 05 '14 at 05:09