Simpatico  v1.10
ddMd/analyzers/stress/StressAutoCorr.h
1 #ifndef DDMD_STRESS_AUTO_CORR_H
2 #define DDMD_STRESS_AUTO_CORR_H
3 
4 /*
5 * Simpatico - Simulation Package for Polymeric and Molecular Liquids
6 *
7 * Copyright 2010 - 2017, The Regents of the University of Minnesota
8 * Distributed under the terms of the GNU General Public License.
9 */
10 
11 #include <ddMd/analyzers/Analyzer.h>
12 #include <ddMd/simulation/Simulation.h>
13 #include <util/mpi/MpiLoader.h>
14 #include <util/space/Tensor.h>
15 #include <util/accumulators/AutoCorrelation.h> // member template
16 
17 namespace DdMd
18 {
19 
20  using namespace Util;
21 
27  class StressAutoCorr : public Analyzer
28  {
29 
30  public:
31 
37  StressAutoCorr(Simulation& simulation);
38 
42  virtual ~StressAutoCorr()
43  {}
44 
50  virtual void readParameters(std::istream& in);
51 
57  virtual void loadParameters(Serializable::IArchive &ar);
58 
64  virtual void save(Serializable::OArchive &ar);
65 
69  virtual void clear();
70 
74  virtual void setup();
75 
81  virtual void sample(long iStep);
82 
86  virtual void output();
87 
88  private:
89 
91  std::ofstream outputFile_;
92 
94  AutoCorrelation<Tensor, double>* accumulatorPtr_;
95 
97  int bufferCapacity_;
98 
100  int maxStageId_;
101 
103  long isInitialized_;
104 
105  };
106 
107 }
108 #endif
Abstract base for periodic output and/or analysis actions.
Parallel domain decomposition (DD) MD simulation.
Main object for a domain-decomposition MD simulation.
Saving / output archive for binary ostream.
Compute stress autocorrelation function for a liquid.
Utility classes for scientific computation.
Definition: accumulators.mod:1
Saving archive for binary istream.