g(x)=(x+1)^2

g(x) = -(x^(2.0) + 2.0 * x + 1.0)
p(x) = x^(2.0) + 2.0 * x + 1.0
t = Function(p(x), 0.0, 2.0)
r = Function(g(x), 0.0, 2.0)
A = (2, 9)
B = (2, -9)
C = (0, 9)
D = (0, -9)
a = Segment(A, C)
b = Segment(A, B)
c = Segment(B, D)
e = Integral(t, 0.0, 2.0)
d = Integral(r, 0.0, 2.0)