Equation of parabola that passes through two points and vertex has coordinates ($x_v$, $0$)

algebra-precalculusgraphing-functionsquadratics

I can't solve the last exercises in a worksheet of Pre-Calculus problems. It says:

Quadratic function $f(x)=ax^2+bx+c$ determines a parabola that passes through points $(0, 2)$ and $(4, 2)$, and its vertex has coordinates $(x_v, 0)$.

a) Calculate coordinate $x_v$ of parabola's vertex.

b) Calculate $a, b$ and $c$ coefficients.

How can I get parabola's equation with this information and find what is requested?

I would appreciate any help. Thanks in advance.

Best Answer

Since $f(0)=c$ and we are given $f(0)=2$, we see immediately that $c=2.$

Furthermore, the equation in vertex form is $f(x)=a(x-x_v)^2+k$,

and since we are given $f(x_v)=0$, we see that $k=0,$ i.e., $f(x)=a(x-x_v)^2$.

From $a(x-x_v)^2=ax^2+bx+2$ we see that $ax_v^2 = 2$ and $-2ax_v=b.$

Since $f(4)=f(0)=2$, $(4-x_v)^2=x_v^2$, which means $x_v=2$. Thus $a=\frac12$ and $b=-2.$