>712
とりあえずmat_mul()を↓に変えてみな

void mat_mul(complex** a, complex** b, complex** c, int n, int m, int l) {
int i, j, k;
complex s, t;

for (i = 0; i < n; i++)
for (j = 0; j < l; j++) {
s.re = s.im = 0.0;
for (k = 0; k < m; k++) {
t = mul(a[i][k], b[k][j]);
s = add(s, t);
}
c[i][j] = s;
}
}