Skip to content
Snippets Groups Projects
Commit b96a2f9f authored by Matthieu Schaller's avatar Matthieu Schaller
Browse files

Updated the unit test case testing the interaction of one cell with its 26 neighbours.

parent 7b5d83ea
No related branches found
No related tags found
No related merge requests found
......@@ -113,30 +113,32 @@ figure(frameon=True)
subplot(311, title="Acceleration along X")
#plot(id[abs(errx_s) > 0.001], e_errx_s , 'ro')
plot(pos_x, accx_u - accx_s, 'bx')
#plot(pos_x, accx_s , 'ro')
plot(pos_x, accx_u, 'bx')
plot(pos_x, accx_s , 'ro')
#text( 0., 0.1, "axis=( %d %d %d )"%(axis[orientation*3 + 0], axis[orientation*3 + 1], axis[orientation*3 + 2]) , ha='center', backgroundcolor='w', fontsize=14)
ylim(-70, 70)
ylim(-15000, 15000)
grid()
subplot(312, title="Acceleration along Y")
#plot(id[abs(erry_s) > 0.001], e_erry_s , 'ro')
plot(pos_y, accy_u - accy_s, 'bx')
#plot(pos_y, accy_s , 'ro')
plot(pos_y, accy_u , 'bx')
plot(pos_y, accy_s , 'ro')
#text( 0., 0.1, "axis=( %d %d %d )"%(axis[orientation*3 + 0], axis[orientation*3 + 1], axis[orientation*3 + 2]) , ha='center', backgroundcolor='w', fontsize=14)
ylim(-70, 70)
#ylim(-70, 70)
ylim(-15000, 15000)
grid()
subplot(313, title="Acceleration along Z")
#plot(id[abs(errz_s) > 0.001], e_errz_s , 'ro', label="Sorted")
plot(pos_z, accz_u - accz_s , 'bx', label="Unsorted")
#plot(pos_z, accz_s , 'ro', label="Sorted")
plot(pos_z, accz_u , 'bx', label="Unsorted")
plot(pos_z, accz_s , 'ro', label="Sorted")
#text( 0., 0.1, "axis=( %d %d %d )"%(axis[orientation*3 + 0], axis[orientation*3 + 1], axis[orientation*3 + 2]) , ha='center', backgroundcolor='w', fontsize=14)
legend(loc="upper right")
ylim(-70, 70)
#ylim(-70, 70)
ylim(-15000, 15000)
grid()
savefig("accelerations_absolute_all.png")
......
......@@ -2337,6 +2337,7 @@ void test_all_direct_neighbours(int N_parts) {
/* Do the interactions without sorting */
for (j = 0; j < 26 ; ++j)
iact_pair_direct_unsorted(&cells[26], &cells[j]);
iact_self_direct(&cells[26]);
message("Unsorted interactions done ");
......@@ -2353,6 +2354,7 @@ void test_all_direct_neighbours(int N_parts) {
/* Do the interactions with sorting */
for (j = 0; j < 26 ; ++j)
iact_pair_direct_sorted(&cells[26], &cells[j]);
iact_self_direct(&cells[26]);
message("Sorted interactions done ");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment