Medical Breathing
This page summarizes the mathematical models used by ACE Medical Breathing. For the numerical methods used to apply the differential equations, see General Considerations.
Respiratory System
Section titled “Respiratory System”The model uses two gas reservoirs: alveoli and blood, connected as follows:
Ventilation exchanges gas with the surroundings and perfusion drives exchange of gas between alveoli and blood. in blood gets continuously converted to . Gas exchanges are simplified as continuous flows. No simulation of actual breathing cycles is done.
Lung Volumes
Section titled “Lung Volumes”Tidal and capacity volumes of the lungs are scaled by pneumothorax (PTX):
- : Tidal volume.
- : Lung capacity.
- : Default tidal volume.
- : Default lung capacity.
- : PTX progress, expressed as the fraction of lung volume lost.
The factors of account for dead space.
Respiratory Rate
Section titled “Respiratory Rate”Respiratory rate increases to compensate for the loss of lung volume:
- : Respiratory rate in breaths per minute.
- : Default respiratory rate (
m_fDefaultRespiratoryRateBPM). - : Maximum respiratory rate (
m_fMaxRespiratoryRateBPM).
Ventilation
Section titled “Ventilation”The volume-fraction-based ventilation rate is given below:
- : Fractional ventilation rate.
Ventilation equilibrates partial gas pressures between alveoli and surroundings:
- , : Alveolar and partial pressures.
- : Supplied pressure, normally 19.925 kPa.
- : Ventilation rate of increase in alveolar partial pressure.
- : Ventilation rate of decrease in alveolar partial pressure.
The partial pressure of the surroundings is currently approximated as 0 kPa. An equipped mask raises to 95 kPa and enforces .
Cellular Respiration
Section titled “Cellular Respiration”is consumed by cellular respiration and is produced in return. The ratio between production and consumption depends on the chemical reactions that take place (i.e. aerobic vs anaerobic conditions) and the ratio is given by the respiratory exchange rate . The values are adjusted through linear interpolation between hypoxic and normal values:
- : consumption rate.
- , : Normal and hypoxic consumption rates (
m_fDefaultOxygenConsumptionMMOLPSandm_fHypoxicOxygenConsumptionMMOLPS). - , , : Current, normal, and hypoxic respiratory exchange ratios (
m_fDefaultRERandm_fHypoxicRER). - : Peripheral blood saturation.
- , : Normal and hypoxic saturation levels (
m_fDefaultSpO2andm_fHypoxicMetabolismSpO2). - : Interpolation fraction.
- : production rate.
Note that both consumption and production rates are defined as positive values. The sign convention will be important later for the correct signs in the ODEs.
Reduced saturation lowers consumption, which simulates the body prioritizing vital organs.
Perfusion
Section titled “Perfusion”Perfusion is driven by cardiac output:
- : Lung perfusion.
- : Cardiac output.
The -based term accounts for loss of surface area through pneumothorax. The exponent of comes from converting a volume-based quantity to an area-based quantity.
Exchange
Section titled “O2 Exchange”binding to hemoglobin at the alveolar pressure follows a Hill function:
- : Equilibrium saturation at the alveolar pressure.
- : Hemoglobin dissociation constant.
- : Hill coefficient for hemoglobin.
The saturation level for venous blood is derived by subtracting consumed from :
- : saturation of venous blood.
- : Heme concentration in blood.
The flux for loading hemoglobin at alveoli is calculated as follows:
- : transfer flux from alveoli to blood.
- : Saturation equilibration rate scale.
- : Bound for saturation increase.
- : Bound for saturation decrease.
- : Default heart rate (
m_fDefaultHeartRateBPM). - : Default stroke volume (
m_fDefaultStrokeVolumeML).
The fluxes are scaled by perfusion and capped by the loading capacity of hemoglobin.
Exchange
Section titled “CO2 Exchange”exchange is driven by an imbalance between venous concentration and alveolar partial pressure . The equilibrium is given by Henry’s law:
- : Henry constant for in blood.
- : Venous blood concentration.
The flux for equilibration is calculated as follows:
- : transfer flux from blood to alveoli.
- : Carbonate dehydration rate scale. Determines how fast equilibration takes place.
- : Maximum rate scale preventing overshoot of Henry’s law equilibrium.
- : Bound for forward concentration change from blood to alveoli.
- : Fixed blood concentration.
The flux is scaled by perfusion and capped by total content of blood. The equilibration is furthermore prone to overshooting, which is why a cap is imposed on the rate scale:
- : Time step of the simulation.
- : Body temperature.
- : Universal gas constant.
- : Venous blood volumes (70% of total blood volume).
Net Evolution of Gas Pressures and Concentrations
Section titled “Net Evolution of Gas Pressures and Concentrations”Ventilation, perfusion, and cellular respiration are combined in ODEs. For evolution of alveolar partial pressures:
Peripheral blood saturation:
concentration in venous blood:
- : Simulation time.
- : Arterial blood volumes (30% of total blood volume).
Conversion between partial pressure and amount of substance is done through the ideal gas law:
Obstructed Airway, Cardiac Arrest and CPR
Section titled “Obstructed Airway, Cardiac Arrest and CPR”Tongue-based obstruction and vomit-based occlusion completely shut down any ventilation. Cardiac arrest additionally shuts down perfusion. Cellular respiration still keeps consuming from stale blood, leading to depletion and acidosis from accumulation. CPR can partially restore exchange with chest compression-induced blood flow and passive ventilation (m_fCPRPassiveVentilationRateBPM). An equipped mask additionally increases ventilation as described in Ventilation.
Changes to Cardiovascular System
Section titled “Changes to Cardiovascular System”An elevated respiratory rate raises the base heart rate target:
- : Shift added to base heart rate target.

