code: private static double[] plusAndConstMult(double[] a, double[] b, double c,
        double[] d) {
      for (int i = 0; i < a.length; i++) {
        d[i] = a[i] + c * b[i];
      }
      return d;
    }
docs: computes d = a + b * c