This paper studies the influence of the number of particles on the microstructure of the NiAl bulk model and the NiAl nanoparticle model using Molecular Dynamics (MD) method with the Sutton-Chen embedded interaction potential and appropriate boundary conditions. The bulk model was studied with periodic boundary conditions, and the nanoparticle model was studied with aperiodic boundary conditions. The studies of NiAl models with 5,324 particles, 6,912 particles and 8,788 particles at increasing in temperatures from 0 K to 2,000 K, then at decreasing temperatures from 2,000 K to 300 K with a moving step dr = 0.01 gave consistent results with experiments. The microstructure characteristics were analyzed using the radial distribution function (RDF), the coordination number, the energy, the size of particles and the common neighbourhood analysis method (CNA). The results showed that the structure phases fcc, hcp and bcc appeared in the models with 5,324 particles; 6,912 particles and 8,788 particles at 300 K. The research results also confirmed that there was an influence of the number of particles on the microstructure of the models.