Based on the ultrarelativistic quantum molecular dynamics (UrQMD) model, the effects of the density-dependent symmetry potential for baryons and of the Coulomb potential for produced mesons are investigated for neutron-rich heavy ion collisions at intermediate energies. The calculated results of the ∆ − /∆ ++ and π − /π + production ratios show a clear beam-energy dependence on the density-dependent symmetry potential, which is stronger for the π − /π + ratio close to the pion production threshold. The Coulomb potential of the mesons changes the transverse momentum distribution of the π − /π + ratio significantly, though it alters only slightly the π − and π + total yields. The π − yields, especially at midrapidity or at low transverse momenta and the π − /π + ratios at low transverse momenta, are shown to be sensitive probes of the density-dependent symmetry potential in dense nuclear matter. The effect of the density-dependent symmetry potential on the production of both, K 0 and K + mesons, is also investigated. † DFG Mercator Guest Professor.