acosθ+bsinθ=c ...(1)
acos2θ+bsin2θ+2asinθcosθ=c
a(1+cos2θ)2+b(1−cos2θ)2+asin2θ=c
a+acos2θ+b−bcos2θ+2asin2θ=2c
(a−b)cos2θ+2asin2θ=2c−(a+b) ...(2)
Squaring (1) on both sides
a2cos2θ+b2sin2θ+absin2θ=c2
a2(1+cos2θ)2+b2(1−cos2θ)2+absin2θ=c2
(a2−b2)cos2θ+2absin2θ=2c2−(a2+b2) ....(3)
From equation (2) sin2θ=[2c−(a+b)]−[(a−b)cos2θ]2a
putting in (3)
(a2−b2)cos2θ+b[(2c−(a+b))−((a−b)cos2θ)]=2c2−a2−b2
(a2−b2)cos2θ+b[2c−a−b−(a−b)cos2θ]=2c2−a2−b2
(a2−b2)cos2θ+2bc−ab−b2−b(a−b)cos2θ=2c2−a2−b2
a2cos2θ−b2cos2θ+2bc−ab−abcos2θ+b2cos2θ=2c2−a2
(a2−ab)cos2θ=2c2−a2+ab−2bc
cos2θ=2c2−a2+ab−2bca2−ab=2c2−2bc−(a2−ab)a2−ab
cos2θ=2c(c−b)a(a−b)−1
θ=12cos−1(2c(c−b)a(a−b)−1)