If you try to relax and follow good bedtime habits yet still cannot get enough restful sleep, talk with your doctor. If your doctor suspects you might have a sleep disorder, you might be referred for a sleep study, called a polysomnography. The sleep study will help determine if you have apnea, restless legs syndrome, or some other problem. All of these disorders require specific therapy that your doctor can prescribe.