Coordinate System
coordinate_system is a mathematical library for computable coordinate systems,
quaternionic frames, and object-level spatial calculus in Python.
Version 13.0.0 is a major cleanup release. The package root is now deliberately pure: it exposes coordinate objects, frame-field calculus, curvature operators, spectral geometry, complex-frame algebra, and curve/surface construction tools. Application-oriented physical wrappers and report generators have been removed from the public package surface.
Core Idea
A computable coordinate system is a local spatial measuring object:
C = (o, q, s) or C = (o, R, D), with E = R D.
ois the affine origin.qorRis the local orientation.sorDis the local scale/ruler structure.
The differential datum of a frame field is the logarithmic or relative local variation of neighboring coordinate objects. The integral operation is the ordered composition that reconstructs global geometry from those local changes.
Installation
pip install coordinate-system
From source:
git clone https://github.com/panguojun/Coordinate-System.git
cd Coordinate-System
pip install -e .
Source builds require a C++17 compiler and pybind11. Runtime dependency is
kept minimal: numpy is required; plotting and SciPy features are optional.
Public Mathematical Layers
Core Coordinate Objects
from coordinate_system import vec3, quat, coord3, ONEC
p = vec3(1.0, 2.0, 3.0)
q = quat(1.0, 0.0, 0.0, 0.0)
scale = vec3(1.0, 1.0, 1.0)
C = coord3(p, q, scale)
CCS Surface Geometry
import math
from coordinate_system import Sphere, compute_ccs_geometry_package
sphere = Sphere(radius=2.0)
pkg = compute_ccs_geometry_package(sphere, math.pi / 4.0, math.pi / 3.0)
print(pkg.K) # Gaussian curvature
print(pkg.H) # Mean curvature
print(pkg.g) # First fundamental form
print(pkg.h) # Second fundamental form
print(pkg.center_frame)
The package keeps the theorem chain explicit:
coord frame -> finite relative variation -> metric/shape data -> curvature invariants
Convenience CCS Wrapper
import math
from coordinate_system import CCS, Sphere
ccs = CCS(step_size=1e-4)
sphere = Sphere(radius=2.0)
print(ccs.gaussian(sphere, math.pi / 4.0, math.pi / 3.0))
print(ccs.mean(sphere, math.pi / 4.0, math.pi / 3.0))
Curve and Surface Construction
import math
from coordinate_system import AnalyticSphere, interpolate_surface_coords
surface = AnalyticSphere(radius=1.0)
frames = interpolate_surface_coords(
surface,
[(math.pi / 3.0, 0.0), (math.pi / 3.0, math.pi / 2.0)],
samples=16,
)
points = [item.frame.o for item in frames]
These APIs are mathematical construction tools. Downstream CAD, rendering, or simulation systems can consume the resulting coord frames, but those application layers are not part of the package root.
Spectral and Complex Frames
from coordinate_system import ComplexFrame, GaugeConnection, FourierFrame
U = ComplexFrame()
A = GaugeConnection()
The complex-frame layer is kept as a mathematical utility for unitary frames, connections, field-strength-like algebra, and spectral constructions. It should not be read as a validated physical model by itself.
API Boundary in 13.0.0
Removed from the public package root:
- CFUT wrapper APIs
- Lambda wrapper APIs
- topological physics application functions
- research registry helpers
- report-generation scripts
- dark-matter, dynamic-stall, and validation application examples
Kept in the mathematical package root:
vec3,vec2,quat,coord3CCS,Surface,Sphere,Torus- metric, intrinsic-gradient, curvature, and CCS geometry package APIs
- spectral geometry utilities
- complex-frame algebra utilities
- curve interpolation, curve intersection, and analytic surface coord tools
Development Smoke Test
python -c "import coordinate_system as cs; print(cs.__version__, cs.Sphere(2).theoretical_gaussian_curvature)"
python -m unittest discover -s test
License
MIT License. Copyright (c) 2024-2026 Pan Guojun.
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 coordinate_system-13.0.1.tar.gz.
File metadata
- Download URL: coordinate_system-13.0.1.tar.gz
- Upload date:
- Size: 99.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f7563dd6c6dd2c54840fca3a0f14a73f9bd7a6c61c856b6bae48e06c6319b70e
|
|
| MD5 |
880ae95b8f630afaca0e23ce950382d3
|
|
| BLAKE2b-256 |
7e7ffa26294371b6049b29a227412a31a8c087437f1d57b6e820b7ce1f273f4e
|
File details
Details for the file coordinate_system-13.0.1-cp313-cp313-win_amd64.whl.
File metadata
- Download URL: coordinate_system-13.0.1-cp313-cp313-win_amd64.whl
- Upload date:
- Size: 231.1 kB
- Tags: CPython 3.13, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/6.2.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d27f5f7c7b65a346afefc1a47317be056a99f87c8266f83b58d0c317e1f322b4
|
|
| MD5 |
48addb3a22143a8e7ba8133c904d8461
|
|
| BLAKE2b-256 |
a0db4dd4e4397188ab15f4e80df048fadc92a862cd09cb3d77adf2d4d3a44607
|