Given
#costheta+sintheta=sqrt2costheta#
Following the formula
#(a+b)^2+(a-b)^2=2(a^2+b^2)#
we can wite
#(costheta+sintheta)^2+(costheta-sintheta)^2=2(cos^2theta+sin^2theta)#
Putting
#costheta+sintheta=sqrt2costheta" "# we get
#(sqrt2costheta)^2+(costheta-sintheta)^2=2*1#
#=>2cos^2theta+(costheta-sintheta)^2=2*1#
#=>(costheta-sintheta)^2=2-2cos^2theta#
#=>(costheta-sintheta)^2=2(1-cos^2theta)#
#=>(costheta-sintheta)^2=2sin^2theta#
#=>costheta-sintheta=sqrt2sintheta#
Proved
In other way when
#costheta-sintheta=sqrt2sintheta" "# we get
#(costheta+sintheta)^2+(sqrt2sintheta)^2=2*1#
#=>(costheta+sintheta)^2 + 2sin^2theta =2#
#=>(costheta+sintheta)^2=2-2sin^2theta#
#=>(costheta+sintheta)^2=2(1-sin^2theta)#
#=>(costheta+sintheta)^2=2cos^2theta#
#=>costheta+sintheta=sqrt2costheta#
Proved