5

I've been struggling with this task for some time now. Basically I want to make this:

enter image description here

Into something like this:

enter image description here

I've tried \mathlarger from relsize package, but it simply didn't work (no effect at all). If it interests anyone, this is the equation code:

\begin{equation}
f_1(x) = min \bigg\{ \sum_{m=1}^{M} \sum_{i=I_{sm}}^{I{em}-N_m} \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \bigg\}
\end{equation}

Thank you!!

  • Possible duplicate: How are big operators defined? – Werner Jun 7 '16 at 19:09
  • 6
    Why would you turn a nice output into a monster? – egreg Jun 7 '16 at 19:43
  • My plan is to keep the three summation symbols at the same size, but bigger than the one outputed by tex. I believe the equation would be better visualized like that. Can you explain further why you think it will become a monster? Is there any reason besides personal aesthetics preferences? – user1050181 Jun 7 '16 at 19:47
  • At least the non-italicised 'min' is an improvement... – Andreas Rejbrand Jun 7 '16 at 23:57
9

You can use Steven B. Segletes’ scalerel package and do something like the following:

% My standard header for TeX.SX answers:
\documentclass[a4paper]{article} % To avoid confusion, let us explicitly 
                                 % declare the paper format.

\usepackage[T1]{fontenc}         % Not always necessary, but recommended.
% End of standard header.  What follows pertains to the problem at hand.

