#include <bits/stdc++.h>
using namespace std;
long long int a[3], first, sum;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(0);
  for (int i = 0; i < 3; i++) cin >> a[i], sum += a[i];
  cin >> first;
  long long int ans = (first + 3) * (first + 2) / 2 * (first + 1) / 3;
  for (long long int s = sum; s <= sum + first; s++) {
    for (int i = 0; i < 3; i++) {
      long long int mn[3];
      for (int j = 0; j < 3; j++)
        if (i ^ j)
          mn[j] = a[j];
        else
          mn[j] = max(a[j], (s + 1) / 2);
      long long int ss = s - mn[0] - mn[1] - mn[2] + 3;
      if (ss >= 3) ans -= (ss - 1) * (ss - 2) / 2;
    }
  }
  cout << ans << '\n';
  return 0;
}
