Skip to content

Commit 5290875

Browse files
committed
expand catalog to 12 anomalies, fix orbital transition button registration, add distant background stars, and format equations in README
1 parent cb9bf38 commit 5290875

3 files changed

Lines changed: 522 additions & 115 deletions

File tree

README.md

Lines changed: 73 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -1,87 +1,107 @@
1-
# Stellar Cartography — Interactive Cosmic Map Explorer
1+
# 🌌 Stellar Cartography
22

3-
An interactive 3D Cosmic Map and real-time relativistic anomaly simulator featuring high-performance physics-based shaders. The project includes:
4-
1. **Interactive 3D Galaxy Map (Web)**: A rotating spiral galaxy of 10,000 stars built using `Three.js` (WebGL). It lets you locate, hover, and select major cosmic anomalies. Selecting a node triggers a smooth camera zoom animation and opens a dedicated simulator.
5-
2. **Volumetric Relativistic Simulations**: Four custom-built GLSL fragment shaders (run either locally on desktop or via browser) representing:
6-
* **Schwarzschild Black Hole**: Gravitational lensing geodesic raymarching with 3D volumetric thickness, Doppler beaming, and gravitational redshift.
7-
* **Vela Pulsar**: A precessing, fast-spinning neutron star emitting conical relativistic jets and a dipole magnetosphere grid.
8-
* **Cygnus Wormhole**: Morris-Thorne Einstein-Rosen bridge coordinate inversion that lets you look straight through a spherical throat to see an alternate universe background.
9-
* **Kepler Dyson Megastructure**: Orbiting geometric panel shields surrounding a star, exposing dynamic solar flares and core temperatures through panel gaps.
10-
3. **Python Desktop App**: Run any of the four shaders locally in a Pygame window powered by PyOpenGL hardware acceleration.
3+
An interactive 3D Cosmic Map and real-time relativistic anomaly simulator. Explore intermediate and supermassive black holes, pulsars, wormholes, and megastructures directly in your browser or via a desktop application.
114

