Of all the adaptations that allow our animal brethren to soar through the air or endure the darkness and crushing pressure of the ocean’s depths, there is one property that is unique in kingdom animalia.

Only wombats can produce cubical poop.

Think about it, though preferably not while eating and definitely not out loud: Of all the animals you can picture in your mind’s eye, which one produces scat that is flat on all sides and could reasonably be used to quiz geometry students?

But how does it get that way? And does it provide any evolutionary advantage to wombats as they take a trip on the circle of life?

Those questions about wombat poop have perplexed scientists since wombat-poop-studying scholars have existed, and the answers have eluded mankind until this precise moment in human history.

Now, we have answers, and they are distinctly intertwined with the nature of the Australian animals.

Gauging wombats by sight alone, the marsupials are what scientists would officially refer to as cuddly. But in the wild, they’re pretty aggressive and territorial — essentially cantankerous cousins of koalas.

Although it’s rare for wombats to attack humans, YouTube videos abound of the muscular marsupials going after zookeepers, hissing and snorting at stunned videographers and startling BBC animal show hosts. In 2010, an Australian man killed a wombat with an ax after finding the aggressive marsupial waiting for him on his doormat.

“Apparently it attacked his leg and got him to the ground and started attacking his chest, then Brucey killed the wombat and got taken to hospital in an ambulance,” a witness told the Australian Broadcasting Corporation, which said the wombat in question may have been in the advanced stages of mange.

If a wombat comes across a strange wombat or a predator in the wild, it’s not unusual for fur to fly.

Still, wombats aren’t itching for a fight. They’re herbivores that subsist on roots and other plant matter, and usually attack only when threatened. Mostly, they just want to be left alone.

That’s where the poop comes into play. Wombats produce up to 100 cubes of poop each night and surround their mazelike dens with it to serve as a no trespassing sign to other wombats — a border wall made out of poop, according to National Geographic. Wombats are nocturnal and have poor eyesight, so the wall is essentially made of smell.

Wombats that are better able to deter unwanted strangers are more likely to avoid conflict and injury, and thus increase their reproductive success, according to the magazine.

But round poop rolls and can’t stay in place on the ground or the logs and rocks that dot the wombat’s landscape.

Still, determining the biological mechanics of how wombat poop turns into a cube understandably took some particularly involved science.

Patricia Yang, a postdoctoral fellow at Georgia Tech, has dedicated her young career to studying, in intricate detail, the biomechanics of how animals poop and pee.

In 2013, various publications wrote about her research on mammal urination (selected headlines: “How fast does an elephant pee?” “New law of urination: Mammals take 20 seconds to pee” and “The Other Golden Rule”). Last year, she delved into the “Hydrodynamics of defecation.”

A significant chunk of her research involved her and other students going to Atlanta’s zoo and taking slow-motion video of animals pooping and peeing. For science.

Studying how nature has solved some of the problems of physics is a distinct branch of design known as biomimicry. Excreting urine and feces is a biological function, but it’s also a physical action, using energy and specially made structures to move solids and liquids around.

An elephant’s urinary tract, for example, can move nearly half a bathtub of water in 20 seconds. As Yang says in her dissertation, it’s an example of “scalable hydrodynamic systems.” Studying how an elephant empties its bladder can provide insight into how to make a better fire hose or sewage pipe.

Biomimicry is particularly useful when designing systems to be more energy efficient and less wasteful. What is a more efficient user of solar energy than a blade of grass?

But understanding the inner workings of wombats required Yang to do much more than setting her video camera to slo-mo mode and dodging suspicious zookeepers.

Yang and other researchers acquired dead wombats that had been hit by cars in Tasmania and euthanized by a veterinarian, according to her paper’s abstract.

They emptied out the animals' dietary tracts and filled it with a balloon, which they used to study the pressure exerted by the walls of the intestines. As a control, they similarly inflated pig intestines.

They found that in the final 8 percent of the wombat intestines — the homestretch of a two-week digestive process where wombat feces turns from a liquid into a solid — the intestines are not uniformly elastic. This difference in elasticity molds the feces into a specific shape.

The result: perfectly stackable wombat poop, with a practical purpose that could cross into the human manufacturing industry.

“We currently have only two methods to manufacture cubes,” Yang told National Geographic Magazine. Throughout history, humans have either cut cubes from hard materials or molded them from soft ones.

“Wombats have a third way.”

Read more: