j25aiml013 commited on
Commit
c0ce83e
·
verified ·
1 Parent(s): cb77ea6

Update README.md

Browse files
Files changed (1) hide show
  1. README.md +104 -79
README.md CHANGED
@@ -1,79 +1,104 @@
1
- # Quantum Simulation Suite
2
-
3
- ## Overview
4
- - Particle in a Box (PIB) time-dependent Schrödinger simulation (Crank–Nicolson, Split-Step Fourier)
5
- - Hydrogen spectrum (Rydberg formula, energy levels, stick spectrum)
6
- - TDSE wavepacket evolution with spacetime heatmap
7
- - Modular UIs: Streamlit (dark theme, sidebar navigation) and PySide6 (legacy)
8
- - Physics engine: real constants, potentials, eigenfunctions, TDSE solver with normalization and stability checks
9
-
10
- ## Project Structure
11
- - `streamlit_main.py` — Streamlit entrypoint with sidebar pages
12
- - `run_app.bat` — Installs deps and launches Streamlit UI
13
- - `run_streamlit_main.bat` — Same as above (alternative launcher)
14
- - `app/core/physics_engine/` — constants, potentials, PIB equations, TDSE solver, hydrogen spectrum
15
- - `app/core/animations/` — Matplotlib animations (PIB, Hydrogen)
16
- - `app/ui_streamlit/` — Streamlit UIs (PIB, Hydrogen, TDSE, TISE placeholder, Custom Potential placeholder)
17
- - `app/ui/` — PySide6 legacy UI (PIB, Hydrogen, main window)
18
- - `app/tests/` — pytest suites for equations, potentials, solver
19
- - `data/`, `docs/` — optional data/docs folders (ignored by git)
20
-
21
- ## Requirements
22
- - Python 3.10+
23
- - numpy, scipy, matplotlib, streamlit, PySide6, numba, pandas (batch files auto-install)
24
-
25
- ## How to Run (Streamlit UI)
26
- 1) Open a terminal:
27
- ```bash
28
- cd "D:\Physics Simulation Project\Physics Simulation Project Code"
29
- run_app.bat
30
- ```
31
- (or `run_streamlit_main.bat` or `streamlit run streamlit_main.py`)
32
- 2) In the browser sidebar, choose:
33
- - **Particle in a Box (PIB)**: set L, n, solver, dt, grid; enable superposition; click Start. Tabs show ψ, |ψ|², energies, live animation. Export PNG/CSV available.
34
- - **Hydrogen Spectrum**: pick series and n₂>n₁; view wavelengths, photon energies, stick spectrum, energy levels.
35
- - **TDSE Simulation**: set wavepacket params, domain, dt/steps; compute frames; view animation and |ψ|² heatmap.
36
- - **TISE / Custom Potential**: placeholders for future extensions.
37
- 3) Animations update frame-by-frame (no jumps); energy and norm displayed live.
38
-
39
- ## How to Use the Simulation
40
- 1. Launch UI
41
- - Double-click `run_app.bat` (or run `streamlit run streamlit_main.py`).
42
- 2. Pick a module in the sidebar:
43
- - **Particle in a Box (PIB):** set L, n, dt, grid, solver (CN/SSFM); optionally enable superposition; click **Start**. View tabs for ψ, |ψ|², energies, animation; export PNG/CSV.
44
- - **Hydrogen Spectrum:** choose series (Lyman/Balmer/...), set n₂>n₁; see wavelength, photon energy, stick spectrum, energy levels.
45
- - **TDSE Simulation:** set wavepacket (x₀, σ, k₀), domain, dt, steps; click **Start TDSE**; scrub frames or auto-play; heatmap in second tab.
46
- - **TISE / Custom Potential:** placeholders ready for extension.
47
- 3. Tips
48
- - Sliders update instantly; animations are frame-by-frame (no jumps).
49
- - If norm drifts, reduce dt or increase grid size.
50
- - Export buttons provide PNG/CSV snapshots.
51
- - Dark theme and auto-scaling are enabled by default.
52
- 4. PySide6 (optional)
53
- - Run `python main.py` (if wired to PIBWindow); use Start/Pause/Reset.
54
-
55
- ## How to Run (PySide6 UI, optional)
56
- ```bash
57
- cd "D:\Physics Simulation Project\Physics Simulation Project Code"
58
- python main.py
59
- ```
60
- (If main.py loads PIBWindow directly.) Use Start/Pause/Reset; plots update via QTimer.
61
-
62
- ## Testing
63
- ```bash
64
- cd "D:\Physics Simulation Project\Physics Simulation Project Code"
65
- python -m pip install pytest
66
- pytest -q
67
- ```
68
-
69
- ## Key Features
70
- - True TDSE solver (CN/SSFM) with normalization each step and stability checks
71
- - Probability current and energy expectation utilities
72
- - Infinite well, finite well, harmonic oscillator potentials
73
- - Hydrogen spectrum calculations (wavelengths, series detection)
74
- - Dark-themed, responsive Streamlit UI with export options and smooth set_ydata updates
75
-
76
- ## Notes
77
- - If you see missing dependency errors, rerun `run_app.bat`.
78
- - For large grids or small dt, computation may take longer; Streamlit shows progress where applicable.
79
- - Custom potential editor and TISE pages are stubs ready for extension.
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ title: Quantum Physics Simulation
3
+ emoji: ⚛️
4
+ colorFrom: indigo
5
+ colorTo: blue
6
+ sdk: streamlit
7
+ sdk_version: "1.32.0"
8
+ app_file: app.py
9
+ pinned: false
10
+ ---
11
+
12
+ # ⚛ Quantum Physics Simulation
13
+
14
+ This interactive app visualizes:
15
+
16
+ - Probability density of Hydrogen atom wavefunctions
17
+ - Orbital shapes for quantum numbers n, l, m
18
+ - Node structure
19
+ - Phase visualization
20
+ - Particle-in-a-box wavefunctions
21
+ - 2D & 3D views
22
+ - Animations
23
+
24
+ Built using **Streamlit**, **NumPy**, and **Plotly 3D**.
25
+
26
+ # Quantum Simulation Suite
27
+
28
+ ## Overview
29
+ - Particle in a Box (PIB) time-dependent Schrödinger simulation (Crank–Nicolson, Split-Step Fourier)
30
+ - Hydrogen spectrum (Rydberg formula, energy levels, stick spectrum)
31
+ - TDSE wavepacket evolution with spacetime heatmap
32
+ - Modular UIs: Streamlit (dark theme, sidebar navigation) and PySide6 (legacy)
33
+ - Physics engine: real constants, potentials, eigenfunctions, TDSE solver with normalization and stability checks
34
+
35
+ ## Project Structure
36
+ - `streamlit_main.py` — Streamlit entrypoint with sidebar pages
37
+ - `run_app.bat` — Installs deps and launches Streamlit UI
38
+ - `run_streamlit_main.bat` — Same as above (alternative launcher)
39
+ - `app/core/physics_engine/` — constants, potentials, PIB equations, TDSE solver, hydrogen spectrum
40
+ - `app/core/animations/` — Matplotlib animations (PIB, Hydrogen)
41
+ - `app/ui_streamlit/` — Streamlit UIs (PIB, Hydrogen, TDSE, TISE placeholder, Custom Potential placeholder)
42
+ - `app/ui/` — PySide6 legacy UI (PIB, Hydrogen, main window)
43
+ - `app/tests/` — pytest suites for equations, potentials, solver
44
+ - `data/`, `docs/` — optional data/docs folders (ignored by git)
45
+
46
+ ## Requirements
47
+ - Python 3.10+
48
+ - numpy, scipy, matplotlib, streamlit, PySide6, numba, pandas (batch files auto-install)
49
+
50
+ ## How to Run (Streamlit UI)
51
+ 1) Open a terminal:
52
+ ```bash
53
+ cd "D:\Physics Simulation Project\Physics Simulation Project Code"
54
+ run_app.bat
55
+ ```
56
+ (or `run_streamlit_main.bat` or `streamlit run streamlit_main.py`)
57
+ 2) In the browser sidebar, choose:
58
+ - **Particle in a Box (PIB)**: set L, n, solver, dt, grid; enable superposition; click Start. Tabs show ψ, |ψ|², energies, live animation. Export PNG/CSV available.
59
+ - **Hydrogen Spectrum**: pick series and n₂>n₁; view wavelengths, photon energies, stick spectrum, energy levels.
60
+ - **TDSE Simulation**: set wavepacket params, domain, dt/steps; compute frames; view animation and |ψ|² heatmap.
61
+ - **TISE / Custom Potential**: placeholders for future extensions.
62
+ 3) Animations update frame-by-frame (no jumps); energy and norm displayed live.
63
+
64
+ ## How to Use the Simulation
65
+ 1. Launch UI
66
+ - Double-click `run_app.bat` (or run `streamlit run streamlit_main.py`).
67
+ 2. Pick a module in the sidebar:
68
+ - **Particle in a Box (PIB):** set L, n, dt, grid, solver (CN/SSFM); optionally enable superposition; click **Start**. View tabs for ψ, |ψ|², energies, animation; export PNG/CSV.
69
+ - **Hydrogen Spectrum:** choose series (Lyman/Balmer/...), set n₂>n₁; see wavelength, photon energy, stick spectrum, energy levels.
70
+ - **TDSE Simulation:** set wavepacket (x₀, σ, k₀), domain, dt, steps; click **Start TDSE**; scrub frames or auto-play; heatmap in second tab.
71
+ - **TISE / Custom Potential:** placeholders ready for extension.
72
+ 3. Tips
73
+ - Sliders update instantly; animations are frame-by-frame (no jumps).
74
+ - If norm drifts, reduce dt or increase grid size.
75
+ - Export buttons provide PNG/CSV snapshots.
76
+ - Dark theme and auto-scaling are enabled by default.
77
+ 4. PySide6 (optional)
78
+ - Run `python main.py` (if wired to PIBWindow); use Start/Pause/Reset.
79
+
80
+ ## How to Run (PySide6 UI, optional)
81
+ ```bash
82
+ cd "D:\Physics Simulation Project\Physics Simulation Project Code"
83
+ python main.py
84
+ ```
85
+ (If main.py loads PIBWindow directly.) Use Start/Pause/Reset; plots update via QTimer.
86
+
87
+ ## Testing
88
+ ```bash
89
+ cd "D:\Physics Simulation Project\Physics Simulation Project Code"
90
+ python -m pip install pytest
91
+ pytest -q
92
+ ```
93
+
94
+ ## Key Features
95
+ - True TDSE solver (CN/SSFM) with normalization each step and stability checks
96
+ - Probability current and energy expectation utilities
97
+ - Infinite well, finite well, harmonic oscillator potentials
98
+ - Hydrogen spectrum calculations (wavelengths, series detection)
99
+ - Dark-themed, responsive Streamlit UI with export options and smooth set_ydata updates
100
+
101
+ ## Notes
102
+ - If you see missing dependency errors, rerun `run_app.bat`.
103
+ - For large grids or small dt, computation may take longer; Streamlit shows progress where applicable.
104
+ - Custom potential editor and TISE pages are stubs ready for extension.