The original picture can be reproduced by
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\[
\frac{(-1)^{\varphi(n)/2}n^{\varphi(n)}}
{\prod_{p\mid n} p^{\varphi(n)/(p-1)}}
\]
\end{document}

whereas using \Pi instead of \prod would give

which is sensibly different.
If the condition is desired to be under the product sign, the correct answer is
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\[
\frac{(-1)^{\varphi(n)/2}\,n^{\varphi(n)}}
{\prod\limits_{p\mid n} p^{\varphi(n)/(p-1)}}
\]
\end{document}
(note the thin space in the numerator and in the exponent at the denominator).

Using \displaystyle would give a much worse output, with a too big product sign
\documentclass{article}
\usepackage{amsmath}
\begin{document}
\[
\frac{(-1)^{\varphi(n)/2}\,n^{\varphi(n)}}
{\displaystyle\prod_{p\mid n} p^{\varphi(n)/(p-1)}}
\]
\end{document}

\limitsor\displaystyle. but really, you should show us what you have already tried, in the form of a "minimum working example", starting with\documentclassand ending with `\end{document}. – barbara beeton Apr 04 '15 at 12:48\displaystyleto the denominator does not fix the problem. – Apr 04 '15 at 13:36