MCPcopy Create free account
hub / github.com/numpy/numpy / test_legpow

Method test_legpow

numpy/polynomial/tests/test_legendre.py:101–108  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

99 assert_equal(trim(res), trim(tgt), err_msg=msg)
100
101 def test_legpow(self):
102 for i in range(5):
103 for j in range(5):
104 msg = f"At i={i}, j={j}"
105 c = np.arange(i + 1)
106 tgt = reduce(leg.legmul, [c] * j, np.array([1]))
107 res = leg.legpow(c, j)
108 assert_equal(trim(res), trim(tgt), err_msg=msg)
109
110
111class TestEvaluation:

Callers

nothing calls this directly

Calls 2

assert_equalFunction · 0.90
trimFunction · 0.70

Tested by

no test coverage detected