#include <bits/stdc++.h>
using namespace std;
long long x[2005], y[2005];
long long k[2005], c[2005];
vector<pair<long long, pair<long long, long long> > > edges;
vector<pair<long long, long long> > two, fin;
vector<long long> one;
struct DSU {
  int connected;
  int par[200005], sz[200005];
  void init(int n) {
    for (int i = 0; i <= n; i++) {
      par[i] = i;
      sz[i] = 1;
    }
    connected = n;
  }
  int getPar(int k) {
    while (k != par[k]) {
      par[k] = par[par[k]];
      k = par[k];
    }
    return k;
  }
  int getSize(int k) { return sz[getPar(k)]; }
  void unite(int u, int v) {
    int par1 = getPar(u), par2 = getPar(v);
    if (par1 == par2) return;
    connected--;
    if (sz[par1] > sz[par2]) swap(par1, par2);
    sz[par2] += sz[par1];
    sz[par1] = 0;
    par[par1] = par[par2];
  }
};
DSU dsu;
int main() {
  long long n, i, j, p, q, r, a, b, ans = 0;
  cin >> n;
  for (i = 1; i <= n; i++) {
    cin >> x[i] >> y[i];
  }
  for (i = 1; i <= n; i++) {
    cin >> c[i];
  }
  for (i = 1; i <= n; i++) {
    cin >> k[i];
  }
  for (i = 1; i <= n; i++) {
    for (j = i + 1; j <= n; j++) {
      p = (k[i] + k[j]) * (abs(x[i] - x[j]) + abs(y[i] - y[j]));
      edges.push_back({p, {i, j}});
    }
  }
  for (i = 1; i <= n; i++) {
    edges.push_back({c[i], {i, 0}});
  }
  sort(edges.begin(), edges.end());
  long long sz = edges.size();
  dsu.init(n);
  for (i = 0; i < sz; i++) {
    p = edges[i].first;
    q = edges[i].second.first;
    r = edges[i].second.second;
    a = dsu.getPar(q);
    b = dsu.getPar(r);
    if (a == b) continue;
    dsu.unite(q, r);
    ans += p;
    fin.push_back({q, r});
  }
  sz = fin.size();
  for (i = 0; i < sz; i++) {
    long long u = fin[i].first;
    long long v = fin[i].second;
    if (u && v) {
      two.push_back({u, v});
    } else {
      one.push_back(u + v);
    }
  }
  cout << ans << endl << one.size() << endl;
  ;
  for (i = 0; i < one.size(); i++) {
    cout << one[i] << ' ';
  }
  cout << endl;
  cout << two.size() << endl;
  for (i = 0; i < two.size(); i++) {
    cout << two[i].first << ' ' << two[i].second << endl;
  }
  return 0;
}
