Add repeat forward a* algorithm.