diff --git a/tests/test_generating_functions.py b/tests/test_generating_functions.py index c275025..08294bc 100644 --- a/tests/test_generating_functions.py +++ b/tests/test_generating_functions.py @@ -36,7 +36,7 @@ def test_lubich_bdf_weights( eoc = EOCRecorder(order=order) a, b = 0.0, 1.0 - s = order + s = 0 from math import gamma @@ -44,10 +44,14 @@ def test_lubich_bdf_weights( t = np.linspace(a, b, n) h = t[1] - t[0] w = lubich_bdf_weights(-alpha, order, n) - omega = np.fromiter( - lubich_bdf_starting_weights(w, s, -alpha, beta=1.0), - dtype=np.dtype((w.dtype, s)), - ).reshape(-1, s) + + if s > 0: + omega = np.fromiter( + lubich_bdf_starting_weights(w, s, -alpha, beta=1.0), + dtype=np.dtype((w.dtype, s)), + ) + else: + omega = np.zeros_like(w) int_ref = t**alpha / gamma(1 + alpha) int_bdf = np.empty_like(int_ref)