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

Function OPS_CircPatch

SRC/material/section/repres/patch/CircPatch.cpp:38–66  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36#include <elementAPI.h>
37
38void* OPS_CircPatch()
39{
40 if(OPS_GetNumRemainingInputArgs() < 7) {
41 opserr<<"insufficient arguments for CircPatch\n";
42 return 0;
43 }
44
45 // get idata
46 int numData = 3;
47 int idata[3];
48 if(OPS_GetIntInput(&numData,&idata[0]) < 0) return 0;
49
50 // get data
51 double data[6] = {0,0,0,0,0,0};
52 numData = OPS_GetNumRemainingInputArgs();
53 static Vector centerPos(2);
54 /*centerPos(0) = data[0];
55 centerPos(1) = data[1];*/
56 if(OPS_GetDoubleInput(&numData,&data[0]) < 0) return 0;
57 centerPos(0) = data[0];
58 centerPos(1) = data[1];
59
60 if (numData < 6)
61 return new CircPatch(idata[0],idata[1],idata[2],centerPos,
62 data[2],data[3]);
63 else
64 return new CircPatch(idata[0],idata[1],idata[2],centerPos,
65 data[2],data[3],data[4],data[5]);
66}
67
68
69CircPatch::CircPatch(): matID(0), nDivCirc(1), nDivRad(1), centerPosit(2),

Callers 2

OPS_PatchFunction · 0.85
ops_addPatchFunction · 0.85

Calls 3

OPS_GetIntInputFunction · 0.50
OPS_GetDoubleInputFunction · 0.50

Tested by

no test coverage detected