Pressure Flow Control

The model VanOsta2024 comes with the Pressure Flow Control (PFC) module.

import circadapt
import matplotlib.pyplot as plt
import numpy as np

from circadapt import VanOsta2024
model = VanOsta2024()

model.run(stable = True)

model['Solver']['store_beats'] = 10
model.run(10)

# plot
fig = plt.figure(figsize=(15,3))
plt.plot(model['Solver']['t']*1e3, model['Cavity']['p'][:, ['cLv', 'SyArt']]/133)
plt.xlabel('Time [ms]')
plt.ylabel('Pressure [mmHg]')
fig
../../../_images/b8684dfa0c933fc1129083e7eef1942c833662ca6e37c10f2cbf968b0ab3af7c.png ../../../_images/b8684dfa0c933fc1129083e7eef1942c833662ca6e37c10f2cbf968b0ab3af7c.png

By default, it is turned on to control cardiac output and mean arterial pressure.

model1 = VanOsta2024()
model1.run(stable = True)
model1['Solver']['store_beats'] = 10
model1['PFC']['p0'] = 15000
model1.run(10)

# plot
fig = plt.figure(figsize=(15,3))
plt.plot(model['Solver']['t']*1e3, model['Cavity']['p'][:, ['cLv', 'SyArt']]/133, c=[0.8, 0.8, 0.8])
plt.plot(model1['Solver']['t']*1e3, model1['Cavity']['p'][:, ['cLv', 'SyArt']]/133)
plt.xlabel('Time [ms]')
plt.ylabel('Pressure [mmHg]')
fig
../../../_images/b69342acf9e28b980c1bf988ca28fba0eff88efc72bdba5a84ada863ff92a343.png ../../../_images/b69342acf9e28b980c1bf988ca28fba0eff88efc72bdba5a84ada863ff92a343.png

Pressure Flow Control off

You can turn pressure flow control off.

model2 = VanOsta2024()
model2.run(stable = True)
model2['Solver']['store_beats'] = 10
model2['PFC']['is_active'] = False
model2['Patch']['Sf_act'] *= 0.5
model2['Patch']['k1'] *= 1.2
model2.run(9)

# plot
fig = plt.figure(figsize=(15,3))
plt.plot(model['Solver']['t']*1e3, model['Cavity']['p'][:, ['cLv', 'SyArt']]/133, c=[0.8, 0.8, 0.8])
plt.plot(model2['Solver']['t']*1e3, model2['Cavity']['p'][:, ['cLv', 'SyArt']]/133)
plt.xlabel('Time [ms]')
plt.ylabel('Pressure [mmHg]')
fig
../../../_images/c24ba03f4f74ebfe9eb8c00d54e9db73ff936334fd4338be6f4f0133c1dfdb99.png ../../../_images/c24ba03f4f74ebfe9eb8c00d54e9db73ff936334fd4338be6f4f0133c1dfdb99.png

Volume control

The total blood volume can be a model input parameter.

model3 = VanOsta2024()
model3.run(stable = True)
model3['Solver']['store_beats'] = 10
model3['PFC']['is_volume_control'] = True
model3['PFC']['target_volume'] = 0.001

model3.run(9)

# plot
fig = plt.figure(figsize=(15,3))
plt.plot(model['Solver']['t']*1e3, model['Cavity']['p'][:, ['cLv', 'SyArt']]/133, c=[0.8, 0.8, 0.8])
plt.plot(model3['Solver']['t']*1e3, model3['Cavity']['p'][:, ['cLv', 'SyArt']]/133)
plt.xlabel('Time [ms]')
plt.ylabel('Pressure [mmHg]')
fig
../../../_images/475768c3348a6ea6c76c014c7b05c79b5c3ed6eabf74d81049193e80c0471b22.png ../../../_images/475768c3348a6ea6c76c014c7b05c79b5c3ed6eabf74d81049193e80c0471b22.png