BA *BC =15

Reactangle

GJ = a =f(x[i]) =4

HI =  b =f(x[i+1]) =6

x[i}

x{i+1]

distance (x[i],x[i+1]) =h =KL-MN = 4

KL -MN = x[i+1] -x[i]

f(x[i])

f(x[i+1])

Area = (x[i+1]-x[i])/2*(f(x[i+1])+f(x[i]))

Area = h/2*(f(x[i+1])+f(x[i]))

Area = 4/2*(6+4) = 20

A = (-10, 6)
B = (-10, 3)
C = (-5, 3)
D = (-5, 6)
q1, a, b, c, d = Polygon(A, B, C, D)
distanceBC = Distance(B, C)
TextBC: Name[B] + (Name[C]) + " = " + distanceBC
distanceBA = Distance(B, A)
TextBA: Name[B] + (Name[A]) + " = " + distanceBA
Textq1: "Area of  " + (Name[A]) + (Name[B]) + (Name[C]) + (Name[D]) + " = " + q1
Pointq1 = PointIn(q1)
E = (-21.31980668264258, -13.237688076296791)
F = (-3.2598066826425782, -13.237688076296791)
G = Point(xAxis)
H = Point(xAxis)
I = (8, 6)
J = (4, 4)
q2, j, i, h, g = Polygon(J, I, H, G)
Textq2: "Area of  " + (Name[J]) + (Name[I]) + (Name[H]) + (Name[G]) + " = " + q2
Pointq2 = PointIn(q2)
K = Point(yAxis)
L = (8, -2)
M = Point(yAxis)
N = (4, -4)
distanceKL = Distance(K, L)
TextKL: Name[K] + (Name[L]) + " = " + distanceKL
distanceMN = Distance(M, N)
TextMN: Name[M] + (Name[N]) + " = " + distanceMN
u = Vector(K, L)
v = Vector(M, N)
w = Vector(G, J)
e = Vector(H, I)