Spectral gap for Glauber type dynamics for a special class of potentials