#include <bits/stdc++.h>
using namespace std;
struct Data {
  long long node, v;
};
struct cmp {
  bool operator()(const Data &l, const Data &r) { return l.v > r.v; }
};
long long n, sum, c[30000], k[30000], vis[30000], l[30000], sta[30000],
    trace[30000];
long long top, top1, ans[30000];
pair<long long, long long> a[30000], ans1[30000];
priority_queue<Data, vector<Data>, cmp> o;
void Input() {
  ios_base::sync_with_stdio(0);
  cin.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) cin >> a[i].first >> a[i].second;
  for (int i = 1; i <= n; i++) {
    cin >> c[i], o.push({i, c[i]});
    l[i] = c[i];
  }
  for (int i = 1; i <= n; i++) cin >> k[i];
}
long long Cal(int u, int v) {
  return (k[u] + k[v]) *
         (abs(a[u].first - a[v].first) + abs(a[u].second - a[v].second));
}
void Process() {
  while (o.size() != 0) {
    Data t = o.top();
    o.pop();
    if (vis[t.node]) continue;
    vis[t.node] = 1;
    sum += l[t.node];
    if (!sta[t.node])
      ans[++top] = t.node;
    else {
      ans1[++top1].first = t.node;
      ans1[top1].second = trace[t.node];
    }
    for (int i = 1; i <= n; i++)
      if (i != t.node && Cal(t.node, i) < l[i]) {
        l[i] = Cal(t.node, i);
        o.push({i, l[i]});
        sta[i] = 1;
        trace[i] = t.node;
      }
  }
  cout << sum << endl << top << endl;
  for (int i = 1; i <= top; i++) cout << ans[i] << " ";
  cout << endl << top1 << endl;
  for (int i = 1; i <= top1; i++)
    cout << ans1[i].first << " " << ans1[i].second << endl;
}
int main() {
  Input();
  Process();
  return 0;
}
