| 1728 | |
| 1729 | |
| 1730 | void |
| 1731 | Node::Print(OPS_Stream &s, int flag) |
| 1732 | { |
| 1733 | if (flag == OPS_PRINT_CURRENTSTATE) { // print out everything |
| 1734 | s << "\n Node: " << this->getTag() << endln; |
| 1735 | s << "\tCoordinates : " << *Crd; |
| 1736 | if (commitDisp != 0) |
| 1737 | s << "\tDisps: " << *trialDisp; |
| 1738 | if (commitVel != 0) |
| 1739 | s << "\tVelocities : " << *trialVel; |
| 1740 | if (commitAccel != 0) |
| 1741 | s << "\tcommitAccels: " << *trialAccel; |
| 1742 | if (unbalLoad != 0) |
| 1743 | s << "\t unbalanced Load: " << *unbalLoad; |
| 1744 | if (reaction != 0) |
| 1745 | s << "\t reaction: " << *reaction; |
| 1746 | if (mass != 0) { |
| 1747 | s << "\tMass : " << *mass; |
| 1748 | s << "\t Rayleigh Factor: alphaM: " << alphaM << endln; |
| 1749 | s << "\t Rayleigh Forces: " << *this->getResponse(RayleighForces); |
| 1750 | } |
| 1751 | if (theEigenvectors != 0) |
| 1752 | s << "\t Eigenvectors: " << *theEigenvectors; |
| 1753 | if (theDOF_GroupPtr != 0) |
| 1754 | s << "\tID : " << theDOF_GroupPtr->getID(); |
| 1755 | s << "\n"; |
| 1756 | } |
| 1757 | |
| 1758 | else if (flag == 1) { // print out: nodeId displacements |
| 1759 | s << this->getTag() << " " << *commitDisp; |
| 1760 | } |
| 1761 | |
| 1762 | if (flag == OPS_PRINT_PRINTMODEL_JSON) { |
| 1763 | s << "\t\t\t{"; |
| 1764 | s << "\"name\": " << this->getTag() << ", "; |
| 1765 | s << "\"ndf\": " << numberDOF << ", "; |
| 1766 | s << "\"crd\": ["; |
| 1767 | int numCrd = Crd->Size(); |
| 1768 | for (int i = 0; i < numCrd - 1; i++) |
| 1769 | s << (*Crd)(i) << ", "; |
| 1770 | s << (*Crd)(numCrd - 1) << "]"; |
| 1771 | if (mass != 0) { |
| 1772 | s << ", \"mass\": ["; |
| 1773 | for (int i = 0; i < numberDOF - 1; i++) |
| 1774 | s << (*mass)(i, i) << ", "; |
| 1775 | s << (*mass)(numberDOF - 1, numberDOF - 1) << "]"; |
| 1776 | } |
| 1777 | s << "}"; |
| 1778 | } |
| 1779 | } |
| 1780 | |
| 1781 | int |
| 1782 | Node::displaySelf(Renderer &theRenderer, int theEleMode, int theNodeMode, float fact) |
nothing calls this directly
no test coverage detected