Rubberize
Rubberize converts raw Python code into readable mathematical notation so calculations can be clearly presented, reviewed, and documented.
Who is Rubberize For?
Rubberize is designed for:
- Scientists and Engineers: Simplify the presentation of complex calculations in Jupyter notebooks by rendering them as clear, typeset math.
- Educators and Students: Create visually appealing and easy-to-understand mathematical explanations directly from Python code.
- Technical Writers: Generate LaTeX representations of Python calculations for seamless integration into professional-grade documents.
If you work with Python code that involves mathematical computations and want to bridge the gap between raw code and polished documentation, Rubberize is for you!
Installation
Install Rubberize with pip:
pip install rubberize
To include dependencies that allow Rubberize to be used with Jupyter Notebooks:
pip install "rubberize[jupyter]"
Quick Start
In a Jupyter notebook, load the extension:
%load_ext rubberize
Use the %%tap magic:
%%tap
import math
a = 3
b = 4
c = math.sqrt(a**2 + b**2)
$\displaystyle a = 3$
$\displaystyle b = 4$
$\displaystyle c = \sqrt{a^{2} + b^{2}} = \sqrt{3^{2} + 4^{2}} = 5.00$
Documentation
Full tutorials, configuration options, and examples are found in Rubberize Documentation.
Why The Names?
Rubberize is inspired by tapping rubber trees for latex.
The %%tap command taps a code cell and extracts LaTeX, turning ordinary Python calculations into structured mathematical output.
Contributing
If you’re interested in contributing or mentoring, please feel free to contact me. I’m eager to collaborate to make Rubberize even better.
Setting Up for Development
Clone the repository:
git clone https://github.com/chitoperalta/rubberize.git
cd rubberize
Set up a virtual environment (recommended):
python -m venv .venv
source .venv/bin/activate
# Windows: .venv\Scripts\activate
Install Rubberize in editable mode with development dependencies:
pip install -e ".[dev]"
License
MIT License © 2025-2026 Chito Peralta and contributors.
Metadata
Release files for rubberize 0.4.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| rubberize-0.4.3.tar.gz | 62.6 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| rubberize-0.4.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 139.6 kB
Release files / rubberize-0.4.3.tar.gz
| Download URL | rubberize-0.4.3.tar.gz |
|---|---|
| Size | 62.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
af3921e7dad43c0e855142cf599f671cb982ce16b81dd9635fd6ed3112753a15
|
|
BLAKE2b-256 checksum How to use checksums |
5a2ac8ecb6966ad441279e0eba9397f92a7f56819d51700f4349aa09007111c0
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Apr 21, 2026.
Transparency logRelease files / rubberize-0.4.3-py3-none-any.whl
| Download URL | rubberize-0.4.3-py3-none-any.whl |
|---|---|
| Size | 76.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c97ebf8d4a6c35886110d319fb3f97ee13ac6db69daf1c01a1d4244f8f856791
|
|
BLAKE2b-256 checksum How to use checksums |
614cc24b15dd31da092792fe581ac26c39008e9aa64378a04c367899806a36b1
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
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.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Apr 21, 2026.
Transparency log