Let y=(sinx−cosx)(sinx−cosx)
Taking logarithm on both the sides, we obtain
logy=log[(sinx−cosx)(sinx−cosx)]
⇒logy=(sinx−cosx).log(sinx−cosx)
Differentiating both sides with respect to x, we obtain
1ydydx=ddx[(sinx−cosx).log(sinx−cosx)
⇒1ydydx=log(sinx−cosx).ddx(sinx−cosx)+(sinx−cosx).ddxlog(sinx−cosx)
⇒1ydydx=log(sinx−cosx).(cosx+sinx)+(sinx−cosx).1(sinx−cosx).ddx(sinx−cosx)
⇒dydx=(sinx−cosx)sinx−cosx[(cosx+sinx).log(sinx−cosx)+(cosx+sinx)]
∴dydx=(sinx−cosx)(sinx−cosx)(cosx+sinx)[1+log(sinx−cosx)]