This paper introduces the Adjacency Matrix at the very beginning, the least transfer between two nodes can be obtained by using the Adjacency Matrix, and then Z matrix is introduced to achieve optimal routing algorithm for public transit transfer and to obtain optimal route by using the “two-step-descending-proliferation” algorithm. Through the "two-step" approach, efficiency and feasibility of data processing was increased. The algorithm focus on multi-objective optimization - takes the least transfer, the least cost, the shortest time, and so on.