Australian ‘Infinity Train’ uses gravity to recharge batteries
railtech.com> The gravitational energy from the heavy iron ore load will be used to regenerate the batteries while the train is running.
"Infinity train" may be a bit of a misnomer: this is viable as long as there is ore (or other mass) at the higher elevation, which can be transported on the train to a lower elevation -- in the process, the train captures some of the gravitational potential energy that was present.
I agree it's not an "infinity train" as such (especially as plenty of energy is used to haul the ore out of the ground), but it's impressive saving 82M litres of diesel a year (and amazing it wasn't done before).
i assume you mean "wasn't done before" in regards to modern railroads..... https://www.rankers.co.nz/system/experience_images/11476/lar...