All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Pages
theta_time_stepping_integrator.h
1 /* Copyright (C) 2004-2009 MBSim Development Team
2  *
3  * This library is free software; you can redistribute it and/or
4  * modify it under the terms of the GNU Lesser General Public
5  * License as published by the Free Software Foundation; either
6  * version 2.1 of the License, or (at your option) any later version.
7  *
8  * This library is distributed in the hope that it will be useful,
9  * but WITHOUT ANY WARRANTY; without even the implied warranty of
10  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11  * Lesser General Public License for more details.
12  *
13  * You should have received a copy of the GNU Lesser General Public
14  * License along with this library; if not, write to the Free Software
15  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
16  *
17  * Contact: martin.o.foerg@googlemail.com
18  */
19 
20 #ifndef _MU_TIME_STEPPING_INTEGRATOR_H_
21 #define _MU_TIME_STEPPING_INTEGRATOR_H_
22 
23 #include "integrator.h"
24 
25 namespace MBSimIntegrator {
26 
37  public:
42 
47 
48  /* INHERITED INTERFACE OF INTEGRATOR */
50  virtual void initializeUsingXML(xercesc::DOMElement *element);
51  /***************************************************/
52 
53  /* GETTER / SETTER */
54  void setStepSize(double dt_) { dt = dt_; }
55  void setTheta(double theta_ ) { theta = theta_; }
56  void setDriftCompensation(bool dc) { driftCompensation = dc; }
57  /***************************************************/
58 
65  void update(MBSim::DynamicSystemSolver& system, const fmatvec::Vec& z, double t);
66 
72 
78  void subIntegrate(MBSim::DynamicSystemSolver& system, double tStop);
79 
85 
86  private:
90  double dt;
91 
95  double theta;
96 
100  double t, tPlot;
101 
105  int iter,step, integrationSteps, maxIter, sumIter;
106 
110  double s0, time;
111 
115  int stepPlot;
116 
120  fmatvec::Vec z, q, u, x;
121 
125  std::ofstream integPlot;
126 
131  };
132 
133 }
134 
135 #endif /* _MU_TIME_STEPPING_INTEGRATOR_H_ */
136 
double dt
step size
Definition: theta_time_stepping_integrator.h:90
bool driftCompensation
flag for drift compensation
Definition: theta_time_stepping_integrator.h:130
solver interface for modelling and simulation of dynamic systems
Definition: dynamic_system_solver.h:48
void postIntegrate(MBSim::DynamicSystemSolver &system)
postintegration steps
Definition: theta_time_stepping_integrator.cc:156
void subIntegrate(MBSim::DynamicSystemSolver &system, double tStop)
integration steps
Definition: theta_time_stepping_integrator.cc:101
void integrate(MBSim::DynamicSystemSolver &system)
start the integration
Definition: theta_time_stepping_integrator.cc:170
virtual void initializeUsingXML(xercesc::DOMElement *element)
initialize integrator
Definition: theta_time_stepping_integrator.cc:177
std::ofstream integPlot
file stream for integration information
Definition: theta_time_stepping_integrator.h:125
double s0
computing time counter
Definition: theta_time_stepping_integrator.h:110
int stepPlot
plot step difference
Definition: theta_time_stepping_integrator.h:115
virtual ~ThetaTimeSteppingIntegrator()
destructor
Definition: theta_time_stepping_integrator.h:46
double theta
convex combination parameter between explicit (0) and implicit (1) Euler scheme
Definition: theta_time_stepping_integrator.h:95
int iter
iteration counter for constraints, plots, integration, maximum constraints, cummulation constraint ...
Definition: theta_time_stepping_integrator.h:105
Definition: theta_time_stepping_integrator.h:36
fmatvec::Vec z
state, position, velocity, order coordinate of dynamical system
Definition: theta_time_stepping_integrator.h:120
double t
time and plot time
Definition: theta_time_stepping_integrator.h:100
void update(MBSim::DynamicSystemSolver &system, const fmatvec::Vec &z, double t)
update of dynamic system necessary values concerning theta time stepping integrator ...
Definition: theta_time_stepping_integrator.cc:43
ThetaTimeSteppingIntegrator()
constructor
Definition: theta_time_stepping_integrator.cc:41
integrator-interface for dynamic systems
Definition: integrator.h:40
static DynamicSystemSolver * system
dynamic system
Definition: solver.h:65
void preIntegrate(MBSim::DynamicSystemSolver &system)
preintegration steps
Definition: theta_time_stepping_integrator.cc:66

Impressum / Disclaimer / Datenschutz Generated by doxygen 1.8.5 Valid HTML