#include <bits/stdc++.h>
using namespace std;
struct Point {
  double x, y;
  Point() {}
  Point(double x, double y) : x(x), y(y) {}
  Point operator+(const Point &p) const { return Point(x + p.x, y + p.y); }
  Point operator-(const Point &p) const { return Point(x - p.x, y - p.y); }
  Point operator*(const double &k) const { return Point(x * k, y * k); }
  bool operator==(const Point &p) const {
    return ((fabs(x - p.x) < (1e-8)) && (fabs(y - p.y) < (1e-8)));
  }
};
double dot(const Point &a, const Point &b) { return a.x * b.x + a.y * b.y; }
double cross(const Point &a, const Point &b) { return a.x * b.y - b.x * a.y; }
double norm(const Point &p) { return dot(p, p); }
double abs(const Point &p) { return sqrt(norm(p)); }
double dist(const Point &a, const Point &b) {
  return sqrt(pow(a.x - b.x, 2) + pow(a.y - b.y, 2));
}
Point rotate90(const Point &p) { return Point(-p.y, p.x); }
int ccw(const Point &p0, const Point &p1, const Point &p2) {
  Point a = p1 - p0;
  Point b = p2 - p0;
  if (cross(a, b) > (1e-8)) return +1;
  if (cross(a, b) < -(1e-8)) return -1;
  if (dot(a, b) < -(1e-8)) return +2;
  if (norm(a) < norm(b)) return -2;
  return +0;
}
struct Segment {
  Point s, t;
  Segment() {}
  Segment(Point s, Point t) : s(s), t(t) {}
};
bool isIntersectLL(const Segment &a, const Segment &b) {
  return (abs(cross(a.t - a.s, b.t - b.s)) > (1e-8) ||
          abs(cross(a.t - a.s, b.t - b.s)) < (1e-8));
}
Point crosspointLL(const Segment &a, const Segment &b) {
  Point va = a.t - a.s, vb = b.t - b.s;
  double d = cross(vb, va);
  if (abs(d) < (1e-8)) return b.s;
  return a.s + va * cross(vb, b.t - a.s) * (1.0 / d);
}
struct Circle {
  Point p;
  double r;
  Circle() {}
  Circle(Point p, double r) : p(p), r(r) {}
};
vector<Point> tangentCP(const Circle &c, const Point &p) {
  double x = norm(p - c.p), d = x - c.r * c.r;
  if (d < -(1e-8)) return vector<Point>();
  d = max(d, 0.0);
  Point p1 = (p - c.p) * (c.r * c.r / x);
  Point p2 = rotate90((p - c.p) * (-c.r * sqrt(d) / x));
  vector<Point> res;
  res.push_back(c.p + p1 - p2);
  res.push_back(c.p + p1 + p2);
  return res;
}
bool isIntersectSP(const Segment &s, const Point &p) {
  return (ccw(s.s, s.t, p) == +0);
}
Point projection(const Segment &s, const Point &p) {
  Point b = s.t - s.s;
  double t = dot(p - s.s, b) / norm(b);
  return s.s + b * t;
}
double distanceSP(const Segment &s, const Point &p) {
  Point r = projection(s, p);
  if (isIntersectSP(s, r)) return abs(r - p);
  return min(abs(s.s - p), abs(s.t - p));
}
bool isIntersectCS(const Circle &c, const Segment &l) {
  double d = distanceSP(l, c.p);
  return (d < c.r - (1e-8));
}
struct edge {
  int to, cap, rev;
  double cost;
  edge(int to, int cap, int rev, double cost)
      : to(to), cap(cap), rev(rev), cost(cost) {}
};
int V, prevv[300], preve[300];
double h[300], dst[300];
vector<edge> G[300];
void add_edge(int from, int to, int cap, double cost) {
  G[from].push_back(edge(to, cap, G[to].size(), cost));
  G[to].push_back(edge(from, 0, G[from].size() - 1, -cost));
}
double min_cost_flow(int s, int t, int f) {
  double res = 0;
  fill(h, h + V, 0);
  while (f > 0) {
    priority_queue<pair<double, int>, vector<pair<double, int> >,
                   greater<pair<double, int> > >
        Q;
    fill(dst, dst + V, 1e9);
    dst[s] = 0;
    Q.push(pair<double, int>(0, s));
    while (!Q.empty()) {
      pair<double, int> p = Q.top();
      Q.pop();
      int v = p.second;
      if (dst[v] < p.first) continue;
      for (int i = 0; i < (int)G[v].size(); i++) {
        edge &e = G[v][i];
        if (e.cap > 0 &&
            dst[e.to] > dst[v] + e.cost + h[v] - h[e.to] + (1e-8)) {
          dst[e.to] = dst[v] + e.cost + h[v] - h[e.to];
          prevv[e.to] = v;
          preve[e.to] = i;
          Q.push(pair<double, int>(dst[e.to], e.to));
        }
      }
    }
    if (dst[t] == 1e9) return -1;
    for (int v = 0; v < V; v++) {
      h[v] += dst[v];
    }
    int d = f;
    for (int v = t; v != s; v = prevv[v]) {
      d = min(d, G[prevv[v]][preve[v]].cap);
    }
    f -= d;
    res += d * h[t];
    for (int v = t; v != s; v = prevv[v]) {
      edge &e = G[prevv[v]][preve[v]];
      e.cap -= d;
      G[v][e.rev].cap += d;
    }
  }
  return res;
}
int main() {
  int N;
  vector<Circle> c(2);
  cin >> N;
  for (int i = 0; i < 2; i++) {
    cin >> c[i].p.x >> c[i].p.y >> c[i].r;
  }
  vector<Point> r(N), b(N);
  for (int i = 0; i < N; i++) {
    cin >> r[i].x >> r[i].y;
  }
  for (int i = 0; i < N; i++) {
    cin >> b[i].x >> b[i].y;
  }
  int S = N * 2, T = S + 1;
  V = N * 2 + 2;
  for (int i = 0; i < N; i++) {
    for (int j = 0; j < N; j++) {
      Segment s(r[i], b[j]);
      double d = 1e9;
      if (!isIntersectCS(c[0], s) && !isIntersectCS(c[1], s)) {
        d = min(d, dist(r[i], b[j]));
      }
      for (int k = 0; k < 2; k++) {
        for (int l = 0; l < 2; l++) {
          vector<Point> vp1 = tangentCP(c[k], r[i]);
          vector<Point> vp2 = tangentCP(c[l], b[j]);
          for (int m = 0; m < (int)vp1.size(); m++) {
            for (int n = 0; n < (int)vp2.size(); n++) {
              Segment l1(r[i], vp1[m]), l2(b[j], vp2[n]);
              if (r[i] == vp1[m]) {
                Point p1 = vp1[m] - c[k].p;
                l1.t = vp1[m] + rotate90(p1);
              }
              if (b[j] == vp2[n]) {
                Point p2 = vp2[n] - c[l].p;
                l2.t = vp2[n] + rotate90(p2);
              }
              if (isIntersectLL(l1, l2)) {
                Point cp = crosspointLL(l1, l2);
                Segment s1(r[i], cp), s2(b[j], cp);
                if (!isIntersectCS(c[k], s1) && !isIntersectCS(c[l], s2) &&
                    !isIntersectCS(c[1 - k], s1) &&
                    !isIntersectCS(c[1 - l], s2)) {
                  d = min(d, dist(r[i], cp) + dist(b[j], cp));
                }
              }
            }
          }
        }
      }
      if (d != 1e9) add_edge(i, j + N, 1, d);
    }
  }
  for (int i = 0; i < N; i++) {
    add_edge(S, i, 1, 0);
    add_edge(i + N, T, 1, 0);
  }
  double res = min_cost_flow(S, T, N);
  if (res == -1) {
    cout << "Impossible" << endl;
  } else {
    printf("%.10f\n", res);
  }
  return 0;
}
