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

Method pointlist

SRC/element/PFEMElement/ParticleGroup.cpp:442–466  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

440}
441
442int ParticleGroup::pointlist(VDouble &pointdata) {
443 int ndm = OPS_GetNDM();
444 pointdata.clear();
445 pointdata.reserve(particles.size() * (3 * ndm + 1));
446 for (auto particle : particles) {
447 auto tag = particle->getTag();
448 const auto& crds = particle->getCrds();
449 const auto& vel = particle->getVel();
450 const auto& accel = particle->getAccel();
451 double p = particle->getPressure();
452 pointdata.push_back(tag);
453 for (int j = 0; j < ndm; ++j) {
454 pointdata.push_back(crds[j]);
455 }
456 for (int j = 0; j < ndm; ++j) {
457 pointdata.push_back(vel[j]);
458 }
459 for (int j = 0; j < ndm; ++j) {
460 pointdata.push_back(accel[j]);
461 }
462 pointdata.push_back(p);
463 }
464
465 return 0;
466}
467
468int ParticleGroup::pointlist(const VDouble &pointdata, int ndm) {
469 VDouble crds(ndm);

Callers 1

OPS_ParticleGroupFunction · 0.80

Calls 10

addParticleMethod · 0.95
getCrdsMethod · 0.80
push_backMethod · 0.80
OPS_GetNDMFunction · 0.70
clearMethod · 0.45
sizeMethod · 0.45
getTagMethod · 0.45
getVelMethod · 0.45
getAccelMethod · 0.45
getPressureMethod · 0.45

Tested by

no test coverage detected