When you inhale (breathe in), the diaphragm, a muscle located beneath the lungs, contracts and moves downward, while the muscles between the ribs contract and pull upward. This action increases the size of the thoracic (chest) cavity and decreases the pressure inside it, causing air to rush into the lungs through the nose or mouth. The air passes through the nasal passages, pharynx, larynx (voice box), and trachea, then into the bronchial tubes and smaller bronchioles, finally reaching tiny air sacs called alveoli. In the alveoli, oxygen from the air diffuses into the blood capillaries to be transported throughout the body
. When you exhale (breathe out), the diaphragm relaxes and moves upward into the chest cavity, and the muscles between the ribs relax, decreasing the volume of the thoracic cavity and increasing the pressure inside. This forces air, now rich in carbon dioxide (a waste product from cellular respiration), out of the lungs and through the respiratory tract to be expelled from the body via the nose or mouth. The process also involves elastic recoil of the lungs and sometimes the contraction of abdominal muscles during forced exhalation
. In summary, inhalation brings oxygen into the lungs for gas exchange, and exhalation removes carbon dioxide from the body, maintaining vital respiratory function