alright
so we have a set of points
any quadratic function can be represeted by the form
y=ax²+bx+c
where a, b, and c are all constants
sometimes we use f(x) instead of y
anyway
we can find the values of a, b, and c by subsituting the points
ok
for (-2,-20)
x=-2 and y=-20
-20=a(-2)²+b(-2)+c or
-20=4a-2b+c
for (0,-4)
x=0 and y=-4
-4=a(0)²+b(0)+c
-4=c
neato
we can subsitute -4 for c later to find a and b later
using (4,-20)
x=4 and y=-20
(at this point we notice that (-2,-20) and (4,-20) have same y values so the x value of the vertex will be the midpoint of the 2 x values which is at x=1 and we can do math to find the other things but whatever)
x=4 and y=-20
-20=a(4)²+b(4)+c
-20=16a+4b+c
alright
we've got
-20=4a-2b+c
-4=c
-20=16a+4b+c
usinb -4=c
-20=4a-2b-4
-20=16a+4b-4
add 4 to everybody
-16=4a-2b
-16=16a+4b
elimination
multiply top equation by 2 and add to 2nd equation
-32=8a-4b
-16=16a+4b +
-48=24a+0b
-48=24a
divide both sides by 24
-2=a
sub back into one of the equations
-16=4a-2b
-16=4(-2)-2b
-16=-8-2b
add 8
-8=-2b
divide by -2 both sides
4=b
a=-2
b=4
c=-4
y=-2x²+4x-4
or
f(x)=-2x²+4x-4