Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

In some case limits and nolimits need to be used together, e.g. an expression \prod\nolimits^{B}\limits_{x \in X}, in which B is in the right-upper corner and x \in X under the \prod, is not displayed it should be, B is displayed above the \prod, not in the right-upper corner. How to resolve this?

share|improve this question

2 Answers 2

up vote 8 down vote accepted

The amsmath package provides \sideset:

\documentclass{article}
\usepackage{amsmath}
\begin{document}

\[
\sideset{}{^{B}}\prod_{x \in X}A_{x}
\]

\end{document}

enter image description here

You may want to define your own command:

\newcommand{\prodB}{\sideset{}{^{B}}\prod}
share|improve this answer
    
Well, it works too. Thank you. –  Popopo Apr 1 '13 at 2:55

enter image description here

\documentclass{article}
\usepackage{mathtools}
\begin{document}

\[
{\prod_{\mathclap{x \in X}}}^{B}
\]
\end{document}
share|improve this answer
    
Thank you, it works. –  Popopo Mar 31 '13 at 17:13
    
Using \mathclap may give undesirable spacing when the subscript is large. –  Aditya Mar 31 '13 at 18:58
    
@Aditya true (it hides the size of the subscript) although if you don't do anything it pushes B to the right if the subscript is wider than the base. sideset as in egregs answer is another possibility. –  David Carlisle Mar 31 '13 at 19:51
1  
You can use \smashoperator{\prod_{x \in X}} instead of that mathclap. –  Manuel Mar 31 '13 at 19:57

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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