Microbes in the intestine can derive energy from the diet, host, or compounds secreted by other members of the consortium. Four classes of microbes may be considered, based on their predominant energy source: diet (purple), host (green), either (pink), or neither (orange). Competition for niche colonization is affected by differential growth rates (r- and K-selected species), utilization of exclusive substrates, susceptibility to host defenses (e.g. antimicrobial peptides), production of inhibitory products, and community organization (e.g. auto-inducers). Perturbation may occur, for example, via dietary change (e.g. changes in a micro or macronutrient or long-term fasting), by antibiotics that differentially select the microbiota, or changes in gastrointestinal tract structure (e.g. gastric bypass). Importantly, in this model, competition between the major classes affects host mucus layer, epithelial permeability, and inflammation, which has downstream metabolic consequences.