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