\usepackage{scalerel}
\newcommand*{\biggsum}{\mathop{\stretchrel*{\sum}{\bigg(}}\limits}



\begin{document}

Text before
\begin{equation}
    f_1(x) = \min \bigg\{ \biggsum_{m=1}^{M} \biggsum_{i=I_{sm}}^{I{em}-N_m}
        \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \bigg\}
\end{equation}
Text after.

\end{document}

I’m not accepting any responsibility for the (very poor) typographical quality of the output! (:-) Indeed, what you get is

Output of the above code

that is, something I would never ever use in a paper of mine; but it is, nonetheless, close to what you asked for.


Addition

The OP has made clear that (s)he had not the (pretty devious ;-) intent of stretching out the summation symbol, as the posted image suggested, but rather to scale it up. As explained in the comments, this is achieved by simply replacing the \stretchrel command with \scalerel:

% My standard header for TeX.SX answers:
\documentclass[a4paper]{article} % To avoid confusion, let us explicitly 
                                 % declare the paper format.

\usepackage[T1]{fontenc}         % Not always necessary, but recommended.
% End of standard header.  What follows pertains to the problem at hand.

\usepackage{scalerel}
\newcommand*{\biggsum}{\mathop{\scalerel*{\sum}{\bigg(}}\limits}



\begin{document}

Text before.  Note that, this time, I'm using 
\verb|\left\{|\,\ldots\verb|\right\}|.
\begin{equation}
    f_1(x) = \min \left\{ \biggsum_{m=1}^{M} \biggsum_{i=I_{sm}}^{I{em}-N_m}
        \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \right\}
\end{equation}
Text after.

Another possibility is to use \verb|\Biggl\{|\,\ldots\verb|\Biggr\}| (which 
looks better, IMHO\@).
\begin{equation}
    f_1(x) = \min \Biggl\{ \biggsum_{m=1}^{M} \biggsum_{i=I_{sm}}^{I{em}-N_m}
        \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \Biggr\}
\end{equation}
Text after.

\end{document}

And here’s the new output:

Output of the second code sample


Second Addition

Actually, there is another, and, I believe, much simpler possibility, that requires nothing more than the amsfonts package (which is automatically loaded when you use the amsmath package). The following code illustrates it:

% My standard header for TeX.SX answers:
\documentclass[a4paper]{article} % To avoid confusion, let us explicitly 
                                 % declare the paper format.

\usepackage[T1]{fontenc}         % Not always necessary, but recommended.
% End of standard header.  What follows pertains to the problem at hand.

\usepackage{amsfonts}

\makeatletter

\newcommand*\@MyHelperSum[1]{%
    \mathop{\hbox{#1$\m@th\displaystyle\sum$}}\limits
}
% Here is a whole series of larger and larger summation symbols:
\newcommand*\largesum{\@MyHelperSum\large}
\newcommand*\Largesum{\@MyHelperSum\Large}
\newcommand*\LARGEsum{\@MyHelperSum\LARGE}
\newcommand*\hugesum {\@MyHelperSum\huge }
\newcommand*\Hugesum {\@MyHelperSum\Huge }

\makeatother



\begin{document}

Text before.  Note that, this time, I'm using 
\verb|\left\{|\,\ldots\verb|\right\}|.
\begin{equation}
    f_1(x) = \min \left\{ \Largesum_{m=1}^{M} \Largesum_{i=I_{sm}}^{I{em}-N_m}
        \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \right\}
\end{equation}
Text after.

Another possibility is to use \verb|\Biggl\{|\,\ldots\verb|\Biggr\}| (which 
looks better, IMHO\@).
\begin{equation}
    f_1(x) = \min \Biggl\{ \Largesum_{m=1}^{M} \Largesum_{i=I_{sm}}^{I{em}-N_m}
        \bigg(\sum_{n=i}^{i +(N_m-1)} P_m[n-i]T_sC[n]\bigg)u_{mi} \Biggr\}
\end{equation}
Text after.

\end{document}

The output is

Output of the third code sample

You might want to try other sizes, too, e.g., \LARGEsum.

Note the following:

  1. The amsfonts package is required because, without it, the cmex10 font would be loaded at fixed size; indeed, the omxcmex.fd file contains the lines

    \DeclareFontFamily{OMX}{cmex}{}
    \DeclareFontShape{OMX}{cmex}{m}{n}{%
       <->sfixed*cmex10%
       }{}
    

    whereas amsfonts.sty has

    \DeclareFontShape{OMX}{cmex}{m}{n}{%
           <-7.5>cmex7%
        <7.5-8.5>cmex8%
        <8.5-9.5>cmex9%
        <9.5->cmex10%
    }{}%
    

    (what makes the difference, here, is the line that says <9.5->cmex10, the other three are relevant for smaller sizes).

  2. This approach makes direct use of fonts that should be available on all sites at the required size, without needing any special help from the rendering device (or typesetting engine) to magnify the glyphs; it should work correctly even with bitmapped fonts, like those that were used decades ago (provided, of course, that the standard sizes are properly installed, as already said). So, it ensures maximum portability.

  3. On the other hand, if outline fonts are being used (as it is ordinarily the case since at least fifteen years ago), this solution will end up asking the rendering device to scale up the summation symbol contained in the cmex10 font, exactly as it happens when the scalerel package is used.

  4. This solution works only if you want to magnify the symbol without distorting it: that’s why I didn’t think of it in the first place.

  5. Drawback: this solution is of course inadequate if you are already typesetting in, say, \Huge size. (;-)


Third Addition

Just to wrap this discussion up, I’d finally like to remark that the OP’s original idea of using the relsize package and its \mathlarger command—which is a perfectly viable solution too—didn’t succeed precisely for the same reason hinted at above: in order for it to work, one should also load the amsfonts package. Indeed, the documentation of the relsize package explicitly warn users about this fact (actually, it mentions the exscale package, which provides similar functionality).

  • Perhaps consider changing your \biggsum to \mathop{\biggsum}\limits. That is, \newcommand*{\biggsum}{\mathop{\stretchrel*{\sum}{\bigg(}}\limits} – Steven B. Segletes Jun 7 '16 at 19:32
  • @StevenB.Segletes: Of course, you are quite right! In the hurry, I overlooked this essential detail. Thank you. – GuM Jun 7 '16 at 19:36
  • I would then also resort to \left\{ syntax in lieu of the leading \bigg\{ – Steven B. Segletes Jun 7 '16 at 19:39
  • 1
    You might also consider aspect-ratio limiting the stretch, with something like \newcommand*{\biggsum}{\mathop{\stretchrel*[90]{\sum}{\bigg(}}\limits}. – Steven B. Segletes Jun 7 '16 at 19:49
  • 1
    @user1050181 There is also a \scalerel in addition to a \stretchrel. The former preserves aspect ratio, though it provides a width limiter as an optional argument. – Steven B. Segletes Jun 7 '16 at 19:50
7

The mtpro2 package offers the \xl, \XL, and \XXL modifiers that can be prefixed to "large" math operators such as \sum, \prod, and \int to create increasingly larger symbols. (Well, there's also the \XXXL modifier, which produces operator symbols that are 5 centimeters [!] tall, but let's not go there.)

Note that the full mtpro2 package isn't free of charge. However, its "lite" subset, which is all that's needed for this case, is free.

The following screenshot shows the normal displaymath-style size for \sum as well as \xl\sum, \XL\sum, and \XXL\sum for the two outer \sum symbols. The innermost \sum is not modified on purpose. I'm pretty sure that rows 3 and 4 will qualify as being "monstrous" in @egreg's classification system.

enter image description here

\usepackage{newtxtext,amsmath}
\usepackage[lite]{mtpro2}
\begin{document}

\begin{align*}
f_1(x) &= \min \biggl\{\, \sum_{m=1}^{M} \sum_{i=I_{sm}}^{I_{em}-N_m} 
          \biggl(\,\sum_{n=i}^{i +N_m-1} P_m[n-i]T_sC[n]\biggr)u_{mi} \biggr\}\\
f_1(x) &= \min \Biggl\{ \xl\sum_{m=1}^{M} \xl\sum_{i=I_{sm}}^{I_{em}-N_m} 
          \biggl(\,\sum_{n=i}^{i +N_m-1} P_m[n-i]T_sC[n]\biggr)u_{mi} \Biggr\}\\
f_1(x) &= \min \LEFTRIGHT\{\}{ \XL\sum_{m=1}^{M} \XL\sum_{i=I_{sm}}^{I_{em}-N_m} 
          \biggl(\,\sum_{n=i}^{i +N_m-1} P_m[n-i]T_sC[n]\biggr)u_{mi}}\\
f_1(x) &= \min \LEFTRIGHT\{\}{ \XXL\sum_{m=1}^{M} \XXL\sum_{i=I_{sm}}^{I_{em}-N_m} 
          \biggl(\,\sum_{n=i}^{i +N_m-1} P_m[n-i]T_sC[n]\biggr)u_{mi}}
\end{align*}

\end{document}
  • Your answer seems to solve all my problems. But to install a package in MikTek using windows is very troublesome (if the package is not listed in the package manager). So it will take some time for me to test this. I'll comment again when I do. Thanks! – user1050181 Jun 7 '16 at 20:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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