# Geometric proof for sum of arctangent identity

## weblog/

Today a colleague showed me an interesting trigonometric identity: atan(α) + atan(β) = atan( (α + β) / (1 - αβ) ) We couldn't come up with a geometric interpretation immediately, but I found a pretty nice understanding. Begin by first recalling what atan(α) measures: the angle θα between the x-axis and some point (xα,yα): atan(α) = atan(yα/xα) = θα The distance of the point (xα,yα) to the origin doesn't matter, since the angle will be the same. Thus we can always normalize (xα,yα) to be unit length or otherwise. When we look at the identity at the top then, we see that the left-hand side is really summing angles:
 atan(α) + atan(β) = atan( (α + β) / (1 - αβ) ) atan(yα/xα) + atan(yβ/xβ) = θα + θβ = = θ? = atan(y?/x?)
And this means the the numerator and denominator inside the atan in right-hand side are telling us the y and x values respectively of some point (x?,y?) along the ray with angle θ? = θα + θβ. To see how we arrive at these particular values for x? and y? we can make a couple assumptions. Without loss of generality assume that xα = 1. If not we can always divide both xα and yα by xα without changing θα or atan(yα/xα) or atan(α). Also, w.l.o.g. assume that xβ = sqrt( xα² + yα² ), that is, the length of (xα,yα) as a vector, for short let's write this xβ = ‖xαyα‖. This illustration shows vectors (xα,yα) and (xβ,yβ).

Now, notice that we can sum θα and θβ by rotating the vector (xβ,yβ) by θα and reading off the angle θ? = θα + θβ. Because we've chosen our lengths carefully, this is very easy.

Because xβ = ‖xαyα‖, we just need to move yβ units in the direction perpendicular to the vector (xα,yα). In other words:
 (x?,y?) = (xα,yα) + yβ (xα,yα)⟂ / ‖xαyα‖ = (xα,yα) + yβ (-yα,xα) / ‖xαyα‖ = (1,yα) + yβ (-yα,1) / xβ
where we immediately simplify the known quantities. Recall that: α = yα / xα = yα and β = yβ / xβ, and now consider each coordinate separately:
 y? = yα + yβ/xβ = α + β x? = 1 - yβyα/xβ = 1 + α β