I have a sleep study coming up next month. My primary care doctor wanted to order one, because I do have trouble sleeping. Although it could be Non 24 hour sleep wake disorder, she also might think it could be sleep apnea. [https://en.wikipedia.org/wiki/Non-24-hour_sleep%E2%80%93wake_disorder] The only way to test for non 24, is to do a 24 hour time isolated surveiled test. In other words, put me in a room, take away my phone, and computer. Uh... no thanks!! I found this link, which explains way more about non 24 that I ever needed to know lol.
I can actually play with my sleep schedules. For instance the Olympics are coming up, and I'm a huge fan. Coincidentally, I have the test the day after the closing ceremony. Since they're in Japan this time, I'm sure I'll be staying up late watching events, and sleeping between the daytime and primetime broadcasts, but let's not forget about latenight.
I tend to stay up all night on purpose most of the time. I'll get wrapped up in the case I'm watching, or the research I'm doing, because I want to keep doing that, even though I know it's 3 AM and I need to go to bed lol.
This has roots from when I first had access to the internet. My sister would want to talk on the phone all! flippin! day! and we had dial-up. I'd stay up into the early morning hours reading blogs, this was back in 2003, because she'd be in bed and wouldn't be on the phone.
This can also happen because of the extremely painful headaches I get. I'll wake up in the middle of the night, and not be able to get back to sleep, or I'll go to bed and not sleep, because of the headache.