To have two limits in double integral?

You are probably expecting iterated integral, not double integral. Hence

\documentclass{article}

\begin{document} 

\newcommand{\Int}{\int\limits}

\begin{equation}
\Int_{-\infty}^{+\infty} \Int_{-\infty}^{+\infty}f(x,y) \,dx\,dy
\end{equation}

\end{document}

enter image description here


The multiple integral macros by amsmath only support lower limits on multiple integrals.

You can get around this by using a specialized font for integrals, like the one provided by esint.

\documentclass{article}
\usepackage{amsmath}
\usepackage{esint}

\makeatletter
%% make esint definition in line with amsmath
\@for\next:={int,iint,iiint,iiiint,dotsint,oint,oiint,sqint,sqiint,
  ointctrclockwise,ointclockwise,varointclockwise,varointctrclockwise,
  fint,varoiint,landupint,landdownint}\do{%
    \expandafter\edef\csname\next\endcsname{%
      \noexpand\DOTSI
      \expandafter\noexpand\csname\next op\endcsname
      \noexpand\ilimits@
    }%
  }
\makeatother

\begin{document}

\begin{equation*}
 \iint \limits_{-\infty}^{+\infty}
\end{equation*}

\end{document}

enter image description here


Here comes a possible solution

\documentclass{article}
\usepackage{amsmath}

\makeatletter
\newlength\tmp@\newlength\t@mp
\newcommand{\comp}[3]
  {\mathop{ \settowidth\tmp@{$\displaystyle\mathop{#1}^{#3}_{#2}$}
  \hbox to \tmp@{\hss \settowidth\t@mp{$\displaystyle #1$}\setlength\t@mp{.45\t@mp}
  $\displaystyle\mathop{#1}^{\hspace\t@mp #3}_{\hspace{-\t@mp}#2}$
  \hss} }}
\makeatother

\begin{document}
\[
\begin{aligned}
  &\comp{\int}{A}{B}+\int\\
  &\intop_A^B+\intop\\
  &\intop+\intop\\
  &\comp{\int}{AAA}{BBB}+\int\\
  &\intop_{AAA}^{BBB}+\int\\
  &\comp{\int}{AAAAAAAAA}{BBBBBBBBB}+\int\\
  &\intop_{AAAAAAAAA}^{BBBBBBBBB}+\int\\
\end{aligned}
%
\begin{aligned}
  &\comp{\int}{A}{B}\intop_{A}^{B}\\
  &\comp{\int}{AAA}{\rule{1cm}{10cm}}\intop_{AAA}^{\rule{1cm}{10cm}}\\
  &\comp{\int}{AAAAAAAAA}{BBBBBBBBB}\intop_{AAAAAAAAA}^{BBBBBBBBB}\\
%
  &\comp{\iint}{A}{B}\iint\limits_{A}^{B}\iint\\
  &\comp{\iint}{AAA}{BBB}\quad\iint\limits_{AAA}^{BBB}\iint
  \comp{\iint}{-\infty}{+\infty}\\
  &\comp{\iint}{AAAAAAAAA}{BBBBBBBBB}\quad\iint\limits_{AAAAAAAAA}^{BBBBBBBBB}\iint\\
%
\end{aligned}
\]
\end{document}

enter image description here enter image description hereenter image description here

Tags:

Math Mode