Skip to content

Commit

Permalink
Use interior nodes only for more fair test
Browse files Browse the repository at this point in the history
  • Loading branch information
unalmis committed Sep 17, 2024
1 parent 6a46efb commit bd68679
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions tests/test_integrals.py
Original file line number Diff line number Diff line change
Expand Up @@ -910,14 +910,13 @@ class TestBounce1DQuadrature:
[
(True, tanh_sinh(40), None),
(False, tanh_sinh(20), None),
# Node density near boundary is (1−x²)⁻¹.
# Node density near boundary is 1/(1−x²).
(True, leggauss(25), auto_sin),
(True, _chebgauss1(30), auto_sin),
# Lobatto nodes
(False, leggauss_lob(10), auto_sin),
(False, chebgauss2(10), auto_sin),
# Node density near boundary is (1−x²)⁻⁰ᐧ⁵.
(False, leggauss_lob(14), None),
(False, leggauss_lob(8, interior_only=True), auto_sin),
# Node density near boundary is 1/√(1−x²).
(False, leggauss_lob(13, interior_only=True), None),
(False, chebgauss2(8), None),
],
)
Expand Down Expand Up @@ -968,7 +967,7 @@ def test_bounce_quadrature(self, is_strong, quad, automorphism):
automorphism,
check=True,
)
result = bounce.integrate(integrand, pitch_inv, check=True, plot=True)
result = bounce.integrate(integrand, pitch_inv, check=True, plot=False)
assert np.count_nonzero(result) == 1
np.testing.assert_allclose(result.sum(), truth, rtol=1e-4)

Expand Down

0 comments on commit bd68679

Please sign in to comment.