Doug C. answered 01/22/19
Math Tutor with Reputation to make difficult concepts understandable
Looks like you are intending to find y'' given then y = xcosx - 3cosx.
To find y' apply the product rule to the first term followed by the derivative of -3cosx
Realize that the product rule for that first term gives x(cosx) + sinx. .
So, y' = x(cosx) + sinx +3sinx = xcosx + 4sinx.
Follow the same pattern to get y''.
y'' = x (-sinx) + cosx + 4cosx = 5cosx -xsinx
Using the product rule and knowing the derivative of sinx and cosx is the key to solving this problem.