The Nek5000/RS project · Argonne National Laboratory

High-order flow simulation, from your laptop to exascale.

nekRS is a fast, scalable spectral element solver for the incompressible and low Mach-number Navier–Stokes equations, used for fluid flow, heat transfer, combustion and magnetohydrodynamics. It runs on GPUs and CPUs, from a single workstation to the largest systems in the world.

nekRS is the successor to Nek5000, which remains available as a legacy code.

40+ years
of spectral element research behind Nek5000/RS
600+ users
in academia, national laboratories and industry
CUDA · HIP · SYCL
plus CPU, from one OCCA kernel source
BSD 3-clause
open source, developed in the open on GitHub

Recognition

Awards and adoption

  1. 1999 ACM Gordon Bell Prize Nek5000

    Terascale spectral element algorithms and implementations, run on ASCI Red.

  2. 2016 R&D 100 Award NekCEM / Nek5000

    Scalable high-order simulation codes for fluid flow and electromagnetics.

  3. 2023 Gordon Bell Prize finalist nekRS

    Exascale multiphysics nuclear reactor simulations, coupling nekRS with Monte Carlo neutron transport on Frontier.

  4. NRC licensing Part of BlueCRAB nekRS / Nek5000

    The NRC’s Comprehensive Reactor Analysis Bundle for licensing advanced reactors includes our codes.

Download

Codes

All development happens in nekRS, and nekAI and nekAgent extend it. Nek5000 is its predecessor.

nekRS

Recommended

v26.1 · C++17 · GPU and CPU

Our actively developed solver for new projects. Written for accelerators from the start and tuned for current and upcoming exascale systems.

nekAI

New

nekRS extension · machine learning

Machine learning built around nekRS simulations. Description and links coming soon.

nekAgent

New

nekRS extension · AI agents

Agent-driven case setup, runs and analysis with nekRS. Description and links coming soon.

Nek5000

Legacy

v19.0 · Fortran 77 · CPU

The original spectral element code, in use since the 1980s. It remains available for existing workflows; new projects should use nekRS, which can read Nek5000 case files.

Capabilities

Accurate where it matters, fast where it counts

High-order methods resolve turbulence, heat transfer and mixing with far fewer degrees of freedom than low-order solvers at the same accuracy.

Physics

  • Incompressible and low Mach-number Navier–Stokeswith any number of passive or coupled scalars
  • Conjugate fluid–solid heat transfer
  • LES and RANS turbulence models
  • Lagrangian phase model
  • Moving and deforming meshesarbitrary Lagrangian–Eulerian formulation

Numerics

  • Spectral element discretizationhigh-order curvilinear conformal hexahedra
  • Semi-implicit 2nd/3rd-order time integrationwith variable time step
  • Overlapping overset grids
  • Scalable multigrid and Schwarz preconditioners
  • Mesh tools and third-party mesh converters

Platform

  • GPU accelerationCUDA, HIP and DPC++/SYCL through OCCA
  • MPI parallelismfrom a laptop to leadership-class systems
  • Parallel I/O
  • VisIt and ParaView supportin-situ visualization through Ascent
  • Linux and macOS

Get started

Run your first nekRS case in three steps

  1. Build and install

    You need an MPI-3.1 library, a C++17 compiler and CMake 3.21 or later. On an HPC system, build on a compute node.

    git clone https://github.com/Nek5000/nekRS.git
    cd nekRS
    CC=mpicc CXX=mpic++ FC=mpif77 ./build.sh -DCMAKE_INSTALL_PREFIX=$HOME/.local/nekrs
  2. Set the environment

    Add these lines to your shell profile, for example ~/.bash_profile.

    export NEKRS_HOME=$HOME/.local/nekrs
    export PATH=$NEKRS_HOME/bin:$PATH
  3. Run an example

    Copy a case outside the install tree and launch it. Each case is set up by a .par file; nrsman documents every option.

    cp -a $NEKRS_HOME/examples/turbPipePeriodic .
    cd turbPipePeriodic
    mpirun -np 2 nekrs --setup turbPipe.par

Job scripts for common supercomputers are in nekRS_HPCsupport. Read the release notes before upgrading. Working with Nek5000? Follow the NekDoc quickstart.

Citing nekRS

If nekRS helps your research, please cite

P. Fischer, S. Kerkemeier, M. Min, Y.-H. Lan, M. Phillips, T. Rathnayake, E. Merzari, A. Tomboulides, A. Karakus, N. Chalmers, T. Warburton. NekRS, a GPU-accelerated spectral element Navier–Stokes solver. Parallel Computing 114 (2022) 102982.
Read the paper

Funding

Supported by

  • U.S. Department of Energy
  • U.S. National Science Foundation
  • EuroHPC Joint Undertaking

This research was supported by the Exascale Computing Project (17-SC-20-SC), a joint project of the U.S. Department of Energy’s Office of Science and National Nuclear Security Administration.