To put it bluntly, you are just nervous or thoughtful. Usually you have this dream because you are scared or tired during the day, so the cerebral cortex is particularly active during sleep. When I wake up, adrenaline surges and my heart naturally beats fast, as if this really happened. Don't worry, go to bed early, get up early, don't play mobile phones or watch horror movies before going to bed, and ensure a calm mood one hour before going to bed, and the quality of sleep will be better.