You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
stieltjes() evaluated at certain points results in large amount of memory allocated.
julia>using ClassicalOrthogonalPolynomials, SingularIntegrals
julia> W =Weighted(ChebyshevU()); x =axes(W, 1); f =expand(W, x ->inv(√2* x +3/2) *√(1-x^2));
julia> z =0.2567881003580743-0.33437737333561895im;
julia>@timeinv.(z .- x') * f # first time run, ignore1.994925 seconds (1.61 M allocations:3.126 GiB, 10.78% gc time, 65.63% compilation time)
1.1162556659904905+1.449666329259747im
julia>@timeinv.(z .- x') * f # large memory allocation0.614899 seconds (78 allocations:2.980 GiB, 19.81% gc time)
1.1162556659904905+1.449666329259747im
julia>@timeinv.(z+0.01im.- x') * f # fine here0.000219 seconds (80 allocations:122.562 KiB)
1.1295620627968406+1.4556063512794264im
After some investigation, it seems that the problem resides in backwardrecurrence!, where:
Line 118: μ is set to 1
Line 121, N is set to maxiterations, which results in K.data being 100_000_000 size.
Setting maxiterations to something smaller seems to "fix" the problem.
The text was updated successfully, but these errors were encountered:
jamiecjx
changed the title
Large memory allocation in stieltjes, recurrencearray
Large memory allocation in stieltjes, backwardrecurrence!
Sep 8, 2023
stieltjes() evaluated at certain points results in large amount of memory allocated.
After some investigation, it seems that the problem resides in
backwardrecurrence!
, where:Line 118: μ is set to 1
Line 121,
N
is set tomaxiterations
, which results inK.data
being 100_000_000 size.Setting maxiterations to something smaller seems to "fix" the problem.
The text was updated successfully, but these errors were encountered: