Calculate sin, cos, tan, inverse trig, and convert between degrees and radians.
NumPy provides full trigonometric capabilities (`np.sin`, `np.cos`, `np.tan`, `np.arcsin`, etc.) that expect angles expressed in radians.
Trigonometric functions in NumPy compute the entire sine wave for 10,000 points simultaneously, enabling instant signal processing.
NumPy trig functions take inputs in radians. Use `np.radians(degrees)` or `np.degrees(radians)` to convert.
s = np.sin(np.radians(90))np.sin(90) # Evaluates 90 radians instead of 90 degreesnp.sin(np.radians(90))Passing raw degrees into `np.sin()` assumes radians, resulting in incorrect calculations.
Solve the objective below using NumPy vectorized syntax
Create `arr = np.array([0, np.pi/2])`, compute `np.sin(arr)`, and print.
[0. 1.]