Chain rule:
If y = f(t) and t = g(x) then dy/dx = dy/dt x dt/dx
Let y = cos x3
If t = x3 then cos x3= cos t or y = cos t
dy/dt = -sin t
dt/dx = 3x2
Now,
dy/dx = dy/dt x dt/dx = 3 x2 (-sin t)
Substituting the value of t back, we get
dy/dx = 3 x2 (-sin x3)
= -3 x2 sin x3