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.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I would like to know if it is possible to force the equation to be closer to the operation sum? When there are a lot of subscript under the sum operator, it tends to pouch the equation to the right, and this is not very aesthetic.

\sum_{n\in N_{-i}}\sum_{\substack{j \in N_{-i} \\ j \neq n}}v_j
share|improve this question
up vote 14 down vote accepted

The first part of following code shows the problem you mentioned and the "standard" possible solutions for a single sum: using a \makebox or using \mathclap (from the mathtools package).

Next I present your concrete example and several variations; now, only using \mathclap makes things worst since the subscripts overlap; using \mathclap and adding some space between the sums could be an option, but I think the best solution would be the last one in which the amount of symbols used in the subscripts has been reduced:




No special treatment (ugly):
\sum_{1\leq i < j < k \leq n}a_{ijk}

Using a \verb!\makebox!:
\sum_{\makebox[0pt]{$\scriptstyle 1\leq i < j < k \leq n$}}a_{ijk}

Using \verb!\mathclap! (requires the \texttt{mathtools} package):
\sum_{\mathclap{1\leq i < j < k \leq n}}a_{ijk}

Your concrete example (ugly): 
\sum_{n \in N_{-i}}\sum_{\substack{j \in N_{-i} \\ j \neq n}}v_j

Your concrete example using \verb!\mathclap! (uglier since scripts overlap):
\sum_{n \in N_{-i}}\sum_{\mathclap{\substack{j \in N_{-i} \\ j \neq n}}}v_j

Your concrete example using \verb!\mathclap! and some space between the sums (a little better?):
\sum_{n \in N_{-i}}\mkern13mu\sum_{\mathclap{\substack{j \in N_{-i} \\ j \neq n}}}v_j

Your concrete example reformulated (better, when possible):
\sum_{n}\sum_{ j \neq n}v_j,
where $n$ and $j$ run over $N_{-i}$.


output of code example

share|improve this answer
I wish it was that simple, sadely the notation \in N_{-i} is necessary in order to differenciate from n \in N – Bibi541 Aug 18 '12 at 1:22
Thank you very much for your help, though. It was very well written and detailed. I will remember those function if I ever encounter this problem. sadely, it seem that for this particular one, there isnt one. – Bibi541 Aug 18 '12 at 1:23
Actually, by applying it to my non-double sum terms, I was able to gain enough space, which was my initial problem and rose the question. So this was indeed useful :) – Bibi541 Aug 18 '12 at 1:31

Your Answer


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.