We present a brief review of sleep research which, when combined with psychoanalytic experience, has led to the hypothesis that REM sleep and dreaming serve the function of adaptation by the process of integration of information. We then report the results of a study of dreams, based on this hypothesis. We studied dreams and their relation to waking mental activity and found a correlation between problems in manifest dreams and those in pre- and postsleep waking life. Dreams can be understood on the basis of problems that appear in them. We also found evidence for a relation between the solution of problems in dreams and the fate of those problems the next day. We discuss these findings in relation to some of the controversies about dreaming, and then present suggestions for future research.