Skip to content

Latest commit

 

History

History

experiments

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 
 
 
 
 

README.md

Follow an experiment

Course contents · Method notes · Saved results

Each numbered script starts with a physical question and fixes the conditions of a comparison. Read the module docstring for its command and outputs, then open run_experiment() to see the setup. Step formulas live in the core package. The experiment chooses what to measure.

From the lesson to the script

Lesson Experiment What to inspect
1A exp01_circular_orbit.py Circular orbits: what does one step do?
1B exp02_convergence.py Step size and convergence order
1C exp03_eccentric_adaptive.py Eccentric orbits and adaptive steps
1D exp04_long_time.py Long-term energy, angular momentum, and phase
1E exp05_kepler_splitting.py Kepler splitting and the two-body limit
1F exp06_spatial_consistency.py From 2D to 3D: rotation consistency
2A exp2a_planetary_three_body.py A third body: physical change or numerical error?
2B exp2b_convergence_efficiency.py Convergence and efficiency with real perturbations
2C exp2c_perturbation_scan.py How perturbation strength changes method choice
2D exp2d_long_term_dynamics.py Long-term three-body dynamics
2E exp2e_close_encounter.py Close encounters: resolving a fast event
2F exp2f_spatial_three_body.py Spatial three-body motion and angular momentum
2G exp2g_reference_horizon.py When does a numerical reference stop being useful?
2R exp2r_restricted_three_body.py The circular restricted three-body problem
3A exp3a_five_body.py Five bodies: reuse the solver, widen the diagnostics
3B exp3b_n_scaling.py N and the cost of direct gravity
3C exp3c_timescale_span.py One system, many orbital timescales
3D exp3d_self_gravitating_cluster.py Self-gravitating clusters without a central star
3E exp3e_ensemble_statistics.py Beyond trajectories: ensembles and uncertainty
3F exp3f_regime_chart.py An evidence-based integrator selection guide
4A exp4a_corrector.py Validate a processor, then read the nine-point error/work scan
4B exp4b_periapsis.py Isolated control, high-eccentricity perturbations, and local resolution
4C exp4c_hybrid.py Actual encounter geometry, external hybrids, and output-dependent timing
4D exp4d_cost_to_target.py Read 3F with explicit profiles and objective-specific margins
4E exp4e_zlk.py Matched inclined triples, secular observables and sampling validation

The path through the code

The setup constructs positions, velocities, masses, and the physical model. The runner then applies the selected settings, compares the trajectories with a checked reference, records diagnostics and work, and saves the plots. 3F is different: it reads saved tables without integrating.

A compact entry point is the method registry. Follow its step function into the relevant family. The driver handles sampling and adaptive trial steps. The design notes explain the other layers.

Function links in the lessons open the relevant source lines on GitHub. They are reading aids, not additional tasks. Formal docstrings describe the interface and assumptions. Longer intuition belongs in the lesson, where it can sit beside a measured example.

Use runpart1.py, runpart2.py, runpart3.py, or runpart4.py from the project root. Part 1 modules rely on package-relative imports. The setup guide gives the supported commands.

Part 4 adds its own shared serialization and external control. Its versioned schema is part4-v1. 4D reads only an explicit legacy 3F snapshot; it does not turn every new result folder into a map input.

The Part 4 code guide explains the local and external adapters used by all five implemented lessons.