#include <bits/stdc++.h>
int **sol;
int *level, *cost, *profit;
int kInvalid = -10000000;
int **create_sol(int N, int M) {
  int **p = (int **)malloc(sizeof(int *) * (N + M + 1));
  for (int i = 0; i <= N + M; ++i) {
    p[i] = (int *)malloc(sizeof(int) * (N + 1));
    for (int j = 0; j <= N; ++j) {
      p[i][j] = kInvalid;
    }
  }
  return p;
}
void free_sol(int N, int M, int **p) {
  for (int i = 0; i <= N + M; ++i) {
    free(p[i]);
  }
  free(p);
}
int max = 0;
void update(int **sol, int k, int i, int value) {
  if (value > sol[k][i]) {
    sol[k][i] = value;
    if (value > -1000) {
    }
    if (i == 1 && value > max) {
      max = value;
    }
  }
}
void print(int *a, int N) {
  for (int i = 0; i < N; ++i) {
    printf("%d ", a[i]);
  }
  printf("\n");
}
void fight(int **sol, int n, int cnt) {
  int l = level[n];
  update(sol, l, cnt + 1, sol[l][cnt] + profit[l] - cost[n]);
  int x = cnt + 1;
  int up = l;
  while (x > 1) {
    int y = x / 2;
    update(sol, up + 1, y, sol[up][x] + y * profit[up + 1]);
    x = y;
    ++up;
  }
}
int main() {
  int N, M;
  scanf("%d%d", &N, &M);
  level = (int *)malloc(sizeof(int) * (N));
  cost = (int *)malloc(sizeof(int) * (N));
  profit = (int *)malloc(sizeof(int) * (N + M + 1));
  for (int n = 0; n < N; ++n) {
    scanf("%d", level + (N - 1 - n));
  }
  for (int n = 0; n < N; ++n) {
    scanf("%d", cost + (N - 1 - n));
  }
  for (int l = 1; l <= N + M; ++l) {
    scanf("%d", profit + l);
  }
  sol = create_sol(N, M);
  update(sol, 0, 0, 0);
  update(sol, level[0], 1, profit[level[0]] - cost[0]);
  for (int n = 1; n < N; ++n) {
    for (int j = n; j >= 0; --j) {
      if (sol[level[n]][j] > kInvalid) {
        fight(sol, n, j);
      }
    }
    update(sol, level[n], 1, profit[level[n]] - cost[n]);
    for (int i = 1; i < level[n]; ++i) {
      update(sol, level[n], 1, sol[i][1] + profit[level[n]] - cost[n]);
    }
  }
  printf("%d\n", max);
  return 0;
}
