Characteristic function of a continuous random variable

In summary: You are using the letter "i" to mean two different things: one as the imaginary unit, the other as an index on the function. This is not the same thing. I am not going to work this out for you. You should find someone who knows complex analysis, and go over this with them.
  • #1
fluidistic
Gold Member
3,924
261

Homework Statement


I must calculate the characteristic function as well as the first moments and cumulants of the continuous random variable [itex]f_X (x)=\frac{1}{\pi } \frac{c}{x^2+c^2}[/itex] which is basically a kind of Lorentzian.

Homework Equations


The characteristic function is simply a Fourier transform, namely [itex]\phi _X (k)= \int _{-\infty } ^{\infty } \frac{e^{ikx}}{x^2+c^2}dx[/itex].

The Attempt at a Solution


My problem resides in evaluation the integral. If there wasn't that exponentional in the numerator, I'd get an arctangent but unfortunately I have a complex exponentional there.
Is [itex]\phi _X (k)=\frac{ce^{ik}}{\pi} \int _{-\infty}^{\infty} \frac{e^x}{x^2+c^2}dx[/itex] valid and a good start?

Edit: Hmm no ! Very bad. This would make the integral not convergent... How is that possible? The range of x is -infinity to infinity!
 
Last edited:
Physics news on Phys.org
  • #2
fluidistic said:

Homework Statement


I must calculate the characteristic function as well as the first moments and cumulants of the continuous random variable [itex]f_X (x)=\frac{1}{\pi } \frac{c}{x^2+c^2}[/itex] which is basically a kind of Lorentzian.

Homework Equations


The characteristic function is simply a Fourier transform, namely [itex]\phi _X (k)= \int _{-\infty } ^{\infty } \frac{e^{ikx}}{x^2+c^2}dx[/itex].

The Attempt at a Solution


My problem resides in evaluation the integral. If there wasn't that exponentional in the numerator, I'd get an arctangent but unfortunately I have a complex exponentional there.
Is [itex]\phi _X (k)=\frac{ce^{ik}}{\pi} \int _{-\infty}^{\infty} \frac{e^x}{x^2+c^2}dx[/itex] valid and a good start?

Edit: Hmm no ! Very bad. This would make the integral not convergent... How is that possible? The range of x is -infinity to infinity!

No, it is not valid: exp(ikx) is not equal to exp(ik)*exp(x).

Below, assume c > 0.

Rewrite the integral as
[tex] J = \int_{\Gamma} \frac{e^{i k z}}{c^2 + z^2} \, dz, [/tex]
where [itex]\Gamma[/itex] is the real axis. You will need to extend this out to the complex z-plane and perform a contour integration. You need to consider two cases: (1) k > 0; and (2) k < 0. In case (1) the exponent in the complex z-plane is ik(x+iy) = ikx - ky, where y is the imaginary part of z. Since we have exponential damping for y > 0, we may complete the contour by adding the semi-circle C from (+∞ + i0 to -∞ + i0--- the limit as R→ ∞ of the semicircle R exp(iθ), for θ going from 0 to π). Now you have a closed contour, and it encloses the pole z = ic of 1/(z^2 + c^2). Letting [itex] \gamma = \Gamma \cup C[/itex] te the closed contour in the upper z=plane, the Cauchy residut theorem gives
[tex] J = \oint_{\gamma} \frac{e^{ikz}}{c^2 + z^2} dz = 2\pi i \text{Res} \left. \left(
\frac{e^{ikz}}{z^2 + c^2} \right) \right|_{z = ic} = 2 \pi i \frac{e^{ik ic}}{2ic} = \pi \frac{e^{-kc}}{c}. [/tex]
You can do something similar for k < 0.

Note: all this has nothing at all to do with probability; it is just standard advanced integration methodology, using contour integration. For more on this, see
http://en.wikipedia.org/wiki/Residue_theorem or
http://math.fullerton.edu/mathews/c2003/ResidueCalcMod.html .

RGV
 
Last edited by a moderator:
  • #3
Ray Vickson said:
No, it is not valid: exp(ikx) is not equal to exp(ik)*exp(x).
Shame on me. It's not the first time I make this error; the last time I made it I think it was on this forum a few years ago!
Below, assume c > 0.

