Practical Chemistry Framework (pchem-framework) 🔬🧪
An open-source Python framework for practical chemistry calculations, data analysis, and visualization. Designed for students, educators, and researchers.
Table of Contents
Key Features 🚀
Chemical Calculations
- Stoichiometry: Limiting reactant analysis, yield calculations
- Solution Chemistry: Molarity <-> molality conversions, dilution calculations
- Acid-Base Chemistry: pH calculations for strong/weak acids/bases, buffers
- Thermodynamics: Enthalpy, entropy, and Gibbs free energy calculations
Data Handling & Visualization
- File I/O: CSV, JSON, and text file support with pandas integration
- Unit Conversion: Robust dimensional analysis with Pint library
- Data Analysis: Statistical functions and linear regression
- Plotting: Publication-ready graphs for kinetics and titration curves
Installation ⚙️
# Stable version
pip install pchem-framework
# Development version
pip install git+https://github.com/somkietacode/pchem-framework.git
Requirements: Python 3.8+ with NumPy, Pandas, Matplotlib, and Pint
Quick Start 🏁
Basic Calculations
from pchem_framework.calculations import molar_mass, ph
# Calculate molar mass of H2SO4
atomic_weights = {'H': 1.008, 'S': 32.07, 'O': 16.00}
print(molar_mass.calculate_molar_mass('H2SO4', atomic_weights)) # Output: 98.086 g/mol
# Calculate buffer pH (Henderson-Hasselbalch)
print(ph.buffer_ph(0.1, 0.2, 4.76)) # Output: 5.06
Data Analysis Workflow
from pchem_framework.data_handling import file_io, plotting
# Load experimental data
kinetic_data = file_io.read_csv("kinetic_data.csv")
# Generate concentration-time plot
fig = plotting.plot_concentration_vs_time(
kinetic_data['time'],
kinetic_data['concentration'],
title="First-Order Reaction Kinetics"
)
fig.savefig("kinetics_plot.png")
Core Functionality 📚
Calculations Module
from pchem_framework.calculations import (
molar_mass, # Formula parsing and MW calculations
stoichiometry, # Reaction balancing and yield predictions
concentration, # Solution preparation calculations
ph, # Acid-base equilibrium calculations
kinetics, # Reaction rate analysis
thermodynamics # Energy calculations
)
Data Handling Module
from pchem_framework.data_handling import (
file_io, # Unified data import/export
unit_conversion, # Dimensional analysis
data_analysis, # Statistical methods
plotting # Scientific visualization
)
Documentation 📖
Explore detailed guides and tutorials in our documentation:
- Full API Reference
- Example Notebooks
- Basic Stoichiometry Calculations
- Advanced Buffer Solutions Analysis
- Kinetic Data Processing Tutorial
Contributing 🤝
We welcome contributions! Please see our:
To report bugs or request features:
License 📄
This project is licensed under the MIT License - see the LICENSE file for details.
Support ☕
If you find this project useful, please consider:
- Starring the Repository
- Citing us in your publications:
@software{pchem_framework, title={Practical Chemistry Framework}, author={Your Name}, year={2024}, publisher={GitHub}, journal={GitHub repository}, howpublished={\url{https://github.com/your-username/pchem-framework}} }
Metadata
Release files for pchem-framework 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| pchem_framework-0.1.0.tar.gz | 11.0 kB | Without provenance | Details for pchem_framework-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| pchem_framework-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for pchem_framework-0.1.0-py3-none-any.whl |
Total release size: 23.0 kB
Release files / pchem_framework-0.1.0.tar.gz
| Download URL | pchem_framework-0.1.0.tar.gz |
|---|---|
| Size | 11.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
203687b495b238cd6b8457cce92052b3879dc3e176a79b297e562f1b71af2f44
|
|
BLAKE2b-256 checksum How to use checksums |
93efa086862d4694285fa13551800a236d3caebd6ad1a721c06381d9e7ca461e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.0
|
Release files / pchem_framework-0.1.0-py3-none-any.whl
| Download URL | pchem_framework-0.1.0-py3-none-any.whl |
|---|---|
| Size | 11.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
91efdf1d15addf5b099730ac9aa19b5f291429ebe2e1b2e31ae472e3fc07bf90
|
|
BLAKE2b-256 checksum How to use checksums |
5eab1646459a38211996b8e38a7e24a1fd54ab7401f48d0cf22a2864c4984a39
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.9.0
|
Security for pchem-framework 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.