From 7789cfbcbf0aeef69a50a9bc543a28fca69a9e1a Mon Sep 17 00:00:00 2001 From: Mike Ingold Date: Mon, 2 Dec 2024 15:00:40 -0500 Subject: [PATCH] Simplify to address inaccurate results --- src/integral.jl | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/integral.jl b/src/integral.jl index eb080673..d0bbee73 100644 --- a/src/integral.jl +++ b/src/integral.jl @@ -76,10 +76,8 @@ function _integral( # Get Gauss-Legendre nodes and weights of type FP for a region [-1,1]ᴺ xs, ws = FastGaussQuadrature.gausslegendre(N) - xsT = Iterators.map(FP, xs) - wsT = Iterators.map(FP, ws) - weights = Iterators.product(ntuple(Returns(wsT), N)...) - nodes = Iterators.product(ntuple(Returns(xsT), N)...) + weights = Iterators.product(ntuple(Returns(FP.(ws)), N)...) + nodes = Iterators.product(ntuple(Returns(FP.(xs)), N)...) # Domain transformation: x [-1,1] ↦ t [0,1] t(x) = (1 // 2) * x + (1 // 2)