87

I am wondering how to make a fraction in LaTeX small enough to fit on a line, or at least just a little larger. I could have sworn I had seen this before but I just cannot find it.

In particular, I would like to use it in an equation environment, and have it maintain this size.

I am sure there is a simple solution, but I cannot find it.

1 Answer 1

109

If you want the numerator on top of the denumerator, and have it appear smaller, the way it typically does in inline math mode as opposed to displayed math style, then use \tfrac{x}{y} (requires amsmath or similar package). If you want a diagonal-style fraction, then check out the xfrac package (with sfrac command).

enter image description here

\documentclass{article}
\usepackage{amsmath}
\usepackage{xfrac}

\begin{document}
Equation:

    frac: \[\frac{x}{y}\]
    
    tfrac: \[\tfrac{x}{y}\]
    
    sfrac: \[\sfrac{x}{y}\]
    
Inline math:

    frac: $\frac{x}{y}$

    tfrac: $\tfrac{x}{y}$

    sfrac: $\sfrac{x}{y}$
\end{document}
3
  • thank you, this was the solution I have used in the past, I just couldn't seem to find it in my old source code. Thank you so much for saving me the time of searching.
    – BBischof
    Commented Oct 7, 2010 at 22:27
  • 1
    Note that tfrac seems to be similar to classical frac in "inline" math mode.
    – zetyty
    Commented May 15, 2023 at 10:16
  • 1
    Note that sfrac is quite "easy" to customize: \sfrac[⟨instance⟩]{⟨num⟩}[⟨sep⟩]{⟨denom⟩} (see documentation on CTAN).
    – zetyty
    Commented May 15, 2023 at 10:22

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .