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

Method setDomain

DEVELOPER/core/Pressure_Constraint.cpp:86–120  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

84}
85
86void
87Pressure_Constraint::setDomain(Domain* theDomain)
88{
89 freesurf = false;
90 // set new domain
91 DomainComponent::setDomain(theDomain);
92
93 // check domain
94 if(theDomain == 0) return;
95
96 // check the node
97 int nodeId = this->getTag();
98 Node* theNode = theDomain->getNode(nodeId);
99 if(theNode == 0) {
100 opserr<<"WARNING: node "<<nodeId<<" does not exist ";
101 opserr<<"-- Pressure_Constraint::setDomain\n";
102 return;
103 }
104
105 // check pval
106 if (pval != 0) return;
107
108 if (pTag == nodeId) {
109 opserr << "WARNING: pressure node has the same tag as the PC\n";
110 return;
111 }
112
113 // check the pressure node
114 Node* pNode = theDomain->getNode(pTag);
115 if(pNode == 0) {
116 opserr<<"WARNING: pressure node "<<pTag<<" does not exist ";
117 opserr<<"-- Pressure_Constraint::setDomain\n";
118 return;
119 }
120}
121
122Node*
123Pressure_Constraint::getPressureNode()

Callers

nothing calls this directly

Calls 2

getTagMethod · 0.45
getNodeMethod · 0.45

Tested by

no test coverage detected