This will just be a linear interpolation.
H = height of whole trapezium
h = vertical distance from bottom edge you want to measure the width at
b = with of bottom edge
t = width of top edge
w(h) = the width at a given height h
w(h) = b + h * (t-b) / H