Code: Select all
\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}
{t=0}
and {n}
exists on the side of the Sum symbol instead of on direct top and bottom of the sum symbol. How do I get it right?
Code: Select all
\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}
{t=0}
and {n}
exists on the side of the Sum symbol instead of on direct top and bottom of the sum symbol. NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
\limits
to change that:Code: Select all
\sum\limits_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}
Code: Select all
\documentclass[10pt,a4paper]{article}
\usepackage{amsmath}
\begin{document}
\centering
$\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$
\[\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}\]
$\displaystyle\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$
$\sum\limits_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$
\end{document}
\sum
to use the limits above and below.\limits
after the \sum
operator but before the limits.\displaystyle
before the \sum
operator.Code: Select all
$$\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$$
Code: Select all
$\displaystyle\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$
$...$
is for math within text, and $$...$$
is for displayed math, i.e. centered and within its own paragraph.Never usefinancialwar wrote:Code: Select all
$$\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$$
$$ … $$
for unnumbered displayed equations. Use \[ … \]
instead.What do you mean by "unnumbered displayed equation"?localghost wrote:Never usefinancialwar wrote:Code: Select all
$$\sum_{t=0}^{n}\dfrac{CF_t}{(1+r)^t}$$
$$ … $$
for unnumbered displayed equations. Use\[ … \]
instead.
$$ … $$
is the same as \[ … \]
. You know the difference between in-line and displayed equations? The latter ones can be automatically numbered by according environments (financialwar wrote:What do you mean by "unnumbered displayed equation"? […]
equation
, align
, …).
Both produce unnumbered displayed formulas. The first is TeX syntax, the latter is LaTeX syntax and thus preferable. Furthermore the TeX syntax causes some unwanted side effects. The below example demonstrates one of them.financialwar wrote:I thought$$ … $$
is the same as\[ … \]
. […]
Code: Select all
% TeX program = pdflatex
\documentclass[11pt,fleqn]{article}
\usepackage[T1]{fontenc}
\begin{document}
\[ E=mc^2 \]
$$ E=mc^2 $$
\end{document}
fleqn
(force left equations) option for the document class. For details see l2tabu.
Our topic »LaTeX Resources for Beginners« and the excellent »Math mode« document (which I already mentioned earlier).financialwar wrote:[…] Is there a good latex book for absolute beginner?
I wrote the LaTeX Beginner's Guide, available in print and as ebook, also in Kindle format. There's free information available on the internet, but not always up to date, and if you prefer to tackle it hands on with a step-by-step guide, this book may help you.financialwar wrote:Is there a good latex book for absolute beginner?
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p