Complex integration is giving the wrong answer by a factor of two

In summary: The OP was somewhat sloppy in changing the function of interest by dropping a factor of ## 1/2 i ##, ( using it to cancel the ## 2i ## of ##2 \pi i ##). In any case, he uses a derivative formula to isolate the term of interest in the series, (the coefficient ## b ## of the ## \frac{b}{z } ## term), and when he did, he miscalculated the coefficient, so the term he got was wrong, and this gave the wrong final answer. He got a term of ## 1 ## instead of ## 2 ##, because he miscalculated a derivative, and this gave the wrong value for the residue.
  • #1
LCSphysicist
646
162
Homework Statement
.
Relevant Equations
.
$$\int_{0}^{2\pi } (1+2cost)^{n}cos(nt) dt$$

$$e^{it} = z, izdt = dz$$

$$\oint (1+e^{it}+e^{-it})^{n}\frac{e^{nit}+e^{-nit}}{2} \frac{dz}{iz} = \oint (1+z+z^{-1})^{n}\frac{z^{n}+z^{-n}}{2} \frac{dz}{iz}$$

$$\oint (z+z^{2}+1)^{n}\frac{z^{2n}+1}{z^{2n+1}} \frac{dz}{2i} = \pi Res = \pi \frac{d^{2n}}{(2n)! dz^{2n}}((z+z^{2}+1)^{n}(z^{2n}+1))$$

$$= \pi \sum \begin{pmatrix}
2n\\ \beta
\end{pmatrix} \frac{d^{\beta} {(z^{2n}+1)}}{dz^{\beta}(2n)!} \frac{d^{2n-\beta}}{dz^{2n-\beta}}(z+z^{2}+1)^{n}$$

Since the pole is at z=0, all terms above vanish apart from ##\beta = 2n##, in this case:

$$= \pi \frac{d^{2n} {(z^{2n}+1)}}{(2n)!dz^{2n}} \frac{d^{0}}{dz^{0}}(z+z^{2}+1)^{n} $$
$$= \pi \frac{(2n)!}{(2n)!} (1) = \pi $$

The answer provided by the book is ##2 \pi##

I can't really find the error i supposedly did :/
 
Physics news on Phys.org
  • #2
Take a look at the integral and integrand to figure out the residue term without the cumbersome derivatives: You are just interested in ## z^{2n} ##, (in the numerator), and you have ## z^{2n}+1 ##, multiplied by ##(z^2+z+1)^n ##. For the ## (z^2+z+1)^n ##, you need the ## z^{2n} ## and the ## 1 ##, (the end terms on either side in the expansion). None of the other terms in the expansion will give a ## z^{2n} ## term when multiplied by ## z^{2n}+1 ##. When multiplied through and summed, it is clear that you get ## 2 z^{2n} ## as the term in the numerator that will give you the residue term, i.e. ## \frac{b}{z} ##, where ## b=2 ##.
 
Last edited:
  • Like
Likes LCSphysicist
  • #3
Charles Link said:
Take a look at the integral and integrand to figure out the residue term without the cumbersome derivatives: You are just interested in ## z^{2n} ##, (in the numerator), and you have ## z^{2n}+1 ##, multiplied by ##(z^2+z+1)^n ##. For the ## (z^2+z+1)^n ##, you need the ## z^{2n} ## and the ## 1 ##, (the end terms on either side in the expansion). None of the other terms in the expansion will give a ## z^{2n} ## term when multiplied by ## z^{2n}+1 ##. When multiplied through and summed, it is clear that you get ## 2 z^{2n} ## as the term in the numerator that will give you the residue term, i.e. ## \frac{b}{z} ##, where ## b=2 ##.
I can see your approach. But i really would like to know what error did i comitted :c i still did't find it
 
  • #4
You have omitted
[tex]\frac{1}{(2n)!}\binom{2n}{0} \frac{d^{0}}{dz^0}(z^{2n}+1)\frac{d^{2n}}{dz^{2n}} ((z^2 + z + 1)^n) = \frac{1}{(2n)!}(z^{2n} + 1)(2n)!.[/tex]
 
  • Like
Likes LCSphysicist and Charles Link
  • #5
Herculi said:
I can see your approach. But i really would like to know what error did i comitted :c i still did't find it
I think you also get a term from ## \beta=0 ## in the derivative summation. (The product rule with multiple derivatives is clumsy, but I think that's the term you missed).

Edit: and I see @pasmith agrees with me=he posted just as I was posting.
 
  • #6
Herculi said:
Homework Statement:: .
Relevant Equations:: .

$$\int_{0}^{2\pi } (1+2cost)^{n}cos(nt) dt$$

$$e^{it} = z, izdt = dz$$

$$\oint (1+e^{it}+e^{-it})^{n}\frac{e^{nit}+e^{-nit}}{2} \frac{dz}{iz} = \oint (1+z+z^{-1})^{n}\frac{z^{n}+z^{-n}}{2} \frac{dz}{iz}$$

