D3 Framework Documentation

Python library and REST API for black hole information geometry. Based on the D3 research series — 9 exact results by Bharat Sharma (2026). Back to calculator  ·  Live site ↗

Quick start

bash
pip install d3framework
python
from d3framework import blackhole, compute, papers

# Black hole calculation (Papers 1-7)
bh = blackhole(mass_solar=30, chi=0.67, q=0)
print(bh.R_total_m) # 75519.2 m — evaporation invariant
print(bh.h_chi_q) # 0.8521 — KN master formula
print(bh.T_hawking_K) # 2.06e-9 K
print(bh.cite) # citation string for your paper

# Computation limits
r = compute(temperature_K=0.015, bits_per_sec=1e6)
print(r.landauer_J_per_bit) # 1.44e-25 J/bit
print(r.D3_m_per_bit) # 2.28e-76 m/bit
print(r.ratio_universal_m_per_J) # 1.65e-44 m/J — universal constant

Installation

bash
# PyPI (recommended)
pip install d3framework

# From source
git clone https://github.com/bsharma173860-oss/d3-research
pip install -e .

Requires Python 3.8+. No dependencies — pure Python standard library.


blackhole() Papers 1–7

Compute all D3 information-geometry invariants for a black hole.

Parameters

ParameterTypeDefaultDescription
mass_solarfloatrequiredBlack hole mass in solar masses (M > 0)
chifloat0.0Dimensionless spin [0, 1) — Kerr parameter
qfloat0.0Dimensionless charge [0, 1) — must have χ²+q² < 1

Returns: BlackHoleResult

FieldUnitsDescriptionPaper
r_s_mmSchwarzschild radius 2GM/c²P1
T_hawking_KKHawking temperatureP1
D3_m_per_bitm/bitD3 displacement per bit erasedP1
S_bekenstein_bitsbitsBekenstein-Hawking entropyP3
f_chiKerr spin suppression f(χ)P2
g_qRN charge suppression g(q)P6
h_chi_qKN master formula h(χ,q)P7
sigmaσ = √(1−χ²−q²)P7
R_total_mmTotal evaporation invariant = h·r_sP3,4,7
D3_over_rs(M_QG/M)² power lawP5
M_QG_kgkgQuantum gravity boundary massP5
M_QG_over_mPM_QG/m_P = √(ln2/8π) = 0.16607P5
citestrCitation string for papers
python — examples
from d3framework import blackhole

# Schwarzschild: R_total = r_s exactly
bh = blackhole(1.0)
assert bh.R_total_m == bh.r_s_m # True — Paper 3
assert bh.h_chi_q == 1.0# h(0,0) = 1

# Kerr: R_total = f(chi)*r_s
bh = blackhole(mass_solar=10, chi=0.9)
print(bh.f_chi) # 0.5359
print(bh.R_total_m) # = f(chi) * r_s

# Kerr-Newman: full master formula
bh = blackhole(mass_solar=5, chi=0.5, q=0.5)
print(bh.h_chi_q) # h(0.5, 0.5) from Paper 7
print(bh.sigma) # sqrt(1-0.25-0.25) = 0.7071

# Export to LaTeX table
print(bh.to_latex())

# Export to dict (for pandas/JSON)
d = bh.to_dict()

compute()

Calculate Landauer energy limit and D3 geometric limit for any computation.

Parameters

ParameterTypeDefaultDescription
temperature_KfloatrequiredOperating temperature in Kelvin
bits_per_secfloat1e9Bits erased per second
run_secondsfloat1.0Total run time in seconds

Returns: ComputeResult

FieldUnitsDescriptionValue at 300K
landauer_J_per_bitJ/bitMinimum energy per bit erasure = k_B·T·ln22.87e-21
D3_m_per_bitm/bitGeometric cost per bit = 2G·k_B·T·ln2/c⁴4.74e-65
ratio_universal_m_per_Jm/JD3/Landauer = 2G/c⁴ — universal constant1.65e-44
landauer_total_JJTotal Landauer heat over run time
D3_total_mmTotal geometric shift over run time
reversible_saving_JJEnergy saved by reversible logic
ML_max_ops_per_secops/sMargolus-Levitin max operations

papers() and get_paper()

python
from d3framework import papers, get_paper

# List all 9 papers
for p inpapers():
    print(f"P{p.number}: {p.central_result}")
    print(f" DOI: {p.doi}")

# Get specific paper
p3 = get_paper(3)
print(p3.title)
print(p3.bibtex()) # BibTeX citation

Export — LaTeX and BibTeX

python — LaTeX table
bh = blackhole(mass_solar=30, chi=0.67)
print(bh.to_latex())

# Output:
# \begin{table}[h]
# \centering
# \begin{tabular}{ll}
# \hline
# Parameter & Value \\
# $r_s$ & $8.8624e+04$\,m \\
# $h(\chi,q)$ & $0.85213232$ \\
# ...
python — BibTeX citation
from d3framework import get_paper

# Get BibTeX for any paper
p = get_paper(3)
print(p.bibtex())

# @article{sharma2026_p3,
# author = {Sharma, Bharat},
# title = {The Schwarzschild Radius as Information-Geometry Invariant},
# doi = {10.5281/zenodo.20548070},
# }

POST /api/blackhole

Base URL: https://phenex-d3.vercel.app

API keys coming soon. Currently open for testing. Rate limits apply after launch.

Request

