MathGroup Archive 2004

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

Search the Archive

Re: Substitute values in functions!!!

In article <cneu7f$q8j$1 at>,
 davidx at (david Lebonvieux) wrote:

> How can substitute some values(the zeros of BesselJ function) in this
> Integrals?
> j0[n_] := x /. FindRoot[BesselJ[0, x] == 0, {x, n 2.5}]

Change this to

 j0[n_] := FindRoot[BesselJ[0, x] == 0, {x, n*2.5}]

so that the result is a replacement rule instead of a value.

> \!\(s\_l = Array[j0, \ 10]\)
> Integrate[BesselJ[0,s0*r/R] BesselJ[0,s2*r/R] BesselJ[0,s3*r/R],{r,0,R}]

By a change of variables r -> R r, this integral becomes

  R Integrate[BesselJ[0,s0 r] BesselJ[0,s2 r] BesselJ[0,s3 r],{r,0,1}]

> where s0, s1,s2,the Zero-Poles of BesselJ.

Substitute the first three zeros into the integrand:

 Times @@ (BesselJ[0, x r] /. Array[j0, 3])

Compute the integral numerically:

 R NIntegrate[%, {r, 0, 1}]


Paul Abbott                                   Phone: +61 8 6488 2734
School of Physics, M013                         Fax: +61 8 6488 1014
The University of Western Australia      (CRICOS Provider No 00126G)         
35 Stirling Highway
Crawley WA 6009                      mailto:paul at 

  • Prev by Date: Lucas Lehmer prime Mersenne test
  • Next by Date: Newly Released Mathematica 5.1 Delivers Unmatched Performance for Handling Data
  • Previous by thread: Substitute values in functions!!!
  • Next by thread: Re: Re: Substitute values in functions!!!