$$\oint (z+z^{2}+1)^{n}\frac{z^{2n}+1}{z^{2n+1}} \frac{dz}{2i} = \pi Res = \pi \frac{d^{2n}}{(2n)! dz^{2n}}((z+z^{2}+1)^{n}(z^{2n}+1))$$

$$= \pi \sum \begin{pmatrix}
2n\\ \beta
\end{pmatrix} \frac{d^{\beta} {(z^{2n}+1)}}{dz^{\beta}(2n)!} \frac{d^{2n-\beta}}{dz^{2n-\beta}}(z+z^{2}+1)^{n}$$

Since the pole is at z=0, all terms above vanish apart from ##\beta = 2n##, in this case:

$$= \pi \frac{d^{2n} {(z^{2n}+1)}}{(2n)!dz^{2n}} \frac{d^{0}}{dz^{0}}(z+z^{2}+1)^{n} $$
$$= \pi \frac{(2n)!}{(2n)!} (1) = \pi $$

The answer provided by the book is ##2 \pi##

I can't really find the error i supposedly did :/
Why is it not ##2\pi i Res## in
$$\oint (z+z^{2}+1)^{n}\frac{z^{2n}+1}{z^{2n+1}} \frac{dz}{2i} = \pi Res = \pi \frac{d^{2n}}{(2n)! dz^{2n}}((z+z^{2}+1)^{n}(z^{2n}+1))$$

The residue at z=0 is $$\frac 1 i$$
 
  • #7
The OP simplified using the factor of ##2i## in the denominator of the integrand. It made me look twice too.
 
  • #8
I still don't see it..
$$ \oint (1+z+z^{-1})^{n}\frac{z^{n}+z^{-n}}{2} \frac{dz}{iz}=2\pi i~Res \left[(1+z+z^{-1})^{n}\frac{z^{n}+z^{-n}}{2} (-i)\right]_{z=0} $$ $$=2\pi$$
 
  • Like
Likes Charles Link
  • #9
The OP is finding the residue of the integrand without the factor of ##2i##.
 
  • Like
Likes Infrared, hutchphd and Charles Link
  • #10
Apologies I don't know what you mean. The value of the integral is ##2\pi## and this is how you find it. He gets the wrong value...
 
  • #11
hutchphd said:
Apologies I don't know what you mean. The value of the integral is ##2\pi## and this is how you find it. He gets the wrong value...
The OP was somewhat sloppy in changing the function of interest by dropping a factor of ## 1/2 i ##, ( using it to cancel the ## 2i ## of ##2 \pi i ##). In any case, he uses a derivative formula to isolate the term of interest in the series, (the coefficient ## b ## of the ## \frac{b}{z } ## term), and when he did, he miscalculated the derivative.
 
  • Like
Likes hutchphd
  • #12
Wow that is a strange manipulation. Got it. Thanks.
I know it was mentioned by @Charles Link but the OP needs to understand his error was occasioned by doing the problem in a most ill-advised manner. That needs to be the take-away IMHO. The Residue Theorem is troo voodoo.
 
  • Like
Likes Charles Link
  • #13
In response to the previous post by @hutchphd , I do see a way to work this problem without using the residue theorem, where you can use ## \int\limits_{0}^{2 \pi} e^{imt} \, dt=0 ## for all integers ## m ##, except ## m=0 ##.
 
  • #14
Don't get me wrong I love Cauchy, but I always feel that I am summoning the occult. Sticking pins in the complex plane as it were. It works so well. I suppose when I really feel at home with Euler's Equation the feeling will abate. But anyway no derivatives are necessary to get to the residue term in this case.
 
  • Like
Likes Charles Link

FAQ: Complex integration is giving the wrong answer by a factor of two

What is complex integration?

Complex integration is a mathematical technique used to evaluate integrals of complex functions. It involves the calculation of a complex number by adding up infinitely many small complex numbers along a given path.

How can complex integration give the wrong answer?

Complex integration can give the wrong answer if there are errors in the calculation or if the path of integration is not properly defined. Additionally, if the function being integrated is not analytic in the region of integration, the result may be incorrect.

What is meant by a factor of two in complex integration?

A factor of two in complex integration refers to the result being twice the expected value. This can happen if the path of integration is traversed twice, or if there is a mistake in the calculation that results in an incorrect doubling of the answer.

How can one avoid getting the wrong answer by a factor of two in complex integration?

To avoid getting the wrong answer by a factor of two in complex integration, it is important to carefully define the path of integration and to check for any errors in the calculation. It is also helpful to use multiple methods of integration to verify the result.

What are some common mistakes that lead to a factor of two error in complex integration?

Some common mistakes that can lead to a factor of two error in complex integration include incorrectly defining the path of integration, using the wrong formula or method for integration, and making errors in the calculation of the integral. It is important to carefully check each step of the process to avoid these mistakes.

Similar threads

Replies
3
Views
1K
Replies
3
Views
774
Replies
9
Views
2K
Replies
1
Views
1K
Replies
14
Views
2K
Replies
2
Views
1K
Replies
8
Views
2K
Back
Top