60RerShell :: RerShell(
int n,
Domain *aDomain) :
92 double x1, x2, x3, y1, y2, y3,
area;
95 x1 = nodeCoords.
at(1);
96 y1 = nodeCoords.
at(2);
99 x2 = nodeCoords.
at(1);
100 y2 = nodeCoords.
at(2);
103 x3 = nodeCoords.
at(1);
104 y3 = nodeCoords.
at(2);
120 for (
int i = 1; i <= 3; i++ ) {
121 int j = i + 1 - i / 3 * 3;
122 int k = j + 1 - j / 3 * 3;
124 int ii = 6 * ( i - 1 );
125 int ki = 6 * ( k - 1 );
127 answer.
at(1, ii + 1) = b.at(i);
128 answer.
at(1, ki + 4) = -( b.at(i) - b.at(j) ) /
Rx *
area / 12.;
129 answer.
at(1, ki + 5) = -( c.at(i) - c.at(j) ) /
Ry *
area / 12.;
131 answer.
at(2, ii + 2) = c.at(i);
132 answer.
at(2, ki + 4) = -( b.at(i) - b.at(j) ) /
Ry *
area / 12.;
133 answer.
at(2, ki + 5) = -( c.at(i) - c.at(j) ) /
Ry *
area / 12.;
135 answer.
at(3, ii + 1) = c.at(i);
136 answer.
at(3, ii + 2) = b.at(i);
137 answer.
at(3, ki + 4) = -( b.at(i) - b.at(j) ) /
Rxy *
area / 6.;
138 answer.
at(3, ki + 5) = -( c.at(i) - c.at(j) ) /
Rxy *
area / 6.;
140 answer.
at(4, ii + 5) = b.at(i);
142 answer.
at(5, ii + 4) = -c.at(i);
144 answer.
at(6, ii + 4) = -b.at(i);
145 answer.
at(6, ii + 5) = c.at(i);
147 answer.
at(7, ii + 3) = b.at(i);
148 answer.
at(7, ii + 5) +=
area * ( 2. / 3. );
149 answer.
at(7, ki + 5) += ( -2.0 *
area + b.at(k) * ( c.at(i) - c.at(j) ) ) / 6.0;
150 answer.
at(7, ki + 4) = b.at(k) * ( b.at(i) - b.at(j) ) / 6.0;
152 answer.
at(8, ii + 3) = c.at(i);
153 answer.
at(8, ii + 4) +=
area * ( -2.0 / 3.0 );
154 answer.
at(8, ki + 4) += ( +2.0 *
area + c.at(k) * ( b.at(i) - b.at(j) ) ) / 6.0;
155 answer.
at(8, ki + 5) = c.at(k) * ( c.at(i) - c.at(j) ) / 6.0;
163RerShell :: computeGaussPoints()
179 double x1, x2, x3, y1, y2, y3, l1, l2, l3, b1, b2, b3, c1, c2, c3;
182 l1 = iLocCoord.
at(1);
183 l2 = iLocCoord.
at(2);
187 x1 = nodeCoords.
at(1);
188 y1 = nodeCoords.
at(2);
191 x2 = nodeCoords.
at(1);
192 y2 = nodeCoords.
at(2);
195 x3 = nodeCoords.
at(1);
196 y3 = nodeCoords.
at(2);
219 answer.
at(1, 1) = l1;
220 answer.
at(1, 7) = l2;
221 answer.
at(1, 13) = l3;
223 answer.
at(2, 2) = l1;
224 answer.
at(2, 8) = l2;
225 answer.
at(2, 14) = l3;
227 answer.
at(3, 3) = l1;
228 answer.
at(3, 4) = -( l1 * l2 * b3 - l1 * l3 * b2 ) * 0.5;
229 answer.
at(3, 5) = -( l1 * l2 * c3 - l1 * l3 * c2 ) * 0.5;
230 answer.
at(3, 9) = l2;
231 answer.
at(3, 10) = -( l2 * l3 * b1 - l1 * l2 * b3 ) * 0.5;
232 answer.
at(3, 11) = -( l2 * l3 * c1 - l1 * l2 * c3 ) * 0.5;
233 answer.
at(3, 15) = l3;
234 answer.
at(3, 16) = -( l3 * l1 * b2 - l2 * l3 * b1 ) * 0.5;
235 answer.
at(3, 17) = -( l3 * l1 * c2 - l2 * l3 * c1 ) * 0.5;
237 answer.
at(4, 4) = l1;
238 answer.
at(4, 10) = l2;
239 answer.
at(4, 16) = l3;
241 answer.
at(5, 5) = l1;
242 answer.
at(5, 11) = l2;
243 answer.
at(5, 17) = l3;
248RerShell :: giveArea()
256 double x1, x2, x3, y1, y2, y3;
259 x1 = nodeCoords.
at(1);
260 y1 = nodeCoords.
at(2);
263 x2 = nodeCoords.
at(1);
264 y2 = nodeCoords.
at(2);
267 x3 = nodeCoords.
at(1);
268 y3 = nodeCoords.
at(2);
270 return (
area = 0.5 * ( x2 * y3 + x1 * y2 + y1 * x3 - x2 * y1 - x3 * y2 - x1 * y3 ) );
277 StructuralElement :: initializeFrom(ir, priority);
308 answer.
at(1, 1) = mss1;
309 answer.
at(2, 2) = mss1;
310 answer.
at(3, 3) = mss1;
312 answer.
at(7, 7) = mss1;
313 answer.
at(8, 8) = mss1;
314 answer.
at(9, 9) = mss1;
316 answer.
at(13, 13) = mss1;
317 answer.
at(14, 14) = mss1;
318 answer.
at(15, 15) = mss1;
327 double dens, dV, load;
344 load = f.
at(1) * dens * dV / 3.0;
347 answer.
at(13) = load;
349 load = f.
at(2) * dens * dV / 3.0;
352 answer.
at(14) = load;
354 load = f.
at(3) * dens * dV / 3.0;
357 answer.
at(15) = load;
383#define POINT_TOL 1.e-3
397 double x1, x2, x3, y1, y2, y3, z1, z2, z3;
400 x1 = nodeCoords.
at(1);
401 y1 = nodeCoords.
at(2);
402 z1 = nodeCoords.
at(3);
405 x2 = nodeCoords.
at(1);
406 y2 = nodeCoords.
at(2);
407 z2 = nodeCoords.
at(3);
410 x3 = nodeCoords.
at(1);
411 y3 = nodeCoords.
at(2);
412 z3 = nodeCoords.
at(3);
416 area = 0.5 * ( x2 * y3 + x1 * y2 + y1 * x3 - x2 * y1 - x3 * y2 - x1 * y3 );
418 answer.
at(1) = ( ( x2 * y3 - x3 * y2 ) + ( y2 - y3 ) * inputCoords_ElCS.
at(1) + ( x3 - x2 ) * inputCoords_ElCS.
at(2) ) / 2. /
area;
419 answer.
at(2) = ( ( x3 * y1 - x1 * y3 ) + ( y3 - y1 ) * inputCoords_ElCS.
at(1) + ( x1 - x3 ) * inputCoords_ElCS.
at(2) ) / 2. /
area;
420 answer.
at(3) = ( ( x1 * y2 - x2 * y1 ) + ( y1 - y2 ) * inputCoords_ElCS.
at(1) + ( x2 - x1 ) * inputCoords_ElCS.
at(2) ) / 2. /
area;
424 midplZ = z1 * answer.
at(1) + z2 *answer.
at(2) + z3 *answer.
at(3);
428 GaussPoint _gp(NULL, 1, answer, 1.0, _2dPlate);
434 if ( elthick / 2.0 + midplZ - fabs( inputCoords_ElCS.
at(3) ) < -
POINT_TOL ) {
440 for (
int i = 1; i <= 3; i++ ) {
474 for (
int i = 1; i <= 3; i++ ) {
475 for (
int j = 1; j <= 3; j++ ) {
477 answer.
at(i, j) = val;
478 answer.
at(i + 3, j + 3) = val;
479 answer.
at(i + 6, j + 6) = val;
480 answer.
at(i + 9, j + 9) = val;
481 answer.
at(i + 12, j + 12) = val;
482 answer.
at(i + 15, j + 15) = val;
494 OOFEM_ERROR(
"cannot transform coordinates- size mismatch");
518 answer.
at(1, 1) = stress.
at(1);
519 answer.
at(2, 2) = stress.
at(2);
520 answer.
at(1, 2) = stress.
at(3);
521 answer.
at(2, 1) = stress.
at(3);
522 answer.
at(1, 3) = stress.
at(7);
523 answer.
at(3, 1) = stress.
at(7);
524 answer.
at(2, 3) = stress.
at(8);
525 answer.
at(3, 2) = stress.
at(8);
530 answer.
at(1, 1) = stress.
at(4);
531 answer.
at(2, 2) = stress.
at(5);
532 answer.
at(1, 2) = stress.
at(6);
533 answer.
at(2, 1) = stress.
at(6);
538 answer.
at(1, 1) = strain.
at(1);
539 answer.
at(2, 2) = strain.
at(2);
540 answer.
at(1, 2) = strain.
at(3) / 2.;
541 answer.
at(2, 1) = strain.
at(3) / 2.;
542 answer.
at(1, 3) = strain.
at(7) / 2.;
543 answer.
at(3, 1) = strain.
at(7) / 2.;
544 answer.
at(2, 3) = strain.
at(8) / 2.;
545 answer.
at(3, 2) = strain.
at(8) / 2.;
549 answer.
at(1, 1) = curv.
at(4);
550 answer.
at(2, 2) = curv.
at(5);
551 answer.
at(1, 2) = curv.
at(6) / 2.;
552 answer.
at(2, 1) = curv.
at(6) / 2.;
573 double layerZeta, layerZCoord, top, bottom;
578 layerZCoord = 0.5 * ( ( 1. - layerZeta ) * bottom + ( 1. + layerZeta ) * top );
582 answer.
at(1) = masterGpStrain.
at(1) + masterGpStrain.
at(4) * layerZCoord;
583 answer.
at(2) = masterGpStrain.
at(2) + masterGpStrain.
at(5) * layerZCoord;
584 answer.
at(5) = masterGpStrain.
at(3) + masterGpStrain.
at(6) * layerZCoord;
585 answer.
at(3) = masterGpStrain.
at(8);
586 answer.
at(4) = masterGpStrain.
at(7);
591RerShell :: printOutputAt(FILE *file,
TimeStep *tStep)
599 fprintf( file,
" GP 1.%d :", gp->giveNumber() );
600 this->
giveIPValue(v, gp, IST_ShellStrainTensor, tStep);
601 fprintf(file,
" strains ");
604 " %.4e %.4e %.4e %.4e %.4e %.4e ",
607 this->
giveIPValue(v, gp, IST_CurvatureTensor, tStep);
608 fprintf(file,
"\n curvatures ");
611 " %.4e %.4e %.4e %.4e %.4e %.4e ",
615 this->
giveIPValue(v, gp, IST_ShellForceTensor, tStep);
616 fprintf(file,
"\n stresses ");
619 " %.4e %.4e %.4e %.4e %.4e %.4e ",
622 this->
giveIPValue(v, gp, IST_ShellMomentTensor, tStep);
623 fprintf(file,
"\n moments ");
626 " %.4e %.4e %.4e %.4e %.4e %.4e ",
635RerShell :: giveDofManDofIDMask(
int inode,
IntArray &answer)
const
637 answer = {D_u, D_v, D_w, R_u, R_v, R_w};
642RerShell :: NodalAveragingRecoveryMI_computeNodalValue(
FloatArray &answer,
int node,
657 if ( type == IST_CurvatureTensor || type == IST_ShellStrainTensor ) {
658 if ( type == IST_CurvatureTensor ) {
666 answer.
at(1) = globTensor.
at(1, 1);
667 answer.
at(2) = globTensor.
at(2, 2);
668 answer.
at(3) = globTensor.
at(3, 3);
669 answer.
at(4) = 2*globTensor.
at(2, 3);
670 answer.
at(5) = 2*globTensor.
at(1, 3);
671 answer.
at(6) = 2*globTensor.
at(1, 2);
674 }
else if ( type == IST_ShellMomentTensor || type == IST_ShellForceTensor ) {
675 if ( type == IST_ShellMomentTensor ) {
683 answer.
at(1) = globTensor.
at(1, 1);
684 answer.
at(2) = globTensor.
at(2, 2);
685 answer.
at(3) = globTensor.
at(3, 3);
686 answer.
at(4) = globTensor.
at(2, 3);
687 answer.
at(5) = globTensor.
at(1, 3);
688 answer.
at(6) = globTensor.
at(1, 2);
692 return StructuralElement :: giveIPValue(answer, gp, type, tStep);
#define REGISTER_Element(class)
FloatMatrix GtoLRotationMatrix
CCTPlate3d(int n, Domain *d)
double computeVolumeAround(GaussPoint *gp) override
virtual double give(CrossSectionProperty a, GaussPoint *gp) const
Node * giveNode(int i) const
std::vector< std ::unique_ptr< IntegrationRule > > integrationRulesArray
CrossSection * giveCrossSection()
int number
Component number.
Index giveSize() const
Returns the size of receiver.
void zero()
Zeroes all coefficients of receiver.
void rotatedWith(FloatMatrix &r, char mode)
void beProductOf(const FloatMatrix &aMatrix, const FloatArray &anArray)
void rotatedWith(const FloatMatrix &r, char mode='n')
void resize(Index rows, Index cols)
void zero()
Zeroes all coefficient of receiver.
double at(std::size_t i, std::size_t j) const
double giveNaturalCoordinate(int i) const
Returns i-th natural element coordinate of receiver.
virtual void computeComponentArrayAt(FloatArray &answer, TimeStep *tStep, ValueModeType mode)
void giveCharacteristicTensor(FloatMatrix &answer, CharTensor type, GaussPoint *gp, TimeStep *tStep)
void giveLocalCoordinates(FloatArray &answer, const FloatArray &global)
const FloatMatrix * computeGtoLRotationMatrix() override
int giveIPValue(FloatArray &answer, GaussPoint *gp, InternalStateType type, TimeStep *tStep) override
void computeStressVector(FloatArray &answer, const FloatArray &strain, GaussPoint *gp, TimeStep *tStep) override
StructuralCrossSection * giveStructuralCrossSection()
Helper function which returns the structural cross-section for the element.
virtual void computeStrainVector(FloatArray &answer, GaussPoint *gp, TimeStep *tStep)
@ CS_BottomZCoord
Bottom z coordinate.
@ CS_TopZCoord
Top z coordinate.
@ ZZNodalRecoveryModelInterfaceType
@ LayeredCrossSectionInterfaceType
@ NodalAveragingRecoveryModelInterfaceType