Part (b)
f[x_]:=((x^2+1)^3+1)^4
Factor[D[f[x],x]]