#include <bits/stdc++.h>
using namespace std;
int main(int argc, char* argv[]) {
  int n;
  cin >> n;
  vector<pair<int, int> > arr(n);
  for (int i = 0; i < n; i++) {
    cin >> arr[i].first >> arr[i].second;
  }
  if (n % 2) {
    cout << "no" << endl;
    return 0;
  }
  vector<int> l1, l2, l3, l4;
  for (int i = 0; i < n - 1; i++) {
    l1.push_back(arr[i].first);
    l2.push_back(arr[i].second);
    l3.push_back(arr[i + 1].first);
    l4.push_back(arr[i + 1].second);
  }
  l1.push_back(arr[n - 1].first);
  l2.push_back(arr[n - 1].second);
  l3.push_back(arr[0].first);
  l4.push_back(arr[0].second);
  int flag = 1;
  for (int i = 0; i < n / 2; i++) {
    int j = i + n / 2;
    int pay1 = l1[i] - l3[i];
    int payda1 = l2[i] - l4[i];
    int par1 = 1;
    if (pay1 < 0) {
      par1 *= -1;
      pay1 *= -1;
    }
    if (payda1 < 0) {
      par1 *= -1;
      payda1 *= -1;
    }
    int pay2 = l1[j] - l3[j];
    int payda2 = l2[j] - l4[j];
    int par2 = 1;
    if (pay2 < 0) {
      par2 *= -1;
      pay2 *= -1;
    }
    if (payda2 < 0) {
      par2 *= -1;
      payda2 *= -1;
    }
    if (pay1 == 0 || payda1 == 0) par1 = 0;
    if (pay2 == 0 || payda2 == 0) par2 = 0;
    if (pay1 != pay2 || payda1 != payda2 || par1 != par2) flag = 0;
  }
  if (flag) {
    cout << "yes" << endl;
  } else {
    cout << "no" << endl;
  }
}
