|
|
@@ -662,12 +662,13 @@ int main(int argc, char *argv[]) |
|
|
|
for(d = 0; d <= TOTAL; d++) |
|
|
|
for(e = 0; e <= TOTAL; e++) |
|
|
|
{ |
|
|
|
int a2 = a, b2 = b, c2 = c, d2 = d, e2 = e, i; |
|
|
|
|
|
|
|
if(a + b + c + d + e != TOTAL) |
|
|
|
continue; |
|
|
|
|
|
|
|
/* Slightly shuffle our coefficients to avoid waiting until |
|
|
|
* 75% progress before having an idea of what's going on. */ |
|
|
|
int a2 = a, b2 = b, c2 = c, d2 = d, e2 = e; |
|
|
|
#define SHUFFLE(p,q,n) \ |
|
|
|
if(p+q) { int tmp = p+q; p = (p+n) % (tmp+1); q = tmp-p; } |
|
|
|
SHUFFLE(c2, d2, 777); SHUFFLE(b2, d2, 555); |
|
|
@@ -684,26 +685,31 @@ int main(int argc, char *argv[]) |
|
|
|
#endif |
|
|
|
/* We only want 4-cell kernels for now */ |
|
|
|
if(b2) continue; |
|
|
|
//printf("K: %d,%d,%d,%d,%d ", a2, b2, c2, d2, e2); |
|
|
|
printf("K: %d,%d,%d,%d ", a2, c2, d2, e2); |
|
|
|
|
|
|
|
dest = ed(src, false, a2, 0, |
|
|
|
b2, c2, d2, e2, 0, |
|
|
|
0, 0, 0, 0, 0); |
|
|
|
if(mode == 4) |
|
|
|
{ |
|
|
|
study(src, dest, 1.2, 0.001, 0., 0.); |
|
|
|
} |
|
|
|
else |
|
|
|
for(i = 1; i <= 2; i++) |
|
|
|
{ |
|
|
|
tmp = gauss(src, mat); |
|
|
|
tmp2 = gauss(dest, mat); |
|
|
|
printf("E: %.5g\n", 1000. * dist(tmp, tmp2, 1.)); |
|
|
|
free(tmp); |
|
|
|
free(tmp2); |
|
|
|
//printf("[%i] K: %d,%d,%d,%d,%d ", i, a2, b2, c2, d2, e2); |
|
|
|
printf("[%i] K: %d,%d,%d,%d ", i, a2, c2, d2, e2); |
|
|
|
|
|
|
|
dest = ed(src, i == 2, a2, 0, |
|
|
|
b2, c2, d2, e2, 0, |
|
|
|
0, 0, 0, 0, 0); |
|
|
|
if(mode == 4) |
|
|
|
{ |
|
|
|
/* XXX: E_fast is meaningless, ignore it */ |
|
|
|
study(src, dest, 1.2, 0.001, 0., 0.); |
|
|
|
} |
|
|
|
else |
|
|
|
{ |
|
|
|
tmp = gauss(src, mat); |
|
|
|
tmp2 = gauss(dest, mat); |
|
|
|
printf("E: %.5g\n", 1000. * dist(tmp, tmp2, 1.)); |
|
|
|
free(tmp); |
|
|
|
free(tmp2); |
|
|
|
} |
|
|
|
fflush(stdout); |
|
|
|
free(dest); |
|
|
|
} |
|
|
|
fflush(stdout); |
|
|
|
free(dest); |
|
|
|
} |
|
|
|
|
|
|
|
free(src); |
|
|
|