#include <bits/stdc++.h>
using namespace std;
int main() {
  int n, m;
  scanf("%d %d", &n, &m);
  double res = 1.0 / (double)n;
  if (n * m > 1)
    res +=
        (((double)(n - 1) / (double)n) * (double)(m - 1) / (double)(n * m - 1));
  printf("%.10lf\n", res);
  return 0;
}
