#include <bits/stdc++.h>
using namespace std;
unordered_map<long long, long long> par;
long long parent(long long x) {
  while (par[x] != x) {
    par[x] = par[par[x]];
    x = par[x];
  }
  return x;
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  long long n, i, j, x, t, y;
  cin >> n;
  unordered_map<long long, pair<long long, long long>> mp;
  unordered_map<long long, long long> c, k;
  for (i = 0; i < n; i++) cin >> mp[i].first >> mp[i].second;
  for (i = 0; i < n; i++) cin >> c[i];
  for (i = 0; i < n; i++) cin >> k[i];
  for (i = 0; i < n; i++) par[i] = i;
  vector<pair<long long, pair<long long, long long>>> v;
  for (i = 0; i < n; i++) {
    for (j = i + 1; j < n; j++) {
      x = (k[i] + k[j]) *
          (abs(mp[i].first - mp[j].first) + abs(mp[i].second - mp[j].second));
      v.push_back({x, {i, j}});
    }
  }
  sort(v.begin(), v.end());
  long long ans = 0;
  vector<long long> s;
  vector<pair<long long, long long>> e;
  for (auto p : v) {
    x = p.second.first;
    y = p.second.second;
    long long xx = parent(x);
    long long yy = parent(y);
    if (xx == yy) continue;
    if ((c[xx] + c[yy]) > (p.first + min(c[xx], c[yy]))) {
      ans += p.first;
      if (c[xx] > c[yy]) swap(xx, yy);
      par[yy] = xx;
      e.push_back({x + 1, y + 1});
    }
  }
  for (i = 0; i < n; i++) {
    if (par[i] == i) {
      ans += c[i];
      s.push_back(i + 1);
    }
  }
  cout << ans << "\n";
  cout << s.size() << "\n";
  for (auto p : s) cout << p << " ";
  cout << "\n" << e.size() << "\n";
  for (auto p : e) cout << p.first << " " << p.second << "\n";
}
