English | 中文文档
reaction-balancer
A precise chemical-equation balancer that uses exact rational arithmetic and CIAAW atomic weights to generate printable recipe sheets (Excel format) from Markdown input.
Features
1. Exact scientific computation
- Uses CIAAW (2024) standard atomic weights.
- All internal math uses sympy.Rational (exact fractions), eliminating round-off errors.
- Linear algebra–based solver ensures correct balancing or gives an informative error if impossible.
2. Flexible input syntax
- Supports parentheses and fractional subscripts:
Ni(NO3)2(H2O)6Fe7/8SeLa1.8Sr0.2CuO4.12
- Optional basis specification (e.g., ) allows partial balancing, which is useful for sol–gel and oxide-precursor routes.
3. Automatic Excel output
- Produces a ready-to-print xlsx recipe sheet with formatted layout.
- Column widths, styles, and alignment handled automatically—no manual editing required.
4. Reproducible and traceable
- Input is a Markdown document, allowing you to record:
- sample IDs
- furnace schedule
- experimental notes
- Perfect for lab notebooks and long-term traceability.
5. Designed for materials synthesis
Suitable for:
- solid-state reactions
- flux growth
- hydrothermal / sol-gel precursor balancing
- cuprates, pnictides, nickelates, chalcogenides, and general inorganic synthesis
Installation
pip install balancer
or if using uv:
uv tool install balancer
Usage
Run the following command in any directory:
python -m balancer
# or use uv:
# uv run balancer
This program needs an input file (default: ./input.md).
If input.md is not found, a template will be automatically created in the current working directory.
Example input:
Corresponding output:
You may also specify an explicit filepath:
balancer <filepath>
Metadata
Release files for reaction-balancer 2.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 |
|---|---|---|---|---|
| reaction_balancer-2.1.0.tar.gz | 70.3 kB | Without provenance | Details for reaction_balancer-2.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| reaction_balancer-2.1.0-py3-none-any.whl | Python 3 | none | any | Details for reaction_balancer-2.1.0-py3-none-any.whl |
Total release size: 91.9 kB
Release files / reaction_balancer-2.1.0.tar.gz
| Download URL | reaction_balancer-2.1.0.tar.gz |
|---|---|
| Size | 70.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
c64337825a3fd4cbf1ba416f22987c060ab3f8a6daf7728af70208e139e03c33
|
|
BLAKE2b-256 checksum How to use checksums |
ed65d6c0f902731d19a6aae52a469e9d821e00c4b4d547e203456b33fd87f4ac
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.8.22
|
Release files / reaction_balancer-2.1.0-py3-none-any.whl
| Download URL | reaction_balancer-2.1.0-py3-none-any.whl |
|---|---|
| Size | 21.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
2fbca569ac7d818c098db14a8ea535f927f23f4e764e7e878db09119d14d51be
|
|
BLAKE2b-256 checksum How to use checksums |
9837304a299491c9275485158a0d593b31b04349b9cc91545a9b95e97a92fe83
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.8.22
|
Security for reaction-balancer 2.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.