Skip to content

Latest commit

 

History

History
59 lines (40 loc) · 1.27 KB

File metadata and controls

59 lines (40 loc) · 1.27 KB

Quickstart Guide

This quickstart demonstrates how to build and run a minimal N-body simulation using NEXT (Newtonian EXact Trajectories).


Prerequisites

  • Git
  • CMake (>= 3.10)
  • C++ Compiler (GCC, Clang, or MSVC with OpenMP support)
  • Python 3 (for initial condition generation)
  • HDF5 libraries

Quickstart Steps

1. Clone the Repository

git clone https://github.com/TimGoTheCreator/NEXT.git
cd NEXT

2. Build NEXT

cmake -B build -S .
cmake --build build --config Release

3. Generate & Run Example Simulation

cd examples/TwoBodies
python two_body.py
../../next two_body.txt 8 0.001 0.1 vtu 50

Arguments Explained:

  • two_body.txt - Initial condition particle data generated by two_body.py
  • 8 - Number of OpenMP CPU worker threads
  • 0.001 - Baseline simulation time step (dt)
  • 0.1 - Simulation time interval between data output dumps
  • vtu - Output file format (vtu, vtk, or hdf5)
  • 50 - (Optional) Maximum steps to run before exiting

4. Visualize Results

  • Open the generated .vtu files (dump_0.vtu, dump_1.vtu, ...) in ParaView or VisIt.
  • Apply a Glyph filter to visualize particles, and press Play to view orbital trajectories.