:::text integrate(1/(1 - exp(%i*x))^(1/2), x, 0, 2*%pi);
The answer is 0 but should be 2 * %pi by the residue theorem. On the other hand, the case
2 * %pi
:::text integrate(1/(1 - exp(%i*x)), x, 0, 2*%pi);
is handled properly
One interesting fact is that if you ask Maxima to come up with an antiderivative, it succeeds:
:::text (%i1) antideriv: integrate(1/(1 - exp(%i*x))^(1/2), x); (%o1) %i*log(sqrt(1-%e^(%i*x))+1)-%i*log(sqrt(1-%e^(%i*x))-1)
and the real part of this expression goes from - %pi at x = 0 through to %pi at x = 2 * %pi, as you'd expect.
- %pi
x = 0
%pi
x = 2 * %pi
If you do the definite integral and trace the integrator function, you see it compute the following antiderivative:
:::text (%i2) integrate(1/(1 - exp(%i*x))^(1/2), x, 0, 2*%pi); 0: (INTEGRATOR ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 ((MEXPT SIMP) $%E ((MTIMES SIMP) $%I $X)))) ((RAT SIMP) -1 2)) $X) 1: (INTEGRATOR ((MTIMES SIMP) -1 $%I ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 $X)) ((RAT SIMP) -1 2)) ((MEXPT SIMP) $X -1)) $X) 1: INTEGRATOR returned ((MTIMES SIMP) -1 $%I ((MPLUS SIMP) ((%LOG SIMP) ((MABS SIMP) ((MPLUS SIMP) -1 ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 $X)) ((RAT SIMP) 1 2))))) ((MTIMES SIMP) -1 ((%LOG SIMP) ((MPLUS SIMP) 1 ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 $X)) ((RAT SIMP) 1 2))))))) 0: INTEGRATOR returned ((MPLUS SIMP) ((MTIMES SIMP) $%I ((%LOG SIMP) ((MPLUS SIMP) 1 ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 ((MEXPT SIMP) $%E ((MTIMES SIMP) $%I $X)))) ((RAT SIMP) 1 2))))) ((MTIMES SIMP) -1 $%I ((%LOG SIMP) ((MABS SIMP) ((MPLUS SIMP) -1 ((MEXPT SIMP) ((MPLUS SIMP) 1 ((MTIMES SIMP) -1 ((MEXPT SIMP) $%E ((MTIMES SIMP) $%I $X)))) ((RAT SIMP) 1 2))))))) (%o2) 0
which is:
:::text (%o4) %i*log(sqrt(1-%e^(%i*x))+1)-%i*log(abs(sqrt(1-%e^(%i*x))-1))
(notice the abs functions). The imaginary parts agree, but the real parts do not.
abs
Log in to post a comment.
One interesting fact is that if you ask Maxima to come up with an antiderivative, it succeeds:
and the real part of this expression goes from
- %piatx = 0through to%piatx = 2 * %pi, as you'd expect.If you do the definite integral and trace the integrator function, you see it compute the following antiderivative:
which is:
(notice the
absfunctions). The imaginary parts agree, but the real parts do not.