LaTeX forum ⇒ Math & ScienceWhat is the nicest fraction package ?

Information and discussion about LaTeX's math and science related features (e.g. formulas, graphs).
User avatar
Cham
Posts: 894
Joined: Sat Apr 02, 2011 4:06 pm

What is the nicest fraction package ?

Postby Cham » Tue Jun 05, 2018 6:01 pm

I'm looking for the nicest way (I know it's subjective!) to display small fractions inside a larger fraction. I know about the nicefrac and xfrac packages :
  1. \documentclass{article}
  2. \usepackage[nice]{nicefrac}
  3. \usepackage{amsmath}
  4. \usepackage{xfrac}
  5.  
  6. \begin{document}
  7. Blablabla
  8. \begin{equation}
  9. (4 / 9)(5 / v) = (\nicefrac{4}{9})(\nicefrac{5}{v}) = \frac{2/3}{1/5} = \frac{\nicefrac{2}{3}}{\nicefrac{1}{5}}.
  10. \end{equation}
  11. Ou encore
  12. \begin{equation}
  13. (4 / 9)(5 / v) = (\sfrac{4}{9})(\sfrac{5}{v}) = \frac{2/3}{1/5} = \frac{\sfrac{2}{3}}{\sfrac{1}{5}}.
  14. \end{equation}
  15. \end{document}

Preview :
fractions.jpg
fractions.jpg (8.35 KiB) Viewed 273 times


I think that the first term is acceptable (could it be better looking?). The second term is too small. The third term is clumsy. The fourth term appears okay, but could it be better looking?

What would you do in this case ? And which package is best : xfrac or nicefrac ?

User avatar
Stefan Kottwitz
Site Admin
Posts: 9019
Joined: Mon Mar 10, 2008 9:44 pm

Postby Stefan Kottwitz » Tue Jun 05, 2018 6:48 pm

Hi Cham,

it depends on taste and your point of view. Just choose the look you like more.

The xfrac package is newer than nicefrac and better maintained, I think. From CTAN: "The pack­age pro­vides a high qual­ity al­ter­na­tive to the fa­cil­i­ties of the nicefrac­ package."

Stefan
Site admin


Return to “Math & Science”

Who is online

Users browsing this forum: No registered users and 3 guests