In Descartes' First Meditation, Descartes writes that he has come to the conclusion that many of the opinions he held in his youth are doubtful, and consequently all ideas built upon those opinions are also doubtful. He deduces that he will have to disprove his current opinions and then construct a new foundation of knowledge if he wants to establish anything firm and lasting that is absolutely true in the sciences. But rather than disprove each of his opinions individually, Descartes attacks the principles that support everything he believes with his Method of Doubt. The Method of Doubt is Descartes' method of fundamental questioning in which he doubts everything that there is the slightest reason to doubt. Descartes does not necessarily believe that everything he doubts is true. He does believe, however, that whatever cannot be doubted for the slightest reason must be true. Descartes concludes that none of his former opinions are safe.
This "evil demon" that created him could not only deceive him about his perceptions, it could also cause him to go wrong when performing even the simplest acts of reasoning. The theory that he comes up with is much like the idea of the "Matrix". No physical, material objects actually exist. All that one can be sure of is their mind, not the physical world.
Descartes later concludes that there are material objects existing outside our minds, with the birth of the mind/body problem, and his idea of interactionism. In interactionism, the mind and body interact with a causal relationship. This lead to the view of materialism, where the only things that really exist are in the physical, material world. This is the opposite view of the evil demon hypothesis. Materialism allows for a transition of beliefs from the material to the physical existence.