Thanks Edwin and WAO..... but I did say Battery hybrid and so the solar panels are not providing all the power required continuously, so that would alter the economics. Also a lot of the heat energy from the firebox is "lost" up the chimney on conventional steam locomotives so again there is an efficiency gain using electrical immersion heating....It may be "green wash" but it may be a route forward if the eco-zealots get more powerful....
I doubt that even if you covered the whole train with solar panels you would get more than 5% of the energy needed to power the motors in the UK. The only thing that helps a bit is that on preserved lines rolling stock often sits around during the week which gives more time to charge. Charging the batteries from a shore supply whenever possible is more likely to be a workable option as is done with some tram routes. I was in Seville recently and saw how the trams there raise the pantograph in the stations to meet the 10 metres of OHL.