PSCF v1.5.0
StepLogger.h
1#ifndef RP_STEP_LOGGER_H
2#define RP_STEP_LOGGER_H
3
4/*
5* PSCF - Polymer Self-Consistent Field
6*
7* Copyright 2015 - 2026, David Morse (morse012@um.edu) and co-authors
8* Distributed under the terms of the GNU General Public License.
9*/
10
11#include <rp/fts/analyzer/Analyzer.h>
12
13#include <pscf/backend/TmplDeclare.h>
14#include <iostream>
15
16namespace Pscf {
17namespace Rp {
18
30 template <int D, class T>
31 class StepLogger : public Analyzer<D,T>
32 {
33
34 public:
35
44
48 ~StepLogger() = default;
49
55 void readParameters(std::istream& in) override;
56
62 void sample(long iStep) override;
63
64 };
65
66 // Explicit instantiation declarations
67 PSCF_TMPL_DECLARE(StepLogger)
68
69}
70}
71#endif
72
Analyzer(Simulator< D, T > &simulator, System< D, T > &system)
Constructor.
Definition Analyzer.tpp:31
Simulator< D, T > & simulator()
Get the parent Simulator by reference.
Definition Analyzer.h:233
System< D, T > & system()
Get the parent System by reference.
Definition Analyzer.h:243
Base class for field theoretic PS-FTS simulator.
Definition Simulator.h:93
Periodically write the step index to a log file.
Definition StepLogger.h:32
StepLogger(Simulator< D, T > &simulator, System< D, T > &system)
Constructor.
void readParameters(std::istream &in) override
Read interval.
~StepLogger()=default
Destructor.
void sample(long iStep) override
Write the step index to a log file.
Base class template for classes that represent a complete system.
Code for programs that simulate real-valued periodic fields.
Definition param_pc.dox:2
PSCF package top-level namespace.