The article briefly mentioned it, but the main reasons these are kept is maintenance and training. That's a far larger concern than the politics, but it isn't as interesting. Hence the nickname "parliamentary trains" -- people love to believe that it's some crazy bureaucratic reason behind them when they're usually very logical.
Some of these routes will probably never be viable on their own, but the segments of track might be needed some day as a detour. For instance if a bridge somewhere needed to be out of service for a year or something.
For example, one of the more famous "ghost trains" (since it's in London) is the daily Paddington to West Ruislip service. Since they're both served by the underground there wouldn't be much need for a mainline train between them. If long-term work disrupted that connection they might want to temporarily run a regular service on that line though.
If you just abandoned the track, you wouldn't know its condition when you needed it. Just as important, the regulators wouldn't let you run passengers using crew that hadn't been trained on that line.
So just running an occasional train and rotating staff through it, the line and the skills are always kept sharp. Then if you suddenly need that bit of track in an emergency it's ready to go.
And since you're going to run a train anyway, you might as well sell a few tickets if people want to join you.
Just like a back up link in a network that may be higher cost or a higher latency but you still route a small amount of traffic on it just to make sure the link is good in case the primary route is down or becomes congested, you want to make sure you know the health of the back up route.
The abandonment side doesn't really make a whole lot of sense.
There's plenty of train lines in the US that are kept on the books/maintained, yet don't see any regular service. Some brush cutting, an inspection train once a year, and that's about it.
There's also plenty which are entirely abandoned and overgrown in practice, yet are still kept on the books, which means the train company retains the right of way and can resume service at any time it wants even though a train hasn't run on it in at all in 30 years and it currently looks like a forest.
Training for emergency detours makes some sense, although unless the line is long you don't really need all that many people trained to be prepared for that. You can have a few people qualified and they can just get on/off the train (riding back and forth) in the section the normal engineers aren't qualified for. And if it's once a decade or longer planned work, it's going to be cheaper to qualify the workforce right before it rather than have to keep them all up to date all the time. (I'm also sure that not all of these lines are worthwhile detours)
I am from Brazil, and I wish our politicians were "bureucratic" as UK politicians regarding trains.
In the monarchy (yes, that long ago), the government believed railroads were the future of the country, and invested in them heavily (in fact half of current railroads in Brazil were built during the reign of the last emperor).
Later during the military dictatorship, the government again saw the point of railroads, and started investing in them again.
Then during our redemocratization, the federal government ended owning lots of railroad companies (example: The São Paulo railroads were given to the federal government as payment because of the São Paulo bank debts with the fedearl government), the federal government then went and shut down every single line that looked unprofitable, even ones that were unprofitable for obvious reasons (example: still under construction, thus zero revenue).
Now we need trains BADLY, but even to use old trains is impossible, for example 0.5% of the country area has 40 million people (out of 200 million in the country total), yet there is nowhere near enough trains for it, most of the transportation is by road (including all the issues of ever increasing absurd traffic, and accidents, one of the highest amounts in the world) or air (São Paulo has the dubious distinction of highest number of helicopters in the world, because road transport is so unsafe, because of accidents and crime, that people that can afford going by helicopter go by helicopter).
My parents live in Valinhos, I live near a train station in São Paulo, the train track near my home passes behind my parents home, yet I cannot do this simple trip, because not only the track is overgrown and unmaintained, but the government decided to repurpose some stations for other uses, and paved over or cemented over the tracks, the sad thing is we have the tracks there, we have the demand, and we have the trains (in storage, the military government bought lots and lots and lots of then bleeding edge electric trains), but everyone sees it as an almost impossible task to fix it.
note this map has some other whole cities in it (Jundiaí is a city, also is the city where the track is paved over... the Ruby track is the one that passes behind my parents house, if it was still in use).
Or Campinas (2 million people in the metro area, has several rail lines already built, stations in almost all cities of the metro area and in the biggest neighbourhoods, but has only a single train running, it is a coal train, and most people using it are tourists wanting to have a train trip, usually parents wanting to show their children how it is to travel by train).
Brazil is IMHO well suited for trains, much more than the US. Connect all the major cities on the coastline. Unfortunately, strategic thinking is something not well suited for a Brazilian mind. And the money - a country with one of the highest tax rates in the world - is much better invested in some corrupt politicians pocket than into infrastructure, be it trains, ridiculous expensive airtravel or roads. Brazil had a home run the last 10-15 years. My prediction: Won't be a home run the next 10-15 years.
I think many navies around the globe keep at least one sailing ship for training purposes. The Italian Navy, for example, keeps the Amerigo Vespucci veliero as a training ship for the Naval Academy: https://en.wikipedia.org/wiki/Italian_training_ship_Amerigo_...
Also the United States Naval Academy has a sailing team, but a lot of colleges on a river or shore do. I assume they do well, as a matter of pride. http://www.usna.edu/Sailing/
Some of these routes will probably never be viable on their own, but the segments of track might be needed some day as a detour. For instance if a bridge somewhere needed to be out of service for a year or something.
For example, one of the more famous "ghost trains" (since it's in London) is the daily Paddington to West Ruislip service. Since they're both served by the underground there wouldn't be much need for a mainline train between them. If long-term work disrupted that connection they might want to temporarily run a regular service on that line though.
If you just abandoned the track, you wouldn't know its condition when you needed it. Just as important, the regulators wouldn't let you run passengers using crew that hadn't been trained on that line.
So just running an occasional train and rotating staff through it, the line and the skills are always kept sharp. Then if you suddenly need that bit of track in an emergency it's ready to go.
And since you're going to run a train anyway, you might as well sell a few tickets if people want to join you.