#include <bits/stdc++.h>
using namespace std;
int main() {
  long long l;
  vector<long long> v(3, 0);
  cin >> v[0] >> v[1] >> v[2];
  cin >> l;
  sort(v.begin(), v.end());
  long long n = (l + 1);
  n = n * (l + 2);
  n = n * (l + 3);
  n = n / 6;
  long long resp = 0;
  long long a = 0;
  for (long long la = 0; la <= l; la++) {
    long long x = min(v[2] - v[1] - v[0] + la, l - la);
    if (x >= 0) {
      a = x + 1;
      a = a * (x + 2);
      a = a / 2;
      resp += a;
    }
  }
  for (long long la = 0; la <= l; la++) {
    long long x = min(v[1] - v[2] - v[0] + la, l - la);
    if (x >= 0) {
      a = x + 1;
      a = a * (x + 2);
      a = a / 2;
      resp += a;
    }
  }
  for (long long la = 0; la <= l; la++) {
    long long x = min(v[0] - v[2] - v[1] + la, l - la);
    if (x >= 0) {
      a = x + 1;
      a = a * (x + 2);
      a = a / 2;
      resp += a;
    }
  }
  cout << n - resp << endl;
  return 0;
}