FieldTypeDefaultDescription
mass_solarnumber1Mass in solar masses
chinumber0Spin [0,1)
qnumber0Charge [0,1), χ²+q²<1
curl
curl -X POST https://phenex-d3.vercel.app/api/blackhole \
  -H "Content-Type: application/json" \
  -d '{"mass_solar":30,"chi":0.67,"q":0}'
curl — GET (quick test)
curl "https://phenex-d3.vercel.app/api/blackhole?mass_solar=30&chi=0.67&q=0"
response
{
  "ok": true,
  "result": {
    "mass_solar": 30,
    "chi": 0.67,
    "r_s_m": 88623.8,
    "T_hawking_K": 2.056e-9,
    "D3_m_per_bit": 3.25e-76,
    "h_chi_q": 0.85213232,
    "R_total_m": 75519.2,
    "S_bekenstein_bits": 1.363e80,
    "M_QG_over_mP": 0.16607064,
    "cite": "Sharma, B. (2026). D3 Research Series..."
  }
}

POST /api/compute

curl
curl "https://phenex-d3.vercel.app/api/compute?temperature_K=300&bits_per_sec=1e9"
python
import requests
r = requests.get('https://phenex-d3.vercel.app/api/compute',
    params={'temperature_K': 0.015, 'bits_per_sec': 1e6})
data = r.json()['result']
print(data['landauer_J_per_bit']) # 1.44e-25
print(data['ratio_universal_m_per_J']) # 1.65e-44

GET /api/papers

curl
# All papers
curl https://phenex-d3.vercel.app/api/papers

# Specific paper
curl https://phenex-d3.vercel.app/api/papers?number=3

Jupyter notebook example

Download ready: 8 complete examples — LIGO events, spin suppression, KN contour, QG boundary, AdS correction, LaTeX/BibTeX export.  Download d3framework_examples.ipynb
jupyter / python
import numpy as np
import matplotlib.pyplot as plt
from d3framework import blackhole

# Plot R_total/r_s vs spin chi for 10 solar mass BH
chis = np.linspace(0, 0.99, 100)
ratios = [blackhole(10, chi=c).h_chi_q for c in chis]

plt.figure(figsize=(8,5))
plt.plot(chis, ratios, 'b-', lw=2)
plt.xlabel('Spin χ')
plt.ylabel('h(χ,0) = R_total/r_s')
plt.title('D3 spin suppression — Paper 7')
plt.grid(alpha=0.3)
plt.show()

# Compare all LIGO events
events = {
  'GW150914': (65, 0.67),
  'GW170814': (53, 0.81),
  'GW190521': (150, 0.69),
}
for name, (M, chi) in events.items():
    bh = blackhole(M, chi=chi)
    print(f"{name}: R_total={bh.R_total_m:.0f} m, h={bh.h_chi_q:.4f}")

All 9 papers

#DOICentral result
P110.5281/zenodo.20502577D3(T) = 2G·kB·T·ln2/c⁴
P210.5281/zenodo.20535347f(χ) = 2√(1−χ²)/(1+√(1−χ²))
P310.5281/zenodo.20548070R_total = r_s — all constants cancel
P410.5281/zenodo.20549627R_total(Kerr) = f(χ)·r_s
P510.5281/zenodo.20549980M_QG = mP·√(ln2/8π)
P610.5281/zenodo.20561229g(q) = 4√(1−q²)/(1+√(1−q²))²
P710.5281/zenodo.20563756h(χ,q) = 4σ/(2(1+σ)−q²)
P810.5281/zenodo.20564313R_total = r_s for all d≥4
P910.5281/zenodo.20567233R_total(AdS) = r_s·(1+(r_s/L)²)

Physical constants used

SymbolValueDescription
G6.67430×10⁻¹¹ m³kg⁻¹s⁻²Newton's constant
c2.99792458×10⁸ m/sSpeed of light
1.054571817×10⁻³⁴ J·sReduced Planck constant
k_B1.380649×10⁻²³ J/KBoltzmann constant
l_P1.616255×10⁻³⁵ mPlanck length
m_P2.176434×10⁻⁸ kgPlanck mass
M_sun1.989×10³⁰ kgSolar mass

How to cite

BibTeX — software
@software{sharma2026d3framework,
  author  = {Sharma, Bharat},
  title   = {d3framework: Black hole information geometry calculator},
  year    = {2026},
  url     = {https://phenex-d3.vercel.app},
  version = {0.1.0}
}
BibTeX — Paper 3 (central result)
@article{sharma2026p3,
  author = {Sharma, Bharat},
  title  = {The Schwarzschild Radius as Information-Geometry Invariant},
  year   = {2026},
  doi    = {10.5281/zenodo.20548070},
  note   = {PhenexAI Research, Vancouver}
}
Contact: bsharma173860@gmail.com · GitHub · phenex-d3.vercel.app

Live Monitoring Agent

Install the D3 monitoring agent on any Linux or Mac server to send real-time metrics to your dashboard.

Requirements

pip install psutil requests

Quick start

# Download agent curl -O https://phenex-d3.vercel.app/d3_agent.py # Run with your org ID python3 d3_agent.py --org YOUR_ORG_ID

What it measures

Supported hardware

Cron setup (Linux)

# Run every 60 seconds * * * * * /usr/bin/python3 /opt/d3/d3_agent.py --once --org YOUR_ORG_ID

Docker

docker run -e D3_ORG_ID=YOUR_ORG_ID phenexai/d3-agent:latest