Firstly,

`d/(dx)cos\ x^2=-2x\ sin\ x^2`

So

`(dy)/(dx)=(-2x\ sin\ x^2)/(cos\ x^2)=-2x\ tan\ x^2`