![]() The second array is calculated from the average of the two elements of the first array. Typically you would compute them as follows: int dimx. So, the setup is two arrays of length n, with all elements set to room temperature, with the first element of the first array set to a higher temperature, like 100. I believe this was massively simplified for us, however it was cool anyways.īasically, the position's temperature is the average of its neighbors. ![]() Basically the simulation of the heat moving from one end of a metal rod to the other. The problem we were working on was temperature diffusion. I even got results in the 4,000x speedup range, although it seems to be a mistake. After the 'warm up', it was lightning fast, speeding up my program anywhere from 32 - 400x the single-thread time. I hope this was an anomaly or something that the HPCC I was using does, because that's quite slow. That is sometimes enough to rule out having it all together. In my testing, starting a CUDA kernel took 80-200ms depending on the gpu. Since there are hundreds or thousands of CUDA cores, you can massively parallelize a program. CUDA programming is quite a bit of fun when you get to see the performance increase.Īs I understand it, CUDA, the way our class was using it, is a very good replacement for a for-loop. Void cenergy(float *energygrid, dim3 grid, float gridspacing, float z, const float *atoms, int numatoms) Needs to be done as an atomic operation ©Wen-mei W.The last bit of my CSE 415 class is CUDA programming. Int k = z / gridspacing The grid parameter gives the number of grid points in each dimension of the lattice. Hwu and David Kirk/NVIDIA, Urbana, August 13-17, 2012Īlgorithm is input oriented For each input atom, calculate its contribution to all grid points in an x-y slice Output (energygrid) is regular Simple linear mapping between grid point indices and modeled physical coordinates Input (atom) is irregular Modeled x,y,z coordinate of each atom needs to be stored in the atom array The algorithm is efficient in performing minimal calculations on distances, coordinates, etc. Hwu and David Kirk/NVIDIA, Urbana, August 13-17, 2012Ītoms come from modeled molecular structures, solvent (water) and ions Irregular by necessity Energy grid models the electrostatic potential value at regularly spaced points Regular by design ©Wen-mei W. One way to compute the electrostatic potentials on a grid, ideally suited for the GPU All atoms affect all map lattice points, most accurate For each lattice point, sum potential contributions for all atoms in the simulated structure: potential += charge / (distance to atom) Approximation-based methods such as cut-off summation can achieve much higher performance at the cost of some numerical accuracy and flexibilityħ Direct Coulomb Summation (DCS) Algorithm DetailĪt each lattice point, sum potential contributions for all atoms in the simulated structure: potential += charge / (distance to atom) ri,j: distance from lattice point j to atom potential: potential at lattice point being evaluated atom ©Wen-mei W. In the Direct Coulomb Summation method, the total potential at lattice point j is the sum of contributions from all atoms in the system.Ħ Overview of Direct Coulomb Summation (DCS) Algorithm The contribution of atom to the electrostatic potential at lattice is potential = atom.charge / rij. ri,j: distance from lattice point j to atom potential: potential at lattice point being evaluated atom interactive mode Run on laptops, desktops, clusters, supercomputersĬalculate initial electrostatic potential map around the simulated structure considering the contributions of all atoms Most time consuming, focus of our example. Visualizing, animating, and analyzing bio-molecular systems More than 200,000 users as of 2012 Batch (movie making) vs. Presentation on theme: "ECE408 / CS483 Applied Parallel Programming Lecture 23: Application Case Study – Electrostatic Potential Calculation."- Presentation transcript:ġ ECE408 / CS483 Applied Parallel Programming Lecture 23: Application Case Study – Electrostatic Potential CalculationĢ Objective To learn how to apply parallel programming techniques to an application Thread coarsening for more work efficiency Data structure padding for reduced divergence Memory access locality and pre-computation techniques
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |