qiskit-community/qiskit-community-tutorials

Missing invocation of np.sin in custom_feature_map.ipynb

emanouil opened this issue · 0 comments

It seems to me the definition of custom_data_map_func in custom_feature_map.ipynb
does not correspond to the mathematical expression.

coeff = x[0] if len(x) == 1 else functools.reduce(lambda m, n: m * n, np.pi - x)

gives the default function, when it should be
coeff = x[0] if len(x) == 1 else functools.reduce(lambda m, n: m * n, np.sin(np.pi - x))

to be consistent with the text.