k = 25 (slider from 0 to 25, step 1)
f(x) = (((-k)) / 6 * x^(3)) + (k / 8 * x^(2))
gL: -0.1
amax: 6
Text1: "f_{" + (LaTeX[k]) + "}"
gU: -0.1
gO: 1
gR: 0.6
f0(x) = If[0 ≤ x ≤ 0.5, f(x)]
f0k(x) = If[¬(0 ≤ x ≤ 0.5), f(x)]
Text2: "f_{\color{red}{" + (LaTeX[k]) + "}}(x) = -\frac{{\color{red}{" + (LaTeX[k]) + " }}}{6}x^3 + \frac{{\color{red}{ " + (LaTeX[k]) + " }}}{8}x^2"
g(t, x) = ((-1 / 6 * t) * x^(3)) + ((1 / 8 * t) * x^(2))
g1(t, x) = ((-1 / 2 * t) * x^(2)) + ((1 / 4 * t) * x)