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