# Fraction of a Fraction order of operation: $\pi/2/\pi^2$

I think I'm having a bit of a senior moment or something... I was evaluating $\pi/2/\pi^2$. My instinct was that the answer would be $\frac{\pi^3}2$ from $\frac{\pi}1 * \frac{\pi^2}2$ but I checked wolfram and got $\frac{1}{2\pi}$.

I'm pretty sure I understand how wolfram evaluated and got that result, but now I have the questions: which is correct, and why?

Symbolab gave me the answer I first assumed: $\frac{\pi^3}2$ with the same input as wolfram and I'm pretty sure they can't both be correct.

The links to the equations I've used are:

https://www.symbolab.com/solver/step-by-step/%5Cfrac%7Bpi%7D%7B%5Cfrac%7B2%7D%7Bpi%5E%7B2%7D%7D%7D

https://www.wolframalpha.com/input/?i=pi%2F2%2Fpi%5E2

The question I was trying to solve when I came across this was $\int_{1/2}^1 x \cos(\pi x) dx$

edit: Thanks for the replies so far, I think what I'm trying to get a feel for is how to know around which terms I should use brackets when I see this type of fraction.

• Moral lesson: when in doubt, use parentheses. – J. M. is a poor mathematician Dec 28 '16 at 16:05
• $/$ is not an associative operation. $$\frac{\pi}{\frac{2}{\pi^2}}=\frac{\pi^3}{2}\neq \frac{1}{2\pi} =\frac{\frac{\pi}{2}}{\pi^2}.$$ – Jack D'Aurizio Dec 28 '16 at 16:44

These are two distinct inputs. $\pi / 2 / \pi^2$ (wolfram input) is interpreted as $\frac{\frac{\pi}{2}}{\pi^2} = \frac{\pi}{2 \pi^2}$ because of the left-to-right order of performing operations, while if you introduce parentheses as in $(\pi) / (2 / (\pi^2))$ (symbolab input) it's interpreted as $\frac{\pi}{\frac{2}{\pi^2}} = \frac{\pi^3}{2}$, which is why you get two different results.
• Without the brackets THE correct way to interpret it is following the left-to-right rule (i.e., how Wolfram got it). There is no alternative approach here. You can alter the expression and hence the result by the use of parentheses which may be correct depending on the circumstances but that's up to you to decide whether there should be parentheses and where or not. All in all $\pi / 2 / \pi^2$ is just equal to $\frac{1}{2 \pi}$. – Hirek Kubica Dec 28 '16 at 18:16
Wolfram and all computer languages I know will evaluate $a/b/c$ from left to right, giving $a/b/c=(a/b)/c=a/(bc)$ This is a good reason to use parentheses in this expression to make sure you get what you want.