On the basis of an switched optimal control algorithm which solves the problem without considering the restriction on the number of switching and switching sequence,the convergence of the algorithm was ana-lyzed . It is proved that the numerical solutions obtained from the algorithm will converge to the theoretical opti-mal solutions as time interval is divided infinitely.