#include <bits/stdc++.h>
using namespace std;
int main() {
  long long n, t, d;
  cin >> t;
  while (t--) {
    long long ans = 0;
    cin >> n >> d;
    bool l = 0;
    for (long long i = max(0ll, (n - 1) / 2 - 10); i <= (n - 1) / 2 + 10; ++i) {
      if (i + (d + i) / (i + 1) <= n) {
        l = 1;
        break;
      }
    }
    if (l)
      cout << "YES" << endl;
    else {
      cout << "NO" << endl;
    }
  }
  return 0;
}
