SERiF 0.0.1a
3+1D Stellar Structure and Evolution
|
Welcome to the documentation for 4DSSE (4D Stellar Structure and Evolution), a new code designed for simulating stellar phenomena in three spatial dimensions plus time. This project is currently under active development.
The primary goal of 4DSSE is to provide a flexible and extensible framework for advanced stellar modeling, incorporating modern numerical techniques and physics modules.
The project uses Meson as its build system. MFEM is a core dependency and will be automatically downloaded and built if not found.
Prerequisites:
pip install meson
)Build Steps:
bash git clone <repository-url> cd 4dsse
mk
script (recommended for ease of use):bash ./mk
bash ./mk --noTest
4DSSEConsole.sh
script: This script provides a simple interface for building and debugging. bash ./4DSSEConsole.sh
Follow the on-screen prompts.build
): bash meson setup build
bash meson compile -C build
bash meson test -C build
The compiled executables and libraries will typically be found in the build
directory.
Below are some high-level examples of how to use key components of 4DSSE.
The PolySolver
class handles the setup and solution of the Lane-Emden equation for polytropic stellar models.
The Composition
class allows for defining and managing chemical compositions.
The Network
and Approx8Network
classes provide interfaces for nuclear reaction network calculations.
The Constants
singleton provides access to a database of physical constants.
The Config
singleton manages settings from a YAML configuration file.
The Probe::LogManager
provides a way to manage and use loggers.
The EosIO
class loads EOS tables, and the helmholtz
namespace provides functions to use them, for example, the Helmholtz EOS.
The MeshIO
class facilitates loading and managing computational meshes.
4DSSE is organized into several key modules:
polySolver.h
, polytropeOperator.h
): Provides tools to solve the Lane-Emden equation for polytropic stellar structures using a mixed finite element method. PolytropeOperator
defines the nonlinear system and its Jacobian, while PolySolver
orchestrates the solution process. The SchurCompliment
and GMRESInverter
classes are helper components for the linear algebra involved.helm.h
, eosIO.h
): Manages Equation of State data. helm.h
provides an implementation of the Helmholtz EOS (Timmes & Swesty 2000), including structures for table data (HELMTable
), input parameters (EOSInput
), and output results (EOS
). It also defines functions for reading tables and calculating EOS quantities. eosIO.h
provides the EosIO
class for loading EOS tables from files, currently supporting the HELM table format.composition.h
, atomicSpecies.h
): Manages chemical compositions, allowing representation in mass or number fractions. It interfaces with atomicSpecies.h
which provides a database of atomic species properties (based on AME2020).network.h
, approx8.h
): Defines a base Network
class for nuclear reaction network calculations. approx8.h
provides a specific implementation, Approx8Network
, for an 8-isotope network (H1, He3, He4, C12, N14, O16, Ne20, Mg24) based on Frank Timmes' "aprox8". It includes functions for individual reaction rates and uses Boost.Numeric.Odeint for solving the ODE system.const.h
): A singleton class Constants
that loads and provides access to a wide range of physical constants with their values, uncertainties, units, and references.config.h
): A singleton class Config
for loading and accessing application settings from YAML configuration files.probe.h
): The Probe
namespace offers utility functions for debugging, such as GLVis visualization (glVisView
), and a LogManager
for handling application-wide logging using the Quill library.meshIO.h
): The MeshIO
class handles loading and basic manipulation (e.g., scaling) of computational meshes using MFEM's mfem::Mesh
. It ensures that meshes are correctly loaded and accessible.integrators.h
): (Details inferred) Likely contains custom MFEM integrators or coefficients used in the finite element formulations.4DSTARTypes.h
): Defines project-specific data type aliases within the SSE
namespace, primarily for simplifying common std::pair
combinations involving mfem::Array<int>
and mfem::Array<double>
. These include SSE::MFEMArrayPair
and SSE::MFEMArrayPairSet
, often used for managing collections of MFEM degree-of-freedom lists and their corresponding values, especially for boundary conditions.Future work will focus on expanding the physics modules (e.g., equation of state, opacity), improving numerical solvers, and enhancing the parallelization capabilities for large-scale simulations.
For questions, bug reports, or contributions, please refer to the project's repository or contact the development team. (Details to be added)