NG:
def F(z, tau): return z + 1 / 2 * np.sin(2 * z) - pi / 2 * tau
OK:
def F(z, tau): return z + 1. / 2. * np.sin(2 * z) - pi / 2 * tau
1 / 2 is 0 in C, python and ruby. JSer and PHPer don't cry
1 / 2
Recommended Posts