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