f(x) = ax^3+bx^2+cx+d find a,b,c,d so that the function has a local maximum at f(-1) = 2 and has a local minimum at f(1) = -1
Substitute the two values of x (-1 and 1) into the given equation, and with the two given function values, that gets you two equations.
Differentiate f(x) and substitute x = -1 and x = 1 and put both equal to zero (since x = -1 and x = 1 are to be max/min points).
That gets you two more equations, and you should be able to solve those for a,b,c and d.
(The two equations from the derivative give you the value of b immediately).
We know that :
a(-1)^3 + b(-1)^2 + c(-1)b+ d = 2 simplifiy
-1a + b - c + d = 2 (1)
Also
a(1)^3 + b(-1)^2 + c(1) + d = -1 simplify
a + b + c + d = -1 (2)
Adding (1) and (2), we have
2b + 2d = 1 (3)
Subtracting (1) and (2), we have
-2a - 2c = 3 (4)
Taking the derivative, we get
f' (x) = 3ax^2 + 2bx + c
And f'(-1) = 0 .....so we have
3a(-1)^2 + 2b(-1) + c = 0
3a - 2b + c = 0 (5)
And f' (1) = 0 ........so we have
3a(1)^2 + 2b(1) + c = 0
3a + 2b + c = 0 (6)
Add (5) and (6)
6a + 2c = 0 (7)
Add (4) and (7) and we get that
4a = 3 so.....a = 3/4
Using (7)
6(3/4) + 2c = 0
9/2 = -2c
-9/4 = c
Using (6)
3(3/4)+ 2b - 9/4 = 0
So.....b = 0
Using (3)
2b + 2d = 1
2b + 2(0) = 1
2b = 1
b = 1/2
So.....the function is....
f(x) = (3/4)x^3 - (9/4)x + 1/2
Here's the graph : https://www.desmos.com/calculator/nffnruhqfi