It’s just hard to get work done in the heat. It's bright sunny and distracting and sometimes it can feel too hot to even move unless the air conditioning is blowing right on you.

New research is showing that the lazy days of summer can also slow down your brain. Can't cool off this summer? Walking around in a trance? Turns out, according to science, the brain fog of summer may not be in your head.

New research published in PLOS Medicine suggests heat waves can slow us down in ways we may not realize. Heat stress, or when too much heat, is absorbed by the body can cause extreme exhaustion but can also mess with our thinking, making things like everyday tasks and simple math a little harder to do.

On top of it, heat waves can have devastating consequences for global public health. Many buildings and homes are designed to trap or hold on to the heat when it is cold outside but they can also maintain those high temperatures even when the air outside warms up.

Doctors said there is evidence that our brains are susceptible to outdoor temperature abnormalities but U.S. adults spend about 90 percent of their time indoors. There is not enough data to show how inside temperatures affect people’s daily habits and living.

To learn more, researchers observed college students living in dorms during a Boston summer heat wave in 2016. Half of the students lived in buildings with central air conditioning, where the indoor air temperature averaged 71 degrees Fahrenheit. The other half lived in dorms with no air conditioning, where air temperatures averaged almost 80 degrees Fahrenheit.

Then, the researchers looked at how a summer heat wave affected the students' cognitive function by administering tests via the students' cell phones twice a day for 12 days. The tests included elementary math, addition and subtraction problems, as well as questions that measured their attention and processing speed.

The research team found that the students who were in the non-air conditioned buildings had slower reaction times, lower performance scores and a drastically decreased number of correct responses on simple math tests. The results show the heat wave got the best of them and their critical thinking skills. The findings add to a growing body of evidence that documents the effect of heat on mental performance, both in schools and workplaces. For instance, past studies found employee productivity is highest at about 72 degrees and gradually decreases as the temperatures exceeded the mid-80s.

Overall, doctors said they still need to learn more about how our bodies and brain respond to heat. They also point out that the students studied were young and healthy and do not represent the elderly or the populations that are more vulnerable to the effects of extreme heat. But heat does seems to interfere with complex tasks.

If you need to do some hard thinking or find yourself feeling extra spacey this summer you may want to schedule your most demanding jobs for the morning or evening or when its cooler, whether that is inside or outside.