Cartesian to Polar

import numpy as np
a = np.random.random((5, 2))
print(a)
[[0.41729967 0.55329891]
 [0.31500693 0.89985254]
 [0.90188216 0.05144744]
 [0.71672937 0.65142741]
 [0.29806038 0.55515573]]
b, c = a[:, 0], a[:, 1]
print(b)
[0.41729967 0.31500693 0.90188216 0.71672937 0.29806038]
print(c)
[0.55329891 0.89985254 0.05144744 0.65142741 0.55515573]
d = np.sqrt(b**2 + c**2)
print(d)
[0.69302142 0.95339601 0.90334837 0.96853428 0.63010941]
# 
e = np.arctan2(c, b)
print(e)
[0.92461076 1.23406355 0.05698277 0.73770448 1.07807011]