openPSTD
2.0
Open source simulation for sound propagation in urban environments
|
Component that computes the state variables of the scene for consecutive time steps. More...
#include <Solver.h>
Public Member Functions | |
Solver (std::shared_ptr< Scene > scene, KernelCallback *callback) | |
Solver constructor (abstract). More... | |
void | compute_propagation () |
Start the simulation solver. More... | |
Protected Member Functions | |
void | update_field_values (std::shared_ptr< Domain > domain, unsigned long rk_step) |
Updates the pressure and velocity fields of the domains to the new values computed in the RK scheme. More... | |
PSTD_FRAME_PTR | get_pressure_vector () |
The GUI format for pressure fields. More... | |
Protected Attributes | |
KernelCallback * | callback |
int | number_of_time_steps |
The final number of computed frames. | |
Component that computes the state variables of the scene for consecutive time steps.
This is an abstract class, implemented in single/multi-threaded solvers. Based on the settings and the scene, the solver repeatedly executes the PSTD method to approximate the pressure and velocity. The time integration is performed with a RK6 method described in <paper>.
OpenPSTD::Kernel::Solver::Solver | ( | std::shared_ptr< Scene > | scene, |
KernelCallback * | callback | ||
) |
Solver constructor (abstract).
Initialized parameters for running the openPSTD algorithm
scene | Pointer to scene object. |
callback | Pointer to callback function |
void OpenPSTD::Kernel::Solver::compute_propagation | ( | ) |
Start the simulation solver.
Runs until the simulation is finished, but meanwhile makes calls to the callback. A more badass name is welcome
|
protected |
The GUI format for pressure fields.
|
protected |
Updates the pressure and velocity fields of the domains to the new values computed in the RK scheme.
domain | Domain under consideration |
rk_step | sub-step of RK6 method |