Fixed index computation in dot-product

This commit is contained in:
Guilhem Lavaux 2012-11-11 13:30:41 -05:00
parent ff7b8dc45e
commit 09551ae85b

View File

@ -195,7 +195,7 @@ namespace CosmoTool
{ {
for (long p = 0; p < plane_size; p++) for (long p = 0; p < plane_size; p++)
{ {
long idx = q0+N0*p; long idx = q0+dims[0]*p;
assert(idx < this->size()); assert(idx < this->size());
result += 2*(conj(d1[idx]) * d2[idx]).real(); result += 2*(conj(d1[idx]) * d2[idx]).real();
} }