Karamelo  714599e9
Parallel Material Point Method Simulator
output.h
1 /* -*- c++ -*- ----------------------------------------------------------
2  *
3  * *** Karamelo ***
4  * Parallel Material Point Method Simulator
5  *
6  * Copyright (2019) Alban de Vaucorbeil, alban.devaucorbeil@monash.edu
7  * Materials Science and Engineering, Monash University
8  * Clayton VIC 3800, Australia
9 
10  * This software is distributed under the GNU General Public License.
11  *
12  * ----------------------------------------------------------------------- */
13 
14 #ifndef MPM_OUTPUT_H
15 #define MPM_OUTPUT_H
16 
17 #include "pointers.h"
18 #include <vector>
19 
20 
23 class Output : protected Pointers {
24 public:
25  bigint next;
26 
27 
28  bigint next_log;
29  int every_log;
30  class Log *log;
31 
32  bigint next_dump_any;
33  vector<int> every_dump;
34  vector<bigint> next_dump;
35  vector<bigint> last_dump;
36  int ndumps;
37  vector<class Dump *> dumps;
38 
39  bigint next_plot_any;
40  vector<int> every_plot;
41  vector<bigint> next_plot;
42  vector<bigint> last_plot;
43  int nplots;
44  vector<class Plot *> plots;
45  bool save_plot;
46  string ofile_plot;
47 
48  Output(class MPM *);
49  ~Output();
50 
51  void setup();
52  void write(bigint);
53  void show_plot();
54 
55  void set_log(vector<string>);
56 
57  void add_dump(vector<string>);
58  int find_dump(string);
59  void modify_dump(vector<string>);
60  void delete_dump(string);
61 
62  void add_plot(vector<string>);
63  int find_plot(string);
64  void modify_plot(vector<string>);
65  void delete_plot(string);
66 };
67 
68 #endif
vector< bigint > last_dump
last timestep each snapshot was output
Definition: output.h:35
void add_plot(vector< string >)
add a Plot to Plot list
Definition: output.cpp:251
void write(bigint)
output for current timestep
Definition: output.cpp:117
bigint next_log
next timestep for log output
Definition: output.h:28
int ndumps
number of defined Dumps, should always be equal to dumps.size()
Definition: output.h:36
void modify_plot(vector< string >)
modify a Plot
Definition: output.cpp:270
vector< bigint > next_dump
next timestep to do each Dump
Definition: output.h:34
bool save_plot
true to save plot in file
Definition: output.h:45
string ofile_plot
filename to save the plot to
Definition: output.h:46
void delete_dump(string)
delete a Dump from Dump list
Definition: output.cpp:233
Definition: mpm.h:29
void delete_plot(string)
delete a Plot from Plot list
Definition: output.cpp:281
bigint next
next timestep for any kind of output
Definition: output.h:25
Definition: output.h:23
int nplots
number of defined Plots, should always be equal to plots.size()
Definition: output.h:43
void show_plot()
show plot
Definition: output.cpp:168
int find_plot(string)
find a Plot in Plot list
Definition: output.cpp:292
vector< class Dump * > dumps
list of defined Dumps
Definition: output.h:37
int find_dump(string)
find a Dump in Dump list
Definition: output.cpp:244
vector< class Plot * > plots
list of defined Plots
Definition: output.h:44
vector< int > every_dump
write freq for each Dump, 0 if var
Definition: output.h:33
int every_log
freq for log output
Definition: output.h:29
void add_dump(vector< string >)
add a Dump to Dump list
Definition: output.cpp:192
bigint next_plot_any
next timestep for any Plot
Definition: output.h:39
void modify_dump(vector< string >)
modify a Dump
Definition: output.cpp:222
Definition: pointers.h:29
bigint next_dump_any
next timestep for any Dump
Definition: output.h:32
vector< bigint > last_plot
last timestep each snapshot was output
Definition: output.h:42
vector< bigint > next_plot
next timestep for plot output
Definition: output.h:41
void set_log(vector< string >)
set log output frequency
Definition: output.cpp:185
vector< int > every_plot
write freq for each Plot, 0 if var
Definition: output.h:40