70{
71 try {
72
73
74
75 H3D_ID elem_id ;
76 H3D_ID RigidElem ;
77 int i,j,nsn;
78
79 char RBE3POOL[] = "Rbe3";
82
83 char RIGIDPOOL[] = "Rigid";
86
87 unsigned int elem_count = 1;
88 unsigned int *conn;
89 double *coef;
90 int *dof;
91
92 if(*COMPID_RBE3S != 0 && *NRBE3 != 0)
93 {
95 H3D_ELEM_CONFIG_RIGIDLINK, *COMPID_RBE3S,
97 for(i=0;i<*NRBE3;i++)
98 {
99 elem_id = IRBE3[*NRBE3L * i + 1];
100 nsn = IRBE3[*NRBE3L * i + 4];
102
103 conn =(unsigned int *)malloc(nsn*sizeof(unsigned int));
104 coef =(double *)malloc(nsn*sizeof(double));
105 dof =(int *)malloc(nsn*sizeof(int));
106
107 for(j=0;j<nsn;j++) conn[j] = ITAB[LRBE3[IRBE3[*NRBE3L * i ] + j ] - 1 ];
108
109 RigidElem = IRBE3[*NRBE3L * i + 1] ;
110
111 unsigned int conn1[1];
112 double coef1[1] = {1.0};
113 int dof1[1] = {6};
114 conn1[0] = ITAB[IRBE3[*NRBE3L * i + 2]-1];
115
119
120 free(conn);
121 free(coef);
122 free(dof);
123
124 }
127 }
128 else
129 {
130 for(i=0;i<*NRBE3;i++)
131 {
132 elem_id = IRBE3[*NRBE3L * i + 1];
133 nsn = IRBE3[*NRBE3L * i + 4];
135
136 conn =(unsigned int *)malloc(nsn*sizeof(unsigned int));
137 coef =(double *)malloc(nsn*sizeof(double));
138 dof =(int *)malloc(nsn*sizeof(int));
139
140 for(j=0;j<nsn;j++) conn[j] = ITAB[LRBE3[IRBE3[*NRBE3L * i ] + j ] - 1 ];
141
142 RigidElem = IRBE3[*NRBE3L * i + 1] ;
143
144 unsigned int conn1[1];
145 double coef1[1] = {1.0};
146 int dof1[1] = {6};
147 conn1[0] = ITAB[IRBE3[*NRBE3L * i + 2]-1];
148
149
151 H3D_ELEM_CONFIG_RIGIDLINK, RigidElem,
158
159 free(conn);
160 free(coef);
161 free(dof);
162 }
163 }
164
165
166 }
167
168 catch(...) {
170 }
171
172}
bool Hyper3DElement2Write(H3DFileInfo *h3d_file, H3D_ID id, unsigned int *inode, int *idof, double *icoeff, unsigned int num_inodes, unsigned int *dnode, int *ddof, double *dcoeff, unsigned int num_dnodes)
bool Hyper3DAddString(H3DFileInfo *h3d_file, const char *const string, H3D_ID *const str_id)
bool Hyper3DExportClearError(H3DFileInfo *h3d_file)
bool Hyper3DElement2End(H3DFileInfo *h3d_file)
bool Hyper3DElement2Begin(H3DFileInfo *h3d_file, unsigned int count, H3D_ID poolname_id, H3D_ElementConfig config, H3D_ID parent_id, H3D_ID parent_poolname_id, H3D_ID node_poolname_id)