Perform operations on vectors.5. (+) Multiply a vector by a scalar.a. Represent scalar multiplication graphically by scaling vectors and possibly reversing their direction; perform scalar multiplication component-wise, e.g., as c(vx, vy) = (cvx, cvy).b. Compute the magnitude of a scalar multiple cv using || cv || = | c |v. Compute the direction of cv knowing that when | c |v ≠ 0, the direction of cv is either along v (for c > 0) or against v (for c < 0).