People's long-term memory is stored in the hippocampus. The hippocampus is like the hard disk of the brain. It stores the most memory, but it has the slowest response. Just like what happened many years ago, you may not remember if others don't mention it. This is because it is stored in the hippocampus system and cannot be mobilized as easily and quickly as the lower nervous layer of our brain, so it is difficult for you to encounter those things that happened decades ago.
Why do we dream is because our subconscious mind comes into contact with those death fragments in the process of activity, which we can simply understand as death fragments, because it is a bit difficult and unnecessary to understand the sensitivity of information recorded by nerves. We dream because the subconscious mind suddenly touches the fragments of the past, and then the brain will form an active impression, which is not what you think of on your own initiative, but what the subconscious mind instills in your dream. The characteristics of dreams are basically headless and tailless, and you don't know why such a scene suddenly came.
Dreaming is just a way for our brains to relax, and according to scientific research, the content of dreams is controllable. After some technical training, people can generally control their dreams, and it is also beneficial to have nightmares. He can relax your brain, so as long as you dream without affecting your normal rest and get up with a full stomach the next morning, there will be no problem.