refactor more national pulse code