To improve the low accuracy of the zero-dimensional combustion model established by BP-NN, a particle swarm-neural network (PSO-NN) algorithm was proposed. The PSO optimize weights and thresholds of NN, and the operating and combustion parameters are constructed, and then compared with NN algorithm. The results show that comparing with NN algorithm, the zero-dimensional combustion model constructed by PSO-NN algorithm has higher prediction accuracy, and the mean square error of the main combustion period m is 0.0034, which is 78.21% lower than that before optimization. The particle swarm algorithm has quicker convergence and stronger versatility, which is suitable for the study of diesel engine 0-D model.