Simpatico  v1.10
OutputPressure.h
1 #ifndef DDMD_OUTPUT_PRESSURE_H
2 #define DDMD_OUTPUT_PRESSURE_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 
15 namespace DdMd
16 {
17 
18  using namespace Util;
19 
27  class OutputPressure : public Analyzer
28  {
29 
30  public:
31 
37  OutputPressure(Simulation& simulation);
38 
42  virtual ~OutputPressure()
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 
83  private:
84 
86  std::ofstream outputFile_;
87 
89  long nSample_;
90 
92  long isInitialized_;
93 
94  };
95 
96 }
97 #endif
Abstract base for periodic output and/or analysis actions.
Periodically write (scalar) pressure to file.
virtual ~OutputPressure()
Destructor.
Parallel domain decomposition (DD) MD simulation.
Main object for a domain-decomposition MD simulation.
Saving / output archive for binary ostream.
Utility classes for scientific computation.
Definition: accumulators.mod:1
Saving archive for binary istream.