Computer simulation technology is frequently applied to the analysis of the microscopic processes of chemical reaction with its powerful functionality and wide applicability. The paper takes aluminum phosphate as the research object and uses the quantum chemistry, reaction kinetics and computer simulation to study the microscopic crystallization mechanism of chemical elements. Based on the replica exchange dynamics method, the simulation parameters of the reaction force field are optimized and this method is used to verify the zeolite system. The results show that the polymerization reaction occurs in the early stage of the crystallization of chemical elements. A preliminary simulation is conducted based on the parameters of reaction force field, obtaining the parameters of reaction force field of various elements. The temperature used in the simulation is set slightly higher than the ultimate temperature, ensuring the simulation efficiency and simulation accuracy; the optimized simulation temperature can be reduced to the experimental temperature, which can also guarantee the simulation accuracy and simulation speed; in the crystallization process of the structure-directing agent, the concentration of the chemical crystal in the reaction can be reduced, which can accelerate the polymerization rate, hinders the formation of other gel clusters and has a structural guiding effect on hydrogen bond interaction. The research results can provide a scientific reference for understanding the mechanism of crystallization process.