FOR the soldier and empire-builder Napoleon Bonaparte, it was "nothing", a trifling detail to be given hardly a second thought.

For physicist and agnostic Albert Einstein, fear of it was "unjustified". Apple co-founder Steve Jobs actually embraced it, thinking it life's best invention, a "change agent" that "clears out the old to make way for the new". And Woody Allen famously said he wasn't scared of it, he just didn't want to be around when it happened. Others have taken a less flippant attitude, though, among them William Shakespeare. In Measure For Measure, he has Claudio call it "a fearful thing" and in Macbeth's most famous soliloquy, the regicidal anti-hero says it's what reduces all humans to dust once life's strutting and fretting is done.

They're talking about death, of course. The Grim Reaper. The Final Curtain. Life's only certainty if you don't count taxes, as Benjamin Franklin did in his oft-quoted remark. And, being life's only certainty, it is also life's big subject, which is why philosophers, artists, poets, theologians, law-makers, politicians, priests and, yes, Woody Allen have all tackled it over the centuries in one way or another.

Some of them have made of it a grand metaphysical theme or used it as a spur for their own creativity. Think of the constant quest for eternal life in the Greek myths or in the 3000-year-old Epic Of Gilgamesh, the first work of literature. Think of Dylan Thomas's poem about the death of his father, Do Not Go Gentle Into That Good Night, with its instruction to "rage against the dying of the light". Think of Damien Hirst's famous shark and its grandiose title, The Physical Impossibility Of Death In The Mind Of Someone Living.

But while we all know that death is inevitable, to what extent is it really ever-present? When these same demographers, actuaries and statisticians talk up the continually rising life expectancy rates, it's easy to forget about death, or at least to relegate it to the lower leagues of the subconscious like some hapless, goal-shy football team. Sure, there are funerals to go to and yes we generally wear black for the ceremony, but the days of widow's threads are long gone. Blame two world wars for that. Blame the secularism that has detached us from religion, the belief system with the most to say about death. Blame the NHS, which collects our dying and parks them in antiseptic white buildings on the outskirts of our cities where they breathe their last out of sight, if not out of mind.

For the three co-authors of a new book, however, this sweep-it-under-the-carpet approach to death is facile and muddle-headed. More than that, it has consequences more far-reaching than we could possibly imagine because, as they see it, death informs practically every aspect of human existence. From the way we organise our societies to the moral codes we live by, even down to how we have sex and what rituals and emotions we ascribe to it, death is the bedrock. Or, as they style it in their book The Worm At The Core, the nasty, wriggling thing at the heart of the apple.

"The central thesis of the book is that human beings are deeply affected by the knowledge of their own inevitable death," explains co-author Jeff Greenberg, a University of Arizona psychology professor. "We're animals so we're pre-disposed biologically to keep alive. But we've also developed a cerebral cortex and a frontal lobe so we're smart enough to know that all of our efforts to keep breathing, keep nutrition in our bodies and avoid potential threats and dangers will ultimately fail."

This is a professorial way of laying out the human condition. But Greenberg goes further to argue that this puts a huge mental burden on humans and that over time we have created manifold ways of dealing with it. The idea is based largely on work done in the 1960s and 1970s by cultural anthropologist Ernest Becker, who won the Pulitzer Prize in 1974 for his book The Denial Of Death just two weeks after his own death from cancer.

"We can't fully accept the reality that our only certain fate is our own death," Greenberg continues. "So cultures have developed ways of looking at reality that help convince us that in some way we'll transcend our own death, either literally, through an afterlife and an immortal soul, or symbolically through our identity carrying on after our death. In this way we can function securely."

The authors call this "terror management theory", which, as well as being a great name for a Norwegian black metal band, is a neat fusion of ideas borrowed from sociology, anthropology, existential philosophy and psychoanalysis. Basically it means the way we give our lives meaning when deep down we know they are actually meaningless. You might call it pulling the wool over our own eyes.

One example would be the way we build a sense of self-esteem for ourselves through actions which make us feel significant. Some do this by striving to acquire money with which they can endow a university library or a new museum wing or, like Microsoft zillionaire Bill Gates, a philanthropic foundation which can build and fund a string of disease surveillance centres across Africa. Others might seek fame on the sports field, the battlefield - think of the heroic deeds outlined in The Iliad - or through writing a bestselling novel or memorable poem.

"Here lies one whose name was writ in water," runs the inscription on a nondescript grave in the Protestant Cemetery in Rome. Its occupant? John Keats, who was desperate for the immortality that literary recognition can bring but who died thinking he hadn't achieved it, hence the anonymous headstone.

On a smaller scale, millions upload videos of themselves to YouTube or post daily images of themselves on Instagram and, while it might seem impertinent to compare Russell Brand to a giant of English letters, the comedian's online web series The Trews has the same death-denying impulse behind it as Keats's Ode On A Grecian Urn: a desire to leave something behind that lets subsequent generations know you were here. In the last few years we've even seen the rise of so-called lifecasters, people who film everything about themselves and post it online. An extreme form of narcissism perhaps, but yet again it's a way of bolstering self-esteem.

