Skip to main content

Lattice Field Medium physics simulation library

Project description

lfm-physics

Tests PyPI Python 3.10+ License: MIT

Lattice Field Medium — a physics simulation library implementing the LFM framework.

Two governing equations. One integer (χ₀ = 19). All of physics.

Install

pip install lfm-physics

For GPU acceleration (NVIDIA):

pip install lfm-physics[gpu]

Quick Start

import lfm

# Fundamental constants derived from χ₀ = 19
print(f"χ₀ = {lfm.CHI0}")       # 19.0
print(f"κ  = {lfm.KAPPA}")      # 0.015873...
print(f"α  = {lfm.ALPHA_EM}")   # 0.007299... ≈ 1/137.088

# Create and run a simulation
config = lfm.SimulationConfig(grid_size=64, report_interval=500)
sim = lfm.Simulation(config)
sim.place_soliton((32, 32, 32), amplitude=6.0, sigma=5.0)
sim.equilibrate()
sim.run(steps=1000)

# Analyze
m = sim.metrics()
print(f"χ_min = {m['chi_min']:.2f}")
print(f"Wells = {m['well_fraction']*100:.1f}%")

# 41+ predictions from one integer
catalog = lfm.predict_all()
for name, entry in list(catalog.items())[:5]:
    print(f"  {name}: predicted={entry['predicted']:.6f}, "
          f"measured={entry['measured']:.6f}, error={entry['error_pct']:.2f}%")

Examples

See examples/ for full working scripts:

  • cosmic_structure_formation.py — 256³ universe simulation showing spontaneous gravitational structure (wells + voids) from GOV-01 + GOV-02 alone. Includes cosmic time conversion, periodic snapshots, and milestone tracking. Set GRID_SIZE = 64 for a quick CPU test.

What is LFM?

The Lattice Field Medium framework derives all physics from two coupled wave equations on a discrete 3D cubic lattice:

  • GOV-01 (Wave Equation): ∂²Ψ/∂t² = c²∇²Ψ − χ²Ψ
  • GOV-02 (Field Equation): ∂²χ/∂t² = c²∇²χ − κ(|Ψ|² − E₀²) − 4λ_H·χ(χ² − χ₀²)

From these two equations and χ₀ = 19 (derived from 3D lattice geometry: 1+6+12=19), the framework predicts 41+ fundamental constants within 2% of measured values.

Documentation

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

lfm_physics-0.1.1.tar.gz (54.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

lfm_physics-0.1.1-py3-none-any.whl (45.0 kB view details)

Uploaded Python 3

File details

Details for the file lfm_physics-0.1.1.tar.gz.

File metadata

  • Download URL: lfm_physics-0.1.1.tar.gz
  • Upload date:
  • Size: 54.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lfm_physics-0.1.1.tar.gz
Algorithm Hash digest
SHA256 2a1dbfd7a830be0706d555cf94fabb259b36176969ba152cff35d8838e427924
MD5 9392b0985226f89aa529f53f18ed8c85
BLAKE2b-256 c812c57c65dc7a4490c99c0cd2bd32b3cd7fb7cfe066dbeed70bf8d775fded59

See more details on using hashes here.

Provenance

The following attestation bundles were made for lfm_physics-0.1.1.tar.gz:

Publisher: publish.yml on gpartin/lfm-physics

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file lfm_physics-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: lfm_physics-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 45.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for lfm_physics-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 ae97740078aee8e4a304e6beb08a52399c6ed83b5a45eeaf5d5cc2787483b314
MD5 e94a7822c6aa97538cd49910ebc4e98b
BLAKE2b-256 dbd5a0644f20694e106c279c10eb8deeea69ec5c5a6db681e83441244460b308

See more details on using hashes here.

Provenance

The following attestation bundles were made for lfm_physics-0.1.1-py3-none-any.whl:

Publisher: publish.yml on gpartin/lfm-physics

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page