Let f(x)=4x+4 and g(x)=x^2+x-1.Evaluate the following.

c. g(-2)=-2^2-2-1=-4-3=-7
f. g(a+1)=a^2+4a
Is c right? and f I got the wrong answer.

nope on c. (-2)^2=4

g(a+1)=(a+1)^2+a+1 -1=a^2+2a+1+a=a^2+3a+1

g(x)=x^2+x-1

g(-2) = (-2)^2 + (-2) - 1
= 4 - 2 - 1
= 1

g(a+1) = (a+1)^2 + (a+1) - 1
= a^2 + 2a + 1 + a + 1 - 1
= a^2 + 3a

To evaluate the function g(-2), you correctly substituted -2 into the equation for x. However, there seems to be a slight error in the calculation.

The correct calculation for g(-2) is as follows:

g(-2) = (-2)^2 + (-2) - 1
= 4 - 2 - 1
= 1

So, the correct answer for g(-2) is 1, not -7.

Now let's evaluate f(g(a+1)):

f(g(a+1)) = f((a+1)^2 + (a+1) - 1)

First, we need to simplify the expression inside g(a+1) before evaluating it.

g(a+1) = (a+1)^2 + (a+1) - 1
= a^2 + 2a + 1 + a + 1 - 1
= a^2 + 3a + 1

Now, substitute this simplified expression into f(x):

f(g(a+1)) = f(a^2 + 3a + 1)

Applying the equation for f(x):

f(g(a+1)) = 4(a^2 + 3a + 1) + 4
= 4a^2 + 12a + 4 + 4
= 4a^2 + 12a + 8

So, the correct answer for f(g(a+1)) is 4a^2 + 12a + 8, not a^2 + 4a.