Some animal behaviour seems very strange at first sight. Why should a female naked mole-rat, for example, stay with a colony where she is prevented from breeding, and seems forced to act as a worker to help raise more of her mother's children?
The answer, it seems, is in their genes. Genes are sections of DNA that carry the code for a particular feature, such as colour or a certain behaviour. We can say that natural selection acts on these features, but it would be more accurate to say it acts on the genes that cause these features, since it is they that are passed on to the next generation. Genes that contain code for a feature allowing an individual carrying it to live long and produce lots of offspring will be more common in the next generation than genes that don't, because those 'successful' genes are obviously more likely to be passed on. In the end 'unsuccessful' genes will become extinct, but the measure of their 'success', or lack of it, is simply their ability to cause more of themselves to be present in the next generation.
We know that a parent's genes are inherited by their children. Because of the way sexual reproduction works, a child will inherit on average half the genes of their mother and half of their father. So, successful genes will be those that cause their owner to produce lots of offspring, each likely to inherit a copy. However, in some cases the odds are stacked against a particular individual reproducing. In the case of a naked mole rat, it is very hard for a young female to set out on her own, find a mate and enough food to survive and rear young simply because they live in burrows in very hard soil. It is only possible to dig new burrows for a couple of months each year, and during the rest of the time they have to survive on what food they managed to dig up during that brief period.
So a young naked mole-rat, and the genes it carries, faces almost certain death if it strikes out alone. However, if it stays with its mother, it can help her raise more brothers and sisters. If these baby siblings share the same parents, then they are as likely to share genes with the youngster as its own babies would be: a 50 per cent chance. This means that a gene that caused a young naked mole-rat to stay and help its mother raise more young would tend to do well. There would be lots of youngsters in the next generation (carrying the same gene) that had been reared by the successful partnership of their mother and their older brothers and sisters. A gene that caused the youngsters to leave the colony in search of a mate for themselves, though, would tend to be doomed to extinction as the youngsters fail in their mission.
All this can be neatly summarised. A gene that causes an animal to help out its relatives will do well in the future if the cost to the animal is smaller than the benefit to its relative divided by the probability that the relative shares the same gene. This sounds a bit mathematical, but by converting the theory into simple maths, theoretical biologists have been able to understand a great deal about what causes animals to behave the way they do.