k = 12.7 (slider from 0 to 30, step 0.1)
P(x) = If[x > 0, ((-x^(2)) + (8 * x)) / k]