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;
const long double PI = acos((long double)-1.0);
struct Point {
  long double x, y;
  Point() { x = y = 0.0; }
  Point(long double x, long double y) : x(x), y(y) {}
  Point operator+(Point a) { return Point(x + a.x, y + a.y); }
  Point operator-(Point a) { return Point(x - a.x, y - a.y); }
  Point operator*(long double k) { return Point(x * k, y * k); }
  long double sqlen() { return x * x + y * y; }
  long double len() { return sqrt(sqlen()); }
  void read() { cin >> x >> y; }
  void print() { cout << x << ' ' << y << endl; }
} P, Q;
struct Line {
  long double a, b, c;
  Point A, B;
  Line(Point A, Point B) : A(A), B(B) {
    a = B.y - A.y;
    b = A.x - B.x;
    c = -(a * A.x + b * A.y);
  }
  long double f(Point A) { return a * A.x + b * A.y + c; }
};
long double vp, v, r;
long double ab(long double x) {
  if (x < 0)
    return -x;
  else
    return x;
}
long double mysqrt(long double x) {
  if (ab(x) < 1e-9) x = 0;
  return sqrt(x);
}
bool order(Point A, Point B, Point C) {
  return ab((C - A).len() - (B - A).len() - (C - B).len()) < 1e-6;
}
vector<Point> cut(Line l, long double r) {
  long double a = l.a * l.a + l.b * l.b;
  long double b = 2 * l.b * l.c;
  long double c = l.c * l.c - l.a * l.a * r * r;
  long double delta = b * b - 4 * a * c;
  vector<Point> res;
  res.clear();
  if (ab(delta) < 1e-9) {
    delta = 0;
    long double x, y;
    y = -b / 2 / a;
    x = mysqrt(r * r - y * y);
    if (l.f(Point(x, y)) < 1e-3) {
      if (order(l.A, Point(x, y), l.B)) res.push_back(Point(x, y));
    } else {
      if (order(l.A, Point(-x, y), l.B)) res.push_back(Point(-x, y));
    }
  } else if (delta > 0) {
    long double x, y;
    y = (-b + sqrt(delta)) / 2 / a;
    x = mysqrt(r * r - y * y);
    if (ab(l.f(Point(x, y))) < 1e-3) {
      if (order(l.A, Point(x, y), l.B)) res.push_back(Point(x, y));
    } else {
      if (order(l.A, Point(-x, y), l.B)) res.push_back(Point(-x, y));
    }
    y = (-b - sqrt(delta)) / 2 / a;
    x = mysqrt(r * r - y * y);
    if (ab(l.f(Point(x, y))) < 1e-3) {
      if (order(l.A, Point(x, y), l.B)) res.push_back(Point(x, y));
    } else {
      if (order(l.A, Point(-x, y), l.B)) res.push_back(Point(-x, y));
    }
  }
  return res;
}
void refine(long double &d) {
  while (d > 2 * PI) d -= 2 * PI;
  while (d < 0) d += 2 * PI;
}
long double cirlen(long double alpha1, long double alpha2) {
  long double d = alpha1 - alpha2;
  refine(d);
  long double res = r * d;
  d = 2 * PI - d;
  refine(d);
  return min(res, r * d);
}
long double dist(Point Q, Point M) {
  Line l(Q, M);
  vector<Point> cur = cut(l, r);
  if (cur.size() < 2) return (Q - M).len();
  long double res = 0.0;
  res += sqrt(Q.sqlen() - r * r);
  res += sqrt(M.sqlen() - r * r);
  long double alpha1 = atan2(Q.y, Q.x);
  long double alpha2 = atan2(M.y, M.x);
  res +=
      min(min(cirlen(alpha1 + acos(r / Q.len()), alpha2 + acos(r / M.len())),
              cirlen(alpha1 + acos(r / Q.len()), alpha2 - acos(r / M.len()))),
          min(cirlen(alpha1 - acos(r / Q.len()), alpha2 + acos(r / M.len())),
              cirlen(alpha1 - acos(r / Q.len()), alpha2 - acos(r / M.len()))));
  return res;
}
bool check(long double t) {
  long double R = P.len();
  long double alpha = atan2(P.y, P.x);
  long double tc = 2 * PI * R / vp;
  alpha += t / tc * 2 * PI;
  Point M(R * cos(alpha), R * sin(alpha));
  if (dist(Q, M) / v < t + 1e-9)
    return true;
  else
    return false;
}
int main() {
  ios ::sync_with_stdio(false);
  P.read();
  cin >> vp;
  Q.read();
  cin >> v >> r;
  cout << (fixed) << setprecision(10);
  long double res = 1e100, l = 0, r = 1e9;
  for (int turn = 0, _a = (1000); turn < _a; turn++) {
    long double mid = (l + r) / 2.0;
    if (check(mid)) {
      res = mid;
      r = mid;
    } else {
      l = mid;
    }
  }
  cout << res << endl;
  return 0;
}