MCPcopy Create free account
hub / github.com/OpenSees/OpenSees / update

Method update

SRC/element/generic/GenericClient.cpp:434–469  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

432
433
434int GenericClient::update()
435{
436 int rValue = 0;
437
438 if (theChannel == 0) {
439 if (this->setupConnection() != 0) {
440 opserr << "GenericClient::update() - "
441 << "failed to setup connection\n";
442 return -1;
443 }
444 }
445
446 // get current time
447 Domain *theDomain = this->getDomain();
448 (*t)(0) = theDomain->getCurrentTime();
449
450 // assemble response vectors
451 int ndim = 0, i;
452 db->Zero(); vb->Zero(); ab->Zero();
453
454 for (i=0; i<numExternalNodes; i++) {
455 Vector disp = theNodes[i]->getTrialDisp();
456 Vector vel = theNodes[i]->getTrialVel();
457 Vector accel = theNodes[i]->getTrialAccel();
458 db->Assemble(disp(theDOF[i]), ndim);
459 vb->Assemble(vel(theDOF[i]), ndim);
460 ab->Assemble(accel(theDOF[i]), ndim);
461 ndim += theDOF[i].Size();
462 }
463
464 // set trial response at remote element
465 sData[0] = RemoteTest_setTrialResponse;
466 rValue += theChannel->sendVector(0, 0, *sendData, 0);
467
468 return rValue;
469}
470
471
472const Matrix& GenericClient::getTangentStiff()

Callers

nothing calls this directly

Calls 7

setupConnectionMethod · 0.95
getDomainMethod · 0.45
getCurrentTimeMethod · 0.45
ZeroMethod · 0.45
AssembleMethod · 0.45
SizeMethod · 0.45
sendVectorMethod · 0.45

Tested by

no test coverage detected