How to compile
===============================================

FEASST requires C++14 and CMake, and is compiled with the following BASH commands:

.. code-block:: bash

    # [apt/yum/dnf/brew] install g++ cmake curl tar. On HPC, try "module avail; module load"
    cd $HOME # replace this with your preference throughout
    curl -OL https://github.com/usnistgov/feasst/archive/refs/tags/v0.25.8.tar.gz # download
    tar -xf v0.25.8.tar.gz           # uncompress
    mkdir feasst-0.25.8/build; cd $_ # out-of-source build
    cmake ..                         # find prerequisites
    make install -j 4                # compile on 4 threads
    # Optional Python packages used in tutorials. Virtual environment recommended:
    # https://packaging.python.org/en/latest/guides/installing-using-pip-and-virtual-environments
    pip install jupyter matplotlib pandas scipy ../pyfeasst # ../ ensures pyfeasst matches feasst
    # Because online documentation changes with verison, open local version documentation.
    xdg-open ../html/index.html      # For macOS, replace "xdg-open" with "open"

How to run a simulation
===============================================

Input a text file to the compiled executable.

.. code-block:: bash

    $HOME/feasst-0.25.8/build/bin/fst < $HOME/feasst-0.25.8/tutorial/example.txt

The following text input file is explained in detail in the first :doc:`tutorial <tutorial/tutorial>`.

.. literalinclude:: tutorial/example.txt

