#include<bits/stdc++.h>
using namespace std;
#define ll long long
#define int long long
#define ii pair<ll,ll>
#define iii pair<ii,ll>
#define fi first
#define se second
#define endl '\n'
#define debug(x) cout << #x << " is " << x << endl

#define pub push_back
#define pob pop_back
#define puf push_front
#define pof pop_front
#define lb lower_bound
#define ub upper_bound

#define all(x) (x).begin(),(x).end()
#define sz(x) (int)(x).size()

inline ll read() {
	ll s=0;
	char ch=getchar();
	while(ch<48||ch>57)ch=getchar();
	while(ch>47&&ch<58)s=(s<<1)+(s<<3)+(ch^48),ch=getchar();
	return s;
}


signed main() {
	ios::sync_with_stdio(0);cin.tie(0);cout.tie(0);cin.exceptions(ios::badbit | ios::failbit);
//	freopen("input.txt", "r", stdin);
	int t;
	cin>>t;
	while(t--){
		int n, x, t;
		cin>>n>>x>>t;
		ll res = 0;
		if(x > t){
			cout<<0<<endl;
			continue;
		}
		else if(x == t){
			cout<<n-1<<endl;
			continue;
		}
		else{
			int w = t/x;
			res += 1LL*min(w, n-1)*(min(w, n-1)+1)/2;
			res += max(0*1LL, 1LL*(n-w-1)*(w));
			cout<<res<<endl;
			continue;
		}
		
	}

	return 0;
}

