Smog settling over a New York City on a summer day. Lucas Jackson For travelers with the gleam of the Big Apple in their eye, nothing seems better than New York City in the summertime.

Restaurants have outdoor seating, there are festivals all over town, and you don't have to worry about bringing your jacket to Top of the Rock.

But long-time city dwellers know the horror behind the mystique: those awful smells that dominate every daily commute to and from the office.

Here's why it's hard to escape the stench of the city in the heat of summer.

New York City has the highest population density in the US, and with 8,550,405 people roaming the nation’s melting pot, it’s bound to get smelly.

A census conducted in July 2015 showed that the city had a population density of over 27,000 people per square mile. To put that into perspective, the US, on average, holds only 80 people per square mile. That much combined body odor alone could be enough to scare anyone away.

With such an insanely huge number of people living in just one city, it should come as no surprise that there is also an insanely huge amount of garbage produced.

Although residents of the city produce 12,000 tons of waste every day, New York City doesn’t have any of its own landfills or incinerators. Garbage piles up in dumpsters until it can all be taken across the Hudson River to be incinerated in New Jersey, or, if possible, recycled locally and overseas.

But even after most of this waste has been incinerated across the river, strong winds can still carry the stench back over to the city on a hot day.

The sheer amount of garbage isn’t the only problem. There also has to be a way to get all of it out of the city. Diesel trucks carry garbage out of Manhattan 7.8 million times each year. Let this sink in: That’s the same as driving around the earth 312 times, and that's just for one city.

A food truck in Manhattan. Carlo Allegri All this driving only adds to pollution and the greenhouse effect, causing the city to become warmer and smellier as time continues.

You may also be wondering why those subway vents on every block smell so much more putrid on a steamy summer day. Or how it is possible to smell a food cart from all the way down the street.

It turns out the combination of heat and humidity allow bacteria to grow faster and smells to travel further. Increasing temps mean molecules move faster, resulting in enzymes speeding up metabolism and cells quickly increasing in size. Heat is bacteria’s best friend.

So when you get stuck with one those incredibly humid days, smells become only more potent. The water in the air causes these odors to dissolve, trapping them longer than if it were a dry day outside.

To many, New York is the city of dreams, but you have to be willing to accept it for the good, the bad, and the smelly.