y = -2x + 2

y = 1 - x

y=ax^2-(2a+2)x+a+2

a\in R,\quad a\ne 0

P = (1, 0)
a = 1 (slider from -5 to 5, step 1)
f(x) = a * x^(2.0) - (2.0 * a + 2.0) * x + a + 2.0
A = Extremum(f)