Skip to content

Commit 74e4def

Browse files
committed
get_prototype for HCubatureJL
1 parent 9a39c80 commit 74e4def

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Integrals.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ function __solvebp_call(cache::IntegralCache, alg::HCubatureJL, sensealg, domain
217217
rtol = reltol, atol = abstol, buffer = cache.cacheval,
218218
maxevals = maxiters, norm = alg.norm, initdiv = alg.initdiv)
219219
else
220-
ret = _f((lb + ub) / 2) * (prod(ub - lb) / 2) # this calculation for type stability with vector endpoints
220+
ret = get_prototype(prob) * (prod(ub - lb) / 2) # this calculation for type stability with vector endpoints
221221
hcubature(_f, lb, ub;
222222
rtol = reltol, atol = abstol, buffer = cache.cacheval,
223223
maxevals = maxiters, norm = alg.norm,

0 commit comments

Comments
 (0)