\text{Drag slider and point C to change their colors.}

\text{https://www.geogebra.org/m/t6v92Gdz#material/mB5juDuN}

a = 2 (slider from -4 to 4, step 0.5)
b = -1.5 (slider from -4 to 4, step 0.5)
f = Polynomial((a * x) + b)
zero: ((-b)) / a
Z: (zero, 0)
c = Integral(f, -50, zero)
d = Integral(f, zero, 50)
P = (-1, 2)
s = 1 (slider from 0 to 1, step 0.1)
A = (3, -5)
B = (10, -5)
l = Segment(A, B)
C = Point(l)
g = Segment(A, C)