star-vec3 0.1.0
The three-dimensional vector operations of orbit and attitude code
Public state: Released & Verified. The registry label is RELEASED. What the states mean →
Apache-2.0 Released & Verified single file
Summary
Dot, cross and triple product, length, distance, unit vector, accurate angle between directions, projection and rejection of three-dimensional vectors; within 6e-16 of SPICE and ERFA and 8e-15 of NumPy on 600 triples of vectors, nearly parallel pairs included; malformed vectors and zero directions refused.
Run in your browser
Edit the code and press Run (or Ctrl+Enter). Python runs in your browser with this package's published code. The first run downloads Python once (about 12 MB).
Runs in the browser: all 24 tests pass in the browser's Python (Pyodide 314.0.7, Python 3.14.2), measured on 20 October 2026.
Use it on your computer
No account and no GitHub needed. Download, then install with one command:
- Install file · star_vec3-0.1.0-py3-none-any.whl 3 kB
- Single file — copy it alongside your code · star_vec3.py 4 kB
- Source code (.zip) 18 kB
python -m pip install star_vec3-0.1.0-py3-none-any.whlIn Python: import star_vec3
Cite it, and its bill of materials
For a paper, a report or a supplier file: the citation in two formats, and the software bill of materials (SBOM) in the two standard formats, with the fingerprint of the wheel.
@software{cavazzini_star_vec3_0_1_0,
author = {Cavazzini, Andrea},
title = {{star-vec3}: The three-dimensional vector operations of orbit and attitude code},
version = {0.1.0},
year = {2026},
url = {https://andrea07072000.github.io/S.T.A.R.-/software/star_vec3/},
note = {Apache-2.0. Source: https://github.com/Andrea07072000/S.T.A.R.-, commit dc09f61d}
}
For developers
Install directly from the public repository:
python -m pip install "star-vec3 @ git+https://github.com/Andrea07072000/S.T.A.R.-.git@dc09f61dcee098d518f070d6a23a8815defc1109#subdirectory=packages/star_vec3"
Technical sheet
Requirements
- R1
dot,cross,triple,norm,distance,unit: the definitions, with the length computed without intermediate overflow or underflow and the sums compensated. - R2
angle_degas atan2(|a × b|, a · b) on unit vectors: in [0, 180], accurate near 0 and near 180 degrees and independent of the lengths;projectandreject, which add up to the first vector. - R3 Measured on 600 triples of vectors (lengths 1e-3 to 1e9; 200 pairs within 1e-9 to 1e-3 rad of parallel or antiparallel): within 6e-16 of SPICE and ERFA relative to the lengths involved, angles within 5e-14 deg; the triple product within 8e-15 of NumPy's determinant.
- R4 Every function returns floats or raises
ValueError: a vector that is not a list or tuple of exactly three finite real numbers within ±1e100 (booleans refused), or the zero vector where a direction is needed.
Limits (what is not claimed)
No matrices, no rotations (see star_quaternion and star_euler), no vectors of other dimensions. The triple product is compared with one library (NumPy) only. Products of components below 1e-154 underflow to zero in dot, cross and triple as in any double-precision code; norm, unit and angle_deg are not affected.
Release gate
Computed by the registry from the result files, with the same function that decides RELEASED.
- Mutation score, latest measure of each module (needs at least 0.850)
- star_vec3.py 0.982 (2026-10-06)
- Independent implementations written by others (needs 2)
- ERFA pdp / pxp / pm / pn / sepp (C), NumPy dot / cross / norm / det, SPICE vdot / vcrss / vnorm / vdist / vhat / vsep / vproj / vperp (C)
- Result
- Released & Verified
Evidence in the registry
| Check | Status | Recorded | What was observed |
|---|---|---|---|
| Clean install from the release tag | VERIFIED | 2026-10-06 | pytest outside the tree: 24 passed in 0.17s |
| Unit tests | VERIFIED | 2026-10-06 | 24 passed in 0.34s |
| Review | VERIFIED | 2026-10-06 | Requirements, interface, units, data provenance, dependency surface and failure behaviour reviewed |
| Review | VERIFIED | 2026-10-06 | Re-running the cross-check gives a byte-identical evidence file |
| Reference value | VERIFIED | 2026-10-06 | (0.0, 0.0, 1.0), 5.0, 45.0: exact to rounding (the angle within 1e-13 deg) (suite: 24 passed in 0.34s) |
| Cross-check with independent libraries | VERIFIED | 2026-10-06 | star_vec3 computes the products, lengths, angles and projections of three-dimensional vectors as three independent libraries do, nearly parallel vectors included |
| Benchmark | VERIFIED | 2026-10-06 | spice 4.3e-14; erfa 2.8e-14; numpy 7.3e-15 |
Fingerprints (SHA-256)
| star_vec3-0.1.0-py3-none-any.whl | 7884ba73fc6b5a589db0f2c618daa58cda8b0810ff7efdf2870c13030c177b58 |
| star_vec3.py | 6fb84ab460f69ff4d86e203000ef517d426a57288cbc10432a4b8e9c9ed71a00 |
| star_vec3-0.1.0-source.zip | d7c35125dd9d6783a253044e11776561409838a45de4043aa74d68f54bcc0e9b |
