Well1024a random = new Well1024a(553267312521321234l);
for (int i = 0; i < 10000; ++i) {
double ux = 10000 * random.nextDouble();
double uy = 10000 * random.nextDouble();
double uz = 10000 * random.nextDouble();
double vx = 10000 * random.nextDouble();
double vy = 10000 * random.nextDouble();
double vz = 10000 * random.nextDouble();
double sNaive = ux * vx + uy * vy + uz * vz;
double sAccurate = new Vector3D(ux, uy, uz).dotProduct(new Vector3D(vx, vy, vz));
Assert.assertEquals(sNaive, sAccurate, 2.5e-16 * sAccurate);