Question: Tricky calculation for a simple equation

The equation tan(y) = 2*tan(x) defines y implicitly as a function of x.  Well, perphas "defines" is too strong a word, since there are multiple solutions for y.  However, if I am not mistaken, there exists a unique continuous solution y(x) that goes through the origin, that is, y(0)=0, and is defined for all x.

Question 1: How do we plot the graph of y(x)?

I have a roundabout solution as follows.  Differentiate the equation tan(y(x)) = 2*tan(x) with respect to x and arrive at a first order differential equation in y(x).  Solve the differential equation with the initial condition y(0)=0.  Surprisingly, Maple obtains an explicit solution:

which we can plot:

plot(rhs(%), x=0..2*Pi);

Question 2: Is there a neat way of getting that solution with algebra only, without appealing to differential equations?

 

Please Wait...