[Tex/LaTex] Making integral ∫ use \limits by default with unicode-math

math-operatorssymbolsunicode-math

How can I make the unicode integral symbol ∫ act as if it is followed by \limits? Classically \usepackage[intlimits]{amsmath} would do. But with unicode-math this does not help anymore. I also tried:

\documentclass{article}
\usepackage{unicode-math}
\setmathfont{XITS Math}

\usepackage{newunicodechar}
\newunicodechar{∫}{∫\limits}

\begin{document}
    \[ ∫_a^b f(x) dx \]
\end{document}

But that seems to lead to an infinite recursion

! TeX capacity exceeded, sorry [input stack size=5000].

Best Answer

You can use the macros \removenolimits and \addnolimits to change the limits for specified operators.

\documentclass{article}
\usepackage{unicode-math}
\setmathfont{XITS Math}

\let\limU\removenolimits  %limit position up
\let\limR\addnolimits     %limit position right

\begin{document}
Example
    \[ ∫_a^b f(x) dx \]
\limU{\int}
    \[ ∫_a^b f(x) dx \]
\limR{\int}
    \[ ∫_a^b f(x) dx \]
\end{document}

You'll have to swicht with \limU/R for each operator you want to change the limits position. (Tested with LuaLaTeX)

Related Question