It's a long way from the Arctic to Tipperary, but scientists have discovered polar bears can trace their family tree to Ireland. Genetic evidence shows they are descended from Irish brown bears that lived during the last ice age.

Modern polar bears share a distinct DNA sequence, passed down the female line, with their now extinct brown ancestors. However, the same DNA fingerprint is absent from other species of brown bear alive today.

It is thought the link arose from interbreeding between prehistoric polar bears and female brown bears when their paths crossed as the Irish climate cooled.

Scientists made the discovery after analysing DNA in mitochondria – energy-producing structures within cells – that are only passed from a mother to her offspring.

Dr Ceiridwen Edwards, from Oxford University, a member of the international team that carried out the study, said: "Hybridisation between ancient Irish brown bears and polar bears has led to the complete replacement of the original polar bear mitochondria. This maternal lineage is now present in all modern polar bears."

Polar and brown bears are hugely different in terms of body size, skin and coat colour, fur type, tooth structure and many other physical features.

They are also very distinct behaviourally. Polar bears, the world's largest carnivores, are expert swimmers which prey on seals, while forest-living brown bears climb and have a varied omnivorous diet. Yet the two appear to mate successfully whenever they come into contact.

Climate change is believed to have produced mating opportunities for the two species at various times in the past 100,000 years.

The scientists extracted mitochondrial DNA from the teeth and bones of 17 bears found at eight cave sites across Ireland.

Ten Irish brown bears from the ice age period between 10,000 and 38,000 years ago had the maternal DNA that is now seen in every polar bear.

Older pre-ice-age brown bears, dating to between 43,000 and 38,000 years ago, had a different genetic signature matching that of modern bears from eastern Europe.

Remains of the last ancient brown bears in Ireland, from 3,000 to 5,000 years ago, had yet another genetic fingerprint seen in modern western European bears.

Only the ice age brown bears carried the maternal genetic hallmark of polar bears.

Polar bears may have moved into what is now Ireland when the region was experiencing much cooler temperatures than it is today. At the same time, brown bears may have been pushed towards the coast by advancing ice sheets.

Warmer periods may bring the species together as melting glacial ice and rising sea levels force polar bears to retreat inland.

"Environmental conditions appear to have played, and continue to play, a big part in the evolutionary history of polar bears," said Edwards. "Today's warming climate is again bringing modern polar bears into contact with brown bears in places like Canada and Alaska." The research is published in the journal Current Biology.