Concept used
(p−q)2=p2−2pq+q2,(p+q)2=p2+2pq+q2,sin2θ+cos2θ=1
Squaring the two equations and adding makes the cross terms ∓2xysinθcosθ cancel, and the identity then removes θ completely.
Given:
xcosθ−ysinθ=a...(i),xsinθ+ycosθ=b...(ii)
Step 1 — Square (i).
x2cos2θ−2xysinθcosθ+y2sin2θ=a2
Step 2 — Square (ii).
x2sin2θ+2xysinθcosθ+y2cos2θ=b2
Step 3 — Add the two results. The terms −2xysinθcosθ and +2xysinθcosθ cancel:
x2cos2θ+x2sin2θ+y2sin2θ+y2cos2θ=a2+b2
x2(cos2θ+sin2θ)+y2(sin2θ+cos2θ)=a2+b2
Step 4 — Use sin2θ+cos2θ=1.
x2×1+y2×1=a2+b2⇒x2+y2=a2+b2
Hence proved.
Note: quick check with θ=0∘: (i) gives a=x and (ii) gives b=y, so a2+b2=x2+y2 ✓.