Symmetry of force on particles: Fij = -Fji (Newton's Law of Action and Reaction!)
-
only half need to be computed
-
Sequentially this can easily be taken into account for one just does loops with sum over particles i, and then sums for force calculation over particles j <= i and then calculate algebraic form of Fij and then accumulates -- Force on i increments by Fij and Force on j decrements by Fij
|
Parallel version has two issues -- firstly one cannot use "owner-computes" rule directly and secondly one must worry about load blancing
|
Assuming for example that processors
|
assigned with block distribution in
|
column direction.
-
To calculate the force between
-
2 particles will take N/Nproc iterations
-
in the longest running processor
|