# Pre subscript versus tensor

What is the best way to typeset \sqcup with two subscripts left/right.

For sure, 1st and 2nd are wrong. But they help us to see the baseline for the indexes.

The 3rd and 4th look equal except by the space around. Also, they insert the index too low (I think).

The 5th produces almost the same but change the baseline for indexes. However it gives me an error (since \sqcup is not an operator).

Limit controls must follow a math operator. $A \sideset{_f}{_g}{\sqcup} MWE \documentclass[a5paper]{report} \usepackage{mathtools} \usepackage{tensor} \begin{document}$A_g  \sqcup_f BA{}_g\sqcup_f BA\prescript{}{g}{\sqcup}_fBA\tensor[_g]{\sqcup}{_f}B$%$A\sideset{_g}{_f}{\sqcup} B$\end{document}  • As explained in amsmath documentation, \sideset is meant for big operators. Feb 10 '15 at 22:39 • @egreg, OK. I just inserted to show the good positioning of indexes. Its spacing looks better than the others. Feb 10 '15 at 22:41 ## 1 Answer You should define the symbol as \mathbin: \documentclass{article} \newcommand{\dsqcup}[2]{% #1 presubscript, #2 postsubscript \mathbin{_{#1}\sqcup_{#2}}% } \begin{document}$A\dsqcup{f}{f}BA\dsqcup{g}{f}B\$

\end{document}


• Very nice solution. Feb 10 '15 at 22:46
• Is \sqcup a mathbin char? If yes, it inserts space before/after it, isn't? In this case, are the spaces between the indexes and \sqcup the right ones? Feb 10 '15 at 22:49
• @Sigur Yes, it is: \DeclareMathSymbol{\sqcup}{\mathbin}{symbols}{"74} Feb 10 '15 at 22:50