#include <bits/stdc++.h>
using namespace std;
template <typename T>
void out(T x) {
  cout << x << endl;
  exit(0);
}
const int maxn = 2e3 + 10;
int n, m;
bool viz[maxn][maxn];
long double dp[maxn][maxn];
long double f(int r, int c) {
  if (r < 0 || c < 0) return 0;
  if (r == 0 && c == 0) return 0;
  if (viz[r][c]) return dp[r][c];
  viz[r][c] = true;
  return dp[r][c] = (n * n + f(r - 1, c - 1) * r * c +
                     f(r - 1, c) * r * (n - c) + f(r, c - 1) * c * (n - r)) /
                    (n * n - (n - r) * (n - c));
}
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cout << fixed << setprecision(12);
  cin >> n >> m;
  set<int> rows, cols;
  for (int i = 0; i < m; i++) {
    int r, c;
    cin >> r >> c;
    rows.insert(r);
    cols.insert(c);
  }
  cout << f(n - int(rows.size()), n - int(cols.size())) << endl;
  return 0;
}
