specfem::program::execute

bool specfem::program::execute(const std::string &dimension, const YAML::Node &parameter_dict, const YAML::Node &default_dict)

Execute complete SPECFEM simulation with runtime dimension selection.

Main entry point for the SPECFEM executable that dispatches to the appropriate dimension-specific implementation (2D or 3D), which orchestrate the full simulation workflow: mesh reading, database generation, source/receiver configuration, assembly, time integration, and seismogram and wavefield/kernel outputs.

Parameters:
  • dimension – Simulation dimension: “2d” or “3d”

  • parameter_dict – User-provided YAML configuration overriding defaults

  • default_dict – YAML default values for all simulation parameters

Throws:

std::runtime_error – if dimension is invalid or simulation encounters fatal error

Returns:

true on successful completion, false on failure