Gas Molecule Density in the Lung Alveoli

Initializing live version
Download to Desktop

Requires a Wolfram Notebook System

Interact on desktop, mobile and cloud with the free Wolfram Player or other Wolfram Language products.

Diffusion is a vital process in human physiology. Diffusion of gas particles from the lung alveoli to the pulmonary capillaries enables the exchange of out of the blood and into the blood. The Smoluchowski differential equation models the probability distribution of alveolar gas particles in space and time. A 3D graph shows the results.

Contributed by: Abbey Todd, Rithika Treasa John, Bhavana Iyengar and Uma Malde (January 2024)
Open content licensed under CC BY-NC-SA



This Demonstration considers the diffusion of gas particles from the lung alveoli to the pulmonary capillaries. An initial particle density is represented by a Gaussian distribution centered around . This provides the initial condition for the Smoluchowski differential equation:

to give the distribution with the potential


is the potential acting on the particle density at time along the alveoli–pulmonary capillary coordinate. You can choose the parameters , and ; represents the thickness of the capillary that the molecule is diffusing into. The thicker the capillary, the less particle density will diffuse into the bloodstream. The variable represents the air pressure from the lungs. Note that as air pressure increases, more particles diffuse across the membrane. The variable is the permeability of the capillary wall. The more permeable the capillary, the more the gas molecule can diffuse into the bloodstream.

When , the particles are within the alveoli; when , the particles are within the pulmonary capillary.


[1] K. Schulten. "Smoluchowski Diffusion Equation." University of Illinois Urbana-Champaign. (Nov 20, 2023)

Feedback (field required)
Email (field required) Name
Occupation Organization
Note: Your message & contact information may be shared with the author of any specific Demonstration for which you give feedback.