12-
---
13-
14-
## Simulated Objects & Physics Math
15-
16-
### 1. Schwarzschild Black Hole (`shaders/black-hole.frag`)
5+
* Live Web Application: [https://vincere-mori.github.io/stellar-cartography/](https://vincere-mori.github.io/stellar-cartography/)
6+
* Desktop Version: Powered by Python + PyOpenGL (real-time GLSL shader compilation)
177

18-
Bends incoming light rays from background stars based on Schwarzschild spacetime geodesics:
8+
---
199

20-
$$\vec{a} = -\frac{1.5 \cdot R_s \cdot |\vec{L}|^2}{r^5} \vec{p}$$
10+
## 🌟 Catalog of Anomalies
11+
12+
The map features 12 unique celestial objects, each located at specific galactic coordinates:
13+
14+
| Key | Name | Classification | Coordinates | Core Characteristics |
15+
|---|---|---|---|---|
16+
| **1** | **Gargantua Singularity** | Schwarzschild Black Hole | X: -3.50, Y: 0.80, Z: -2.00 | Volumetric accretion disk, Keplerian velocity, Doppler lensing |
17+
| **2** | **Vela Pulsar** | Rotating Neutron Star | X: 5.00, Y: 1.00, Z: -4.00 | Conical relativistic radio jets, precessing magnetic dipole field |
18+
| **3** | **Cygnus Wormhole** | Morris-Thorne Bridge | X: -6.00, Y: -1.00, Z: 5.00 | Spacetime bridge, throat inversion to an alternate universe |
19+
| **4** | **Kepler Dyson Sphere** | Stellar Megastructure | X: 3.00, Y: -2.00, Z: 7.00 | Swarm of geometric solar panels, stellar flares, silhouettes |
20+
| **5** | **Sagittarius A*** | Supermassive Black Hole | X: 0.00, Y: 0.00, Z: 0.00 | Milky Way galactic core, extreme redshift, active plasma flow |
21+
| **6** | **Crab Pulsar** | High-Spin Neutron Star | X: -8.00, Y: 3.00, Z: -6.00 | Young pulsar, ultra-rapid rotation, Chandra X-ray pink theme |
22+
| **7** | **Andromeda Gateway** | Intergalactic Wormhole | X: 8.00, Y: -3.00, Z: -8.00 | Massive gateway bridge leading to the Andromeda galaxy |
23+
| **8** | **Solara Dyson Swarm** | Dense Megastructure | X: -2.00, Y: -4.00, Z: -5.00 | Solar energy collector plates with escaping coronal glare |
24+
| **9** | **Polaris Singularity** | Intermediate Black Hole | X: 1.00, Y: 6.00, Z: -7.00 | High-spin intermediate singularity, ultraviolet accretion disk |
25+
| **10** | **Aldebaran Bulge** | Stellar Core Flare | X: -4.00, Y: 5.00, Z: 3.00 | Hyperactive red giant star core, violent flares, magnetic clouds |
26+
| **11** | **SGR 1806-20 Magnetar** | Extreme Magnetar | X: -7.00, Y: -5.00, Z: 2.00 | Strongest magnetic field observed, precessing gamma-ray jets |
27+
| **12** | **Centauri Bridge** | Micro Wormhole | X: 4.00, Y: -3.00, Z: -2.00 | Quantum-stabilized micro-throat connecting Sol and Centauri |
2128

22-
Features a true 3D volumetric accretion disk calculated inside a vertical Gaussian density envelope:
29+
---
2330

24-
$$\text{Density}_{\text{vol}} = \text{FBM}(r, \theta) \cdot \exp\left(-\frac{y^2}{d^2}\right)$$
31+
## 🔬 Physics & Mathematics
2532

26-
And shifts frequencies due to both Keplerian orbital speeds (Doppler Beaming) and gravity well energy loss (Gravitational Redshift):
33+
The simulations run directly on the GPU using high-performance GLSL fragment shaders. The underlying physics models include:
2734

28-
$$D = \frac{1}{\gamma(1 - \beta \cos\theta)}, \quad z_g = \frac{1}{\sqrt{1 - R_s/r}} - 1$$
35+
### Gravitational Spacetime Bending
36+
Light rays near black holes and wormholes are bent using Schwarzschild geodesics integrated step-by-step during raymarching:
2937

30-
### 2. Vela Pulsar (`shaders/pulsar.frag`)
31-
A precessing magnetic axis vector $\vec{m}(t)$ creates precessing cones of radiation. When a photon enters the cone ($\cos\alpha > \text{threshold}$), it accumulates high-energy jet glow:
38+
`a = -1.5 * Rs * |L|² / (r⁵) * p`
3239

33-
$$\text{JetGlow} \propto \frac{\text{power}(\cos\alpha, N)}{r}$$
40+
* **p**: Photon position vector
41+
* **a**: Bending acceleration vector
42+
* **Rs**: Schwarzschild horizon radius
43+
* **L**: Angular momentum vector (`L = p × v`)
3444

35-
Surrounding the star is a dipole magnetosphere grid representing field line equations.
45+
### Volumetric Accretion Disk
46+
Accretion disks are rendered as 3D participating media with density mapped inside a vertical Gaussian envelope:
3647

37-
### 3. Cygnus Wormhole (`shaders/wormhole.frag`)
38-
Models a Morris-Thorne wormhole throat transition. When a ray reaches throat radius $r < R_s$, the space coordinate is inverted:
48+
`Density = Noise(r, θ) * exp(-y² / thickness²)`
3949

40-
$$\vec{p}_{\text{new}} = -\vec{p} \cdot 1.01$$
50+
This produces realistic gas silhouettes from edge-on camera angles rather than flat 2D planes.
4151

42-
The ray emerges on the opposite side of the throat and continues its trajectory inside an **alternate universe** sampling a different colored nebula and starfield.
52+
### Relativistic Doppler Beaming & Redshift
53+
* **Doppler Shift**: Relativistic beaming shifts the color and brightness of the accretion disk depending on whether gas is moving towards or away from the camera:
54+
`D = 1 / (γ * (1 - β * cos(θ)))`
55+
* **Gravitational Redshift**: Light escaping from the gravity well shifts towards dark red/infrared near the event horizon:
56+
`z = 1 / sqrt(1 - Rs / r) - 1`
4357

44-
### 4. Kepler Dyson Sphere (`shaders/dyson-sphere.frag`)
45-
A central star sphere surrounded by a larger spherical shell. A rotating sin-cos grid equation partitions the shell into geometric panels and structural gaps:
58+
### Morris-Thorne Throat Crossing
59+
When a ray penetrates the wormhole throat boundary (`r < Rs`), coordinates are inverted:
4660

47-
$$\text{Panel} = \text{step}(\text{gap}, \text{fract}(\theta \cdot F)) \cdot \text{step}(\text{gap}, \text{fract}(\phi \cdot F))$$
61+
`p_new = -p * 1.01`
4862

49-
Rays passing through gaps expose active solar flares on the star core.
63+
The ray emerges in another coordinate space, sampling an alternate starfield background.
5064

5165
---
5266

53-
## Running the Web App Locally
67+
## 💻 Running the Application
5468

55-
Due to browser security CORS restrictions, loading fragment shaders dynamically requires running a simple web server:
69+
### 1. Web Version (Local Development)
70+
Because browser security policies (CORS) restrict loading shader files directly from local storage, serve the directory using any local server:
5671

5772
```bash
58-
# Using Python
59-
python -m http.server 8000
73+
# Option A: Python (installed by default on most systems)
74+
python -m http.server 8080
6075

61-
# Using Node.js
76+
# Option B: Node.js / npm
6277
npx serve .
6378
```
6479

65-
Open `http://localhost:8000` in your web browser.
80+
Then open `http://localhost:8080` in your web browser.
6681

67-
---
68-
69-
## Running the Python Desktop App
70-
71-
Ensure you have Python 3.8+ and run:
82+
### 2. Desktop Version
83+
Run the simulation locally on your desktop using hardware-accelerated OpenGL:
7284

7385
```bash
86+
# Install dependencies
7487
pip install -r requirements.txt
88+
89+
# Run the app
7590
python main.py
7691
```
7792

78-
### Desktop Bindings
79-
* **`1` / `2` / `3` / `4`**: Swap active object (Black Hole, Pulsar, Wormhole, Dyson Sphere).
80-
* **Mouse Drag / Scroll**: Orbit / Zoom camera.
81-
* **SPACE**: Toggle Camera Autopilot.
82-
* **Q / A**: Adjust Horizon/Star Radius ($R_s$).
83-
* **W / S**: Adjust Spin/Orbital Speed.
84-
* **E / D**: Adjust Glow/Circuit Brightness.
85-
* **R / F**: Adjust Lensing/Warp strength.
86-
* **T**: Cycle through Theme color palettes.
87-
* **ESC**: Close application.
93+
#### Keyboard & Mouse Controls (Desktop)
94+
95+
| Control | Action |
96+
|---|---|
97+
| **Mouse Drag** | Rotate / Orbit Camera |
98+
| **Mouse Scroll** | Zoom Camera In / Out |
99+
| **SPACE** | Toggle Camera Autopilot |
100+
| **1 – 9** | Switch to Gargantua, Vela, Cygnus, Kepler, Sgr A*, Crab, Andromeda, Solara, Polaris |
101+
| **0, -, =** | Switch to Aldebaran, SGR 1806-20, Centauri Bridge |
102+
| **Q / A** | Increase / Decrease Schwarzschild Radius (Rs) |
103+
| **W / S** | Increase / Decrease Spin / Orbital Speed |
104+
| **E / D** | Increase / Decrease Jet Glow / Telemetry Intensity |
105+
| **R / F** | Increase / Decrease Spacetime Lensing Warp |
106+
| **T** | Swap Theme Color Palette |
107+
| **ESC** | Close Desktop Window |

0 commit comments

Comments
 (0)