i tried over and over again but could never find and understand how to solve this problem. please help.

Write a function that accepts two arguments, integer n and real number x, computes the following series, and returns the computed result:

1 - 2(x^2)/1! + 3(x^4)/2! - 4(x^6)/3! + ... + [(-1)^n](n+1)(x^2n)/n!

here are some answers when computing.

n= 3 10 15 20

x= 2 2 2 2

Ans= -25.666668 0.865679 -0.057734 -0.054947