MHB Finding \sum_{n=0}^{N-1} Cos (nx)

  • Thread starter Thread starter ognik
  • Start date Start date
  • Tags Tags
    Cos
Click For Summary
The discussion revolves around the calculation of the sum \( \sum_{n=0}^{N-1} \cos(nx) \) using the complex exponential form. The book suggests using the formula \( \sum_{n=0}^{N-1} (e^{ix})^n = \frac{1-e^{iNx}}{1-e^{ix}} \) and then extracting the real part. A participant expresses confusion over the application of the geometric series formula, particularly regarding the index and the terms involved when summing from \( n=0 \) to \( N-1 \). The conversation emphasizes the importance of correctly interpreting the series and the relationship between the complex exponential and trigonometric functions to derive the correct result. Clarifying the manipulation of indices and terms is crucial for resolving the misunderstanding.
ognik
Messages
626
Reaction score
2
Hi - going in circles about a step in an example, to find $ \sum_{n=0}^{N-1} Cos (nx) $

The book says we find $$ \sum_{n=0}^{N-1} \left( e^{ix} \right)^n = \frac{1-e^{iNx}}{1-e^{ix}}$$ , then take the real part.

But I see $ \sum_{n=0}^{N-1} \left( e^{ix} \right)^n $ as a geometric series with a=1, $ r= e^{ix}$ and n=N-1 and $$S_n = \frac{1-r^n}{1-r} = \frac{1-e^{i(N-1)x}}{1-e^{ix}}$$

If I take the sum from n=1 to N I still don't get their result, 'cos then the 1st term would be $e^{ix}$ instead of 1

What am I missing with that N-1 slight of hand please?
 
Physics news on Phys.org
Try $n = N$, the formula for a geometric partial sum is:

$S_n = \sum\limits_{k=0}^{n-1} ar^k$

there's no "index sleight-of-hand".
 
Hi - I know that if I just use n=N it works, but the series is only summed to N-1? This would add an extra term...
 
ognik said:
Hi - going in circles about a step in an example, to find $ \sum_{n=0}^{N-1} Cos (nx) $

The book says we find $$ \sum_{n=0}^{N-1} \left( e^{ix} \right)^n = \frac{1-e^{iNx}}{1-e^{ix}}$$ , then take the real part.

But I see $ \sum_{n=0}^{N-1} \left( e^{ix} \right)^n $ as a geometric series with a=1, $ r= e^{ix}$ and n=N-1 and $$S_n = \frac{1-r^n}{1-r} = \frac{1-e^{i(N-1)x}}{1-e^{ix}}$$

If I take the sum from n=1 to N I still don't get their result, 'cos then the 1st term would be $e^{ix}$ instead of 1

What am I missing with that N-1 slight of hand please?

Remember that $\displaystyle \begin{align*} \mathrm{e}^{\mathrm{i}\,n\,\theta} \equiv \cos{ \left( n\,\theta \right) } + \mathrm{i} \sin{ \left( n\,\theta \right) } \end{align*}$, so that means

$\displaystyle \begin{align*} \sum_{n = 0}^{N - 1}{ \left( \mathrm{e}^{\mathrm{i}\,x} \right) ^n } &= \sum_{n = 0}^{N-1}{ \left[ \cos{ \left( n\,x \right) } + \mathrm{i}\sin{ \left( n\,x \right) } \right] } \\ \frac{1 - \left( \mathrm{e}^{i\,x} \right) ^N }{ 1 - \mathrm{e}^{\mathrm{i}\,x} } &= \sum_{n = 0}^{N-1}{ \cos{ \left( n \,x \right) }} + \mathrm{i} \sum_{n = 0}^{\infty}{ \sin{ \left( n \,x \right) } } \\ \frac{1 - \left[ \cos{ \left( N \,x \right) } + \mathrm{i}\sin{ \left( N\,x \right) } \right] }{1 - \left[ \cos{(x)} + \mathrm{i}\sin{(x)} \right] } &= \sum_{n = 0}^{N-1}{ \cos{ \left( n\,x \right) } } + \mathrm{i} \sum_{n = 0}^{\infty}{ \sin{ \left( n\,x \right) } } \\ \frac{\left[ 1 - \cos{( \left( N\,x \right) } - \mathrm{i}\sin{ \left( N \, x \right) } \right] \left[ 1 - \cos{(x)} + \mathrm{i}\sin{(x)} \right]}{\left[ 1 - \cos{(x)} \right] ^2 + \left[ \sin{(x)} \right] ^2} &= \sum_{n = 0}^{N-1}{ \cos{ \left( n\,x \right) } } + \mathrm{i} \sum_{n = 0}^{\infty}{ \sin{ \left( n\,x \right) } } \end{align*}$

Cleaning up the left hand side so that you can read off its real and imaginary parts will enable you to answer the question.
 
Thread 'Problem with calculating projections of curl using rotation of contour'
Hello! I tried to calculate projections of curl using rotation of coordinate system but I encountered with following problem. Given: ##rot_xA=\frac{\partial A_z}{\partial y}-\frac{\partial A_y}{\partial z}=0## ##rot_yA=\frac{\partial A_x}{\partial z}-\frac{\partial A_z}{\partial x}=1## ##rot_zA=\frac{\partial A_y}{\partial x}-\frac{\partial A_x}{\partial y}=0## I rotated ##yz##-plane of this coordinate system by an angle ##45## degrees about ##x##-axis and used rotation matrix to...

Similar threads

  • · Replies 2 ·
Replies
2
Views
3K
  • · Replies 3 ·
Replies
3
Views
3K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 5 ·
Replies
5
Views
3K
  • · Replies 5 ·
Replies
5
Views
467
  • · Replies 3 ·
Replies
3
Views
2K
  • · Replies 6 ·
Replies
6
Views
3K
  • · Replies 5 ·
Replies
5
Views
2K
  • · Replies 9 ·
Replies
9
Views
1K
  • · Replies 2 ·
Replies
2
Views
3K