GeneralHow can I get \frac to accept Greek letters?

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
auntmooshka
Posts: 2
Joined: Wed Mar 12, 2008 2:17 am

How can I get \frac to accept Greek letters?

Post by auntmooshka »

I am using Texmaker and trying to write fractions with Greek letters in the numerator.
I've tried variations of \frac{$\pi$}{2} without any success, while \frac seems happy to accept numbers and/English letters.

Any advice would be greatly appreciated by this newbie. :)

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

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

gmedina
Posts: 2313
Joined: Wed Jul 11, 2007 11:45 pm

How can I get \frac to accept Greek letters?

Post by gmedina »

Code: Select all

\documentclass{article}
\usepackage{amsmath}

\begin{document}
text text $\frac{\pi}{2}$ text text text text $\dfrac{\pi}{2}$ text text text text text text
\[
  \frac{\pi}{2}
\]
text text text text 
\begin{equation}
  \frac{\pi}{2}
\end{equation}

\end{document}
The lshort and l2tabu documents can be useful and also the user guide of the amsmath package .
1,1,2,3,5,8,13,21,34,55,89,144,233,...
auntmooshka
Posts: 2
Joined: Wed Mar 12, 2008 2:17 am

Re: How can I get \frac to accept Greek letters?

Post by auntmooshka »

My sincerest thanks!
Post Reply