Equivalent of j in NumPy
In Python, 1j or 0+1j is a literal of complex type. You can broadcast that into an array using expressions, for example In [17]: 1j * np.arange(5) Out[17]: array([ 0.+0.j, 0.+1.j, 0.+2.j, 0.+3.j, 0.+4.j]) Create an array from literals: In [18]: np.array([1j]) Out[18]: array([ 0.+1.j]) Note that what Michael9 posted creates a complex, not a … Read more