# Evaluation of Different Control Algorithms for Carbon Dioxide Removal with Membrane Oxygenators
###### Abstract  
Membrane oxygenators are devices that benefit from automatic control. This is especially true for implantable membrane oxygenators--a class of wearable rehabilitation devices that show high potential for fast recovery after lung injury. We present a performance comparison for reference tracking of carbon dioxide partial pressure between three control algorithms--a classical proportional-integral (PI) controller, a modern non-linear model predictive controller, and a novel deep reinforcement learning controller. The results are based on simulation studies of an improved compartmental model of a membrane oxygenator. The compartmental model of the oxygenator was improved by decoupling the oxygen kinetics from the system and only using the oxygen saturation as an input to the model. Both the gas flow rate and blood flow rate were used as the manipulated variable of the controllers. All three controllers were able to track references satisfactorily, based on several performance metrics. The PI controller had the fastest response, with an average rise time and settling time of 1.18 s and 2.24 s and the lowest root mean squared error of 1.06 mmHg. The NMPC controller showed the lowest steady state error of 0.17 mmHg and reached the reference signal with less than 2% error in 90% of the cases within 15 s. The PI and RL reached the reference with less than 2% error in 84% and 50% of the cases, respectively, and showed a steady state error of 0.29 mmHg and 0.5 mmHg. m +
Footnote †: journal: Applied Sciences  
State-of-the-art membrane oxygenators consist of a packing of cylindrical hollow and asymmetric polymethylpentene fibers that are usually arranged concentrically along the long axis of the device. The blood flows on the shell side of the membrane fibers and is pumped by a blood pump, while the sweep gas is pumped through the lumen side of the membranes. The gas phase and the blood phase exchange CO\({}_{2}\) and O\({}_{2}\) through the permeable membrane, due to the partial pressure differences of the gases in both phases. The sweep gas usually consists of O\({}_{2}\) and N\({}_{2}\) in different ratios, while the CO\({}_{2}\) concentration should be close to zero, in order to maximize partial pressure differences. Thus, CO\({}_{2}\) diffuses from the blood into the sweep fluid and gets removed to the ambient, while O\({}_{2}\) diffuses through the membrane into the blood. For a detailed review of membrane oxygenators, the interested reader is referred to [5]. In the clinics, the heart-lung machine (oxygenator, blood pump, and all periphery) is controlled by a perfusionist. The perfusionist is a highly trained member of the medical staff whose role [6], among others, is to adjust the parameters of the blood oxygenator--blood flow rate, gas flow rate, and sweep oxygen--content in a way that sets the CO\({}_{2}\) partial pressure and blood oxygenation at desired levels [7]. Due to the human factor, this process is prone to errors that can lead to serious injuries to tissues and organs [8]. An automatic controller with accurate reference tracking can reduce the costs and treatment risks. For future wearable intracorporeal membrane oxygenators, automatic control is obligatory, since a perfusionist is not available outside a clinical setting. Therefore, here we present a feasible method to automatically control these classes of devices. Many efforts can be found in the literature that attempt to automate the heart-lung machine. Most of the works focus on controlling blood oxygenation with proportional-integral (PI) controllers, but some also take care of CO\({}_{2}\) removal. [PERSON] et al. [9] developed a PI controller with gain scheduling for the control of both blood gases. [PERSON] et al. recently proposed a self-tuning fuzzy-PI [10] that follows setpoints for the CO\({}_{2}\) partial pressure in the blood. [PERSON] et al. [11] proposed a fractional PI that controls the oxygen partial pressure. [PERSON] et al. [12] presented a linear quadratic gaussian controller to control the oxygenation of the blood.