Based on the improved isospin-dependent Boltzmann-Langevin model which incorporates the dynamical fluctuations, we study the π production in central heavy ion collisions at different incident energies from 250 to 1200 A MeV. It is found that the π multiplicity is sensitive to the nuclear equation of state. At π subthreshold energy, the fluctuations have a larger effect on the π multiplicity. The π − /π + ratios as a probe of nuclear symmetry energy are calculated with different stiffness of symmetry energy. The results favor a supersoft symmetry energy of the potential term in comparison with the FOPI data, which supports the one obtained by the usual Boltzmann-Uehling-Uhlenbeck model.During the last few years, the study of nuclear symmetry energy E sym (ρ) has been a highly interesting subject. The constraining of E sym (ρ) is important for not only understanding of heavy-ion reactions [1] but also many issues in astrophysics [1,2].Unfortunately, the form of E sym (ρ) is very controversial, especially at supra-saturation density. At sub-saturation density, constraints on the E sym (ρ) were obtained by analyzing the isospin diffusion data [3]. At supra-saturation density, the main difference of the E sym (ρ) forms predicted by some microscopical or phenomenological many-body approaches is the trend of the E sym (ρ) with the density. One is the E sym (ρ) increases continuously with the increasing density, and the other is the E sym (ρ) increases