72GaussIntegrationRule :: SetUpPointsOn2DEmbeddedLine(
int nPoints, MaterialMode mode,
const FloatArray &coord0,
const FloatArray &coord1)
78 for (
int i = 1; i <= nPoints; i++ ) {
79 double x = ( coords_xi.
at(i) + 1.0 ) * 0.5;
84 this->
gaussPoints [ i - 1 ]->setSubPatchCoordinates(subpatchCoord);
87 ( 1. - x ) * coord0.
at(1) + x * coord1.
at(1),
88 ( 1. - x ) * coord0.
at(2) + x * coord1.
at(2) );
89 this->
gaussPoints [ i - 1 ]->setGlobalCoordinates(globalCoord);
92 this->
giveElement()->computeLocalCoordinates(naturalCoord, globalCoord);
93 this->
gaussPoints [ i - 1 ]->setNaturalCoordinates(naturalCoord);
102GaussIntegrationRule :: SetUpPointsOnSquare(
int nPoints, MaterialMode mode)
105 int nPoints_xi1 = ( int ) floor( sqrt(
double ( nPoints ) ) );
106 int nPoints_xi2 = nPoints_xi1;
107 FloatArray coords_xi1, weights1, coords_xi2, weights2;
110 this->
gaussPoints.resize( nPoints_xi1 * nPoints_xi2 );
112 for (
int i = 1; i <= nPoints_xi1; i++ ) {
113 for (
int j = 1; j <= nPoints_xi2; j++ ) {
115 weights1.
at ( i ) *weights2.
at ( j ), mode);
125GaussIntegrationRule :: SetUpPointsOn3dDegShell(
int nPointsXY,
int nPointsZ, MaterialMode mode)
128 int nPoints_xi1 = ( int ) floor(sqrt(
double ( nPointsXY ) ) + 0.1 );
129 int nPoints_xi2 = nPoints_xi1;
130 int nPoints_xi3 = nPointsZ;
131 FloatArray coords_xi1, weights1, coords_xi2, weights2, coords_xi3, weights3;
135 this->
gaussPoints.resize( nPoints_xi1 * nPoints_xi2 * nPoints_xi3 );
138 for (
int i = 1; i <= nPoints_xi1; i++ ) {
139 for (
int j = 1; j <= nPoints_xi2; j++ ) {
140 for (
int k = 1; k <= nPoints_xi3; k++ ) {
142 weights1.
at ( i ) *weights2.
at ( j ) *weights3.
at ( k ), mode);
153GaussIntegrationRule :: SetUpPointsOn3dDegShellLayers(
int nPointsXY,
int nPointsZ, MaterialMode mode,
const FloatArray &layerThickness)
155 int nPoints_xi1 = ( int ) floor(sqrt(
double ( nPointsXY ) ) + 0.1 );
156 int nPoints_xi2 = nPoints_xi1;
157 int nPoints_xi3 = nPointsZ;
158 FloatArray coords_xi1, weights1, coords_xi2, weights2, coords_xi3, weights3;
162 int pointsPerLayer = nPoints_xi1 * nPoints_xi2 * nPoints_xi3;
165 double totalThickness = layerThickness.
sum();
168 double scaledThickness;
170 for (
int t = 1; t <= layerThickness.
giveSize(); t++ ) {
171 scaledThickness = layerThickness.
at(t) / totalThickness;
173 for (
int i = 1; i <= nPoints_xi1; i++ ) {
174 for (
int j = 1; j <= nPoints_xi2; j++ ) {
175 for (
int k = 1; k <= nPoints_xi3; k++ ) {
176 this->
gaussPoints [ count ] =
new GaussPoint(
this, count + 1,
Vec3(coords_xi1.
at(i), coords_xi2.
at(j), ( coords_xi3.
at(k) + 1. ) * scaledThickness + bottom),
177 weights1.
at(i)*weights2.
at(j)*weights3.
at(k)*scaledThickness, mode);
182 bottom += 2.0 * scaledThickness;
190GaussIntegrationRule :: SetUpPointsOnCube(
int nPoints, MaterialMode mode)
193 int nPoints_xi1 = ( int ) floor(
cbrt(
double ( nPoints ) ) + 0.5);
194 int nPoints_xi2 = nPoints_xi1;
195 int nPoints_xi3 = nPoints_xi1;
196 FloatArray coords_xi1, weights1, coords_xi2, weights2, coords_xi3, weights3;
200 this->
gaussPoints.resize( nPoints_xi1 * nPoints_xi2 * nPoints_xi3 );
202 for (
int i = 1; i <= nPoints_xi1; i++ ) {
203 for (
int j = 1; j <= nPoints_xi2; j++ ) {
204 for (
int k = 1; k <= nPoints_xi3; k++ ) {
206 weights1.
at ( i ) *weights2.
at ( j ) *weights3.
at ( k ), mode);
217int GaussIntegrationRule :: SetUpPointsOnCubeLayers(
int nPoints1,
int nPoints2,
int nPointsDepth, MaterialMode mode,
const FloatArray &layerThickness)
219 FloatArray coords_xi1, weights1, coords_xi2, weights2, coords_xi3, weights3;
223 int pointsPerLayer = nPoints1 * nPoints2 * nPointsDepth;
227 double totalThickness = layerThickness.
sum();
231 double scaledThickness;
232 for (
int t = 1; t <= layerThickness.
giveSize(); t++ ) {
233 scaledThickness = layerThickness.
at(t) / totalThickness;
234 for (
int i = 1; i <= nPoints1; i++ ) {
235 for (
int j = 1; j <= nPoints2; j++ ) {
236 for (
int k = 1; k <= nPointsDepth; k++ ) {
238 Vec3(coords_xi1.
at(i), coords_xi2.
at(j), ( coords_xi3.
at(k) + 1. ) * scaledThickness + bottom),
239 weights1.
at(i)*weights2.
at(j)*weights3.
at(k)*scaledThickness, mode);
244 bottom += 2.0 * scaledThickness;
286GaussIntegrationRule :: SetUpPointsOnWedge(
int nPointsTri,
int nPointsDepth, MaterialMode mode)
288 FloatArray coords_xi1, coords_xi2, coords_xi3, weightsTri, weightsDepth;
291 this->
gaussPoints.resize( nPointsTri * nPointsDepth );
294 for (
int i = 1; i <= nPointsTri; i++ ) {
295 for (
int j = 1; j <= nPointsDepth; j++ ) {
297 weightsTri.
at ( i ) *weightsDepth.
at ( j ), mode);
307GaussIntegrationRule :: SetUpPointsOnWedgeLayers(
int nPointsTri,
int nPointsDepth, MaterialMode mode,
const FloatArray &layerThickness)
309 FloatArray coords_xi1, coords_xi2, coords_xi3, weightsTri, weightsDepth;
312 int pointsPerLayer = nPointsTri * nPointsDepth;
316 double totalThickness = layerThickness.
sum();
320 double scaledThickness;
321 for (
int k = 1; k <= layerThickness.
giveSize(); k++ ) {
322 scaledThickness = layerThickness.
at(k) / totalThickness;
323 for (
int i = 1; i <= nPointsTri; i++ ) {
324 for (
int j = 1; j <= nPointsDepth; j++ ) {
326 Vec3(coords_xi1.
at(i), coords_xi2.
at(i), ( coords_xi3.
at(j) + 1. ) * scaledThickness + bottom),
327 weightsTri.
at ( i ) * ( weightsDepth.
at ( j ) *scaledThickness ), mode);
331 bottom += 2.0 * scaledThickness;
495 coords_xi1.
resize(nPoints);
496 coords_xi2.
resize(nPoints);
497 coords_xi3.
resize(nPoints);
510 a = ( 5. + 3. * sqrt(5.) ) / 20.;
511 b = ( 5. - sqrt(5.) ) / 20.;
585 a = ( 1. + sqrt(5. / 14.) ) / 4.;
586 b = ( 1. - sqrt(5. / 14.) ) / 4.;
617 w = 0.302836780970891856e-1;
624 w = 0.602678571428571597e-2;
643 w = 0.116452490860289742e-1;
660 a = 0.665501535736642813e-1;
661 b = 0.433449846426335728;
662 w = 0.109491415613864534e-1;
692 a = 0.356191386222544953;
693 b = 0.214602871259151684;
694 w = 0.665379170969464506e-2;
711 a = 0.877978124396165982;
712 b = 0.406739585346113397e-1;
713 w = 0.167953517588677620e-2;
730 a = 0.329863295731730594e-1;
731 b = 0.322337890142275646;
732 w = 0.922619692394239843e-2;
749 a = 0.603005664791649076;
750 b = 0.269672331458315867;
751 c = 0.636610018750175299e-1;
752 w = 0.803571428571428248e-2;
808 w = -0.393270066412926145e-1;
813 a = 0.617587190300082967;
814 b = 0.127470936566639015;
815 w = 0.408131605934270525e-2;
832 a = 0.903763508822103123;
833 b = 0.320788303926322960e-1;
834 w = 0.658086773304341943e-3;
851 a = 0.450222904356718978;
852 b = 0.497770956432810185e-1;
853 w = 0.438425882512284693e-2;
878 a = 0.316269552601450060;
879 b = 0.183730447398549945;
880 w = 0.138300638425098166e-1;
905 a = 0.513280033360881072;
906 b = 0.229177878448171174e-1;
907 c = 0.231901089397150906;
908 w = 0.424043742468372453e-2;
957 a = 0.193746475248804382;
958 b = 0.730313427807538396;
959 c = 0.379700484718286102e-1;
960 w = 0.223873973961420164e-2;
1013 OOFEM_SERROR(
"unsupported number of IPs (%d)", nPoints);
1439 switch ( nPoints ) {
1445 coords_xi =
Vec1(0.0);
1446 weights =
Vec1(2.0);
1450 coords_xi =
Vec2(-0.577350269189626, 0.577350269189626);
1451 weights =
Vec2(1.0, 1.0);
1484 -0.9061798459386639927976269,
1485 -0.5384693101056830910363144,
1487 0.5384693101056830910363144,
1488 0.9061798459386639927976269
1491 0.2369268850561890875142640,
1492 0.4786286704993664680412915,
1493 0.5688888888888888888888889,
1494 0.4786286704993664680412915,
1495 0.2369268850561890875142640
1501 -0.2386191860831969086305017,
1502 -0.6612093864662645136613996,
1503 -0.9324695142031520278123016,
1504 0.9324695142031520278123016,
1505 0.6612093864662645136613996,
1506 0.2386191860831969086305017
1509 0.4679139345726910473898703,
1510 0.3607615730481386075698335,
1511 0.1713244923791703450402961,
1512 0.1713244923791703450402961,
1513 0.3607615730481386075698335,
1514 0.4679139345726910473898703
1520 -0.9491079123427585245261897,
1521 -0.7415311855993944398638648,
1522 -0.4058451513773971669066064,
1524 0.4058451513773971669066064,
1525 0.7415311855993944398638648,
1526 0.9491079123427585245261897
1529 0.1294849661688696932706114,
1530 0.2797053914892766679014678,
1531 0.3818300505051189449503698,
1532 0.4179591836734693877551020,
1533 0.3818300505051189449503698,
1534 0.2797053914892766679014678,
1535 0.1294849661688696932706114
1864 OOFEM_SERROR(
"unsupported number of IPs (%d)", nPoints);
static FloatArray Vec8(const double &a, const double &b, const double &c, const double &d, const double &e, const double &f, const double &g, const double &h)
static FloatArray Vec7(const double &a, const double &b, const double &c, const double &d, const double &e, const double &f, const double &g)