#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  long long n;
  cin >> n;
  vector<pair<long long, long long>> v(n);
  for (long long i = 0; i < n; i++) {
    cin >> v[i].first >> v[i].second;
  }
  if (n % 2 != 0) {
    cout << "No";
    return 0;
  }
  long long xo = v[0].first + v[n / 2].first;
  long long yo = v[0].second + v[n / 2].second;
  for (long long i = 0; i < n / 2; i++) {
    long long x1 = v[i].first + v[i + n / 2].first;
    long long y1 = v[i].second + v[i + n / 2].second;
    if (x1 != xo || y1 != yo) {
      cout << "No";
      return 0;
    }
  }
  cout << "Yes";
  return 0;
}
