Real-Time Dynamic Train Dispatching for Sustainable and Energy-Efficient Operations: An Automata-Based Receding Horizon Control Framework | Synapse