We mostly do not worry about deriving these each time. That's why they're memorized or looked up if needed. You can use the triangle to derive the derivative of arctan.
Differentiate the right equation implicitly:
It follows from the triangle that:
And so, from , we have