#include <bits/stdc++.h>
using namespace std;
struct Point {
  long long x, y;
  Point() { x = y = 0; }
  Point(int _x, int _y) : x(_x), y(_y) {}
};
const int NMAX = 500000;
Point polygon[2 * NMAX + 1], psum[2 * NMAX + 1];
long long n;
int l, r;
unsigned long long last;
long long ans;
const long long MOD = 1e9 + 7;
long long dot(int i, int j) {
  return ((polygon[i].x * polygon[j].y - polygon[j].x * polygon[i].y));
}
long long dot_raw(const Point& p, const Point& q) {
  return p.x * q.y - p.y * q.x;
}
long long tot, base;
long long hcnt;
long long msum(long long a, long long b) {
  a %= MOD, b %= MOD;
  long long ret = a + b;
  ret %= MOD;
  while (ret < 0) ret += MOD;
  ret %= MOD;
  return ret;
}
long long mmult(long long a, long long b) {
  a %= MOD, b %= MOD;
  long long ret = a * b % MOD;
  while (ret < 0) ret += MOD;
  ret %= MOD;
  return ret;
}
Point get_sum(int L, int R) {
  return Point(msum(psum[R].x, -psum[L - 1].x),
               msum(psum[R].y, -psum[L - 1].y));
}
void go() {
  while (1) {
    unsigned long long nxt = last;
    nxt += dot(r, r + 1) + dot(r + 1, l) + dot(l, r);
    if (nxt * 2 <= tot) {
      if (nxt * 2 == tot) {
        hcnt++;
        return;
      } else {
        last = nxt;
        r++;
        base = msum(base, last % MOD);
      }
    } else
      return;
  }
}
int main() {
  cin.sync_with_stdio(0), cout.sync_with_stdio(0);
  cin >> n;
  polygon[0] = (Point(0, 0));
  for (int i = 1; i <= n; i++) {
    long long x, y;
    cin >> x >> y;
    polygon[i] = (Point(x, y));
  }
  reverse(polygon + 1, polygon + n + 1);
  for (int i = 1; i <= n; i++) polygon[i + n] = (polygon[i]);
  psum[0] = (Point(0, 0));
  for (int i = 1; i <= 2 * n; i++)
    psum[i] = (Point(msum(psum[i - 1].x, polygon[i].x),
                     msum(psum[i - 1].y, polygon[i].y)));
  for (int i = 1; i <= n; i++) tot += dot(i, i + 1);
  r = 1;
  for (int i = 1; i <= n; i++) {
    l = i;
    go();
    ans = msum(ans, base);
    base = msum(base, -(mmult(dot(l, l + 1), r - l)));
    base = msum(base, dot_raw(get_sum(l + 1, r),
                              Point(msum(polygon[l + 1].x, -polygon[l].x),
                                    msum(polygon[l + 1].y, -polygon[l].y))));
    last -= dot(l, l + 1) + dot(l + 1, r) + dot(r, l);
  }
  long long ret = mmult(tot, n * (n - 3) / 2);
  for (int i = 0; i < 2; i++) ret = msum(ret, -ans);
  for (int i = 0; i < hcnt; i++) {
    ret = msum(ret, -tot / 2);
  }
  cout << ret;
}
