Numerical/Analytical Solution to a Complex Integral

In summary, the conversation discussed solving an integral involving a complex exponential function and seeking a more efficient method for computation. The attempt at a solution involved simplifying the integral by completing the square and changing variables, resulting in the use of the error function. However, it was uncertain whether the term involving the error function would converge or diverge as the real and imaginary parts of the function approached infinity. Further investigation and analysis were needed to determine the behavior of the integral in this case. The conversation also touched on the possibility of using roots of unity to simplify the problem, but it was unclear if this approach would be helpful.
  • #1
WWCY
479
12

Homework Statement



I have the following integral I wish to solve (preferably analytically):

$$ I(x,t) = \int_{-\infty}^{0} \exp{[-(\sigma^2 + i\frac{t}{2})p^2 + (2\sigma ^2 p_a + ix)p]} \ dp$$

where ##x## ranges from ##-\infty## to ##\infty## and ##t## from ##0## to ##\infty##. ##\sigma## and ##p_a## are positive and real

letting ##(\sigma^2 + i\frac{t}{2}) = g## and ##(2\sigma ^2 p_0 + ix) = h##,

$$I(x,t) = \int_{-\infty}^{0} e^{-(gp^2 - hp)} \ dp$$

Thus far, I have tried writing this in the form of ##\text{erf}## but it becomes eye-wateringly complex (I will write my attempt below). Are there any more efficient ways to compute this integral, either numerically or analytically?

Thanks very much in advance for any assistance.

Homework Equations

The Attempt at a Solution



I simplify the integral by completing the square, which gives:

$$e^{\frac{h^2}{4g}} \int_{-\infty}^{0} e^{-(\sqrt{g}p \ - \frac{h}{2\sqrt{g}})^2} \ dp$$

I then change variables with ##t = (\sqrt{g}p \ - \frac{h}{2\sqrt{g}})##, giving

$$\frac{e^{\frac{h^2}{4g}}}{\sqrt{g}} \int_{z_2}^{z_1} e^{-t^2} \ dt$$

with ##z_1 = - \ \frac{h}{2\sqrt{g}}## and ## z_2 = \lim_{\ p \to -\infty } (\sqrt{g}p \ - \frac{h}{2\sqrt{g}}) ##

I then write this in term of the error function

$$I = \frac{\sqrt{\pi}}{2 } \ \frac{e^{\frac{h^2}{4g}}}{\sqrt{g}} \Big[ \text{erf} (z_1) - \text{erf} (z_2) \Big]$$

However, I am unable to determine whether or not the term ##\text{erf} (z_2)## converges or diverges, or indeed what its value is.
 
Physics news on Phys.org
  • #2
WWCY said:

Homework Statement



I have the following integral I wish to solve (preferably analytically):

$$ I(x,t) = \int_{-\infty}^{0} \exp{[-(\sigma^2 + i\frac{t}{2})p^2 + (2\sigma ^2 p_a + ix)p]} \ dp$$

where ##x## ranges from ##-\infty## to ##\infty## and ##t## from ##0## to ##\infty##. ##\sigma## and ##p_a## are positive and real

letting ##(\sigma^2 + i\frac{t}{2}) = g## and ##(2\sigma ^2 p_0 + ix) = h##,

$$I(x,t) = \int_{-\infty}^{0} e^{-(gp^2 - hp)} \ dp$$

Thus far, I have tried writing this in the form of ##\text{erf}## but it becomes eye-wateringly complex (I will write my attempt below). Are there any more efficient ways to compute this integral, either numerically or analytically?

Thanks very much in advance for any assistance.

Homework Equations

The Attempt at a Solution



I simplify the integral by completing the square, which gives:

$$e^{\frac{h^2}{4g}} \int_{-\infty}^{0} e^{-(\sqrt{g}p \ - \frac{h}{2\sqrt{g}})^2} \ dp$$

I then change variables with ##t = (\sqrt{g}p \ - \frac{h}{2\sqrt{g}})##, giving

$$\frac{e^{\frac{h^2}{4g}}}{\sqrt{g}} \int_{z_2}^{z_1} e^{-t^2} \ dt$$

with ##z_1 = - \ \frac{h}{2\sqrt{g}}## and ## z_2 = \lim_{\ p \to -\infty } (\sqrt{g}p \ - \frac{h}{2\sqrt{g}}) ##

I then write this in term of the error function

$$I = \frac{\sqrt{\pi}}{2 } \ \frac{e^{\frac{h^2}{4g}}}{\sqrt{g}} \Big[ \text{erf} (z_1) - \text{erf} (z_2) \Big]$$

However, I am unable to determine whether or not the term ##\text{erf} (z_2)## converges or diverges, or indeed what its value is.

I think you should be able to prove the following:
(1) If ##f(N) = \text{erf}(aN + ib)## with ##a,b## constant, then ##\lim f(N)## exists and is finite as ##N \to \pm \infty##
(2) If ##f(N) = \text{erf}(a + i b N)## for constants ##a,b##, then ##b \neq 0 \Rightarrow f(N)## diverges as ##N \to \pm \infty##. You ought to be able to do this by looking at the integral and seeing whether it can converge or not. So, if the imaginary part of the erf function stays bounded but the real part becomes infinite, you get a finite answer; if the real part remains bounded while the imaginary part becomes infinite you will have an infinite answer.

A trickier case (like yours) is where the real and imaginary parts go to ##\infty## together, such as for ##f(N) = \text{erf}((a+ib)N)## with real ##a,b##. I looked at this in Maple, and think that for ##a,b > 0## at least we have that ##f(N)## converges if ## b \leq a## but diverges if ##b > a##. The attached file is from a Maple session in which I looked at ##f_1(x) = \text{erf}((1+i)x), f_2(x)= \text{erf}((1+1.01) x)## and ##f_3(x) = \text{erf}((1+0.9 i)x))##, giving plots of the real and imaginary parts from ##x=0## to some moderately large positive value. The graphs show quite convincingly that we get convergence for ##f_1## and ##f_3## but divergence for ##f_2.##

