Commit 106624ab authored by Matthieu Schaller's avatar Matthieu Schaller

Fixed SPH tests to use the new dx_max nomenclature

parent d7a357f9
......@@ -62,7 +62,8 @@ struct runner {
void runner_do_ghost(struct runner *r, struct cell *c, int timer);
void runner_do_extra_ghost(struct runner *r, struct cell *c, int timer);
void runner_do_sort(struct runner *r, struct cell *c, int flag, int clock);
void runner_do_drift_particles(struct runner *r, struct cell *c, int timer);
void runner_do_drift_part(struct runner *r, struct cell *c, int timer);
void runner_do_drift_gpart(struct runner *r, struct cell *c, int timer);
void runner_do_kick1(struct runner *r, struct cell *c, int timer);
void runner_do_kick2(struct runner *r, struct cell *c, int timer);
void runner_do_end_force(struct runner *r, struct cell *c, int timer);
......
......@@ -315,7 +315,7 @@ struct cell *make_cell(size_t n, const double offset[3], double size, double h,
cell->h_max = h;
cell->count = count;
cell->gcount = 0;
cell->dx_max = 0.;
cell->dx_max_part = 0.;
cell->dx_max_sort = 0.;
cell->width[0] = size;
cell->width[1] = size;
......@@ -324,7 +324,7 @@ struct cell *make_cell(size_t n, const double offset[3], double size, double h,
cell->loc[1] = offset[1];
cell->loc[2] = offset[2];
cell->ti_old = 8;
cell->ti_old_part = 8;
cell->ti_end_min = 8;
cell->ti_end_max = 8;
cell->ti_sort = 0;
......@@ -592,8 +592,7 @@ int main(int argc, char *argv[]) {
const ticks tic = getticks();
/* Initialise the particles */
for (int j = 0; j < 125; ++j)
runner_do_drift_particles(&runner, cells[j], 0);
for (int j = 0; j < 125; ++j) runner_do_drift_part(&runner, cells[j], 0);
/* First, sort stuff */
for (int j = 0; j < 125; ++j) runner_do_sort(&runner, cells[j], 0x1FFF, 0);
......
......@@ -158,7 +158,7 @@ struct cell *make_cell(size_t n, double *offset, double size, double h,
cell->split = 0;
cell->h_max = h;
cell->count = count;
cell->dx_max = 0.;
cell->dx_max_part = 0.;
cell->dx_max_sort = 0.;
cell->width[0] = size;
cell->width[1] = size;
......@@ -167,7 +167,7 @@ struct cell *make_cell(size_t n, double *offset, double size, double h,
cell->loc[1] = offset[1];
cell->loc[2] = offset[2];
cell->ti_old = 8;
cell->ti_old_part = 8;
cell->ti_end_min = 8;
cell->ti_end_max = 8;
cell->ti_sort = 8;
......@@ -438,7 +438,7 @@ int main(int argc, char *argv[]) {
cells[i * 9 + j * 3 + k] = make_cell(particles, offset, size, h, rho,
&partId, perturbation, vel);
runner_do_drift_particles(&runner, cells[i * 9 + j * 3 + k], 0);
runner_do_drift_part(&runner, cells[i * 9 + j * 3 + k], 0);
runner_do_sort(&runner, cells[i * 9 + j * 3 + k], 0x1FFF, 0);
}
......
......@@ -91,7 +91,7 @@ int main() {
printf("\nVector Output for kernel_deval_2_vec\n");
printf("-------------\n");
/* Test vectorised kernel that uses two vectors. */
for (int i = 0; i < numPoints; i += VEC_SIZE) {
......@@ -100,7 +100,7 @@ int main() {
vector vx_2, vx_h_2;
vector W_vec_2, dW_vec_2;
for (int j = 0; j < VEC_SIZE; j++) {
vx.f[j] = (i + j) * 2.25f / numPoints;
vx_2.f[j] = (i + j) * 2.25f / numPoints;
......@@ -127,7 +127,7 @@ int main() {
return 1;
}
}
/* Check second vector results. */
for (int j = 0; j < VEC_SIZE; j++) {
printf("%2d: h= %f H= %f x=%f W(x,h)=%f dW(x,h)=%f\n", i + j, h,
......
......@@ -84,7 +84,8 @@ struct cell *make_cell(size_t n, double *offset, double size, double h,
cell->split = 0;
cell->h_max = h;
cell->count = count;
cell->dx_max = 0.;
cell->dx_max_part = 0.;
cell->dx_max_sort = 0.;
cell->width[0] = n;
cell->width[1] = n;
cell->width[2] = n;
......@@ -92,7 +93,7 @@ struct cell *make_cell(size_t n, double *offset, double size, double h,
cell->loc[1] = offset[1];
cell->loc[2] = offset[2];
cell->ti_old = 8;
cell->ti_old_part = 8;
cell->ti_end_min = 8;
cell->ti_end_max = 8;
......
......@@ -71,7 +71,8 @@ struct cell *make_cell(size_t N, float cellSize, int offset[3], int id_offset) {
cell->h_max = h;
cell->count = count;
cell->gcount = 0;
cell->dx_max = 0.;
cell->dx_max_part = 0.;
cell->dx_max_sort = 0.;
cell->width[0] = cellSize;
cell->width[1] = cellSize;
cell->width[2] = cellSize;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment