Problem: Qwerty the Ranger arrived to the Diatar system with a very important task. He should deliver a special carcinogen for scientific research to planet Persephone. This is urgent, so Qwerty has to get to the planet as soon as possible. A lost day may fail negotiations as nobody is going to pay for an overdue carcinogen.

You can consider Qwerty's ship, the planet Persephone and the star Diatar points on a plane. Diatar is located in the origin of coordinate axes — at point (0, 0). Persephone goes round Diatar along a circular orbit with radius R in the counter-clockwise direction at constant linear speed vp (thus, for instance, a full circle around the star takes <image> of time). At the initial moment of time Persephone is located at point (xp, yp).

At the initial moment of time Qwerty's ship is at point (x, y). Qwerty can move in any direction at speed of at most v (v > vp). The star Diatar is hot (as all stars), so Qwerty can't get too close to it. The ship's metal sheathing melts at distance r (r < R) from the star.

Find the minimum time Qwerty needs to get the carcinogen to planet Persephone.

Input

The first line contains space-separated integers xp, yp and vp ( - 104 ≤ xp, yp ≤ 104, 1 ≤ vp < 104) — Persephone's initial position and the speed at which it goes round Diatar.

The second line contains space-separated integers x, y, v and r ( - 104 ≤ x, y ≤ 104, 1 < v ≤ 104, 1 ≤ r ≤ 104) — The intial position of Qwerty's ship, its maximum speed and the minimum safe distance to star Diatar.

It is guaranteed that r2 < x2 + y2, r2 < xp2 + yp2 and vp < v.

Output

Print a single real number — the minimum possible delivery time. The answer will be considered valid if its absolute or relative error does not exceed 10 - 6.

Examples

Input

10 0 1
-10 0 2 8


Output

9.584544103

Input

50 60 10
50 60 20 40


Output

0.000000000

Solution (in CPP):

Solution:
#include <bits/stdc++.h>
using namespace std;
template <class F, class T>
T convert(F a, int p = -1) {
  stringstream ss;
  if (p >= 0) ss << fixed << setprecision(p);
  ss << a;
  T r;
  ss >> r;
  return r;
}
template <class T>
void db(T a, int p = -1) {
  if (p >= 0) cout << fixed << setprecision(p);
  cout << a << " ";
}
template <class T>
T gcd(T a, T b) {
  T r;
  while (b != 0) {
    r = a % b;
    a = b;
    b = r;
  }
  return a;
}
template <class T>
T lcm(T a, T b) {
  return a / gcd(a, b) * b;
}
template <class T>
T sqr(T x) {
  return x * x;
}
template <class T>
T cube(T x) {
  return x * x * x;
}
template <class T>
struct Triple {
  T x, y, z;
  Triple() {}
  Triple(T _x, T _y, T _z) : x(_x), y(_y), z(_z) {}
};
template <class T>
Triple<T> euclid(T a, T b) {
  if (b == 0) return Triple<T>(1, 0, a);
  Triple<T> r = euclid(b, a % b);
  return Triple<T>(r.y, r.x - a / b * r.y, r.z);
}
template <class T>
int getbit(T s, int i) {
  return (s >> i) & 1;
}
template <class T>
T onbit(T s, int i) {
  return s | (T(1) << i);
}
template <class T>
T offbit(T s, int i) {
  return s & (~(T(1) << i));
}
template <class T>
int cntbit(T s) {
  return s == 0 ? 0 : cntbit(s >> 1) + (s & 1);
}
const int bfsz = 1 << 16;
char bf[bfsz + 5];
int rsz = 0;
int ptr = 0;
char gc() {
  if (rsz <= 0) {
    ptr = 0;
    rsz = fread(bf, 1, bfsz, stdin);
    if (rsz <= 0) return EOF;
  }
  --rsz;
  return bf[ptr++];
}
void ga(char& c) {
  c = EOF;
  while (!isalpha(c)) c = gc();
}
int gs(char s[]) {
  int l = 0;
  char c = gc();
  while (isspace(c)) c = gc();
  while (c != EOF && !isspace(c)) {
    s[l++] = c;
    c = gc();
  }
  s[l] = '\0';
  return l;
}
template <class T>
bool gi(T& v) {
  v = 0;
  char c = gc();
  while (c != EOF && c != '-' && !isdigit(c)) c = gc();
  if (c == EOF) return false;
  bool neg = c == '-';
  if (neg) c = gc();
  while (isdigit(c)) {
    v = v * 10 + c - '0';
    c = gc();
  }
  if (neg) v = -v;
  return true;
}
const double PI = 2 * acos(0);
const string months[] = {"January",   "February", "March",    "April",
                         "May",       "June",     "July",     "August",
                         "September", "October",  "November", "December"};
