Finding solutions in an interval for a basic tangent, cotangent, secant, or cosecant equation