In geology, a vein is a distinct sheetlike body of crystallized minerals within a rock. Veins form when mineral constituents carried by an aqueous solution within the rock mass are deposited through precipitation. The hydraulic flow involved is usually due to hydrothermal circulation.
Veins are classically thought of as being the result of growth of crystals on the walls of planar fractures in rocks, with the crystal growth occurring normal to the walls of the cavity, and the crystal protruding into open space. This certainly is the method for the formation of some veins. However, it is rare in geology for significant open space to remain open in large volumes of rock, especially several kilometers below the surface. Thus, there are two main mechanisms considered likely for the formation of veins: open-space filling and crack-seal growth.
Open space filling is the hallmark of epithermal vein systems, such as a , in greisens or in certain skarn environments. For open space filling to take effect, the confining pressure is generally considered to be below 0.5 GPa, or less than 3-5 kilometers. Veins formed in this way may exhibit a colloform, agate-like habit, of sequential selvages of minerals which radiate out from nucleation points on the vein walls and appear to fill up the available open space. Often evidence of fluid boiling is present. Vugs, cavities and geodes are all examples of open-space filling phenomena in hydrothermal systems.