The challenge is to somehow prove all this "analytically", but to date I don't know how to do it.
 

Attachments

  • Complex_erf_limits.pdf
    152.1 KB · Views: 228
Last edited:
  • Like
Likes WWCY
  • #3
Thank you for the reply!

Ray Vickson said:
A trickier case (like yours) is where the real and imaginary parts go to ##\infty## together, such as for ##f(N) = \text{erf}((a+ib)N)## with real ##a,b##. I looked at this in Maple, and think that for ##a,b > 0## at least we have that ##f(N)## converges if ## b \leq a## but diverges if ##b > a##. The attached file is from a Maple session in which I looked at ##f_1(x) = \text{erf}((1+i)x), f_2(x)= \text{erf}((1+1.01) x)## and ##f_3(x) = \text{erf}((1+0.9 i)x))##, giving plots of the real and imaginary parts from ##x=0## to some moderately large positive value. The graphs show quite convincingly that we get convergence for ##f_1## and ##f_3## but divergence for ##f_2.##
The challenge is to somehow prove all this "analytically", but to date I don't know how to do it.

I have a few follow-up questions I'd like to ask:
1. What do the analytical expressions for the real and imaginary parts of ## \text{erf} (x + iy)## look like? I've looked around for such expressions but have been unable to find them.
2. I assume the case mentioned in the quote refers to ##\text{erf} (z_2)##. My main concern in this case is that ##t## is a temporal variable, and ##x## is spatial. I'm concerned that the function diverges when these two head to infinity. Could I investigate by plotting against ##x## and ##t## (for Re and I am of erf) in Maple as you did?

I was also thinking about the following to see if we can sort this out analytically by rewriting the terms in the erf's using roots of unity. However I don't know whether or not simplifying the input actually does anything to make the problem simpler or clearer. Do you mind taking a look?

Take for instance ##z_2## where ##p## implicitly heads to ##-\infty## while ##x## goes to ##\infty##
Start with
$$z_2 = \sqrt{ \sigma^2 + i\frac{t}{2} } p \ - \frac{2\sigma ^2 p_0 + ix}{2\sqrt{\sigma^2 + i\frac{t}{2} }}$$
as ##t## tends to ##\infty##, the term $$\sqrt{\sigma^2 + i\frac{t}{2} } = \sqrt{e^{i\frac{\pi}{2}}} = e^{i\frac{\pi}{4}}$$
where I take the positive root of unity. I actually don't know whether or not this is a valid choice, though what I learned was that both choices are equally valid. I then rewrite ##z_2## as

$$z_2 = \frac{1}{\sqrt{2}} (1+i)p - \frac{ (2\sigma^2 p_0 + ix)(1-i) }{\frac{2}{\sqrt{2}} (1+i)(1-i)} $$

which then reduces to

$$z_2 = [\frac{1}{\sqrt{2}} (1+i)]p - \frac{1}{2 \sqrt{2}} [x + 2\sigma^2 p_0 + (x - 2\sigma^2 p_0)i ]$$

also, this means

$$z_1 = \frac{1}{2 \sqrt{2}} [x + 2\sigma^2 p_0 + (x - 2\sigma^2 p_0)i$$

Does this do anything for the problem or should I stick to the numerical methods?

Thank you again for your assistance. Apologies for my lack of understanding wrt some of these ideas.
 

1. What is a numerical/analytical solution to a complex integral?

A numerical/analytical solution to a complex integral is a method of finding the value of a complex integral by using numerical or analytical techniques. This involves breaking down the integral into smaller, solvable parts and then using approximation or exact methods to determine the final value.

2. When is a numerical solution preferred over an analytical solution for a complex integral?

A numerical solution is preferred over an analytical solution for a complex integral when the integral cannot be solved using traditional mathematical methods. This can occur when the integral is too complex or when it involves unknown or variable parameters.

3. What are some common techniques used for numerical/analytical solutions to complex integrals?

Some common techniques used for numerical/analytical solutions to complex integrals include the trapezoidal rule, Simpson's rule, and Monte Carlo integration. Other methods such as Gaussian quadrature and Romberg integration can also be used.

4. How accurate are numerical/analytical solutions to complex integrals?

The accuracy of a numerical/analytical solution to a complex integral depends on the chosen method and the number of intervals used in the approximation. Generally, the more intervals used, the more accurate the solution will be. However, numerical solutions are prone to rounding errors and may not provide an exact solution.

5. Can numerical/analytical solutions be used for all types of complex integrals?

No, not all types of complex integrals can be solved using numerical/analytical solutions. Some integrals may be too complex or may not have a known analytical solution. In these cases, numerical methods may be the only option for finding an approximate solution.

Similar threads

  • Calculus and Beyond Homework Help
Replies
6
Views
1K
  • Calculus and Beyond Homework Help
Replies
7
Views
886
  • Calculus and Beyond Homework Help
Replies
17
Views
2K
  • Calculus and Beyond Homework Help
Replies
2
Views
888
  • Calculus and Beyond Homework Help
Replies
5
Views
724
  • Calculus and Beyond Homework Help
Replies
3
Views
665
  • Calculus and Beyond Homework Help
Replies
9
Views
1K
  • Calculus and Beyond Homework Help
Replies
19
Views
707
  • Calculus and Beyond Homework Help
Replies
1
Views
970
  • Calculus and Beyond Homework Help
Replies
3
Views
1K
Back
Top