Text Formatting ⇒ Diagonal fractions
-
- Posts: 2
- Joined: Wed Oct 06, 2010 3:28 pm
Diagonal fractions
I'm trying to write a fraction commonly used for distance and weight, e.g. 3/8". However I can't find a way on LaTeX to write it with the 3 in the top left and 8 on the bottom right, so it'd look a bit like:
3/
/8
as you'd see on say a measure of weight for your weighing scale as opposed to the traditional fraction of one vertically above the other (\frac{}{}) or the solidus with letter horizontally next to each other (3 / 8)
Does anyone know how to do this?
John
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
Diagonal fractions
perhaps \nicefrac is what you are looking for:
Code: Select all
\documentclass{article}
\usepackage{units}
\begin{document}
\nicefrac{3}{8}
\end{document}
-
- Posts: 2
- Joined: Wed Oct 06, 2010 3:28 pm
Re: Diagonal fractions
- localghost
- Site Moderator
- Posts: 9202
- Joined: Fri Feb 02, 2007 12:06 pm
Diagonal fractions
Best regards and welcome to the board
Thorsten
Board Rules
Avoidable Mistakes
¹ System: TeX Live 2025 (vanilla), TeXworks 0.6.10