I have a problem with a numerical integration. I have a 4x4x4x4 array that has for each entry an integral and I want to use NIntegrate
to evaluate it. It gives me no problem, it's actually pretty fast. But if I increase the size of the array to 9x9x9x9 I get this message:
NIntegrate::slwcon: Numerical integration converging too slowly; suspect one of the following: singularity, value of the integration is 0, highly oscillatory integrand, or WorkingPrecision too small.
I increased the working precision already but it didn't help.
EDITED:
I put here a simplified version of my code:
B9b = Array[Nspher[#2, #4] &, {9, 9, 9, 9}, {1, 0, 1, 0}]
where
Nspher[l_, k_] :=
NIntegrate[
SphericalHarmonicY[l, 0, θ, φ] SphericalHarmonicY[k, 0, θ, φ]*Sin[θ],
{θ, 0, π}, {φ, 0, 2 π},
WorkingPrecision -> 50, AccuracyGoal -> 10, MaxRecursion -> 30]
Method -> "ClenshawCurtisOscillatoryRule"
. $\endgroup$SphericalHarmonicY[]
... $\endgroup$