#include <bits/stdc++.h>
using namespace std;
const int N = 1e6 + 7;
const int M = 48;
const int inf = 1e9 + 7;
const long long base = 1e18;
const double pi = acos(-1);
const double ep = 1e-9;
int a, b, c, l;
long long ans = 0;
int main() {
  cin >> a >> b >> c >> l;
  for (int i = 0; i < l + 1; i++) {
    long long r = l - i + 1;
    ans += (long long)r * (r + 1) / 2;
  }
  for (int i = 0; i < l + 1; i++) {
    int a1 = a + i;
    int r = a1 - b - c;
    if (r >= 0) {
      r = min(r, l - i);
      ans -= ((long long)r + 1) * ((long long)r + 2) / 2;
    }
    r = b + i - a - c;
    if (r >= 0) {
      r = min(r, l - i);
      ans -= ((long long)r + 1) * ((long long)r + 2) / 2;
    }
    r = c + i - a - b;
    if (r >= 0) {
      r = min(r, l - i);
      ans -= ((long long)r + 1) * ((long long)r + 2) / 2;
    }
  }
  cout << ans;
}