Take a step back, however, and it's clear that terror management theory also affects the big ideas, the ones that bind peoples together. In fact these big ideas are themselves terror management theories. Religion is the obvious example of a belief system which gives us what Greenberg calls "a protective sense of immortality". But equally you could get it from a political ideology like communism, or even a national identity.

One of the major ideas the authors had was that if people are reminded of their own mortality, they cling more tightly to these belief systems. They tested the theory by asking a group of municipal court judges in Arizona to set bail for a specific crime, in this case prostitution. Half of the group was also given a questionnaire to answer beforehand containing instructions like: "Describe the emotions that the thought of your own death arouses in you".

"If we didn't slip in a reminder of death, they suggested a bail of $50," says Greenberg. "If they did think about death, it was around $455". That's nine times the usual tariff. The point is that when reminded of their own mortality, the judges were inclined to penalise more heavily those deemed to have transgressed their belief system. And these are people who are supposed to be entirely even-handed. So much for the law.

Problems can arise, however, when different belief systems with different ways of making life seem meaningful come into contact with each other. The result? Each death-denying world view thinks the other is wrong, which is psychologically unsettling for both. Think of communism versus capitalism, Christianity versus Islam, even Mods versus Rockers.

Of course different belief systems and world views rub up against each other all the time with little or no problems. Sometimes one world view can simply assimilate another, sometimes it can reach an accommodation with it instead. "Sometimes an alternative world view has some appealing aspects so what people seem to do is try to incorporate the appealing aspects while diffusing the more threatening elements," says Greenberg.

But conflict can occur when one world view or belief system sets about denigrating another. "One thing that goes with that is de-humanisation," says Greenberg, "viewing the 'out' group as less human and more animalistic. And of course if they're animals, it's easier to do things to them and that of course takes you down the path towards genocide." That, of course, is the most drastic way to deal with an opposing world view: all-out annihilation.

But death-denying world views and terror management strategies aren't just for the boardroom and the battlefield. They find their way into the bedroom too and this really is a minefield because it's during sex that we are at our most animalistic and therefore most prone to being reminded that all we are is lumps of flesh. Or, as Greenberg and co put it in The Worm At The Core, "transient ambulatory gene repositories taking a short lap round the track of life before passing the baton to the next generation and joining the ranks of innumerable iterations of the unknown and unliving". Nor, in their eyes, do we make love: instead we participate in a "biomechanical docking manoeuvre".

Whatever you call it, though, their research found that thinking about death makes us not want to have sex, and that having sex brings death thoughts closer to the surface. Interestingly, dwelling on the romantic aspects of sex has no such effect - who knew roses and chocolates were such an effective terror management strategy?

A companion study also found that when people are reminded of others' corporality, and therefore their mortality, they rate them as being less attractive and less intelligent. They even sit further away from them. The experiment took the form of a woman rummaging in her handbag and "accidentally" dropping either a tampon or a hairclip. Which item she dropped had a huge effect on how she was viewed by both male and female participants.

Along with menstruation, pregnancy and lactation are other aspects of femininity which serve as physical and biological reminders that we are animals and therefore mortal. No wonder these perfectly natural functions become so codified and fenced in by ritual.

On the face of it there seems to be no escape from the constructs we've created to deal with out own mortality, whether it's our personal desire for fame, wealth and celebrity, our adherence to a political credo, country or subculture, our religious faith or some other kind of value system. But from time to time human culture does throw up "disruptive" imaginations, individuals who shirk off the death-denying world view and bring the idea of death closer to the surface. Picasso is one such individual and perhaps Damien Hirst is another, his pickled shark acting as an uncomfortable reminder of death just as his diamond-encrusted skull covers irrefutable proof of it with a sparkling veneer of wealth and attainment.

So what final advice do the authors of The Worm At The Core have for us? "Our editor wanted us to give answers in the last chapter," Greenberg laughs. "I think that's a path towards becoming a guru or something. We tried to show the theoretical analysis and what our research was revealing, which suggests possible things we could do better. But it's not our job to say, 'This is the right world view'. People have to construct their own."

But he will give some pointers. "Maybe just thinking about death deeply and not hiding from it can get us to accept it better and thereby become less driven, less concerned with selling our world view to others and less concerned with protecting our belief system."

Another possibility, he thinks, is to find more constructive kinds of world views, ones which still make us feel we have significance but which are asserted in ways that don't cause harm or conflict. Ultimately, then, self-awareness and clear-sighted knowledge are key. We won't cheat the Grim Reaper by becoming more compassionate and tolerant - but until the big guy comes knocking we might make everyone's else's lives just that little bit easier. The End.

The Worm At The Core: On The Role Of Death In Life by Jeff Greenberg, Sheldon Solomon and Tom Pyszczynski is published on Tuesday (Allan Lane, £20)