A new algorithm of perturbation analysis for serial production lines and assembly production lines