MBDyn-1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups
thirdorderstepsol.cc
Go to the documentation of this file.
1 /* $Header: /var/cvs/mbdyn/mbdyn/mbdyn-1.0/mbdyn/base/thirdorderstepsol.cc,v 1.51 2017/01/12 14:46:11 masarati Exp $ */
2 /*
3  * MBDyn (C) is a multibody analysis code.
4  * http://www.mbdyn.org
5  *
6  * Copyright (C) 1996-2017
7  *
8  * Pierangelo Masarati <masarati@aero.polimi.it>
9  * Paolo Mantegazza <mantegazza@aero.polimi.it>
10  *
11  * Dipartimento di Ingegneria Aerospaziale - Politecnico di Milano
12  * via La Masa, 34 - 20156 Milano, Italy
13  * http://www.aero.polimi.it
14  *
15  * Changing this copyright notice is forbidden.
16  *
17  * This program is free software; you can redistribute it and/or modify
18  * it under the terms of the GNU General Public License as published by
19  * the Free Software Foundation (version 2 of the License).
20  *
21  *
22  * This program is distributed in the hope that it will be useful,
23  * but WITHOUT ANY WARRANTY; without even the implied warranty of
24  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25  * GNU General Public License for more details.
26  *
27  * You should have received a copy of the GNU General Public License
28  * along with this program; if not, write to the Free Software
29  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
30  */
31 
32  /*
33  *
34  * Copyright (C) 2008
35  * Marco Morandini <morandini@aero.polimi.it>
36  *
37  * third order integrator; brain-damaged code, mainly due to some
38  * brain-damaged design decision in mbdyn.
39  * This will have to change, but will require
40  * a substantial effort.
41  */
42 
43 
44 #include "mbconfig.h" /* This goes first in every *.c,*.cc file */
45 
46 #include <cmath>
47 #include "thirdorderstepsol.h"
48 #include "schurdataman.h"
49 
50 #include "stepsol.hc"
51 
53  const doublereal dSolutionTol,
54  const integer iMaxIt,
55  const bool bmod_res_test)
56 : ImplicitStepIntegrator(iMaxIt, dT, dSolutionTol, 1, 2, bmod_res_test),
57 pXPrev(0),
58 pXPrimePrev(0),
59 bAdvanceCalledFirstTime(true)
60 {
62  pJacxi_x = &Jacxi_x;
63  pJac_xp = &Jac_xp;
64  pJac_x = &Jac_x;
65 };
66 
68  NO_OP;
69 };
70 
73  const doublereal TStep,
74  const doublereal dAlph,
75  const StepChange StType,
76  std::deque<MyVectorHandler*>& qX,
77  std::deque<MyVectorHandler*>& qXPrime,
78  MyVectorHandler* const pX,
79  MyVectorHandler* const pXPrime,
80  integer& EffIter,
81  doublereal& Err,
82  doublereal& SolErr)
83 {
85  integer n = pDM->iGetNumDofs();
86  Restmp.Resize(n);
87  EqIsAlgebraic.resize(n);
88  EqIsDifferential.resize(n);
89  DataManager::DofIterator_const CurrDof = pDofs->begin();
90  for (int iCntm1 = 0; iCntm1 < n;
91  iCntm1++, ++CurrDof)
92  {
93  ASSERT(CurrDof != pDofs->end());
94  EqIsAlgebraic[iCntm1] = (
95  CurrDof->EqOrder == DofOrder::ALGEBRAIC);
96  EqIsDifferential[iCntm1] = (!EqIsAlgebraic[iCntm1]);
97  }
98  CurrDof = pDofs->begin();
99  Jacxi_xp.Resize(n, n);
100  Jacxi_x.Resize(n, n);
101  Jac_xp.Resize(n, n);
102  Jac_x.Resize(n, n);
103  bAdvanceCalledFirstTime = false;
104  }
105  pXCurr = pX;
106  pXPrev = qX[0];
107 
108  pXPrimeCurr = pXPrime;
109  pXPrimePrev = qXPrime[0];
110 
111  SetCoef(TStep, dAlph, StType);
112 
113  Predict();
115 
116  Err = 0.;
117  pS->pGetNonlinearSolver()->Solve(this, pS, MaxIters, dTol,
118  EffIter, Err, dSolTol, SolErr);
119 
120  return Err;
121 };
122 
123 
125  const DofOrder::Order Order,
126  const VectorHandler* const pSol) const {
127  if (Order == DofOrder::DIFFERENTIAL) {
128  doublereal dXnm1 = pXPrev->operator()(DCount);
129  doublereal dXPnm1 =
130  pXPrimePrev->operator()(DCount);
131 
132  doublereal dXn = dXnm1+dXPnm1*dT;
133  doublereal dXPn = dXPnm1;
134 
135  pXPrimeCurr->PutCoef(DCount, dXPn);
136  pXCurr->PutCoef(DCount, dXn);
137 
138  } else if (Order == DofOrder::ALGEBRAIC) {
139  doublereal dXnm1 = pXPrev->operator()(DCount);
140  //doublereal dXInm1 = pXPrimePrev->operator()(DCount);
141  doublereal dXn = dXnm1;
142  doublereal dXIn = dXnm1*dT;
143 
144  pXCurr->PutCoef(DCount, dXn);
145  pXPrimeCurr->PutCoef(DCount, dXIn);
146 
147  } else {
148  silent_cerr("ThirdOrderIntegrator::PredictDof_for_AfterPredict:"
149  << "unknown order for dof "
150  << DCount<< std::endl);
152  }
153 }
155  const DofOrder::Order Order,
156  const VectorHandler* const pSol) const {
157  integer iNumDofs = pDM->iGetNumDofs();
158  //simple copy of predicted state
159  pXPrimeCurr->PutCoef(DCount+iNumDofs,
160  pXPrimeCurr->operator()(DCount));
161  pXCurr->PutCoef(DCount+iNumDofs, pXCurr->operator()(DCount));
162  if (Order == DofOrder::DIFFERENTIAL) {
163  //doublereal dXPnm1 =
164  // pXPrimePrev->operator()(DCount);
165 
166  /* tempo theta*/
167 // doublereal dXn = dXPnm1*(theta-1.)*dT;
168 // pXCurr->IncCoef(DCount+iNumDofs, dXn);
169 // pXCurr->PutCoef(DCount+iNumDofs,
170 // m0*pXCurr->operator()(DCount)+m1*pXPrev->operator()(DCount)
171 // +dT*(n0*pXPrimeCurr->operator()(DCount)+
172 // n1*pXPrimePrev->operator()(DCount)));
173  pXCurr->IncCoef(DCount+iNumDofs,
174  pXPrimePrev->operator()(DCount)*theta*dT);
175  } else if (Order == DofOrder::ALGEBRAIC) {
176  //doublereal dXnm1 = pXPrev->operator()(DCount);
177 
178  /* tempo theta*/
179 // doublereal dXIn = dXnm1*(theta-1.)*dT;
180 // pXPrimeCurr->IncCoef(DCount+iNumDofs, dXIn);
181 // pXPrimeCurr->PutCoef(DCount+iNumDofs,
182 // m0*pXPrimeCurr->operator()(DCount)+m1*pXPrimePrev->operator()(DCount)
183 // +dT*(n0*pXCurr->operator()(DCount)+
184 // n1*pXPrev->operator()(DCount)));
185 // pXCurr->PutCoef(DCount+iNumDofs,
186 // pXPrev->operator()(DCount));
187  pXPrimeCurr->IncCoef(DCount+iNumDofs,
188  pXPrev->operator()(DCount)*theta*dT);
189  } else {
190  silent_cerr("ThirdOrderIntegrator::RealPredictDof: "
191  << "unknown order for dof "
192  << DCount<< std::endl);
194  }
195 }
196 
197 void
199 {
200  DEBUGCOUTFNAME("ThirdOrderIntegrator::Predict");
201  ASSERT(pDM != NULL);
202 
203 #ifdef USE_SCHUR
204  SchurDataManager* pSDM;
205  if ((pSDM = dynamic_cast<SchurDataManager*> (pDM)) != 0) {
206  silent_cerr("Warning: ThirdOrderIntegrator currently is "
207  << "untested with the parallel solver" << std::endl);
208  }
209 #endif // USE_SCHUR
210 
211  DataManager::DofIterator_const CurrDof = pDofs->begin();
212 
213  /*
214  * Linear combination of previous step state and derivative
215  * etc....
216  */
217  /*
218  * Predict for AfterPredict
219  */
222  pDM->AfterPredict();
223 
224  /*
225  * Vero Predict
226  */
228  return;
229 };
230 
232 {
233  DEBUGCOUTFNAME("ThirdOrderIntegrator::Residual");
234  ASSERT(pDM != NULL);
235 
236  integer iNumDofs = pDM->iGetNumDofs();
237 
238  MyVectorHandler state, stateder, res;
239 
240  /* theta*dT */
241  state.Attach(iNumDofs, pXCurr->pdGetVec()+iNumDofs);
242  stateder.Attach(iNumDofs, pXPrimeCurr->pdGetVec()+iNumDofs);
243  res.Attach(iNumDofs, pRes->pdGetVec()+iNumDofs);
244  pDM->SetTime(pDM->dGetTime() + theta*dT);
245  pDM->LinkToSolution(state, stateder);
246  pDM->Update();
247  pDM->AssRes(res, 1.);
248 
249  /* dT */
250  pDM->SetTime(pDM->dGetTime() - theta*dT);
252  pDM->Update();
253  pDM->AssRes(*pRes, 1.);
254 
255  return;
256 };
257 
259 {
260  DEBUGCOUTFNAME("ThirdOrderIntegrator::Jacobian");
261  ASSERT(pDM != NULL);
262 
263  integer iNumDofs = pDM->iGetNumDofs();
264 
265  MyVectorHandler state, stateder;
266  pJac->Reset();
267 #if 0
268  pJacxi_x->Reset();
269  pJacxi_xp->Reset();
270  pJac_x->Reset();
271  pJac_xp->Reset();
272 #endif
273  /* theta*dT */
274  state.Attach(iNumDofs, pXCurr->pdGetVec()+iNumDofs);
275  stateder.Attach(iNumDofs, pXPrimeCurr->pdGetVec()+iNumDofs);
276  pDM->SetTime(pDM->dGetTime() + theta*dT);
277  pDM->LinkToSolution(state, stateder);
278  pDM->Update();
279 #warning This trick does not work with Coulomb friction (and other elements too)
280  /*
281  The reason is that
282  a) Colomb friction residual (and other elements) can throw
283  to signal the need of a new jacobian
284  b) Have internal states that depend on the order of residual
285  calls
286  However, this is needed for all the elements (almost all)
287  that compute something during residual and use it
288  later during Jacobain computation
289  */
290  pDM->AssRes(Restmp, 1.);
291  pDM->AssJac(*pJacxi_x, 1.);
292  pDM->AssJac(*pJacxi_xp, 0.);
293 
294  /* dT */
295  pDM->SetTime(pDM->dGetTime() - theta*dT);
297  pDM->Update();
298  pDM->AssRes(Restmp, 1.);
299  pDM->AssJac(*pJac_x, 1.);
300  pDM->AssJac(*pJac_xp, 0.);
301 
302 
303  /* Attenzione: a differenza di quanto riportato a p. 16,
304  * "Unconditionally stable multistep integration of ordinary
305  * differential and differential-algebraic equations with
306  * controlled algorithmic dissipation for multibody dynamic
307  * applications"
308  * qui il tempo finale e' in cima, il tempo theta in basso
309  */
310 
311  /* 2,2 */
312  // doublereal J22_x = (1.+3.*rho)/(6.*rho*(1.+rho))*dT;
313  Jacxi_x.MulAndSumWithShift(*pJac, jx22, iNumDofs, iNumDofs);
314  Jacxi_xp.FakeThirdOrderMulAndSumWithShift(*pJac, EqIsDifferential, 1. - jx22, iNumDofs, iNumDofs);
315 
316  /* 2,1 */
317  // doublereal J21_x = -1./(6.*rho*(1.+rho)*(1.+rho))*dT;
318  Jacxi_x.MulAndSumWithShift(*pJac, jx21, iNumDofs, 0);
320 
321  /* 1,2 */
322  // doublereal J12_x = (1.+rho)*(1.+rho)/(6.*rho)*dT;
323  Jac_x.MulAndSumWithShift(*pJac, jx12, 0, iNumDofs);
325 
326  /* 1,1 */
327  // doublereal J11_x = (2.*rho-1.)/(6.*rho)*dT;
328  Jac_x.MulAndSumWithShift(*pJac, jx11, 0, 0);
330 
331  return;
332 };
333 
334 void ThirdOrderIntegrator::UpdateDof(const int DCount,
335  const DofOrder::Order Order,
336  const VectorHandler* const pSol) const {
337  integer iNumDofs = pDM->iGetNumDofs();
338  doublereal dxp = pSol->operator()(DCount);
339  doublereal dxp_xi = pSol->operator()(DCount+iNumDofs);
340  if (Order == DofOrder::DIFFERENTIAL) {
341 
342  pXPrimeCurr->IncCoef(DCount, dxp);
343  pXPrimeCurr->IncCoef(DCount+iNumDofs, dxp_xi);
344 
345  pXCurr->IncCoef(DCount, dT*(w1*dxp_xi+w0*dxp));
346  pXCurr->IncCoef(DCount+iNumDofs,
347  dT*(m0*w1*dxp_xi+(m0*w0+n0)*dxp));
348 
349  } else if (Order == DofOrder::ALGEBRAIC) {
350  pXCurr->IncCoef(DCount, dxp);
351  pXCurr->IncCoef(DCount+iNumDofs, dxp_xi);
352 
353  pXPrimeCurr->IncCoef(DCount, dT*(w1*dxp_xi+w0*dxp));
354  pXPrimeCurr->IncCoef(DCount+iNumDofs,
355  dT*(m0*w1*dxp_xi+(m0*w0+n0)*dxp));
356  } else {
357  silent_cerr("unknown order for dof "
358  << DCount<< std::endl);
360  }
361 };
362 
363 void
365 {
366  DEBUGCOUTFNAME("ThirdOrderIntegrator::Predict");
367  ASSERT(pDM != NULL);
368 
369 #ifdef USE_SCHUR
370  SchurDataManager* pSDM;
371  if ((pSDM = dynamic_cast<SchurDataManager*> (pDM)) != 0) {
372  silent_cerr("Warning: ThirdOrderIntegrator is untested "
373  << "with the parallel solver" << std::endl);
374  }
375 #endif // USE_SCHUR
376 
378  pDM->Update();
379  return;
380 };
381 
382 // /* scale factor for tests */
383 // doublereal
384 // ThirdOrderIntegrator::TestScale(const NonlinearSolverTest *pResTest) const
385 // {
386 // #ifdef __HACK_RES_TEST__
387 //
388 // #ifdef USE_MPI
389 // #warning "StepNIntegrator TestScale parallel broken !! "
390 // #endif /* USE_MPI */
391 //
392 // Dof CurrDof;
393 // doublereal dXPr = 0.;
394 //
395 // DofIterator.bGetFirst(CurrDof);
396 //
397 // for (int iCntp1 = 1; iCntp1 <= pXPrimeCurr->iGetSize();
398 // iCntp1++, DofIterator.bGetNext(CurrDof)) {
399 //
400 // if (CurrDof.Order == DofOrder::DIFFERENTIAL) {
401 // doublereal d = pXPrimeCurr->operator()(iCntp1);
402 // doublereal d2 = d*d;
403 //
404 // doublereal ds = pResTest->dScaleCoef(iCntp1);
405 // doublereal ds2 = ds*ds;
406 // d2 *= ds2;
407 //
408 // dXPr += d2;
409 // }
410 // /* else if ALGEBRAIC: non aggiunge nulla */
411 // }
412 //
413 // return 1./(1.+dXPr);
414 //
415 // #else /* ! __HACK_RES_TEST__ */
416 // return 1.;
417 // #endif /* ! __HACK_RES_TEST__ */
418 // }
419 
420 
422  const doublereal dSolutionTol,
423  const integer iMaxIt,
424  const DriveCaller* pRho,
425  const bool bmod_res_test)
426 : ThirdOrderIntegrator(dT, dSolutionTol, iMaxIt, bmod_res_test),
427 Rho(pRho)
428 {
429  NO_OP;
430 }
431 
433 {
434  NO_OP;
435 }
436 
437 void
439  doublereal dAlpha,
440  enum StepChange /* NewStep */)
441 {
442  dT = dt;
443 
444  /* from "Unconditionally stable multistep integration of ordinary
445  * differential and differential-algebraic equations with
446  * controlled algorithmic dissipation for multibody dynamic
447  * applications", pp 8-9
448  */
449  rho = Rho.dGet();
450  theta = -rho/(1.+rho);
451  w0 = (1.+3*theta)/(6.*theta);
452  w1 = -1./(6.*theta*(1.+theta));
453  w2 = (2.+3.*theta)/(6.*(1.+theta));
454  /* from "Unconditionally stable multistep integration of ordinary
455  * differential and differential-algebraic equations with
456  * controlled algorithmic dissipation for multibody dynamic
457  * applications", pp 3
458  */
459  m0 = 1.-theta*theta*(3.+2.*theta);
460  m1 = theta*theta*(3.+2.*theta);
461  n0 = theta*(1.+theta)*(1.+theta);
462  n1 = theta*theta*(1.+theta);
463 
464  /* Attenzione: a differenza di quanto riportato a p. 16,
465  * "Unconditionally stable multistep integration of ordinary
466  * differential and differential-algebraic equations with
467  * controlled algorithmic dissipation for multibody dynamic
468  * applications"
469  * qui il tempo finale e' in cima, il tempo theta in basso
470  */
471  jx22 = (1.+3.*rho)/(6.*rho*(1.+rho))*dT;
472  jx21 = -1./(6.*rho*std::pow(1.+rho,2.))*dT;
473  jx12 = std::pow(1.+rho,2.)/(6.*rho)*dT;
474  jx11 = (2.*rho-1.)/(6.*rho)*dT;
475 
476  DEBUGCOUT("Tunable Third Order Integrator coefficients:" << std::endl
477  << "\t rho: " << rho << std::endl
478  << "\ttheta: " << theta << std::endl
479  << "\t w0: " << w0 << std::endl
480  << "\t w1: " << w1 << std::endl
481  << "\t w2: " << w2 << std::endl
482  << "\t m0: " << m0 << std::endl
483  << "\t m1: " << m1 << std::endl
484  << "\t n0: " << n0 << std::endl
485  << "\t n1: " << n1 << std::endl);
486 }
487 
488 void
490 {
491  Rho.pGetDriveCaller()->SetDrvHdl(pDH);
492 }
493 
495  const doublereal dSolutionTol,
496  const integer iMaxIt,
497  const bool bmod_res_test)
498 : ThirdOrderIntegrator(dT, dSolutionTol, iMaxIt, bmod_res_test)
499 {
500  NO_OP;
501 }
502 
504 {
505  NO_OP;
506 }
507 
508 void
510  doublereal dAlpha,
511  enum StepChange /* NewStep */)
512 {
513  dT = dt;
514 
515  /* from "Unconditionally stable multistep integration of ordinary
516  * differential and differential-algebraic equations with
517  * controlled algorithmic dissipation for multibody dynamic
518  * applications", pp 8-9
519  */
520  theta = -2./3.;
521  w0 = (2.*theta + 1.)/(2.*theta);
522  w1 = -1./(2.*theta);
523  w2 = 0.;
524  /* from "Unconditionally stable multistep integration of ordinary
525  * differential and differential-algebraic equations with
526  * controlled algorithmic dissipation for multibody dynamic
527  * applications", pp 3
528  */
529  m0 = 1.-theta*theta;
530  m1 = theta*theta;
531  n0 = theta*(1.+theta);
532  n1 = 0.;
533 
534  /* Attenzione: a differenza di quanto riportato a p. 16,
535  * "Unconditionally stable multistep integration of ordinary
536  * differential and differential-algebraic equations with
537  * controlled algorithmic dissipation for multibody dynamic
538  * applications"
539  * qui il tempo finale e' in cima, il tempo theta in basso
540  */
541  jx22 = 5./12.*dT;
542  jx21 = -1./12.*dT;
543  jx12 = 3./4.*dT;
544  jx11 = 1./4.*dT;
545 
546  DEBUGCOUT("Ad Hoc Third Order Integrator coefficients:" << std::endl
547  << "\t rho: " << rho << std::endl
548  << "\ttheta: " << theta << std::endl
549  << "\t w0: " << w0 << std::endl
550  << "\t w1: " << w1 << std::endl
551  << "\t w2: " << w2 << std::endl
552  << "\t m0: " << m0 << std::endl
553  << "\t m1: " << m1 << std::endl
554  << "\t n0: " << n0 << std::endl
555  << "\t n1: " << n1 << std::endl);
556 }
557 
VectorHandler * pXPrimePrev
AdHocThirdOrderIntegrator(const doublereal dT, const doublereal dSolutionTol, const integer iMaxIt, const bool bmod_res_test)
VectorHandler * pXPrev
MyVectorHandler Restmp
std::vector< bool > EqIsAlgebraic
void SetCoef(doublereal dT, doublereal dAlpha, enum StepChange NewStep)
GradientExpression< BinaryExpr< FuncPow, LhsExpr, RhsExpr > > pow(const GradientExpression< LhsExpr > &u, const GradientExpression< RhsExpr > &v)
Definition: gradient.h:2961
#define MBDYN_EXCEPT_ARGS
Definition: except.h:63
#define DEBUGCOUTFNAME(fname)
Definition: myassert.h:256
virtual doublereal * pdGetVec(void) const =0
void PredictDof_for_AfterPredict(const int DCount, const DofOrder::Order Order, const VectorHandler *const pSol=0) const
void UpdateDof(const int DCount, const DofOrder::Order Order, const VectorHandler *const pSol=0) const
virtual void Jacobian(MatrixHandler *pJac) const
void SetDriveHandler(const DriveHandler *pDH)
SpMapMatrixHandler Jacxi_x
doublereal dGetTime(void) const
Definition: dataman2.cc:165
SpMapMatrixHandler Jac_x
virtual void IncCoef(integer iRow, const doublereal &dCoef)=0
doublereal dSolTol
Definition: stepsol.h:99
MatrixHandler * pJac_x
MatrixHandler * pJac_xp
virtual void AssRes(VectorHandler &ResHdl, doublereal dCoef)
Definition: elman.cc:498
#define NO_OP
Definition: myassert.h:74
virtual void Resize(integer iSize)
Definition: vh.cc:347
virtual void Reset(void)=0
virtual void Update(const VectorHandler *pSol) const
virtual void AfterPredict(void) const
Definition: dataman2.cc:2472
void LinkToSolution(VectorHandler &XCurr, VectorHandler &XPrimeCurr)
Definition: dataman2.cc:172
virtual ~AdHocThirdOrderIntegrator(void)
virtual void SetDrvHdl(const DriveHandler *pDH)
Definition: drive.cc:487
const DataManager::DofVecType * pDofs
Definition: stepsol.h:94
std::vector< bool > EqIsDifferential
MatrixHandler & MulAndSumWithShift(MatrixHandler &out, doublereal s=1., integer drow=0, integer dcol=0) const
Definition: spmapmh.cc:269
DataManager * pDM
Definition: stepsol.h:93
virtual void Predict(void)
void Resize(integer ir, integer ic)
Definition: spmapmh.cc:174
MatrixHandler * pJacxi_xp
MatrixHandler * pJacxi_x
virtual NonlinearSolver * pGetNonlinearSolver(void) const
Definition: solver.h:404
VectorHandler * pXPrimeCurr
Definition: stepsol.h:164
#define DEBUGCOUT(msg)
Definition: myassert.h:232
VectorHandler * pXCurr
Definition: stepsol.h:163
integer MaxIters
Definition: stepsol.h:98
Definition: mbdyn.h:77
virtual void AssJac(MatrixHandler &JacHdl, doublereal dCoef)
Definition: elman.cc:392
void SetCoef(doublereal dT, doublereal dAlpha, enum StepChange NewStep)
DofVecType::const_iterator DofIterator_const
Definition: dataman.h:802
#define ASSERT(expression)
Definition: colamd.c:977
MatrixHandler & FakeThirdOrderMulAndSumWithShift(MatrixHandler &out, std::vector< bool > b, doublereal s=1., integer drow=0, integer dcol=0) const
Definition: spmapmh.cc:296
virtual ~ThirdOrderIntegrator(void)
Order
Definition: shapefnc.h:42
virtual void PutCoef(integer iRow, const doublereal &dCoef)=0
DriveCaller * pGetDriveCaller(void) const
Definition: drive.cc:658
void SetTime(const doublereal &dTime, const doublereal &dTimeStep=-1., const integer &iStep=-1, bool bServePending=true)
Definition: dataman2.cc:139
Definition: solver.h:78
virtual void Residual(VectorHandler *pRes) const
ThirdOrderIntegrator(const doublereal dT, const doublereal dSolutionTol, const integer iMaxIt, const bool bmod_res_test)
virtual void SetCoef(doublereal dT, doublereal dAlpha, enum StepChange NewStep)=0
void RealPredictDof(const int DCount, const DofOrder::Order Order, const VectorHandler *const pSol=0) const
doublereal dGet(const doublereal &dVar) const
Definition: drive.cc:664
SpMapMatrixHandler Jacxi_xp
virtual void Update(void) const
Definition: dataman2.cc:2511
void Attach(integer iSize, doublereal *pd, integer iMSize=0)
Definition: vh.cc:418
void UpdateLoop(const T *const t, void(T::*pUpd)(const int DCount, const DofOrder::Order Order, const VectorHandler *const pSol) const, const VectorHandler *const pSol=0) const
virtual doublereal Advance(Solver *pS, const doublereal TStep, const doublereal dAlph, const StepChange StType, std::deque< MyVectorHandler * > &qX, std::deque< MyVectorHandler * > &qXPrime, MyVectorHandler *const pX, MyVectorHandler *const pXPrime, integer &EffIter, doublereal &Err, doublereal &SolErr)
virtual ~TunableThirdOrderIntegrator(void)
virtual void Solve(const NonlinearProblem *pNLP, Solver *pS, const integer iMaxIter, const doublereal &Tol, integer &iIterCnt, doublereal &dErr, const doublereal &SolTol, doublereal &dSolErr)=0
double doublereal
Definition: colamd.c:52
long int integer
Definition: colamd.c:51
doublereal dTol
Definition: stepsol.h:99
integer iGetNumDofs(void) const
Definition: dataman.h:809
SpMapMatrixHandler Jac_xp
TunableThirdOrderIntegrator(const doublereal dT, const doublereal dSolutionTol, const integer iMaxIt, const DriveCaller *pRho, const bool bmod_res_test)