You feel nausea coming on. Your stomach starts to roil. Then, all of a sudden, you make a dash for the bathroom, just in time to empty the contents of your stomach into the toilet. Something has upset your stomach, but you're not sure how or why. Although it seems pretty simple, throwing up or vomiting is actually a fairly complex process involving both the brain and the nervous system. To understand how throwing up occurs, you must know how vomiting is triggered and what happens during the act of vomiting itself.
The act of throwing up requires a trigger or stimulus. Basically, many different stimulae exist that induce vomiting, and the type of stimulus determines which part of the body transmits the signal to the brain. A structure of the brain called the pons is where all vomiting is coordinated, and there's also a chemoreceptor zone in the brain designated specifically for chemical triggers that induce vomiting. When certain drugs or toxins cross the blood-brain barrier to stimulate this zone, it leads to the act of vomiting. Other triggers stimulate the nervous system into causing the body to vomit. When you try to eat something disgusting or stick your finger down your throat, it causes one of your cranial nerves to initiate your gag reflex. A different cranial nerve is involved with motion sickness. If your stomach is irritated by food poisoning or chemcials, your enteric nervous system triggers vomiting, while your central nervous system is associated with stress-related vomiting. Regardless of the stimulus, your brain and nervous system are integral parts in the process of vomiting.
Once vomiting has been triggered, the act of throwing up itself actually occurs. This process typically occurs in steps. First of all, the mouth begins to produce excess quantities of saliva to serve as a protective barrier for the teeth. Next, waves of contractions begin in the small intestine, forcing the contents of the stomach upwards. Both the pyloric and esophogeal sphinctors relax and the stomach muscles contract, further assisting the body in expelling the contents of the stomach. Finally, retching typically occurs as well, along with sweating and a rapid heartbeat.