#include <bits/stdc++.h>
using namespace std;
long long read() {
  long long w = 0, f = 1;
  char c = ' ';
  while (c < '0' || c > '9') c = getchar(), f = c == '-' ? -1 : f;
  while (c >= '0' && c <= '9') w = w * 10 + c - 48, c = getchar();
  return w * f;
}
struct node {
  long long u, v, w;
  node() { u = v = w = 0; }
  node(long long U, long long V, long long W) { u = U, v = V, w = W; }
} e[2005 * 2005], ae[2005];
long long n, m, x[2005], y[2005], c[2005], k[2005], f[2005], cnt1, cnt2,
    fd[2005];
long long find(long long x) { return f[x] == x ? x : f[x] = find(f[x]); }
signed main() {
  n = read();
  for (long long i = 1; i <= n; i++) x[i] = read(), y[i] = read();
  for (long long i = 1; i <= n; i++) c[i] = read();
  for (long long i = 1; i <= n; i++) k[i] = read();
  for (long long i = 1; i <= n; i++)
    for (long long j = i + 1; j <= n; j++)
      e[++m] =
          node(i, j, (k[i] + k[j]) * (abs(x[i] - x[j]) + abs(y[i] - y[j])));
  for (long long i = 1; i <= n; i++) e[++m] = node(i, n + 1, c[i]);
  for (long long i = 1; i <= n + 1; i++) f[i] = i;
  sort(e + 1, e + m + 1, [&](node x, node y) { return x.w < y.w; });
  long long ans = 0, now = 0;
  for (long long i = 1; i <= m; i++) {
    if (find(e[i].u) == find(e[i].v)) continue;
    ans += e[i].w, now++;
    if (e[i].v == n + 1)
      fd[++cnt1] = e[i].u;
    else
      ae[++cnt2] = node(e[i].u, e[i].v, 0);
    f[find(e[i].u)] = find(e[i].v);
    if (now == n) break;
  }
  printf("%lld\n", ans);
  printf("%lld\n", cnt1);
  for (long long i = 1; i <= cnt1; i++)
    printf("%lld%c", fd[i], i == cnt1 ? '\n' : ' ');
  printf("%lld\n", cnt2);
  for (long long i = 1; i <= cnt2; i++) printf("%lld %lld\n", ae[i].u, ae[i].v);
  return 0;
}
