Lines Matching +full:- +full:j
1 // Copyright (c) 2017-2026, Lawrence Livermore National Security, LLC and other CEED contributors.
2 // All Rights Reserved. See the top-level LICENSE and NOTICE files for details.
4 // SPDX-License-Identifier: BSD-2-Clause
16 // -----------------------------------------------------------------------------
20 // Reference (parent) 2D coordinates: X \in [-1, 1]^2
22 // Global 3D physical coordinates given by the mesh: xx \in [-R, R]^3 with R radius of the sphere
24 // Local 3D physical coordinates on the 2D manifold: x \in [-l, l]^3 with l half edge of the cube i…
44 // -----------------------------------------------------------------------------
47 const CeedScalar *X = in[0], *J = in[1], *w = in[2]; in SetupMassGeoSphere() local
61 {J[i + Q * 0], J[i + Q * 3]}, in SetupMassGeoSphere()
62 {J[i + Q * 1], J[i + Q * 4]}, in SetupMassGeoSphere()
63 {J[i + Q * 2], J[i + Q * 5]} in SetupMassGeoSphere()
69 for (int j = 0; j < 3; j++) { in SetupMassGeoSphere() local
71 xx_sq[j][k] = 0; in SetupMassGeoSphere()
72 … for (int l = 0; l < 1; l++) xx_sq[j][k] += xx[j][l] * xx[k][l] / (sqrt(mod_xx_sq) * mod_xx_sq); in SetupMassGeoSphere()
77 …{1. / sqrt(mod_xx_sq) - xx_sq[0][0], -xx_sq[0][1], -xx_sq[0][2] … in SetupMassGeoSphere()
78 …{-xx_sq[1][0], 1. / sqrt(mod_xx_sq) - xx_sq[1][1], -xx_sq[1][2] … in SetupMassGeoSphere()
79 …{-xx_sq[2][0], -xx_sq[2][1], 1. / sqrt(mod_xx_sq) - xx… in SetupMassGeoSphere()
83 for (int j = 0; j < 3; j++) { in SetupMassGeoSphere() local
85 dxdX[j][k] = 0; in SetupMassGeoSphere()
86 for (int l = 0; l < 3; l++) dxdX[j][k] += dxdxx[j][l] * dxxdX[l][k]; in SetupMassGeoSphere()
90 // J is given by the cross product of the columns of dxdX in SetupMassGeoSphere()
91 const CeedScalar J[3][1] = {{dxdX[1][0] * dxdX[2][1] - dxdX[2][0] * dxdX[1][1]}, in SetupMassGeoSphere() local
92 {dxdX[2][0] * dxdX[0][1] - dxdX[0][0] * dxdX[2][1]}, in SetupMassGeoSphere()
93 {dxdX[0][0] * dxdX[1][1] - dxdX[1][0] * dxdX[0][1]}}; in SetupMassGeoSphere()
94 // Use the magnitude of J as our detJ (volume scaling factor) in SetupMassGeoSphere()
95 const CeedScalar mod_J = sqrt(J[0][0] * J[0][0] + J[1][0] * J[1][0] + J[2][0] * J[2][0]); in SetupMassGeoSphere()
100 // -----------------------------------------------------------------------------