updated the automatic scatter program