My Bachelor Degree thesis project.
The
This thesis work concerned the development of an algorithm for the efficient and effective solution of an n-body problem based on the Barnes-Hut approach. The problem considered consisted in the calculation of the electric force field established by a non-uniform network of charges all of the same sign.
Wanting to solve an
The discussed approach was implemented in a code written in MATLAB language and the performance of the Barnes-Hut algorithm was compared with an exact calculation of particle interactions in terms of accuracy and computational cost.
The code is divided in two parts:
- quadtree and Barnes-Hut algorithm part;
- operations count part.
This part shows how quadtree and Barnes-Hut algorithm work. To run this part, open the quadtree_main.m
file on MATLAB and run it.
This part compares the complexity of the Barnes-Hut algorithm with the exact method. To run this part, open the opCount_main.m
file on MATLAB and run it.