3

I want to typeset the integral

$$ \int{\dfrac{1}{\cos^2\left(5 - \dfrac{3x}{4}\right)}}\,\mathrm{d}x$$

I tried

\documentclass[12pt,a4paper]{article}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\begin{document}
$$ \int{\dfrac{1}{\cos^2\left(5 - \dfrac{3x}{4}\right)}}\,\mathrm{d}x$$
\end{document}

and I get

enter image description here

The integration symbol not high enough. How to typeset this integral?

  • 1
    The \int glyph is not scalable. And it shouldn’t be scaled really. But for what it’s worth: making a big summation sign – Qrrbrbirlbel Nov 24 '13 at 13:08
  • 3
    Never use $$ in LaTeX. – egreg Nov 24 '13 at 13:24
  • For more on creating large integral symbols, see Big integral sign. However, in the present context I would definitely not advocate inserting a large integral symbol -- it's much better here to use \frac (twice) instead of \dfrac. – Mico Nov 24 '13 at 13:38
6

Option 1

\documentclass[preview,border=12pt,varwidth]{standalone}% change it back to your own document class
\usepackage{amsmath}

\begin{document}
\abovedisplayskip=0pt\relax% remove this line in  your production
\[
\int \frac{1}{\cos^2\left(5 - \frac{3x}{4}\right)}\,\mathrm{d}x
\]
\end{document}

enter image description here

Option 2

\documentclass[preview,border=12pt,varwidth]{standalone}% change it back to your own document class
\usepackage{amsmath}

\begin{document}
\abovedisplayskip=0pt\relax% remove this line in  your production
\[
\int \frac{1}{\cos^2\left(5 - \frac{3}{4}x\right)}\,\mathrm{d}x
\]
\end{document}

enter image description here

Option 3

Prof. Enrico likes this style I think.

\documentclass[preview,border=12pt,varwidth]{standalone}% change it back to your own document class
\usepackage{amsmath}

\begin{document}
\abovedisplayskip=0pt\relax% remove this line in  your production
\[
\int \frac{1}{\cos^2(5 - 3x/4)}\,\mathrm{d}x
\]
\end{document}

enter image description here

Option 4

By Thorsten Donig's comment below.

\documentclass[preview,border=12pt,varwidth]{standalone}% change it back to your own document class
\usepackage{amsmath,xfrac}

\begin{document}
\abovedisplayskip=0pt\relax% remove this line in  your production
\[
\int \frac{1}{\cos^2 (5 - \sfrac{3x}{4})}\,\mathrm{d}x
\]
\end{document}

enter image description here

Option ∞

Based on Qrrbrbirlbel's and Egreg's comments below.

\documentclass[preview,border=12pt]{standalone}% change it back to your own document class
\usepackage{amsmath,xfrac}

\begin{document}
\abovedisplayskip=0pt\relax% remove this line in  your production
\begin{gather*}
\int \sec^2\left(5 - \tfrac{3x}{4}\right)\,\mathrm{d}x \\
\int \sec^2\left(5 - \tfrac 3 4 x\right)\,\mathrm{d}x \\
\int \sec^2(5 - 3x/4)\,\mathrm{d}x \\
\int \sec^2\left(5 - \sfrac{3x}{4}\right)\,\mathrm{d}x 
\end{gather*}
\end{document}

enter image description here

  • Personally, I prefer the 2nd option. By the way, is \left/\right really needed here? – Manuel Nov 24 '13 at 13:03
  • The space between cos and opening parenthesis looks too big in versions 1 and 2 (due to the use of \left and \right I think)... – clemens Nov 24 '13 at 13:03
  • Mathematically, \cos^{-2} is also possible, avoiding the fraction altogether. – Qrrbrbirlbel Nov 24 '13 at 13:06
  • A fourth option would be to typeset the fraction by \sfrac from »xfrac«. – Thorsten Donig Nov 24 '13 at 13:12
  • 1
    @Qrrbrbirlbel Unfortunately there's somebody who writes \cos^{-1} to mean the arccosine, so \cos^{-2} would be difficult to interpret. – egreg Nov 24 '13 at 13:23

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.