1

When one tries to display, for example, a large union using ‘bigcup’ one issue is that text above and below gets pushed up and down, respectively. The below image shows that it is possible to correct this. (The ‘big cup’ is clearly pushed upwards, somehow, and it looks like it fits into the writing almost perfectly, without having any substantial affect on the line spacing.) My question is: how can I produce a similar result as the below, also for products and the like? Do I have to increase the size of the line spacing? Thank you. enter image description here

\documentclass[class=book,crop=false,a4paper, 9pt, oneside, leqno]{standalone}
\usepackage[T1]{fontenc} 
\usepackage[utf8]{inputenc}        
\setlength{\baselineskip}{5in}

\usepackage[thmmarks, thref]{ntheorem} \usepackage{mathtools} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{yhmath} \begin{document} An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example $\bigcup\limits_{s\in \mathscr{S}}\mathrm{W}_s(\mathrm{D})$ An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example An example. \end{document}

Sandy G
  • 42,558
  • 3
    Welcome to TeX.SX. Please read the introductory material for this site. When you post a question, please provide a "Minimal Working Example" (MWE) that starts with \documentclass, includes all relevant \usepackage commands, ends with \end{document} and compiles without errors, even if it does not produce your desired output. – Sandy G Apr 23 '22 at 01:06
  • 1
    It looks like you're inputing the formula as $\mathrm{S}_i'=\bigcup\limits _{\mathclap{i\ne j}} \mathrm{S}_j$. Why? Why the \limits directive? Do give either $\mathrm{S}_i'=\bigcup_{i\ne j} \mathrm{S}_j$ or $\mathrm{S}_i'=\mathop{\cup}_{i\ne j} \mathrm{S}_j$ a try. – Mico Apr 23 '22 at 01:11
  • @Mico I want \limits. The issue is that \limits pushes the lines apart. But the picture I have given this does not happen. – Jackson Jacobson Apr 23 '22 at 01:12
  • 1
    you have shown no code. The whole reason that inline math is set in the compresssed \textstyle is to avoid the problem that you show that line spacing is affected. Presumably you are forcing \displaystyle or using \limits so explicitly forcing the "obnoxious" layout. The pictures you show don't show enough context to comment. – David Carlisle Apr 23 '22 at 01:18
  • 1
    Please edit the question to limit it to a specific problem with enough detail to identify an adequate answer. – Community Apr 23 '22 at 01:27
  • My apologies. I added a minimum working example. I am on my phone so I could not put it into the correct format. Thanks again. – Jackson Jacobson Apr 23 '22 at 01:32
  • My issue does not involve removing \limits, but ‘pushing’ the bigcup operator ‘upwards’. – Jackson Jacobson Apr 23 '22 at 01:33
  • 1
    @JacksonJacobson pushing it upwards is not advised since there may be superscripts sometimes. – M. Logic Apr 23 '22 at 04:19
  • 1

1 Answers1

3

The commands \limits and \nolimits are placed immediately after variable-sized operator symbols, such as those produced by \int, \sum and \bigcup. \limits instructs TeX to place the subscript and superscript terms of the operation (the lower and upper limits of integration in the case of \int) immediately below and above the operator symbol itself. In contrast, \nolimits instructs TeX to place the subscript and superscript terms to the lower right and upper right of the symbol, which conserves vertical space while consuming more horizontal space.

In mathematical typesetting, a very widely followed typographical convention is to generate the small variant of variable-size operator symbols and to employ \nolimits if TeX is in inline math mode. This convention helps assure that the spacing between lines in a paragraph can be fairly even if \sum, \int, and \bigcup instructions occur in a paragraph. Conversely, if TeX is in display math mode -- as is the case immediately after, say, \begin{equation} -- it is conventional to generate the large variants of the variable-sized operators and to employ \limits by default (except in the case of \int, \iint, and friends).

The defaults associated with typographical conventions can be overridden. Naturally, you override the defaults at your own peril. For more information on how one might override the defaults see, e.g., the posting Show inline math as if it were display math (and vice versa).

The upper half of the following screenshot consists of a single paragraph. The paragraph features a large and unsightly gap below the line that contains $\bigcup\limits_{s\in \mathscr{S}}...$. Importantly, no such gap occurs below the lines that contain either $\bigcup_{s\in \mathscr{S}}...$ or $\bigcup\nolimits_{s\in \mathscr{S}}...$. "Pushing the bigcup operator upwards," as you put it, in no way suffices to prevent the gap below that line -- unless one moved up the \bigcup symbol so much as to force a gap above the line.

In short: If you want to avoid creating unsightly gaps in a paragraph that contains \bigcup, do not use \limits.

enter image description here

\documentclass[class=book,crop=false,a4paper, 9pt, oneside, leqno]{standalone}
\usepackage[T1]{fontenc} 
\usepackage[utf8]{inputenc}        
\setlength{\baselineskip}{5in}

\usepackage[thmmarks, thref]{ntheorem} \usepackage{mathtools} \usepackage{amssymb} \usepackage{amsbsy} \usepackage{mathrsfs} \usepackage{yhmath} \begin{document} An example An example An example An example An example An example An example An example An example An example An example An example An example $\bigcup_{s\in \mathscr{S}}\mathrm{W}s(\mathrm{D})$ An example An example An example An example An example An example An example $\bigcup\limits{s\in \mathscr{S}}\mathrm{W}s(\mathrm{D})$ An example An example An example An example An example An example An example An example An example An example $\bigcup\nolimits{s\in \mathscr{S}}\mathrm{W}s(\mathrm{D})$ An example An example An example An example An example An example. [\bigcup{s\in \mathscr{S}}\mathrm{W}s(\mathrm{D})] and [\bigcup\limits{s\in \mathscr{S}}\mathrm{W}s(\mathrm{D})] and [\bigcup\nolimits{s\in \mathscr{S}}\mathrm{W}_s(\mathrm{D})] \end{document}

Mico
  • 506,678
M. Logic
  • 4,214
  • The first paragraph isn't formulated well, as you appear to be mixing the meanings of the TeX terms \displaystyle and \textstyle (which govern the size of "large operators" such as \sum, \prod, and \bigcup) on the one hand with those of the more general terms "display style" (not "offline", please) and "inline style" on the other. The terms aren't synonyms. For instance, bla bla bla $\displaystyle\sum$ bla bla bla renders the sum symbol in inline math mode, i.e., in the same paragraph as the material that immediately precedes and follows it, not in display style math mode. – Mico Apr 23 '22 at 05:06
  • @Mico I improved the statements. – M. Logic Apr 23 '22 at 05:13
  • I've taken the liberty of editing your explanations. Feel free to revert. – Mico Apr 23 '22 at 06:11
  • 1
    @Mico Thanks very much! – M. Logic Apr 23 '22 at 06:14