$\cos x = kx$, finding $k$ that gives two solutions $\cos x = 0.3x$ has three solutions. $\cos x = 0.4x$ has one solution. How to find $k$ so that $\cos x = kx$ has two solutions?
 A: By symmetry we can assume $a>0$.
By IVT there is a solution between $0$ and $\frac{\pi}{2}$. You want a second solution $x_0$.
This means that $ax$ will be tangent to $\cos(x)$ at $x_0$, otherwise you can prove there is another solution.
Thus $\cos(x_0)=ax_0$ and $-\sin(x_0)=a$. Hence $a^2(x_0^2+1)=1$. Which means that 
$$x_0$ must be the solution to
$$\cos(x_0)= \frac{x_0}{\sqrt{x_0^2+1}}$$, between $\frac{3\pi}{2}$ and $2\pi$.
Then $a=\frac{1}{\sqrt{x_0^2+1}}$.
Geometrically, this is the point so that $ax$ is tangent to the second "mountain" of $\cos(x)$.
The equation unfortunately seems to be impossible to solve exactly, but you can approximate the solution. 
$%edits must have at least 6 characters, blah blah blah...$
A: For a certain value of $k$ (I am assuming $k$ here is nonnegative), the line $kx$ will be tangent to the cosine curve. If you find that critical value of $k$ (call it $k^\ast$), any value of $k$ within the interval $[0,k^\ast)$ will yield a line that intersects the cosine more than twice.
Assembling the equation of the tangent line at $x=u$ gives
$$y=-(\sin\,u)(x-u)+\cos\,u$$
We thus need the value of $u$ that zeroes the $y$-intercept; i.e., the value of $u$ that satisfies the equation
$$u=-\cot\,u$$
Unfortunately, there is no closed form expression for $u$. Numerical computations indicate that $u\approx -2.79838604578388713672024890314$, corresponding to the critical slope $k^\ast=-\sin\,u\approx 0.33650841691839529161631981441$.

