#include <bits/stdc++.h>
using namespace std;
long long cross(pair<int, int> a, pair<int, int> b) {
  return 1LL * a.first * b.second - 1LL * a.second * b.first;
}
long long ccw(pair<int, int> a, pair<int, int> b, pair<int, int> c) {
  pair<int, int> p = pair<int, int>(b.first - a.first, b.second - a.second);
  pair<int, int> q = pair<int, int>(c.first - a.first, c.second - a.second);
  return cross(p, q);
}
long long dot(pair<int, int> a, pair<int, int> b) {
  return 1LL * a.first * b.first + 1LL * a.second * b.second;
}
double dist(pair<int, int> a, pair<int, int> b) {
  int dx = a.first - b.first;
  int dy = a.second - b.second;
  return sqrt(1LL * dx * dx + 1LL * dy * dy);
}
int N;
pair<int, int> P[40010];
long long psum[80010];
long long area(int l, int r) {
  if (l > r) r += N;
  if (l == 0) l += N, r += N;
  return abs(psum[r - 1] - psum[l - 1] + cross(P[r % N], P[l % N]));
}
double calc(int l, int r) {
  int m = (l + 1) % N;
  double c = dist(P[l], P[r]);
  pair<int, int> p =
      pair<int, int>(P[m].first - P[l].first, P[m].second - P[l].second);
  pair<int, int> q =
      pair<int, int>(P[r].first - P[l].first, P[r].second - P[l].second);
  double Cos = (double)dot(p, q) / dist(pair<int, int>(0, 0), p) /
               dist(pair<int, int>(0, 0), q);
  double Sin = (double)cross(p, q) / dist(pair<int, int>(0, 0), p) /
               dist(pair<int, int>(0, 0), q);
  return c * c * Cos * abs(Sin);
}
double ans;
void solve() {
  for (int i = 0; i < 2 * N; i++) {
    psum[i] = cross(P[i % N], P[(i + 1) % N]);
    if (i) psum[i] += psum[i - 1];
  }
  int pos = 1;
  for (int i = 0; i < N; i++) {
    int j = (i + 1) % N;
    while (1) {
      int nxt = (pos + 1) % N;
      pair<int, int> p =
          pair<int, int>(P[i].first - P[j].first, P[i].second - P[j].second);
      pair<int, int> q = pair<int, int>(P[nxt].first - P[pos].first,
                                        P[nxt].second - P[pos].second);
      if (dot(p, q) >= 0)
        break;
      else
        pos = nxt;
    }
    double tmp = calc(i, pos) - area(i, pos);
    ans = min(ans, tmp);
  }
}
int main() {
  scanf("%d", &N);
  for (int i = 0; i < N; i++) {
    scanf("%d %d", &P[i].first, &P[i].second);
  }
  for (int i = 0; i < N; i++) {
    int j = (i + 1) % N;
    int k = (i + 2) % N;
    pair<int, int> p =
        pair<int, int>(P[i].first - P[j].first, P[i].second - P[j].second);
    pair<int, int> q =
        pair<int, int>(P[k].first - P[j].first, P[k].second - P[j].second);
    if (dot(p, q) >= 0) {
      printf("0");
      return 0;
    }
  }
  ans = 1e18;
  solve();
  reverse(P, P + N);
  solve();
  ans /= 2;
  cout << fixed;
  cout.precision(20);
  cout << ans;
}
