Skip to content

Commit

Permalink
get_prototype for HCubatureJL
Browse files Browse the repository at this point in the history
  • Loading branch information
lxvm committed Mar 2, 2024
1 parent 9a39c80 commit 74e4def
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/Integrals.jl
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ function __solvebp_call(cache::IntegralCache, alg::HCubatureJL, sensealg, domain
rtol = reltol, atol = abstol, buffer = cache.cacheval,
maxevals = maxiters, norm = alg.norm, initdiv = alg.initdiv)
else
ret = _f((lb + ub) / 2) * (prod(ub - lb) / 2) # this calculation for type stability with vector endpoints
ret = get_prototype(prob) * (prod(ub - lb) / 2) # this calculation for type stability with vector endpoints
hcubature(_f, lb, ub;
rtol = reltol, atol = abstol, buffer = cache.cacheval,
maxevals = maxiters, norm = alg.norm,
Expand Down

0 comments on commit 74e4def

Please sign in to comment.