added deriv_R_theta