#include <bits/stdc++.h>
#pragma comment(linker, "/STACK:16777216")
using namespace std;
const double eps = 1e-9;
const double pi = acos(-1.0);
double cross(double a, double b, double l, double r) {
  return max(0.0, min(b, r) - max(a, l));
}
int main() {
  int nf, ne, ns;
  cin >> nf >> ne >> ns;
  double rf, re, rs;
  cin >> rf >> re >> rs;
  double df, de;
  cin >> df >> de;
  rf = sqrt(rf * rf - 1);
  re = sqrt(re * re - 1);
  rs = sqrt(rs * rs - 1);
  int n = nf + ne + ns;
  int all = (1 << n) - 1;
  double ans = 0.0;
  for (int mask = 0; mask <= all; mask++)
    if (__builtin_popcountll(mask) == ns) {
      double tot = 0.0;
      vector<double> u;
      int sub = mask ^ all;
      for (int i = 0; i < n; i++)
        if (sub & (1 << i)) {
          int x = i / 2;
          double dff = df * rf * 2.0;
          double dee = de * re * 2.0;
          for (int j = 0; j < n; j++)
            if (mask & (1 << j)) {
              int y = j / 2;
              dff += cross(x - rf, x + rf, y - rs, y + rs) * df;
              dee += cross(x - re, x + re, y - rs, y + rs) * de;
            }
          tot += dff;
          u.push_back(dff - dee);
        }
      sort((u).begin(), (u).end());
      for (int i = 0; i < ne; i++) {
        tot -= u[i];
      }
      ans = max(ans, tot);
    }
  printf("%.9lf\n", ans);
  return 0;
}
