Consider ABCD as a rectangle which is inscribed in a circle having O as centre and a as radius
Now join OC where ∠COX = θ
So the co-ordinate of C are (a cos θ, a sin θ)
We get OM = a cos θ, MC = a sin θ
BC = 2MC = 2a and CD = 2OM = 2a cos θ
It can be written as
P = 2a(cos θ + sin θ)
By differentiating w.r.t. x
Here, P is maximum at θ = π/4
BC = √2a = CD