title: Calculate the volume from a sequence of points in N^2
body: <p>Given a sequence of <code>(integer, integer)</code> points, say <code>(p1, ..., pn)</code>, which define the lines <code>(p_i, p_i+1)</code> for <code>1 &lt;= i &lt; n</code>, plus the line <code>(p_n, p_1)</code>. The resulting lines have the additional property that they don't intersect pairwise. What would be the best way to calculate the resulting volume? </p>