Members of an elephant family may be out of sight but they are always in the minds of the herd’s matriarchs, reseachers have found.

Tests have found that female elephants are able to remember the whereabouts of at least 17 family members simultaneously and perhaps as many as 30. They can keep mental tabs on which of their relations are ahead of them when the herd searches for food, which of them are lagging behind and which are travelling in separate groups.

Professor Richard Byrne, of the University of St Andrews, said that the elephants performed an impressive feat of memory by being able to recall where each of their relatives was in a constantly changing environment. “It’s hard enough for us to keep track of two or three children in a busy shopping centre. Imagine trying to do it with 30 or so,” he said.

Researchers tested the ability of African elephants to remember where each family member had got to by watching their behaviour while sniffing urine. Elephants have poor eyesight but an excellent sense of smell and are able to identify one another from traces of urine on the ground.

To test the memories of the elephants samples of urine-soaked earth were collected by researchers and placed in positions where a herd was about to pass. Observations showed that the animals exhibited surprise when they could detect the odour of a family member they knew was behind them. Interest was shown when the urine was that of a close relative travelling in the same group or in a separate herd, but samples left by unknown individuals were ignored.

Professor Byrne said that the study cast light on the way that elephants used their memories, especially as powers of long-term recall were likely to be of limited use to them.

Anecdotal evidence has suggested that elephants have good long-term memories but the study, in the Amboseli National Park, in Kenya, suggested that the ability to remember where a female relative could be found was much more important to them.

“Very long-term memory may not be all that important to animals except on rare occasions,” Professor Byrne said. “But keeping track of a constantly changing situation would be.

“Elephants are keeping track of whether a member of the family is in the group they are in and whether they are in front or behind. That’s quite a challenge for any of us when you are talking about 20 to 30 individuals.”

The experiments were carried out by researchers from the University of St Andrews and the Amboseli Trust for Elephants in Kenya. More than 1,400 elephants from eight clans live in the park, in 58 family units.

The researchers, who reported their findings in the journal Biology Letters, concluded: “It seems that female elephants have a general interest in monitoring family members with whom they are travelling. Elephants’ order of travelling often changes and ‘overtaking’ is common, suggesting that elephants must frequently update their expectation of where others are in relation to themselves.

“As a highly social species, elephants would benefit from knowing which individuals were near by.”