Beans, beans, the musical fruit. The more you eat, the more you toot. But don't blame your flatulence on the poor legumes directly. The blame lies instead with the loads of little critters teeming in your gut.
Once you mash a bowl of barbecue baked beans into a fine mush in your mouth and stomach, it moves along to the small intestine. This organ is basically a molecular chop shop, where digestive enzymes strip your meal down for whatever bits and pieces your body can use and break them into smaller components that are more easily absorbed. Proteins get broken down into peptides and amino acids, fats into fatty acids and glycerol, and some carbohydrates into simple sugars. These are then absorbed through the intestinal wall to become fuel for your body.
This process isn’t so smooth with beans.
Their natural sweetness comes from a group of sugars called oligosaccharides (some of the more common ones in beans are raffinose and stachyose, which sound like rejected Musketeers). These sugars are hulking, awkward molecules. They’re far too big to slip though the intestinal wall on their own, and our guts’ enzymatic tool kit doesn’t have the right stuff to break the big things apart into more manageable pieces. So the sugars get a free ride though the small intestine. No one messes with them, and they move on into the large intestine intact.
Here their journey comes to a halt when they’re greeted by some of your closest friends, the 700+ species of bacteria that call your lower gut home. Fully capable of handling the big meal and never ashamed to have at your leftovers, the bacteria dig into the sugars. As they eat, their metabolic activity produces gases, hydrogen and methane among them. All that gas accumulates and eventually escapes your body as a fart, which may or may not be blamed on the dog.
Not all organisms have this problem with oligosaccharides, and some fungus species possess the right enzymes to break them down. These enzymes are easy enough to extract, and are often turned into gas-relieving supplements. Beano, the most well-known example, is made with the enzyme alpha galactosidase, derived from the fungus Aspergillus niger. Pop a tablet in your mouth before dinner, and the enzyme will snap those big sugars apart into handy little sugars like sucrose, glucose and fructose, giving you things your body can use and keeping you from giving a performance attributable to the musical fruit.