Skip to content

Commit 97ce2eb

Browse files
Fix HaltonSampling
In 0.2.10 of QuasiMonteCarlo they changed the interface in a patch release breaking functionality.
1 parent 033b978 commit 97ce2eb

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ FiniteDifferences = "0.12"
3535
Formatting = "0.4"
3636
Mustache = "1.0"
3737
Primes = "0.5"
38-
QuasiMonteCarlo = "0.2.4"
38+
QuasiMonteCarlo = "0.2.10"
3939
Reexport = "0.2, 1.0"
4040
Symbolics = "4"
4141
julia = "1.6, 1.7, 1.8"

src/simulations/montecarlo.jl

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,9 @@ end
5454
function qmc_samples(sim::HaltonSampling, rvs::Integer)
5555
coprimes = [prime(i) for i in 1:rvs]
5656
return transpose(
57-
QuasiMonteCarlo.sample(sim.n, zeros(rvs), ones(rvs), LowDiscrepancySample(coprimes))
57+
QuasiMonteCarlo.sample(
58+
sim.n, zeros(rvs), ones(rvs), LowDiscrepancySample(coprimes, false)
59+
),
5860
)
5961
end
6062

0 commit comments

Comments
 (0)