โ† All examples

geometry 4d

Uniform point sets on the 3-sphere

Sample unit quaternions three ways (normalized Gaussians, a Hopf fibration grid, a super-Fibonacci spiral), measure separation, covering radius and cap discrepancy against the exact cap volume of S3, and write the stereographic image as a glTF point cloud.

Recorded render of Uniform point sets on the 3-sphere

What this component contains

  • ATTRIBUTION.md
  • LICENSE
  • README.md
  • component.json
  • example.gltf
  • fourd.py
  • preview.png
  • test_package.py
  • three_sphere_sampling.py
  • verification/native.json

How it works

Entry points
gaussian, fibonacci_sphere, lift, hopf_map, hopf_grid, super_fibonacci, sample, cap_fraction and 7 more
Outputs
example.gltf
Coordinates
unit quaternions (x, y, z, w) = w + xi + yj + zk; stereographic image from (0, 0, 0, 1), Godot/glTF +Y up

Recorded checks

godot 4.7.2.stable.official.ed1daf0bf

  • cli_rebuilds_example
  • gltf_structure_example
  • cli_example_runs
  • cli_example_gltf_structure
  • godot_loads_example
  • godot_loads_cli_hopf_grid
  • preview_render

Limits to consider

Separation is an O(n^2) scan and covering radius and discrepancy are estimates from random probes and caps, so they suit sets of a few thousand points. The hopf_grid rounds the count to bases times fibre points. Points whose image lies beyond the clip radius (those near the projection pole) are left out of the glTF. POINTS render at one pixel in most viewers.