First, you need to find the derivative of this function. This is done by multiplying the exponent of the variable by the coefficient, and then reducing the exponent by 1.
f'(x)=3x^2-3
Now, set this function equal to 0 to find x-values of the relative max and min.
0=3x^2-3
0=3(x^2-1)
0=3(x+1)(x-1)
x=-1, 1
To determine which is the max and which is the min, plug in values to f'(x) that are greater than and less than each. We will use -2, 0, 2.
f'(-2)=3(-2)^2-3=3(4)-3=12-3=9
f'(0)=3(0)^2-3=3(0)-3=0-3=-3
f'(2)=3(2)^2=3(4)-3=12-3=9
We examine the sign changes to determine whether it is a max or a min. If the sign goes from + to -, then it is a maximum. If it goes from - to +, it is a minimum. Therefore, x=-1 is a relative maximum and x=1 is a relative miminum.
To determine the values of the relative max and min, plug in the x-values to f(x).
f(-1)=(-1)^3-3(-1)+1=-1+3+1=3
f(1)=(1)^3-3(1)+1=1-3+1=-1
Hope this helps!!