BSS 797: Principles of Parallel Computing Project 4 Notes Select any one, or more, of the three problems Project collection: email only (no hardcopy) Project must include algorithm description, programs with comments, results, and analysis Figures must be in ps/gif/tiff/jpg form Problem 4.1 In three dimensions, N particles with random charges uniformly distributed in [-1,1] and fixed at sites that have random coordinates in a 10*10*10 cube (any triplet of random numbers in [0,10] can be the coordinates of a particle.) These particles interact under the Coulomb's law: fij = qi qj/rij2 where fij is the force on particle i by j (with distance rij whose charges are qi and qj.) Further, assume the mass of these particles is a constant which is normalized to "1". Further Further, assume these particles move at the same velocity vector (1,0,0) initially. We also assume periodic boundary conditions. Further Further Further, assume there is a fixed positive charge Q=7 at the corner (10,10,10). These particles, as expected, move under the Newton's second law. For N= 50,000, for P=5, 10, 20. Write a parallel program to compute distribution of the speed (magnitude of velocity) of these N particles by P processors after 100 steps with step size = 10-6 units. In addition, collect timing results on all processors for P=5, 10, 20. Are loads balanced on these processors with your decomposition? Problem 4.2 Similar to Problem 4.1 but you should replace the force by fij = qi qj/rij5 (this is artificial and I don't know if such interaction really exist.) We also will remove the so-called fixed extra charge at (10,10,10) but we will add a constant force in -z direction (gravity) g*m where g=9.8 and m is the particle mass. Do the rest the same as in Problem 4.1. Problem 4.3 (Enhanced problem from Problem 2.3.) In three dimensions, N particles are arranged in a 10*10*10 cube (any triplet of random numbers in [0,10] can be the coordinates of a particle), initially. These particles interact under the so-called Lennard-Jones potential Vij = 1/rij12 - 2/rij6 where Vij is the pair-wise potential between particles i and j with distance rij. Write a parallel program to minimize the total energy of the particle system by moving the particles. For N=64, P=8 and 16 use two parallel simulated annealing methods to minimize the energy. Method I: Particle decomposition. Method II: Spatial decomposition. After reporting and comparing the timing results of both methods, make some comments about their relative efficiency. Problem 4.4 Load balance problem: In two dimensions, we have placed 4 x 4 grids. In these 16 mesh blocks, you place particles uniformly within each mesh block. There are three cases for us to place particles in the mesh blocks. 1. 500 particles at each of the diagonal mesh blocks but 50 at all other blocks. 2. Alternately place 500 and 50 particles at the mesh blocks. No adjacent blocks will have the same number of particles. 3. The number of particles in each block (i,j) is 100*i + 10*j*j. Now, we use 16 processors to compute the total system energy with pair-wise energy Vij = 1/rij12 - 2/rij6 Please re-mesh the particles so that the loads on all 16 processors are nearly balanced.