MathGroup Archive 2008

[Date Index] [Thread Index] [Author Index]

Search the Archive

Re: Extending Integrate[]

  • To: mathgroup at
  • Subject: [mg87789] Re: Extending Integrate[]
  • From: dh <dh at>
  • Date: Wed, 16 Apr 2008 22:34:22 -0400 (EDT)
  • References: <fu4lnj$si9$>

Hi Szabolcs,

it looks like mathematica does not automatically distribute your rule 

over Plus. This comes a bit as a surprise. But you can teach it. If you 

additionally give the following rule:


then your example works. Of course you also need linearity.

hope this helps, Daniel

Szabolcs Horvát wrote:

> According to the documentation it is possible to extend Integrate[] with 

> new rules:




> The specific example that is given is:


> Unprotect[Integrate]


> Integrate[Sin[Sin[a_. + b_. x_]], x_] := Jones[a, x]/b


> Now Integrate[Sin[Sin[3x]], x] will return Jones[0, x]/3


> But if I try an integrand that is just slightly more complicated, 

> Mathematica returns it unevaluated:


> In[21]:= Integrate[a + Sin[Sin[x]], x]

> Out[21]= Integrate[a + Sin[Sin[x]], x]


> My question is:  Is it really possible to extend Integrate in an 

> intelligent way?  The above example seems to be just simple pattern 

> matching.  It would work with any function, not just Integrate[].  There 

> is nothing new or surprising about it.


> But is it *really* possible to extend Integrate[] with new definitions 

> in a way that Mathematica will use these rules when calculating more 

> complicated Integrals?


> If (as I suspect) it is not possible to do this, then the documentation 

> is a bit misleading ...


  • Prev by Date: Re: Select from list
  • Next by Date: Re: Extending Integrate[]
  • Previous by thread: Re: Extending Integrate[]
  • Next by thread: Re: Extending Integrate[]