Drux: Drug Release Analysis Framework
Project description
Overview
Drux is a Python-based framework for simulating drug release profiles using mathematical models. It offers a reproducible and extensible platform to model, analyze, and visualize time-dependent drug release behavior, making it ideal for pharmaceutical research and development. By combining simplicity with scientific rigor, Drux provides a robust foundation for quantitative analysis of drug delivery kinetics.
| PyPI Counter |
|
| Github Stars |
|
| Branch | main | dev |
| CI |
|
|
| Code Quality |
Installation
PyPI
- Check Python Packaging User Guide
- Run
pip install drux==0.2
Source code
- Download Version 0.2 or Latest Source
- Run
pip install .
Supported Models
Zero-Order
The Zero-Order model describes a constant rate of drug release over time. According to this model, the cumulative amount of drug released at time $t$ is given by:
$$ M_t = M_0 + k_0 t $$
where:
- $M_t (mg)$ is the cumulative absolute amount of drug released at time $t$.
- $M_0 (mg)$ is the initial amount of drug in the system. $M_0$ defaults to zero in this model.
- $k_0 (\frac{mg}{s})$ is the zero-order release rate constant.
Applications
- Tablets with extended release
- Transdermal Patches
- Implantable Device
- Intraocular Implants
- Infusion Systems
First-Order
The first-order drug release model describes a process where the rate of drug release is proportional to the remaining amount of drug in the system. According to this model, the cumulative amount of drug released at time $t$ is given by:
$$ M_t = M_0 (1 - e^{-kt}) $$
where:
- $M_t (mg)$ is the cumulative absolute amount of drug released at time $t$.
- $M_0 (mg)$ is entire releasable amount of drug (the asymptotic maximum).
- $k (\frac{1}{s})$ is the first-order release rate constant.
Applications
- Immediate-release tablets and capsules
- Liquid drug formulations (oral solutions, intravenous injections)
- Controlled-release matrix systems
- Elastomeric infusion pumps
Higuchi
The Higuchi model describes the release of a drug from a matrix system, where the drug diffuses through a porous medium. The Higuchi equation addressed important aspects of drug transport and release from planar devices. According to this model, the cumulative amount of drug released at time $t$ is given by:
$$ M_t = \sqrt{D(2c_0 - c_s)c_st} $$
where:
- $M_t (\frac{mg}{cm^2})$ is the cumulative absolute amount of drug released at time $t$
- $D ({\frac{cm^2}{s}})$ is the drug diffusivity in the polymer carrier
- $c_0 (\frac{mg}{cm^3})$ is the initial drug concentration (total concentration of drug in the matrix)
- $c_s (\frac{mg}{cm^3})$ is the solubility of the drug in the polymer (carrier)
⚠️ The Higuchi model assumes that $c_0 \ge c_s$
Applications
- Matrix Tablets
- Hydrophilic polymer matrices
- Controlled - Release Microspheres
- Semisolid Systems
- Implantable Drug delivery systems
Usage
Zero-Order Model
from drux import ZeroOrderModel
model = ZeroOrderModel(k0=0.1, M0=0)
model.simulate(duration=1000, time_step=10)
model.plot(show=True)
First-Order Model
from drux import FirstOrderModel
model = FirstOrderModel(k=0.003, M0=0.1)
model.simulate(duration=1000, time_step=10)
model.plot(show=True)
Higuchi Model
from drux import HiguchiModel
model = HiguchiModel(D=1e-6, c0=1, cs=0.5)
model.simulate(duration=1000, time_step=10)
model.plot(show=True)
Issues & bug reports
Just fill an issue and describe it. We'll check it ASAP! or send an email to drux@openscilab.com.
- Please complete the issue template
You can also join our discord server
References
1- T. Higuchi, "Rate of release of medicaments from ointment bases containing drugs in suspension," Journal of Pharmaceutical Sciences, vol. 50, no. 10, pp. 874–875, 1961.
2- D. R. Paul, "Elaborations on the Higuchi model for drug delivery," International Journal of Pharmaceutics, vol. 418, no. 1, pp. 13–17, 2011.
3- R. T. Medarametla, K. V. Gopaiah, J. N. Suresh Kumar, G. Anand Babu, M. Shaggir, G. Raghavendra, D. Naveen Reddy, and B. Venkamma, "Drug Release Kinetics and Mathematical Models," International Journal of Science and Research Methodology, vol. 27, no. 9, pp. 12–19, Sep. 2024.
4- R. Vaju and K. V. Murthy, "Development and validation of new discriminative dissolution method for carvedilol tablets," Indian Journal of Pharmaceutical Sciences, vol. 73, no. 5, pp. 527–536, Sep. 2011.
5- S. Dash, "Kinetic modeling on drug release from controlled drug delivery systems," Acta Poloniae Pharmaceutica, 2010.
6- K. H. Ramteke, P. A. Dighe, A. R. Kharat, S. V. Patil, Mathematical models of drug dissolution: A review, Sch. Acad. J. Pharm., vol. 3, no. 5, pp. 388-396, 2014.
Show your support
Star this repo
Give a ⭐️ if this project helped you!
Donate to our project
If you do like our project and we hope that you do, can you please support us? Our project is not and is never going to be working for profit. We need the money just so we can continue doing what we do ;-) .
Changelog
All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
Unreleased
0.2 - 2025-09-27
Added
- Zero-order model
- First-order model
Changed
README.mdmodified- Test system modified
- Release range bug in
time_for_releasefixed matplotlibimport bug fixedplotmethod modified
0.1 - 2025-07-27
Added
- Base model
- Higuchi model
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file drux-0.2.tar.gz.
File metadata
- Download URL: drux-0.2.tar.gz
- Upload date:
- Size: 15.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
be353cf8fd5e0dbb5c8e80f4418cdc9dc606f51d66b67ec49c1c142e8cadf271
|
|
| MD5 |
38d66b6f1eb2aec0007c825e9431f58e
|
|
| BLAKE2b-256 |
4a6f33c4005b16ddb23920b9c54eca70a842f9969a93a9a14e5a6252a9432d1b
|
File details
Details for the file drux-0.2-py3-none-any.whl.
File metadata
- Download URL: drux-0.2-py3-none-any.whl
- Upload date:
- Size: 11.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
c272075d6e6e7a34684a9d4fc3b5766e2e57ddcc2106daf429d816984b42fcfc
|
|
| MD5 |
2d7b799f7786663f03cdb391c1a5d4d3
|
|
| BLAKE2b-256 |
5205e4f9f1017ff13c3adc0f8535163936261a0f29df18ccfb4e23b0781d64d1
|