{"id":29285744,"url":"https://github.com/ratwolfzero/spacetime","last_synced_at":"2025-07-05T23:10:06.508Z","repository":{"id":300067459,"uuid":"1005039249","full_name":"ratwolfzero/Spacetime","owner":"ratwolfzero","description":"Quantum Golomb Spacetime Simulator","archived":false,"fork":false,"pushed_at":"2025-06-19T17:22:57.000Z","size":369,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-06-19T18:39:57.422Z","etag":null,"topics":["emergent","emergent-behavior","golomb","golomb-ruler","quantum-mechanics","spacetime"],"latest_commit_sha":null,"homepage":"https://github.com/ratwolfzero/Spacetime","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ratwolfzero.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-06-19T15:10:16.000Z","updated_at":"2025-06-19T17:25:32.000Z","dependencies_parsed_at":"2025-06-19T18:52:02.861Z","dependency_job_id":null,"html_url":"https://github.com/ratwolfzero/Spacetime","commit_stats":null,"previous_names":["ratwolfzero/spacetime"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ratwolfzero/Spacetime","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratwolfzero%2FSpacetime","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratwolfzero%2FSpacetime/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratwolfzero%2FSpacetime/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratwolfzero%2FSpacetime/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ratwolfzero","download_url":"https://codeload.github.com/ratwolfzero/Spacetime/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ratwolfzero%2FSpacetime/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263819240,"owners_count":23516123,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["emergent","emergent-behavior","golomb","golomb-ruler","quantum-mechanics","spacetime"],"created_at":"2025-07-05T23:09:51.504Z","updated_at":"2025-07-05T23:10:06.442Z","avatar_url":"https://github.com/ratwolfzero.png","language":"Python","readme":"# 🧠 Quantum Golomb Spacetime Simulator\n\n\u003e ## *My Spacetime is Made of Numbers and Poor Decisions*  \n\u003e\n\u003e ### *Inside the Quantum Golomb Simulator That Accidentally Discovered the Universe*\n\n![Quantum Golomb Spacetime](Quantum_Golomb_Spacetime_Analysis.png)\n\n\u003e *“Some say the universe began with a bang. This one began with `[0, 1]` and a poorly tuned random number generator.”*\n\n---\n\n## 📌 Overview\n\nThis project simulates a playful model of spacetime growth inspired by:\n\n- 🧮 **Golomb rulers**\n- 🎲 **Quantum fluctuations**\n- 🌌 **Curved geometry**\n- 🕸 **Causal networks**\n\nWhile not physically rigorous, the simulator explores how *structure, density, and curvature* can emerge from simple number-theoretic rules—rendered with surprisingly rich visualizations.\n\n---\n\n## 📐 What Is a Quantum Golomb Spacetime?\n\nA **Golomb ruler** is a set of integers (marks) such that all pairwise distances are unique.\n\nIn this simulator:\n\n- Each mark is treated as a **discrete event** in time.\n- New marks are added via a **temperature-driven growth process**.\n- A synthetic **matter–curvature interaction** perturbs new candidates.\n- The result is embedded in **polar coordinates**, giving rise to:\n  - Mass density fields\n  - Local curvature\n  - Causal structure\n  - Fractal geometry\n\n\u003e ⚠️ This is not quantum gravity—just quantum creativity.\n\n---\n\n## 🌱 Step 1: Birth of the Universe\n\nWe begin with two marks:\n\n```python\nsimulator = QuantumGolombSpacetime(initial_marks=[0, 1])\nsimulator.quantum_growth(max_marks=40, temperature=0.1)\n````\n\nGrowth proceeds by probabilistically selecting the next valid integer that maintains the Golomb condition (no repeated distances). The `temperature` parameter controls how chaotic the search is:\n\n- **Low T** → Conservative, stable expansion\n- **High T** → Chaotic, entropy-maximizing behavior\n\n---\n\n## 🔀 Step 2: Quantum Decisions (and Other Mistakes)\n\nThe system's growth isn't deterministic — it's guided by temperature-controlled randomness.\nLow temperatures yield precise, deliberate mark choices; high temperatures allow chaotic, exploratory additions.\nStarting from the third mark onward, growth becomes influenced by an emergent interaction:\n\n$$\n\\text{Potential} \\sim \\sum_i \\frac{\\rho_i}{d_i^2 + \\varepsilon}\n$$\n\nWhere:\n\n- \\$\\rho\\_i\\$ = local matter density\n- \\$d\\_i\\$ = distance to existing mark \\$i\\$\n\nThis interaction biases the selection of new candidates, introducing asymmetry and reinforcing local structure.\nThough **curvature** is formally introduced in Step 3, this effect lays the groundwork — subtly shaping how space (and regret) unfold.\n\n---\n\n## 🌀 Step 3: Polar Embedding\n\nEach mark is mapped into 2D using polar coordinates:\n\n$$\nx = r \\cdot \\cos(\\theta), \\quad y = r \\cdot \\sin(\\theta)\n$$\n\nWhere:\n\n- \\$r\\$ = log-scaled radial distance from origin\n- \\$\\theta\\$ = angular position around the circle (uniform spacing)\n\nThis creates a spiraling spacetime diagram that reveals geometric clustering and local tension.\n\n---\n\n## 🌌 Step 4: Mass Density and Fractal Geometry\n\nThe polar embedding is converted into a 2D density map using Gaussian-smoothed binning. We then estimate the **fractal dimension** using box-counting:\n\n$$\nD = \\lim_{\\varepsilon \\to 0} \\frac{\\log N(\\varepsilon)}{\\log(1/\\varepsilon)}\n$$\n\n\u003e Example result: `Estimated fractal dimension: 2.181`\n\nThis value suggests dimensional emergence or compactified structure.\n\n---\n\n## 🔊 Step 5: FFT of the Density Field\n\nWe apply a 2D Fast Fourier Transform (FFT) to the mass density map. This reveals:\n\n- Radial and angular **symmetries**\n- Hidden **periodicities**\n- Noise or self-similarity signatures\n\n---\n\n## 🧭 Step 6: Causal Network Construction\n\nWe build a causal graph where:\n\n- **Nodes** = Events (marks)\n- **Edges** = Future-directed links based on angular proximity\n- **Weights** encode difficulty of information transfer:\n\n$$\nw_{ij} = \\frac{\\rho_i}{\\Delta t_{ij} \\cdot (\\Delta\\theta_{ij} + \\delta)}\n$$\n\nThe graph reflects how events influence each other, with metrics like:\n\n- Causal connection density\n- Average path length\n- Degree–matter correlation\n\n---\n\n## 📊 Diagnostics: Quantum Physics with a Wink\n\n### 🧬 Quantum Fluctuations\n\nAverage deviation from uniform growth is computed as:\n\n```python\nQuantum Fluctuation = mean(abs(∆position - 1))\n```\n\nCaptures jitter introduced by temperature and curvature feedback.\n\n---\n\n### 🌐 Curvature–Matter Feedback\n\nWe compute **local curvature** from nearest-neighbor triangles. Higher curvature regions receive more \"matter\"—mimicking attraction.\n\n---\n\n### ⚖️ Energy Balance (Kind Of)\n\nA toy-model energy proxy is defined as:\n\n$$\n\\text{Energy} \\sim \\frac{\\text{Total Matter}}{\\text{Average Curvature}}\n$$\n\nThis ratio is tracked across growth to observe pseudo-conservation behavior.\n\n---\n\n## 📈 Visualization Dashboard\n\nThe simulator outputs a 6-panel visual summary:\n\n| Panel | Content Description      |\n| ----- | ------------------------ |\n| 📍    | Polar Embedding (r, θ)   |\n| 🌋    | Smoothed Mass Density    |\n| 🔊    | FFT of Density Field     |\n| 🪐    | Local Curvature Map      |\n| 🌐    | Causal Network Diagram   |\n| 🌈    | Matter Density per Event |\n\nAll panels include colorbars and standardized axis ratios for interpretability.\n\n---\n\n## 🧠 Summary of Findings\n\nWhile this simulation is fictional and symbolic, it provides:\n\n- A **sandbox for emergent structure** from simple constraints\n- A new way to look at **Golomb uniqueness as causal order**\n- Feedback loops between **matter, curvature, and event layout**\n- Visual metaphors for **dimensional compactification**, **causal flow**, and **quantum foam**\n\n---\n\n## 💡 Philosophical Addendum\n\n\u003e “My universe grew, curved, pulsed, and linked. All from `[0, 1]`.\n\u003e Just like ours—chaotic, kind of pretty, and mostly made up.”\n\nYou may not find a Theory of Everything, but you might:\n\n- Build intuition for emergent geometry\n- Appreciate discrete structures as creative fuel\n- Laugh at causality’s LinkedIn behavior\n\n---\n\n## 🛠 Requirements\n\n```bash\npip install numpy matplotlib scipy scikit-learn networkx scikit-image\n```\n\n---\n\n## ⚠️ Note\n\nThis simulator is designed for **exploration and metaphor**, not physical accuracy.\nBut it might replace your existential dread with constructive curiosity.  \n\nNote on Computational Artifacts\n\nWhile some features may stem from numerical artifacts or boundary effects, the central insight holds: complexity and geometry can emerge from minimalist, rule-based logic. This model isn’t a literal blueprint of spacetime — but it consistently produces structured behavior from simple combinatorial constraints, making it a valuable tool for intuition and exploration\n\nNote on Golomb search limit:  \n\nAll visualizations shown here use a Golomb search limit of 1000. Pushing this limit to 10,000 alters the growth dynamics and dimensional scaling.\n\n---\n\n## 🧠 Quick Summary: Physics Behind the Simulator\n\n\u003e See full annex: [ANNEX\\_PhysicsBehindTheSimulator.md](./ANNEX_PhysicsBehindTheSimulator.md)\n\n1. **Golomb Rulers = Distinct Quantum Events**\n   Unique distances prevent overlap — like enforcing unitarity in quantum systems.\n\n2. **Thermal Growth = Quantum Fluctuations**\n   Randomized mark addition simulates vacuum noise or inflation-like expansion.\n\n3. **Matter Density = Mass-Energy Field**\n   Each mark contributes to a local scalar field influencing future growth.\n\n4. **Numeric Potential = Proto-Curvature**\n   Attraction toward denser regions mimics curvature before geometry exists.\n\n5. **Polar Embedding = Emergent Geometry**\n   Spatial coordinates are constructed, revealing extrinsic curvature and structure.\n\n6. **Fractal Dimension = Spacetime Texture**\n   Dimension $D$ evolves from chaotic \u003e2.0 to smooth \\~2.0, reflecting emergence.\n\n7. **Causal Network = Information Flow**\n   Directed edges encode relativistic causal relations between events.\n\n8. **Spectral FFT = Hidden Structure**\n   Fourier analysis of matter density reveals holographic/spectral patterns.\n\n9. **Curvature vs. Matter = Balance Law**\n   A toy energy-like quantity $E = \\rho / \\langle K \\rangle$ remains approximately stable.\n\n10. **Dimensional Emergence**\n    Early universe is foamy and noisy; later universe becomes geometric and causal.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fratwolfzero%2Fspacetime","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fratwolfzero%2Fspacetime","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fratwolfzero%2Fspacetime/lists"}