Rewrite the integral as
[tex] J = \int_{\Gamma} \frac{e^{i k z}}{c^2 + z^2} \, dz, [/tex]
where [itex]\Gamma[/itex] is the real axis. You will need to extend this out to the complex z-plane and perform a contour integration. You need to consider two cases: (1) k > 0; and (2) k < 0. In case (1) the exponent in the complex z-plane is ik(x+iy) = ikx - ky^2, where y is the imaginary part of z. Since we have exponential damping for y > 0, we may complete the contour by adding the semi-circle C from (+∞ + i0 to -∞ + i0--- the limit as R→ ∞ of the semicircle R exp(iθ), for θ going from 0 to π). Now you have a closed contour, and it encloses the pole z = ic of 1/(z^2 + c^2). Letting [itex] \gamma = \Gamma \cup C[/itex] te the closed contour in the upper z=plane, the Cauchy residut theorem gives
[tex] J = \oint_{\gamma} \frac{e^{ikz}}{c^2 + z^2} dz = 2\pi i \text{Res} \left. \left(
\frac{e^{ikz}}{z^2 + c^2} \right) \right|_{z = ic} = 2 \pi i \frac{e^{ik ic}}{2ic} = \pi \frac{e^{-kc}}{c}. [/tex]
You can do something similar for k < 0.

Note: all this has nothing at all to do with probability; it is just standard advanced integration methodology, using contour integration. For more on this, see
http://en.wikipedia.org/wiki/Residue_theorem or
http://math.fullerton.edu/mathews/c2003/ResidueCalcMod.html .

RGV
Ok I'm going to close my eyes for a few, and will use your post if I'm stuck somewhere. I didn't realize I could use complex integration. I have supposedly studied this so I should be fine. Thanks a bunch. :wink: I'll post here if I get stuck.
 
Last edited by a moderator:
  • #4
I think I can get rid of the cases of the positiveness of k.
Feel free to correct me if I'm wrong: [itex]I=\oint _{\gamma} \frac{e^{ikz}}{z^2+c^2}dz[/itex] where gamma is a curve enclosing the 2 singularities (at [itex]z=\pm ic[/itex]).
Thus [itex]I=2\pi i \left [ \text{Res} (f, -ic)+ \text{Res} (f, ic) \right ]=2\pi i \left [ \lim _{z \to -ic} (z+ic) \frac{e^{ik}}{z^2+c^2} +\lim _{z \to ic} (z-ic) \frac{e^{ik}}{z^2+c^2} \right ][/itex][itex]=2\pi i \left ( \lim _{z \to -ic } \frac{e^{ikz}}{z-ic} + \lim _{z\to ic} \frac{e^{ikz}}{z+ic} \right )[/itex][tex]=\frac{\pi}{c} (e^{-kc}-e^{kc})[/tex].
Therefore [itex]\phi _X (k)=e^{-kc}-e^{kc}[/itex]. Do you think this is correct?
Edit: I don't think I'm right. There's no "i" in the characteristic function, implying that the first moment will be complex which is impossible... hmm sigh.
 
Last edited:
  • #5
fluidistic said:
I think I can get rid of the cases of the positiveness of k.
Feel free to correct me if I'm wrong: [itex]I=\oint _{\gamma} \frac{e^{ikz}}{z^2+c^2}dz[/itex] where gamma is a curve enclosing the 2 singularities (at [itex]z=\pm ic[/itex]).
Thus [itex]I=2\pi i \left [ \text{Res} (f, -ic)+ \text{Res} (f, ic) \right ]=2\pi i \left [ \lim _{z \to -ic} (z+ic) \frac{e^{ik}}{z^2+c^2} +\lim _{z \to ic} (z-ic) \frac{e^{ik}}{z^2+c^2} \right ][/itex][itex]=2\pi i \left ( \lim _{z \to -ic } \frac{e^{ikz}}{z-ic} + \lim _{z\to ic} \frac{e^{ikz}}{z+ic} \right )[/itex][tex]=\frac{\pi}{c} (e^{-kc}-e^{kc})[/tex].
Therefore [itex]\phi _X (k)=e^{-kc}-e^{kc}[/itex]. Do you think this is correct?

No. You want to integrate along the real axis and then close the contour with a big half circle. And then you want argue that you can ignore the circle part as R->infinity. The choice of whether to close in the upper half plane or the lower is going to depend on the sign of k. Is that ringing a bell?
 
  • #6
