# Plotting complicated Bessel functions expression

I am trying to plot this function

f[X_,Y_]=-(1/Sqrt)(√((1/2 - 0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2/((1/2 -
0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2 +
10000.3 BesselJ[1, 0.01 X]^2 Sin[Y]^2) + (
10000.3 BesselJ[1, 0.01 X]^2 Sin[
Y]^2)/((1/2 - 0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2 +
10000.3 BesselJ[1, 0.01 X]^2 Sin[
Y]^2) + (√((1/2 - 0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2 ((1/2 -
0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2 +
10000.3 BesselJ[1, 0.01 X]^2 Sin[Y]^2)))/((1/2 -
0.500013 BesselJ[0, 0.01 X] +
100.001 BesselJ[1, 0.01 X] Cos[Y])^2 +
10000.3 BesselJ[1, 0.01 X]^2 Sin[Y]^2)))


But I get this plot.

Plot[f[X, π/2], {X, 1, 10^4}] I was expecting more regular oscillations, whereas I see in the lower part certain irregularities, and this make me think of some plotting error. Is there anything I can do to make the bessel function be plotted right?

Thanks!

• @rhermans Done, thanks for pointing it out – usumdelphini Oct 21 '15 at 14:46
• I'm not sure what you mean, but if you are unsatisfied by the quality of the Plot probably you could try increasing the number of points the function is evaluated on. beware this will be slow: Plot[f[X, Pi/2], {X, 1, 10^4}, PlotRange -> {-1.1, -0.7}, PlotPoints -> 100, MaxRecursion -> 15] – rhermans Oct 21 '15 at 14:53

plotlist = 