def rotate(self, angles): """ dftvector.rotate(angles): Rotate dftvector.components by the angles in the array 'angles' (radians) and return the newly rotated vector. """ return self.components * umath.exp(complex(0.0, 1.0) * angles)
def rotate_components(components, angles): return components * umath.exp(complex(0.0, 1.0) * angles)