A WISP of steam curls out of the chimney, followed by another, then all of a sudden a white cloud belches into the air, followed seconds later by a fine mist of water and soot.

Slowly, grindingly, creakingly, the metal beast strains its way along the rails, the rhythm of its smoky discharge changing as it picks up speed.

San Pareil is on its way. Its mission: to ease an historical sore that has been running for more than 170 years.

Timothy Hackworth's engine, built at Shildon in County Durham, was one of the three favourites at the Rainhill Trials of 1829, run to find the best engine of the day. But a cracked cylinder forced it to withdraw, leaving George Stephenson's Rocket to win by default.

Ever since there has been talk of sabotage - Sans Pareil's fated cylinder was made by George Stephenson's foundry in Newcastle. The result is that Rocket achieved immortality while San Pareil's fate was to be of interest only to historians and steam enthusiasts.

Now, a television programme is giving Sans Pareil the chance to avenge its defeat. The BBC's Timewatch is recreating those Rainhill Trials to try to find out if Rocket would have won if its main competitors had not been forced to pull out.

Replicas of the three favourites at those 1829 trials - San Pareil, Rocket and the Swedish Novelty - have been brought to the Lllangollen Railway in North Wales to be put to the test.

Here, on a small stretch of track between Carrog and Glyndyfrdwy - Glyn to its friends - the locomotives are being asked to cover the equivalent of the original trial distance, the 70 miles from Liverpool to Manchester and back, pulling twice their own weight at an average speed of 10mph or more.

The first day saw Novelty take to the tracks, but, just as in 1829 when its boiler pipe burst, it faced problems, this time running out of oil, leaving the race between Rocket and Sans Pareil.

Yesterday was San Pareil's turn, with Alan Pearce, curator of the Timothy Hackworth Museum in Shildon, at the controls.

But for Sans Pareil it was nearly over before it began. The wrong type of coal meant the first two practice days were almost written off. It was only the arrival of Polish coal, donated by the Rocket team from York's National Railway Museum, that saved the day.

Even then, the first few runs did not go to plan.

"We were trying to be economical, so we were going at only 15mph, but the engine was starting to labour because it was too slow, so we ended up running out of steam," said Mr Pearce, halfway through the first session.

"We have worked out that the secret is to drive it hard and it is going brilliantly now."

Averaging about 18mph on the uphill stretch and 22mph on the downhill, Sans Pareil was making a competition of it.

"A lot of it is for historical curiosity, but we want to prove that the engine was a true competitor," Mr Pearce said.

"We are treating it as a bit of fun. It is not rewriting history, but it is giving us an insight into a period when there were huge advances in the development of the railways.

"But the competition is being taken very seriously and everybody feels they have got a lot to prove and a lot to lose."

Perhaps with most to lose is the Rocket team, keen to preserve their engine's place in history.

"My boss told me not to bother coming back if we didn't win," said Richard Gibbon, head of engineering at the National Railway Museum in York and fireman for the Rocket.

"The beauty of this competition is that if we win the excuses would have to stop, but it would be an embarrassment if we lost."

With the Rocket not running until today, the result of the trials will not be known until tonight, and even then it will be kept a closely guarded secret until the programme airs sometime early next year.

Mr Pearce has never subscribed to the sabotage theory, but yesterday he was keen to show that Sans Pareil could have made it.

"We are making a competition of it. They have got some serious rivals. We're like the Alf Tupper of the locomotive world, the one who always turns up covered in dirt and without the proper equipment."