Dick said:
No. You want to integrate along the real axis and then close the contour with a big half circle. And then you want argue that you can ignore the circle part as R->infinity. The choice of whether to close in the upper half plane or the lower is going to depend on the sign of k. Is that ringing a bell?

Hmm not really. :frown: I don't really understand why the sign of k would matter when z could also be real and either negative or positive.
Anyway for k<0, ikz is ik(x+iy)=ikx-ky^2. Here I have a "problem" in the sense that for both y tending to -negative and positive infinity, the real part of the exponential tends to infinity. So that I don't have any exponential damping but the exponental remains "small" for small values of y.
Does this tells me to choose a "small" half circle ranging from say z=-2c to z=2c and in the "negative i" part of the complex plane as to englobe the pole at z=-ic? If I call \gamma _2 the curve of this half circle, then [itex]\oint _{\gamma _2 } \frac{e^{ikz}}{z^2+c^2} dz=2\pi i \text{Res}(\frac{e^{ikz}}{z^2+c^2},-ic)[/itex]. Which I already calculated, so I'm sure I'm wrong again, but don't know where.
 
  • #7
You are blocking on this. ik(x+iy)=ikx-ky. Not ky^2. If k<0 then one half plane is definitely better than the other. Which one is exponentially damped? y>0 or y<0??
 
  • #8
Dick said:
You are blocking on this. ik(x+iy)=ikx-ky. Not ky^2. If k<0 then one half plane is definitely better than the other. Which one is exponentially damped? y>0 or y<0??
y<0 without any doubt. This doesn't change my draft of the semi-circle, still in the lower part (under the real axis in the complex plane) of the complex plane. It still encloses the pole z=-ic.
 
  • #9
fluidistic said:
y<0 without any doubt. This doesn't change my draft of the semi-circle, still in the lower part (under the real axis in the complex plane) of the complex plane. It still encloses the pole z=-ic.

Ok, then. So depending on the sign of k you enclose one pole or the other. Don't forget that if you close in the upper half plane your contour is counterclockwise and if you close in the lower half plane it's clockwise. That makes a difference too.
 
  • #10
fluidistic said:
Hmm not really. :frown: I don't really understand why the sign of k would matter when z could also be real and either negative or positive.
Anyway for k<0, ikz is ik(x+iy)=ikx-ky^2. Here I have a "problem" in the sense that for both y tending to -negative and positive infinity, the real part of the exponential tends to infinity. So that I don't have any exponential damping but the exponental remains "small" for small values of y.
Does this tells me to choose a "small" half circle ranging from say z=-2c to z=2c and in the "negative i" part of the complex plane as to englobe the pole at z=-ic? If I call \gamma _2 the curve of this half circle, then [itex]\oint _{\gamma _2 } \frac{e^{ikz}}{z^2+c^2} dz=2\pi i \text{Res}(\frac{e^{ikz}}{z^2+c^2},-ic)[/itex]. Which I already calculated, so I'm sure I'm wrong again, but don't know where.

My original post had a typo: I should have written ik(x+iy) = ikx - ky (not -ky^2). I have edited out that error.

The point is that when k > 0 you get damping by having y > 0, but when k < 0 you need y < 0 instead.

RGV
 
  • #11
Dick said:
Ok, then. So depending on the sign of k you enclose one pole or the other. Don't forget that if you close in the upper half plane your contour is counterclockwise and if you close in the lower half plane it's clockwise. That makes a difference too.
Oh I see. Does this mean that [itex]\phi _X (k)=e^{-kc}+e^{kc}[/itex] instead of my previous [itex]\phi _X (k)=e^{-kc}-e^{kc}[/itex]? (P.S.:Latex isn't working so that's why I jump to the further conclusion here)
But that would still make no sense to me... :(


Ray Vickson said:
My original post had a typo: I should have written ik(x+iy) = ikx - ky (not -ky^2). I have edited out that error.

The point is that when k > 0 you get damping by having y > 0, but when k < 0 you need y < 0 instead.

RGV
Yeah I noticed thanks to Dick :) I missed the typo.
 
  • #12
