#include <bits/stdc++.h>
using namespace std;
const int N = 2000 + 7;
const long long inf = 1e16 + 19;
int n;
long long x[N], y[N], k[N], c[N];
long long cost[N];
int update[N];
long long g[N][N];
long long ans;
set<pair<long long, int> > seti;
vector<int> station;
vector<pair<int, int> > edge;
int distance(int i, int j) {
  int d = max(x[i] - x[j], x[j] - x[i]) + max(y[i] - y[j], y[j] - y[i]);
  return d;
}
void make_graph() {
  for (int i = 1; i <= n; i++) {
    g[0][i] = c[i] * 1LL;
    g[i][0] = c[i] * 1LL;
    for (int j = i; j <= n; j++) {
      long long price = (distance(i, j) * 1LL) * (k[i] + k[j] * 1LL);
      g[i][j] = price;
      g[j][i] = price;
    }
  }
}
void prime() {
  for (int i = 1; i <= n; i++) {
    cost[i] = inf;
    seti.insert(make_pair(cost[i], i));
  }
  seti.insert(make_pair(0, 0));
  while (!seti.empty()) {
    int u = (*seti.begin()).second;
    seti.erase(seti.begin());
    for (int v = 0; v <= n; v++) {
      long long w = g[u][v];
      if (cost[v] > w && seti.find(make_pair(cost[v], v)) != seti.end()) {
        seti.erase(make_pair(cost[v], v));
        cost[v] = w;
        update[v] = u;
        seti.insert(make_pair(cost[v], v));
      }
    }
  }
}
int main() {
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> x[i] >> y[i];
  for (int i = 1; i <= n; i++) cin >> c[i];
  for (int i = 1; i <= n; i++) cin >> k[i];
  make_graph();
  prime();
  for (int i = 1; i <= n; i++) {
    ans += cost[i];
    if (update[i] == 0)
      station.push_back(i);
    else
      edge.push_back(make_pair(i, update[i]));
  }
  cout << ans << endl;
  cout << station.size() << endl;
  for (int i = 0; i < station.size(); i++) cout << station[i] << " ";
  cout << endl << edge.size() << endl;
  for (int i = 0; i < edge.size(); i++)
    cout << edge[i].first << " " << edge[i].second << endl;
}