const int days[] = {31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31};
const int dr[] = {-1, 0, +1, 0};
const int dc[] = {0, +1, 0, -1};
const int inf = (int)1e9 + 5;
const long long linf = (long long)1e16 + 5;
const double eps = 1e-9;
struct Point {
  double x, y;
  double dis() { return sqrt(sqr(x) + sqr(y)); }
};
Point P, A, B;
double vp, va, r;
double kc(Point X, Point Y) { return sqrt(sqr(X.x - Y.x) + sqr(X.y - Y.y)); }
bool getLine(Point p0, Point p1, double& a, double& b, double& c) {
  a = p1.y - p0.y;
  b = p0.x - p1.x;
  c = -(a * p0.x + b * p0.y);
}
Point Intersect(Point p0, Point p1, Point p2, Point p3) {
  double a0, b0, c0, a1, b1, c1;
  getLine(p0, p1, a0, b0, c0);
  getLine(p2, p3, a1, b1, c1);
  double d = a0 * b1 - a1 * b0;
  double dx = b0 * c1 - b1 * c0;
  double dy = -(c1 * a0 - c0 * a1);
  Point p4;
  p4.x = dx / d;
  p4.y = dy / d;
  return p4;
}
Point giao(Point X, double R, Point Y) {
  Point res1, res2;
  double goc = atan2(X.y, X.x);
  double add = acos(R / sqrt(sqr(X.x) + sqr(X.y)));
  double goc1 = goc + add, goc2 = goc - add;
  res1.x = R * cos(goc1);
  res1.y = R * sin(goc1);
  res2.x = R * cos(goc2);
  res2.y = R * sin(goc2);
  if (kc(Y, res1) < kc(Y, res2))
    return res1;
  else
    return res2;
}
double disCir(Point X, Point Y, double R) {
  double gocX = atan2(X.y, X.x);
  double gocY = atan2(Y.y, Y.x);
  double goc = abs(gocX - gocY);
  if (goc > PI) goc = PI + PI - goc;
  return R * goc;
}
double dis(Point X, Point Y, double R) {
  if (abs(X.x - Y.x) < eps && abs(X.y - Y.y) < eps) return 0;
  double area = 0.5 * ((X.x - Y.x) * (X.y + Y.y) + (Y.x - 0) * (Y.y + 0) +
                       (0 - X.x) * (X.y + 0));
  area = abs(area);
  if (area / kc(X, Y) * 2 >= R ||
      (X.dis() * X.dis() + kc(X, Y) * kc(X, Y) < Y.dis() * Y.dis()) ||
      (Y.dis() * Y.dis() + kc(X, Y) * kc(X, Y) < X.dis() * X.dis()))
    return kc(X, Y);
  Point X1 = giao(X, R, Y);
  Point Y1 = giao(Y, R, X);
  return kc(X, X1) + kc(Y, Y1) + disCir(X1, Y1, R);
}
bool thoaman(double x) {
  double R = sqrt(sqr(P.x) + sqr(P.y));
  double gP = atan2(P.y, P.x);
  double time = 2 * PI * R / vp;
  double gocadd = ((x / time) - int(x / time)) * 2 * PI;
  double goc = gP + gocadd;
  B.x = R * cos(goc);
  B.y = R * sin(goc);
  double d = dis(A, B, r);
  if (d <= va * x) return true;
  return false;
}
int main() {
  cin >> P.x >> P.y >> vp;
  cin >> A.x >> A.y >> va >> r;
  double u = 0, v = 1e9, mid;
  for (typeof(1000) run = 0; run < (1000); ++run) {
    mid = (u + v) / 2;
    if (thoaman(mid))
      v = mid;
    else
      u = mid;
  }
  printf("%.12lf\n", u);
  return 0;
}