#include <bits/stdc++.h>
using namespace std;
double f[1005][1005], ans;
int n, m, N;
int main() {
  scanf("%d %d", &n, &m);
  N = n * m;
  f[1][1] = 1;
  for (int i = 2; i <= n; i++)
    for (int j = 1; j <= i; j++)
      f[j][i] = f[j - 1][i - 1] * (m - j + 1) / (N - i + 1) +
                f[j][i - 1] * (N - i + 1 - m + j) / (N - i + 1);
  for (int i = 1; i <= m; i++) ans += f[i][n] * i;
  printf("%.9lf\n", ans / n);
  return 0;
}
