#include <bits/stdc++.h>
using namespace std;
long long pai[5005];
long long x[2005], y[2005], c[2005], k[2005];
long long findpai(long long u) {
  return pai[u] == u ? u : pai[u] = findpai(pai[u]);
}
void unionset(long long x, long long y) {
  x = findpai(x);
  y = findpai(y);
  pai[x] = y;
}
int main() {
  long long n;
  cin >> n;
  for (long long i = 1; i <= 2 * n; i++) pai[i] = i;
  for (long long i = 1; i <= n; i++) cin >> x[i] >> y[i];
  for (long long i = 1; i <= n; i++) cin >> c[i];
  for (long long i = 1; i <= n; i++) cin >> k[i];
  vector<tuple<long long, long long, long long> > edges;
  for (long long i = 1; i <= n; i++)
    for (long long j = i + 1; j <= n; j++) {
      long long difx = abs(x[i] - x[j]);
      long long dify = abs(y[i] - y[j]);
      long long w = (k[i] + k[j]) * (difx + dify);
      edges.emplace_back(w, i, j);
    }
  for (long long i = 1; i <= n; i++) edges.emplace_back(c[i], n + 5, i);
  sort(edges.begin(), edges.end());
  vector<long long> power;
  vector<pair<long long, long long> > connection;
  long long res = 0;
  for (auto e : edges) {
    long long w, u, v;
    tie(w, u, v) = e;
    if (findpai(u) != findpai(v)) {
      res += w;
      if (u == n + 5)
        power.push_back(v);
      else
        connection.push_back({u, v});
      unionset(u, v);
    }
  }
  cout << res << endl;
  cout << power.size() << endl;
  for (long long v : power) cout << v << " ";
  cout << endl;
  cout << connection.size() << endl;
  for (pair<long long, long long> p : connection)
    cout << p.first << " " << p.second << endl;
  return 0;
}
