MCPcopy Index your code
hub / github.com/matplotlib/matplotlib / test_real_roots_in_01

Function test_real_roots_in_01

lib/matplotlib/tests/test_bezier.py:27–31  ·  view source on GitHub ↗
(roots, expected_in_01)

Source from the content-addressed store, hash-verified

25 ([0.3, 0.3], [0.3, 0.3]), # repeated root
26])
27def test_real_roots_in_01(roots, expected_in_01):
28 roots = np.array(roots)
29 coeffs = np.poly(roots)[::-1] # np.poly gives descending, we need ascending
30 result = _real_roots_in_01(coeffs.real)
31 assert_allclose(result, expected_in_01, atol=1e-10)
32
33
34@pytest.mark.parametrize("coeffs", [[5], [0, 0, 0]])

Callers

nothing calls this directly

Calls 1

_real_roots_in_01Function · 0.90

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…