The invention discloses a PIC (
Peripheral Interface Controller) model-based accelerator
simulation method implemented by using a GPU (Graphic
Processing Unit) in parallel. The method comprises the following steps:
copying initialization information from a host to the GPU for calculating nodes; determining a corresponding relationship of particle positions and grids according to the initialization information; according to the corresponding relationship of the particle positions and the grids, calculating
charge density weights, on the grids, of all particles in each grid to obtain the
charge density distribution of the grid; calculating the potential distribution of the grids according to the
charge density distribution of the grids, and calculating the
electric field distribution of the grids according to the potential distribution of the grids; calculating the motion change of each particle under the action of an
electric field, and updating the motion state of each particle; replacing the initialization information by the updated motion state of each particle, and iteratively carrying out the steps until the motion states of the particles satisfy design requirements. According to the method, the technical problems of being low in operation speed of a
simulation algorithm, high in cost and the like in the existing PIC model-based accelerator can be solved.