Karamelo  714599e9
Parallel Material Point Method Simulator
update.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_UPDATE_H
15 #define MPM_UPDATE_H
16 
17 #include "pointers.h"
18 #include <vector>
21 class Update : protected Pointers {
22  public:
23  double run_duration;
25  double dt;
26  double dt_factor;
27  bool dt_constant;
28  bigint ntimestep;
29  int nsteps;
30  double atime;
31  double maxtime;
32  bigint atimestep;
33  bigint firststep,laststep;
34  bigint beginstep,endstep;
36 
37  class Scheme *scheme;
38  string scheme_style;
39 
40  class Method *method;
41  string method_type;
43 
44  Update(class MPM *);
45  ~Update();
46  void set_dt_factor(vector<string>);
47  void set_dt(vector<string>);
48  void create_scheme(vector<string>);
49  void create_method(vector<string>);
50  void update_time();
51  int update_timestep();
52 protected:
53 
54 };
55 
56 
57 #endif
bool dt_constant
is dt constant?
Definition: update.h:27
void create_method(vector< string >)
Creates a method: tlmpm, ulmpm, tlcpdi, ...
Definition: update.cpp:104
bigint laststep
1st & last step of this run
Definition: update.h:33
string method_type
Name of the method type.
Definition: update.h:41
double run_duration
Stop simulation if elapsed simulation time exceeds this.
Definition: update.h:23
Definition: mpm.h:29
string scheme_style
Name of the scheme style.
Definition: update.h:38
string method_shape_function
Type of shape function used.
Definition: update.h:42
double dt_factor
Timestep factor.
Definition: update.h:26
Definition: method.h:25
double maxtime
Maximum simulation time (infinite if -1)
Definition: update.h:31
void set_dt(vector< string >)
Sets the timestep.
Definition: update.cpp:65
double atime
Simulation time at atime_step.
Definition: update.h:30
class Scheme * scheme
Pointer to the type of Scheme used.
Definition: update.h:37
bigint atimestep
Last timestep atime was updated.
Definition: update.h:32
int update_timestep()
Update timestep.
Definition: update.cpp:141
int nsteps
Number of steps to run.
Definition: update.h:29
void update_time()
Update elapsed time.
Definition: update.cpp:131
Definition: pointers.h:29
void create_scheme(vector< string >)
Creates a scheme: USL, or MUSL.
Definition: update.cpp:79
double dt
Timestep.
Definition: update.h:25
class Method * method
Pointer to the type of Method used.
Definition: update.h:40
bigint ntimestep
current step
Definition: update.h:28
bigint endstep
1st and last step of multiple runs
Definition: update.h:34
Definition: update.h:21
int first_update
0 before initial update, 1 after
Definition: update.h:35
double elapsed_time_in_run
Elapsed simulation time for a single run;.
Definition: update.h:24
void set_dt_factor(vector< string >)
Sets the factor to be applied to the CFL timestep.
Definition: update.cpp:58