|
TPCCLIB
|
Simulation of compartment models with loss rate constant. More...
#include "tpcclibConfig.h"#include <stdio.h>#include <stdlib.h>#include <math.h>#include <time.h>#include <string.h>#include "tpccm.h"Go to the source code of this file.
Functions | |
| int | simC3vpKLoss (double *t, double *ca, double *cb, const int nr, const double k1, const double k2, const double k3, const double k4, const double k5, const double k6, const double kLoss, const double f, const double vb, const double fa, const int vvm, double *cpet, double *cta, double *ctb, double *ctc, double *ctab, double *ctvb) |
| int | simC2l (double *t, double *ca, const int nr, const double k1, const double k2, const double k3, const double kLoss, double *ct, double *cta, double *ctb) |
| int | simC2vl (double *t, double *ca, double *cb, const int nr, const double k1, const double k2, const double k3, const double kL, const double f, const double vb, const double fa, const int vvm, double *cpet, double *cta, double *ctb, double *ctab, double *ctvb) |
Simulation of compartment models with loss rate constant.
Definition in file simkloss.c.
| int simC2l | ( | double * | t, |
| double * | ca, | ||
| const int | nr, | ||
| const double | k1, | ||
| const double | k2, | ||
| const double | k3, | ||
| const double | kLoss, | ||
| double * | ct, | ||
| double * | cta, | ||
| double * | ctb ) |
Simulate tissue TAC using 2 tissue compartment model (in series) and plasma TAC, at plasma TAC times. In contrary to the common model, kLoss represents a direct loss rate from the 2nd tissue compartment to venous plasma.
Memory for ct must be allocated in the calling program. To retrieve the separate tissue compartment TACs, pointer to allocated memory for cta and ctb can be given; if compartmental TACs are not required, NULL pointer can be given instead.
The units of rate constants must be related to the time unit; 1/min and min, or 1/sec and sec.
| t | Array of time values. |
| ca | Array of arterial activities. |
| nr | Number of values in TACs. |
| k1 | Rate constant of the model. |
| k2 | Rate constant of the model. |
| k3 | Rate constant of the model. |
| kLoss | Rate constant of the model. |
| ct | Pointer for TAC array to be simulated; must be allocated. |
| cta | Pointer for 1st compartment TAC to be simulated, or NULL. |
| ctb | Pointer for 2nd compartment TAC to be simulated, or NULL. |
Definition at line 169 of file simkloss.c.
| int simC2vl | ( | double * | t, |
| double * | ca, | ||
| double * | cb, | ||
| const int | nr, | ||
| const double | k1, | ||
| const double | k2, | ||
| const double | k3, | ||
| const double | kL, | ||
| const double | f, | ||
| const double | vb, | ||
| const double | fa, | ||
| const int | vvm, | ||
| double * | cpet, | ||
| double * | cta, | ||
| double * | ctb, | ||
| double * | ctab, | ||
| double * | ctvb ) |
Simulate tissue TAC using 2 tissue compartment model and plasma TAC, at plasma TAC times, considering also arterial and venous vasculature. The efflux from 2nd tissue compartment (at rate kL) goes directly to blood.
Memory for cpet must be allocated in the calling program. To retrieve the separate tissue compartment TACs, pointer to allocated memory for cta, ctb, ctab, and/or ctvb can be given; if compartmental TACs are not required, NULL pointer can be given instead.
The units of rate constants must be related to the time unit; 1/min and min, or 1/sec and sec. If blood flow is set to 0, function assumes that f>>k1, and Cvb=Cab.
| t | Array of time values. |
| ca | Array of arterial plasma activities. |
| cb | Array of arterial blood activities. |
| nr | Number of values in TACs. |
| k1 | Rate constant of the model. |
| k2 | Rate constant of the model. |
| k3 | Rate constant of the model. |
| kL | Rate constant of the model. |
| f | Blood flow; if 0, function assumes that f>>k1, and Cvb=Cab. |
| vb | Vascular volume fraction. |
| fa | Arterial fraction of vascular volume. |
| vvm | Vascular volume modelling: set to 0 to use Cpet = Vb*Cb + (1-Vb)*Ct, or set to 1 to use Cpet = Vb*Cb + Ct. |
| cpet | Pointer for TAC array to be simulated; must be allocated. |
| cta | Pointer for 1st compartment TAC to be simulated, or NULL. |
| ctb | Pointer for 2nd compartment TAC to be simulated, or NULL. |
| ctab | Pointer for arterial TAC in tissue, or NULL. |
| ctvb | Pointer for venous TAC in tissue, or NULL. |
Definition at line 261 of file simkloss.c.
| int simC3vpKLoss | ( | double * | t, |
| double * | ca, | ||
| double * | cb, | ||
| const int | nr, | ||
| const double | k1, | ||
| const double | k2, | ||
| const double | k3, | ||
| const double | k4, | ||
| const double | k5, | ||
| const double | k6, | ||
| const double | kLoss, | ||
| const double | f, | ||
| const double | vb, | ||
| const double | fa, | ||
| const int | vvm, | ||
| double * | cpet, | ||
| double * | cta, | ||
| double * | ctb, | ||
| double * | ctc, | ||
| double * | ctab, | ||
| double * | ctvb ) |
Simulate tissue TAC using 3 tissue compartmental model with two parallel compartments, and plasma TAC, at plasma TAC sample times, considering also arterial and venous vasculature. The efflux from 3rd tissue compartment (C) goes directly to blood at rate kLoss.
Memory for cpet must be allocated in the calling program. To retrieve the separate tissue compartment TACs, pointer to allocated memory for cta, ctb, ctab, and/or ctvb can be given; if compartmental TACs are not required, NULL pointer can be given instead.
The units of rate constants must be related to the time unit; 1/min and min, or 1/sec and sec.
If blood flow is set to 0, function assumes that f>>k1, and Cvb=Cab.,
| t | Array of sample times. |
| ca | Array of arterial plasma activities. |
| cb | Array of arterial blood activities. |
| nr | Number of sample values in TACs. |
| k1 | Rate constant of the model. |
| k2 | Rate constant of the model. |
| k3 | Rate constant of the model. |
| k4 | Rate constant of the model. |
| k5 | Rate constant of the model. |
| k6 | Rate constant of the model. |
| kLoss | Rate constant of the model. |
| f | Blood flow; if 0, function assumes that f>>k1, and Cvb=Cab. |
| vb | Vascular volume fraction. |
| fa | Arterial fraction of vascular volume. |
| vvm | Vascular volume modelling: set to 0 to use Cpet = Vb*Cb + (1-Vb)*Ct, or set to 1 to use Cpet = Vb*Cb + Ct. |
| cpet | Pointer for TAC array to be simulated; must be allocated. |
| cta | Pointer for 1st tissue compartment TAC to be simulated, or NULL. |
| ctb | Pointer for 2nd compartment TAC to be simulated, or NULL. |
| ctc | Pointer for 3rd compartment TAC to be simulated, or NULL. |
| ctab | Pointer for arterial TAC in tissue, or NULL. |
| ctvb | Pointer for venous TAC in tissue, or NULL. |
Definition at line 36 of file simkloss.c.