Magma of partial melting of the mantle, komatiite and picrite are produced. Magma develops within the mantle or crust where the temperature and pressure conditions favor the molten state. After its formation, magma buoyantly rises toward the Earth's surface. As it migrates through the crust, magma may collect and reside in magma chambers (though recent work suggests that magma may be stored in trans-crustal crystal-rich mush zones rather than dominantly liquid magma chambers ). Magma can remain in a chamber until it cools and crystallizes forming igneous rock, it erupts as a volcano, or moves into another magma chamber.There are two
Magma known processes by which magma changes: by crystallization within the crust or mantle to form a pluton, or by volcanic eruption to become lava or tephra. When magma cools it begins to form solid mineral phases. Some of these settle at the bottom of the magma chamber forming cumulates that might form mafic layered intrusions. Magma that cools slowly within a magma chamber usually ends up forming bodies of plutonic rocks such as gabbro, diorite and granite, depending upon the composition of the magma. Alternatively, if the magma is erupted it forms volcanic rocks such as basalt, andesite and rhyolite