A spider monkey tries to get a banana from a tourist visiting the Santafe Zoo in Medellin, Colombia. Albeiro Lopera / Reuters

One of the grand questions in life is when it’s time to move on. Whether you’re a hunter-gatherer rapidly depleting the berries in your area or an oil company considering leaving one well to start up another, from the point of view of a mathematician, you face the same basic dilemma: “When should you go to where the grass is greener?” says Sidney Redner, a physicist at the Santa Fe Institute. The problem shows up in ecology, where researchers study the optimal strategy for a foragers moving through its environment; in management research, where companies decide between sinking money into innovation or excelling where they are strongest; and many, many other places.

It also turns out to be a fairly thorny one to solve. Think of a tropical forest scattered with groves of banana trees, and imagine some forager who consumes the low-hanging fruit of one grove. After a while, this hypothetical forager faces the decision of leaving to find another grove or climbing the trees to get harder-to-reach bananas. Mathematically, it does not seem to be possible to make generalizations about which strategy is the best if the forager walks randomly until they stumble upon a new patch, Redner says; the forager can take almost any path through the environment, and very quickly the possible routes diverge enormously, so it winds up being very difficult to say anything conclusive.

However, in a recent paper in the journal Physical Review E, Redner and his collaborators find that if you think about a one-dimensional situation—with the metaphorical banana groves spread out in a line—then it becomes tractable. The decision now is between climbing the trees of the current grove or moving down the line to the next grove in the distance. In this situation, the forager can tell how far away the next opportunity is; all the uncertainty that remains is whether it is worth it to keep exploiting the resources they have right now or strike out for the next destination. Redner and colleagues found that in this case, the optimal survival strategy is to leave the grove when the time needed to continue to exploit it matches the time that would be required to reach the next one.

The interesting thing about this insight, Redner says, is that it does not require many qualifications or assumptions. Some models of this sort of process, for instance, build in the requirement that once the resources in a given patch have sunk to a certain level, regardless of other factors, the forager will move on. But in Redner and his colleagues’ model, nothing like that is required. And the model also provides details like how much food foragers consume overall in their lifetimes. “If a lot of food is eaten, then the forager typically had a full belly for most of its life,” Redner says. “In the opposite case, the forager was perhaps living at the edge of starvation before finally succumbing.”

Now Redner is working on a different challenge: a model of foraging where the forager is endowed with greed. Rather than wandering through the environment, stumbling upon food, and walking on in a random direction when finished, the greedy forager in this model can tell in what direction nearby food is and goes to it. “It turns out this greed leads to very strange behavior,” Redner says. Foragers that have such low interest in food that they essentially wander randomly have very long life expectancies, and those that seek out food more aggressively die more quickly, though there is an exception for the most greedy of all.

The researchers aren’t really sure why this is happening, but Redner suggests that one explanation may be this: A forager that is so fixated on food that it wipes out all the resources near it is, in essence, creating a desert. They survive by eating around the edges of their wasteland. But if they make a wrong turn into the stripped-bare zone, there is a significant risk that they die before they can return to the safety of the fringe.

“So there is this tension,” says Redner, between consuming all that comes within reach and the increased vulnerability that comes with such efficient destruction. “If you make a mistake,” he says, it’s “really dangerous.”

We want to hear what you think. Submit a letter to the editor or write to letters@theatlantic.com.