#include <bits/stdc++.h>
using namespace std;
long long run(long long a, long long b, long long c, long long l) {
  long long ret = 0;
  for (int i = max(b + c, a); i <= a + l; ++i) {
    long long rem = max(0LL, l - (i - a));
    rem = min(rem, i - (b + c));
    ret += ((rem + 1) * (rem + 2)) / 2;
  }
  return ret;
}
int main() {
  long long a, b, c, l;
  cin >> a >> b >> c >> l;
  long long ans = ((l + 3) * (l + 2) * (l + 1)) / 6;
  ans -= run(a, b, c, l);
  ans -= run(b, a, c, l);
  ans -= run(c, a, b, l);
  cout << ans << endl;
  return 0;
}
