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

Function OPS_LinearCrdTransf3d

SRC/coordTransformation/LinearCrdTransf3d.cpp:50–80  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

48Matrix LinearCrdTransf3d::kg(12,12);
49
50void* OPS_LinearCrdTransf3d()
51{
52 if(OPS_GetNumRemainingInputArgs() < 4) {
53 opserr<<"insufficient arguments for LinearCrdTransf3d\n";
54 return 0;
55 }
56
57 // get tag
58 int tag;
59 int numData = 1;
60 if(OPS_GetIntInput(&numData,&tag) < 0) return 0;
61
62 // get vector
63 Vector vec(3);
64 double* vptr = &vec(0);
65 numData = 3;
66 if(OPS_GetDoubleInput(&numData,vptr) < 0) return 0;
67
68 // get option
69 Vector jntOffsetI(3), jntOffsetJ(3);
70 double *iptr=&jntOffsetI(0), *jptr=&jntOffsetJ(0);
71 while(OPS_GetNumRemainingInputArgs() > 6) {
72 std::string type = OPS_GetString();
73 if(type == "-jntOffset") {
74 if(OPS_GetDoubleInput(&numData,iptr) < 0) return 0;
75 if(OPS_GetDoubleInput(&numData,jptr) < 0) return 0;
76 }
77 }
78
79 return new LinearCrdTransf3d(tag,vec,jntOffsetI,jntOffsetJ);
80}
81
82
83// constructor:

Callers 1

OPS_LinearCrdTransfFunction · 0.85

Calls 4

OPS_GetIntInputFunction · 0.50
OPS_GetDoubleInputFunction · 0.50
OPS_GetStringFunction · 0.50

Tested by

no test coverage detected