#include <bits/stdc++.h>
using namespace std;
int n, m;
double f[2100 + 1][2100 + 1];
bool r[2100 + 1], c[2100 + 1];
int main(int argc, char *argv[]) {
  ios ::sync_with_stdio(false);
  cin >> n >> m;
  for (int i = 1; i <= m; ++i) {
    int x, y;
    cin >> x >> y;
    r[x] = true, c[y] = true;
  }
  int rc = 0, cc = 0;
  for (int i = 1; i <= n; ++i) {
    if (r[i]) ++rc;
    if (c[i]) ++cc;
  }
  f[n][n] = 0.0;
  for (int i = n; i >= rc; --i)
    for (int j = n; j >= cc; --j) {
      if (i == n && j == n) continue;
      double c = (double)i * j / n / n;
      if (i < n) c += (f[i + 1][j] + 1) * (n - i) * j / n / n;
      if (j < n) c += (f[i][j + 1] + 1) * i * (n - j) / n / n;
      if (i < n && j < n)
        c += (f[i + 1][j + 1] + 1) * (n - i) * (n - j) / n / n;
      c /= 1 - (double)i * j / n / n;
      f[i][j] = c;
    }
  cout << fixed << setprecision(10) << f[rc][cc] << endl;
  fclose(stdin);
  fclose(stdout);
  return 0;
}