fluidistic said:
Oh I see. Does this mean that [itex]\phi _X (k)=e^{-kc}+e^{kc}[/itex] instead of my previous [itex]\phi _X (k)=e^{-kc}-e^{kc}[/itex]? (P.S.:Latex isn't working so that's why I jump to the further conclusion here)
But that would still make no sense to me... :(

Read the stuff you quoted from me again. You don't have any contour including both poles. Which pole is enclosed depends on the sign of k. So you don't have both e^(kc) and e^(-kc) in the solution. Split it into the cases k>0 and k<0 and given an answer for each case. Then think about how you might write them as a single formula. The absolute value function might be useful.
 
  • #13
Dick said:
Read the stuff you quoted from me again. You don't have any contour including both poles. Which pole is enclosed depends on the sign of k. So you don't have both e^(kc) and e^(-kc) in the solution. Split it into the cases k>0 and k<0 and given an answer for each case. Then think about how you might write them as a single formula. The absolute value function might be useful.
Ok thanks. I think I start to understand some things now. This would make:
for k<0, [itex]I=\oint _{\gamma} \frac{e^{ikz}}{z^2+c^2}dz=-\frac{\pi}{c}e^{kc}[/itex]
for k>0, [itex]I=-\frac{\pi}{c}e^{-kc}[/itex].
This would mean that for [itex]k<0[/itex], [itex]\phi _X (k)=-e^{kc}[/itex] and for [itex]k>0[/itex], [itex]\phi _X (k)=-e^{-kc}[/itex].
Or in more compact form, [itex]\phi _X(k)=-e^{|k|c}[/itex].
I know I made a sign error everywhere, since I'm sure I should get a fonction like a mountain and not like a hole.
Details: for k>0, [itex]I=2\pi i \text {Res} (f,ic)=-2\pi i \cdot \lim _{z \to ic} (z-ic) \frac{e^{ikz}}{z^2+c^2}=-\frac{\pi}{c}e^{-kc}[/itex]. The mignus sign in front of "2" comes from the counter clock-wise curve with semi circle shape. So I guess I got it wrong and should put a mignus sign when the curve's direction is clock-wise?
Anyway I can't be right on the final form anyway since I'm sure I should have a factor "i" in the numerator; because otherwise the first moment will be complex which is impossible. hmm...
Thank you guys for being so patient with me.
 
  • #14
fluidistic said:
Ok thanks. I think I start to understand some things now. This would make:
for k<0, [itex]I=\oint _{\gamma} \frac{e^{ikz}}{z^2+c^2}dz=-\frac{\pi}{c}e^{kc}[/itex]
for k>0, [itex]I=-\frac{\pi}{c}e^{-kc}[/itex].
This would mean that for [itex]k<0[/itex], [itex]\phi _X (k)=-e^{kc}[/itex] and for [itex]k>0[/itex], [itex]\phi _X (k)=-e^{-kc}[/itex].
Or in more compact form, [itex]\phi _X(k)=-e^{|k|c}[/itex].
I know I made a sign error everywhere, since I'm sure I should get a fonction like a mountain and not like a hole.
Details: for k>0, [itex]I=2\pi i \text {Res} (f,ic)=-2\pi i \cdot \lim _{z \to ic} (z-ic) \frac{e^{ikz}}{z^2+c^2}=-\frac{\pi}{c}e^{-kc}[/itex]. The mignus sign in front of "2" comes from the counter clock-wise curve with semi circle shape. So I guess I got it wrong and should put a mignus sign when the curve's direction is clock-wise?
Anyway I can't be right on the final form anyway since I'm sure I should have a factor "i" in the numerator; because otherwise the first moment will be complex which is impossible. hmm...
Thank you guys for being so patient with me.

You are making a lot of progress. Yes, clockwise contours get the extra negative sign, so the overall minus shouldn't be there. And check your absolute value assignment as well. I've think you've got that backwards too. And finally, I wouldn't worry much about the first moment. Your distribution doesn't really have one. The integral is pretty badly behaved. I hope Ray Vickson can fill in the details here, this isn't really my field.
 
  • #15
Dick said:
You are making a lot of progress. Yes, clockwise contours get the extra negative sign, so the overall minus shouldn't be there. And check your absolute value assignment as well. I've think you've got that backwards too. And finally, I wouldn't worry much about the first moment. Your distribution doesn't really have one. The integral is pretty badly behaved. I hope Ray Vickson can fill in the details here, this isn't really my field.

Ok thanks for the encouragements! Yes I made a typo for the sign in the exponential, so that [itex]\phi _X(k)=e^{-|k|c}[/itex].
I have 2 definitions to calculate the first moment. One involves computing [itex]\langle x \rangle = \int _{-\infty} ^{\infty} x\frac{1}{\pi } \frac{c}{x^2+c^2} dx[/itex] which would be a pain like you say and the other way seems much easier: [itex]\langle x \rangle = \frac{1}{i} \frac{d\phi (k)}{dk} \big | _{k=0}=\frac{-c}{i} if k>0[/itex] and [itex]\frac{c}{i}[/itex] if [itex]k<0[/itex].
However the first moment should be a real number...

Now I'm looking at wikipedia (http://en.wikipedia.org/wiki/Cauchy_distribution).
It seems like my characteristic function would have been complex if [itex]x_0[/itex] was different from 0. Namely if I was given that [itex]f_X (x)=\frac{1}{\pi } \frac{c}{(x-x_0)^2+c^2}[/itex] I would have gotten [itex]\phi (k)=e^{ikx_0-c|k|}[/itex].
Nevermind, this would still not get rid of the problem.
Does this mean that there's no mean?!

OH WOW! On that wikipedia's page it's written that there's no mean nor any higher moment!
 
  • #16
fluidistic said:
Ok thanks for the encouragements! Yes I made a typo for the sign in the exponential, so that [itex]\phi _X(k)=e^{-|k|c}[/itex].
I have 2 definitions to calculate the first moment. One involves computing [itex]\langle x \rangle = \int _{-\infty} ^{\infty} x\frac{1}{\pi } \frac{c}{x^2+c^2} dx[/itex] which would be a pain like you say and the other way seems much easier: [itex]\langle x \rangle = \frac{1}{i} \frac{d\phi (k)}{dk} \big | _{k=0}=\frac{-c}{i} if k>0[/itex] and [itex]\frac{c}{i}[/itex] if [itex]k<0[/itex].
However the first moment should be a real number...

Now I'm looking at wikipedia (http://en.wikipedia.org/wiki/Cauchy_distribution).
It seems like my characteristic function would have been complex if [itex]x_0[/itex] was different from 0. Namely if I was given that [itex]f_X (x)=\frac{1}{\pi } \frac{c}{(x-x_0)^2+c^2}[/itex] I would have gotten [itex]\phi (k)=e^{ikx_0-c|k|}[/itex].
Nevermind, this would still not get rid of the problem.
Does this mean that there's no mean?!

OH WOW! On that wikipedia's page it's written that there's no mean nor any higher moment!

Sure. Look at the integral representation of the moments. They pretty obviously diverge.
 
  • #17
Dick said:
Sure. Look at the integral representation of the moments. They pretty obviously diverge.

You are right. So I'm guessing this also means that there's no cummulants eithers.
 

Related to Characteristic function of a continuous random variable

1. What is a characteristic function?

A characteristic function is a mathematical function that uniquely describes the probability distribution of a random variable. It is defined as the expectation value of the complex exponential function of the random variable.

2. How is a characteristic function related to a probability density function (PDF)?

A characteristic function and a probability density function are closely related. The characteristic function is the Fourier transform of the PDF, which means that it contains all of the information about the PDF. It can be used to derive the PDF and other statistical properties of the random variable.

3. What is the importance of the characteristic function in probability and statistics?

The characteristic function plays a crucial role in probability and statistics as it allows for the calculation of moments and other statistical properties of a random variable. It also helps in the analysis and prediction of data, as well as in the development of statistical models.

4. Can a characteristic function be used for discrete random variables?

Yes, a characteristic function can be used for both continuous and discrete random variables. However, for discrete random variables, the characteristic function is defined as a sum instead of an integral.

5. How is a characteristic function used in hypothesis testing?

In hypothesis testing, the characteristic function is used to calculate the probability of rejecting a null hypothesis. It is also used to determine the significance level and power of a statistical test.

Similar threads

  • Calculus and Beyond Homework Help
Replies
2
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
511
Replies
9
Views
1K
  • Calculus and Beyond Homework Help
Replies
2
Views
342
Replies
5
Views
1K
  • Calculus and Beyond Homework Help
Replies
4
Views
350
  • Calculus and Beyond Homework Help
Replies
3
Views
446
  • Calculus and Beyond Homework Help
Replies
5
Views
504
Replies
5
Views
1K
  • Calculus and Beyond Homework Help
Replies
3
Views
438
Back
Top