import numpy as np
from numpy_core import positions

pe = positions(4, 8)
np.testing.assert_allclose(pe[0, 0::2], 0)
np.testing.assert_allclose(pe[0, 1::2], 1)
np.testing.assert_allclose((pe ** 2).sum(axis=-1), 4)

robot = np.arange(8, dtype=float) / 8
at_zero = robot + pe[0]
at_three = robot + pe[3]
assert not np.allclose(at_zero, at_three)
print(pe.shape)  # (4, 8)
