11 csv_writer->initialize({
"iteration",
"temperature"});
25 csv_writer->writeRow({iteration, current_temperature});
31 csv_writer->writeRow({iteration, current_temperature});
35 std::string indent = std::string(depth * 2,
' ');
41 TemperatureSensorInterceptor::operator std::string()
const {
return ""; }
const std::string ansi_end
const std::string ansi_orange_bold
static std::shared_ptr< spdlog::logger > logger
Publically accessible shared pointer to the logger.
size_t every_nth_iteration
double delta_t
Time step of a single simulation iteration.
std::filesystem::path output_dir_path
Path to the directory in which to save the simulation output.
size_t start_iteration
Start iteration of the simulation.
double end_time
End time of the simulation.
Class to run a simulation.
std::unique_ptr< ParticleContainer > particle_container
Reference to the ParticleContainer on whose content the simulation is performed.
const SimulationParams & params
Reference to the simulation parameters object.
double sample_every_x_percent
void onSimulationStart(Simulation &simulation) override
This function is empty as the thermostat doesnt need initialization.
std::unique_ptr< CSVWriter > csv_writer
void operator()(size_t iteration, Simulation &simulation) override
This function is called on every nth iteration. It scales the temperature of the particles in accorda...
std::shared_ptr< Thermostat > thermostat
The thermostat that is used to scale the temperature.
void onSimulationEnd(size_t iteration, Simulation &simulation) override
This function is empty as the thermostat doesnt need to do anything at the end of the simulation.
void logSummary(int depth) const override
Logs the summary of the thermostat.