f(x) = 3.0 * sin(x) + x^(2.0) / 5.0
h = Derivative(f)
p = If(h(x) < 0.0, f(x))
q = If(h(x) > 0.0, f(x))