| 421 | |
| 422 | |
| 423 | int HHTExplicit_TP::update(const Vector &aiPlusOne) |
| 424 | { |
| 425 | updateCount++; |
| 426 | if (updateCount > 1) { |
| 427 | opserr << "WARNING HHTExplicit_TP::update() - called more than once -"; |
| 428 | opserr << " HHTExplicit_TP integration scheme requires a LINEAR solution algorithm\n"; |
| 429 | return -1; |
| 430 | } |
| 431 | |
| 432 | AnalysisModel *theModel = this->getAnalysisModel(); |
| 433 | if (theModel == 0) { |
| 434 | opserr << "WARNING HHTExplicit_TP::update() - no AnalysisModel set\n"; |
| 435 | return -2; |
| 436 | } |
| 437 | |
| 438 | // check domainChanged() has been called, i.e. Ut will not be zero |
| 439 | if (Ut == 0) { |
| 440 | opserr << "WARNING HHTExplicit_TP::update() - domainChange() failed or not called\n"; |
| 441 | return -3; |
| 442 | } |
| 443 | |
| 444 | // check aiPlusOne is of correct size |
| 445 | if (aiPlusOne.Size() != U->Size()) { |
| 446 | opserr << "WARNING HHTExplicit_TP::update() - Vectors of incompatible size "; |
| 447 | opserr << " expecting " << U->Size() << " obtained " << aiPlusOne.Size() << endln; |
| 448 | return -4; |
| 449 | } |
| 450 | |
| 451 | // determine the response at t+deltaT |
| 452 | Udot->addVector(1.0, aiPlusOne, c2); |
| 453 | |
| 454 | Udotdot->addVector(0.0, aiPlusOne, c3); |
| 455 | |
| 456 | // update the response at the DOFs |
| 457 | theModel->setVel(*Udot); |
| 458 | theModel->setAccel(*Udotdot); |
| 459 | if (theModel->updateDomain() < 0) { |
| 460 | opserr << "HHTExplicit_TP::update() - failed to update the domain\n"; |
| 461 | return -5; |
| 462 | } |
| 463 | |
| 464 | return 0; |
| 465 | } |
| 466 | |
| 467 | |
| 468 | int HHTExplicit_TP::commit(void) |
nothing calls this directly
no test coverage detected