Re: Re: partial fraction
- To: mathgroup at smc.vnet.net
- Subject: [mg32917] Re: [mg32881] Re: [mg32865] partial fraction
- From: Murray Eisenberg <murraye at attbi.com>
- Date: Tue, 19 Feb 2002 02:29:57 -0500 (EST)
- Organization: Mathematics & Statistics, Univ. of Mass./Amherst
- References: <200202181022.FAA14858@smc.vnet.net>
- Reply-to: murray at math.umass.edu
- Sender: owner-wri-mathgroup at wolfram.com
What's wrong with the following: Integrate[1/(1 - x^2)^2, x] -x/(2*(-1 + x^2)) - Log[-1 + x]/4 + Log[1 + x]/4 Or, if you want to see the partial fractions, using the built-in Apart: Apart[1/(1 - x^2)^2] 1/(4*(-1 + x)^2) - 1/(4*(-1 + x)) + 1/(4*(1 + x)^2) + 1/(4*(1 + x)) Integrate[%, x] -1/(4*(-1 + x)) - 1/(4*(1 + x)) - Log[-1 + x]/4 + Log[1 + x]/4 (Or, as you show, then use Map[Integrate[#, x]&, %] to make sure Mathematica is really doing the integration term-by-term rather than first somehow simplifying the partial fraction expression.) BobHanlon at aol.com wrote: > > In a message dated 2/16/02 4:45:52 AM, kyguan at hotmail.com writes: > > >Do you have any ideas on how to integrate the following function by partial > > > >fraction? > > > >1/(1-x^2)^2 (Sorry it was supposed to be a minus instead of plus) > > > >I have found the answer by using 'the integrator'. However, I have no single > > > >clue on how the answer were calculated. > > > > Although it does not appear to be documented, the standard add-on > package DiscreteMath`RSolve` defines the function PartialFractions. > > Needs["DiscreteMath`RSolve`"]; > > f[x_] := 1/(1-x^2)^2; > > pfe1 = PartialFractions[f[x], x] > > 1/(4*(-1 + x)^2) - 1/(4*(-1 + x)) + 1/(4*(1 + x)^2) + > 1/(4*(1 + x)) > > Integrating term-by-term > > Integrate[#,x]& /@ pfe1 > > -1/(4*(-1 + x)) - 1/(4*(1 + x)) - Log[-1 + x]/4 + > Log[1 + x]/4 > > %//Simplify > > ((-2*x)/(-1 + x^2) - Log[-1 + x] + Log[1 + x])/4 > > You could also do the partial fraction expansion yourself > > Factor[f[x]] > > 1/((-1 + x)^2*(1 + x)^2) > > The partial fraction is then of the form > > pfe2 = {a, b, c, d}.(1/{x+1, (x+1)^2 , (x-1), (x-1)^2}) > > d/(-1 + x)^2 + c/(-1 + x) + b/(1 + x)^2 + a/(1 + x) > > eqn = Thread[ > (cl = > > CoefficientList[Numerator[Together[pfe2]],x])== > PadRight[ > CoefficientList[Numerator[f[x]],x], > Length[cl]]] > > {a + b - c + d == 1, -a - 2*b - c + 2*d == 0, > > -a + b + c + d == 0, a + c == 0} > > soln = Solve[eqn, {a,b,c,d}][[1]] > > {a -> 1/4, b -> 1/4, c -> -1/4, d -> 1/4} > > (pfe2 /. soln) == pfe1 > > True > > Bob Hanlon > Chantilly, VA USA -- Murray Eisenberg murray at math.umass.edu Mathematics & Statistics Dept. Lederle Graduate Research Tower phone 413 549-1020 (H) University of Massachusetts 413 545-2859 (W) 710 North Pleasant Street Amherst, MA 01375
- References:
- Re: partial fraction
- From: BobHanlon@aol.com
- Re: partial fraction