Home
last modified time | relevance | path

Searched refs:X (Results 1 – 25 of 45) sorted by relevance

12

/libCEED/examples/solids/include/
H A Dmatops.h16 PetscErrorCode ApplyLocalCeedOp(Vec X, Vec Y, UserMult user);
19 PetscErrorCode FormResidual_Ceed(SNES snes, Vec X, Vec Y, void *ctx);
22 PetscErrorCode ApplyJacobianCoarse_Ceed(SNES snes, Vec X, Vec Y, void *ctx);
25 PetscErrorCode ApplyJacobian_Ceed(Mat A, Vec X, Vec Y);
28 PetscErrorCode Prolong_Ceed(Mat A, Vec X, Vec Y);
31 PetscErrorCode Restrict_Ceed(Mat A, Vec X, Vec Y);
37 PetscErrorCode ComputeStrainEnergy(DM dm_energy, UserMult user, CeedOperator op_energy, Vec X, Pets…
/libCEED/examples/petsc/
H A Dindex.md10 …in \mathbb{R}^3$, while the coordinates of the reference element are $\bm{X}=(X,Y) \equiv (X_0,X_1…
23 …coordinates on the discrete surface, denoted by $\bm{{x}}=(x,y)$, to $\bm{X}=(X,Y) \in \textrm{I}$…
26 …}{\partial \bm{X}}_{(2\times2)} = \frac{\partial {\bm{x}}}{\partial \bar{\bm{x}}}_{(2\times3)} \fr…
32 …\partial \bar{\bm{x}}}{\partial \bm{X}}\right)\right\| \left\|col_2 \left(\frac{\partial \bar{\bm{…
35 …cube`, the right-most Jacobian matrix ${\partial\bar{\bm{x}}}/{\partial \bm{X}}_{(3\times2)}$ is p…
38X}}\right) / \left\| col_1\left(\frac{\partial\bar{\bm{x}}}{\partial \bm{X}}\right)\right\| , col_…
60 …cle and 1D linear element in figure {numref}`fig-sphere-coords`), to $\bm{X}=(X,Y) \in \textrm{I}$…
63 …{\partial \bm{X}}_{(3\times2)} = \frac{\partial \overset{\circ}{\bm{x}}}{\partial \bm{x}}_{(3\time…
69 …rset{\circ}{\bm{x}}}{\partial \bm{X}}\right) \times col_2 \left(\frac{\partial \overset{\circ}{\bm…
77 …$q_1$, marked by blue dots, with physical coordinates denoted by $\bm x(\bm X)$, are mapped to the…
[all …]
H A Dbpsraw.c224 static PetscErrorCode MatMult_Mass(Mat A, Vec X, Vec Y) { in MatMult_Mass() argument
233 …PetscCall(VecScatterBegin(op_apply_ctx->l_to_g, X, op_apply_ctx->X_loc, INSERT_VALUES, SCATTER_REV… in MatMult_Mass()
234 …PetscCall(VecScatterEnd(op_apply_ctx->l_to_g, X, op_apply_ctx->X_loc, INSERT_VALUES, SCATTER_REVER… in MatMult_Mass()
261 static PetscErrorCode MatMult_Diff(Mat A, Vec X, Vec Y) { in MatMult_Diff() argument
270 …PetscCall(VecScatterBegin(op_apply_ctx->l_to_g_0, X, op_apply_ctx->X_loc, INSERT_VALUES, SCATTER_R… in MatMult_Diff()
271 …PetscCall(VecScatterEnd(op_apply_ctx->l_to_g_0, X, op_apply_ctx->X_loc, INSERT_VALUES, SCATTER_REV… in MatMult_Diff()
290 PetscCall(VecScatterBegin(op_apply_ctx->g_to_g_D, X, Y, INSERT_VALUES, SCATTER_FORWARD)); in MatMult_Diff()
291 PetscCall(VecScatterEnd(op_apply_ctx->g_to_g_D, X, Y, INSERT_VALUES, SCATTER_FORWARD)); in MatMult_Diff()
298 …mputeErrorMax(OperatorApplyContext op_apply_ctx, CeedOperator op_error, Vec X, CeedVector target, … in ComputeErrorMax() argument
309 …PetscCall(VecScatterBegin(op_apply_ctx->l_to_g, X, op_apply_ctx->X_loc, INSERT_VALUES, SCATTER_REV… in ComputeErrorMax()
[all …]
H A Dbpssphere.c56 Vec X, X_loc, rhs, rhs_loc; in main() local
136 PetscCall(DMCreateGlobalVector(dm, &X)); in main()
137 PetscCall(VecGetLocalSize(X, &l_size)); in main()
138 PetscCall(VecGetSize(X, &g_size)); in main()
141 PetscCall(VecDuplicate(X, &rhs)); in main()
228 PetscCall(KSPSolve(ksp, rhs, X)); in main()
240 PetscCall(VecZeroEntries(X)); in main()
249 PetscCall(KSPSolve(ksp, rhs, X)); in main()
281 PetscCall(ComputeL2Error(X, &l2_error, op_error_ctx)); in main()
305 PetscCall(VecView(X, vtk_viewer_soln)); in main()
[all …]
H A Dmultigrid.c62 Vec *X, *X_loc, *mult, rhs, rhs_loc; in main() local
168 PetscCall(PetscMalloc1(num_levels, &X)); in main()
196 PetscCall(DMCreateGlobalVector(dm[i], &X[i])); in main()
197 PetscCall(VecGetLocalSize(X[i], &l_size[i])); in main()
198 PetscCall(VecGetSize(X[i], &g_size[i])); in main()
219 PetscCall(VecDuplicate(X[fine_level], &rhs)); in main()
228 PetscCall(VecGetType(X[0], &vec_type)); in main()
313 PetscCall(VecZeroEntries(X[i])); in main()
314 PetscCall(DMLocalToGlobal(dm[i], X_loc[i], ADD_VALUES, X[i])); in main()
318 PetscCall(DMGlobalToLocal(dm[i], X[i], INSERT_VALUES, mult[i])); in main()
[all …]
H A Dbpsswarm.c59 Vec X, X_loc, rhs; in main() local
221 PetscCall(DMCreateGlobalVector(dm_mesh, &X)); in main()
222 PetscCall(VecGetLocalSize(X, &l_size)); in main()
223 PetscCall(VecGetSize(X, &g_size)); in main()
226 PetscCall(VecDuplicate(X, &rhs)); in main()
244 PetscCall(VecGetType(X, &vec_type)); in main()
320 PetscCall(KSPSolve(ksp, rhs, X)); in main()
332 PetscCall(VecZeroEntries(X)); in main()
341 PetscCall(KSPSolve(ksp, rhs, X)); in main()
392 PetscCall(VecViewFromOptions(X, NULL, "-solution_view")); in main()
[all …]
H A Dbps.c58 Vec X, X_loc, rhs, rhs_loc; in RunWithDM() local
94 PetscCall(DMCreateGlobalVector(dm, &X)); in RunWithDM()
95 PetscCall(VecGetLocalSize(X, &l_size)); in RunWithDM()
96 PetscCall(VecGetSize(X, &g_size)); in RunWithDM()
99 PetscCall(VecDuplicate(X, &rhs)); in RunWithDM()
126 PetscCall(VecGetType(X, &vec_type)); in RunWithDM()
216 PetscCall(KSPSolve(ksp, rhs, X)); in RunWithDM()
228 PetscCall(VecZeroEntries(X)); in RunWithDM()
236 PetscCall(KSPSolve(ksp, rhs, X)); in RunWithDM()
268 PetscCall(ComputeL2Error(X, &l2_error, op_error_ctx)); in RunWithDM()
[all …]
/libCEED/examples/petsc/include/
H A Dmatops.h21 PetscErrorCode ApplyLocal_Ceed(Vec X, Vec Y, OperatorApplyContext op_apply_ctx);
22 PetscErrorCode MatMult_Ceed(Mat A, Vec X, Vec Y);
23 PetscErrorCode FormResidual_Ceed(SNES snes, Vec X, Vec Y, void *ctx);
24 PetscErrorCode MatMult_Prolong(Mat A, Vec X, Vec Y);
25 PetscErrorCode MatMult_Restrict(Mat A, Vec X, Vec Y);
26 PetscErrorCode ComputeL2Error(Vec X, PetscScalar *l2_error, OperatorApplyContext op_error_ctx);
/libCEED/examples/fluids/qfunctions/
H A Ddensitycurrent.h86 CEED_QFUNCTION_HELPER State Exact_DC(CeedInt dim, CeedScalar time, const CeedScalar X[], CeedInt Nf… in Exact_DC() argument
105 const CeedScalar x = X[0]; in Exact_DC()
106 const CeedScalar y = X[1]; in Exact_DC()
107 const CeedScalar z = X[2]; in Exact_DC()
135 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[0]; in ICsDC() local
142 const CeedScalar x[] = {X[0][i], X[1][i], X[2][i]}; in ICsDC()
H A Dblasius.h30 …CeedScalar *X; // !< Chebyshev polynomial… member
82 CeedScalar X = 2 * (eta / blasius->eta_max) - 1.; in BlasiusSolution() local
86 ChebyshevEval(N, blasius->Tf_cheb, X, blasius->eta_max, f); in BlasiusSolution()
87 ChebyshevEval(N - 1, blasius->Th_cheb, X, blasius->eta_max, h); in BlasiusSolution()
104 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[0]; in ICsBlasius() local
120 const CeedScalar x[3] = {X[0][i], X[1][i], X[2][i]}; in ICsBlasius()
135 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[3]; in Blasius_Inflow() local
153 const CeedScalar x[3] = {X[0][i], X[1][i], 0.}; in Blasius_Inflow()
190 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[3]; in Blasius_Inflow_Jacobian() local
209 const CeedScalar x[3] = {X[0][i], X[1][i], X[2][i]}; in Blasius_Inflow_Jacobian()
H A Dchannel.h32 CEED_QFUNCTION_HELPER State Exact_Channel(CeedInt dim, CeedScalar time, const CeedScalar X[], CeedI… in Exact_Channel() argument
48 const CeedScalar x[3] = {0, X[1], X[2]}; in Exact_Channel()
67 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[0]; in ICsChannel() local
74 const CeedScalar x[] = {X[0][i], X[1][i], X[2][i]}; in ICsChannel()
89 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[3]; in Channel_Inflow() local
107 const CeedScalar x[3] = {0, X[1][i], X[2][i]}; in Channel_Inflow()
H A Dtaylorgreen.h18 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[0]; in ICsTaylorGreen() local
30 CeedScalar x[] = {X[0][i], X[1][i], X[2][i]}; in ICsTaylorGreen()
H A Dgaussianwave.h28 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[0]; in IC_GaussianWave() local
45 const CeedScalar x[3] = {X[0][i], X[1][i], X[2][i]}; in IC_GaussianWave()
H A Dstg_shur14.h157 CEED_QFUNCTION_HELPER void StgShur14Calc(const CeedScalar X[3], const CeedScalar t, const CeedScala… in StgShur14Calc()
165 CeedScalar xhat[] = {0., X[1], X[2]}; in StgShur14Calc()
168 xhat[0] = (X[0] - stg_ctx->u0 * t) * Max(2 * kappa[0] / kappa[n], 0.1); in StgShur14Calc()
198 CEED_QFUNCTION_HELPER void StgShur14Calc_PrecompEktot(const CeedScalar X[3], const CeedScalar t, co… in StgShur14Calc_PrecompEktot()
210 CeedScalar xhat[] = {0., X[1], X[2]}; in StgShur14Calc_PrecompEktot()
213 xhat[0] = (X[0] - stg_ctx->u0 * t) * Max(2 * kappa[0] / kappa[n], 0.1); in StgShur14Calc_PrecompEktot()
332 const CeedScalar(*X)[CEED_Q_VLA] = (const CeedScalar(*)[CEED_Q_VLA])in[3]; in StgShur14Inflow() local
353 const CeedScalar x[] = {X[0][i], X[1][i], X[2][i]}; in StgShur14Inflow()
363 InterpolateProfile(X[1][i], ubar, cij, &eps, &lt, stg_ctx); in StgShur14Inflow()
365 CalcSpectrum(X[1][i], eps, lt, h_node_sep, mu / rho, qn, stg_ctx); in StgShur14Inflow()
/libCEED/examples/solids/src/
H A Dmatops.c23 PetscErrorCode ApplyLocalCeedOp(Vec X, Vec Y, UserMult user) { in ApplyLocalCeedOp() argument
30 PetscCall(DMGlobalToLocal(user->dm, X, INSERT_VALUES, user->X_loc)); in ApplyLocalCeedOp()
56 PetscErrorCode FormResidual_Ceed(SNES snes, Vec X, Vec Y, void *ctx) { in FormResidual_Ceed() argument
66 PetscCall(ApplyLocalCeedOp(X, Y, user)); in FormResidual_Ceed()
77 PetscErrorCode ApplyJacobianCoarse_Ceed(SNES snes, Vec X, Vec Y, void *ctx) { in ApplyJacobianCoarse_Ceed() argument
86 PetscCall(ApplyLocalCeedOp(X, Y, user)); in ApplyJacobianCoarse_Ceed()
92 PetscErrorCode ApplyJacobian_Ceed(Mat A, Vec X, Vec Y) { in ApplyJacobian_Ceed() argument
102 PetscCall(ApplyLocalCeedOp(X, Y, user)); in ApplyJacobian_Ceed()
108 PetscErrorCode Prolong_Ceed(Mat A, Vec X, Vec Y) { in Prolong_Ceed() argument
119 PetscCall(DMGlobalToLocal(user->dm_c, X, INSERT_VALUES, user->loc_vec_c)); in Prolong_Ceed()
[all …]
/libCEED/examples/petsc/src/
H A Dmatops.c66 PetscErrorCode ApplyLocal_Ceed(Vec X, Vec Y, OperatorApplyContext op_apply_ctx) { in ApplyLocal_Ceed() argument
71 PetscCall(DMGlobalToLocal(op_apply_ctx->dm, X, INSERT_VALUES, op_apply_ctx->X_loc)); in ApplyLocal_Ceed()
93 PetscErrorCode MatMult_Ceed(Mat A, Vec X, Vec Y) { in MatMult_Ceed() argument
100 PetscCall(ApplyLocal_Ceed(X, Y, op_apply_ctx)); in MatMult_Ceed()
107 PetscErrorCode MatMult_Prolong(Mat A, Vec X, Vec Y) { in MatMult_Prolong() argument
116 PetscCall(DMGlobalToLocal(pr_restr_ctx->dmc, X, INSERT_VALUES, pr_restr_ctx->loc_vec_c)); in MatMult_Prolong()
141 PetscErrorCode MatMult_Restrict(Mat A, Vec X, Vec Y) { in MatMult_Restrict() argument
150 PetscCall(DMGlobalToLocal(pr_restr_ctx->dmf, X, INSERT_VALUES, pr_restr_ctx->loc_vec_f)); in MatMult_Restrict()
175 PetscErrorCode ComputeL2Error(Vec X, PetscScalar *l2_error, OperatorApplyContext op_error_ctx) { in ComputeL2Error() argument
179 PetscCall(VecDuplicate(X, &E)); in ComputeL2Error()
[all …]
/libCEED/examples/petsc/qfunctions/bps/
H A Dbp1sphere.h47 const CeedScalar *X = in[0], *J = in[1], *w = in[2]; in SetupMassGeo() local
54 const CeedScalar xx[3] = {X[i + 0 * Q], X[i + 1 * Q], X[i + 2 * Q]}; in SetupMassGeo()
108 const CeedScalar *X = in[0], *q_data = in[1]; in SetupMassRhs() local
119 const CeedScalar theta = asin(X[i + 2 * Q] / R); in SetupMassRhs()
H A Dbp3sphere.h60 const CeedScalar *X = in[0], *J = in[1], *w = in[2]; in SetupDiffGeo() local
66 const CeedScalar xx[3] = {X[i + 0 * Q], X[i + 1 * Q], X[i + 2 * Q]}; in SetupDiffGeo()
144 const CeedScalar *X = in[0], *q_data = in[1]; in SetupDiffRhs() local
155 CeedScalar x = X[i + Q * 0], y = X[i + Q * 1], z = X[i + Q * 2]; in SetupDiffRhs()
H A Dbp4sphere.h21 const CeedScalar *X = in[0], *q_data = in[1]; in SetupDiffRhs3() local
32 CeedScalar x = X[i + Q * 0], y = X[i + Q * 1], z = X[i + Q * 2]; in SetupDiffRhs3()
/libCEED/tests/
H A Dt305-basis.c14 CeedScalar M[p * p], K[p * p], X[p * p], lambda[p]; in main() local
37 CeedSimultaneousDiagonalization(ceed, K, M, X, lambda, p); in main()
44 for (int k = 0; k < p; k++) sum += M[p * i + k] * X[p * k + j]; in main()
51 for (int k = 0; k < p; k++) sum += X[p * k + i] * work_array[p * k + j]; in main()
69 for (int k = 0; k < p; k++) sum += K[p * i + k] * X[p * k + j]; in main()
76 for (int k = 0; k < p; k++) sum += X[p * k + i] * work_array[p * k + j]; in main()
H A Dt330-basis.h61 CeedScalar X[2]; in BuildHdivQuadrilateral() local
70 X[0] = q_ref_1d[j]; in BuildHdivQuadrilateral()
71 X[1] = q_ref_1d[i]; in BuildHdivQuadrilateral()
72 BuildNodalHdivQuadrilateral(X, Bx, By); in BuildHdivQuadrilateral()
/libCEED/
H A DCITATION.cff28 orcid: 0000-0001-5831-561X
31 orcid: 0000-0002-0965-214X
55 orcid: 0000-0001-7273-049X
83 orcid: 0000-0001-5831-561X
86 orcid: 0000-0002-0965-214X
137 orcid: 0000-0001-5831-561X
140 orcid: 0000-0002-0965-214X
164 orcid: 0000-0001-7273-049X
187 orcid: 0000-0001-5831-561X
/libCEED/examples/petsc/qfunctions/area/
H A Dareasphere.h47 const CeedScalar *X = in[0], *J = in[1], *w = in[2]; in SetupMassGeoSphere() local
54 const CeedScalar xx[3][1] = {{X[i + 0 * Q]}, {X[i + 1 * Q]}, {X[i + 2 * Q]}}; in SetupMassGeoSphere()
/libCEED/examples/fluids/src/
H A Dpetsc_ops.c216 PetscErrorCode ApplyCeedOperator_Core(Vec X, Vec X_loc, CeedVector x_ceed, CeedVector y_ceed, Vec Y… in ApplyCeedOperator_Core() argument
222 if (X) PetscCall(DMGlobalToLocal(ctx->dm_x, X, INSERT_VALUES, X_loc)); in ApplyCeedOperator_Core()
227 PetscCall(PetscLogEventBegin(FLUIDS_CeedOperatorApply, X, Y, 0, 0)); in ApplyCeedOperator_Core()
232 PetscCall(PetscLogEventEnd(FLUIDS_CeedOperatorApply, X, Y, 0, 0)); in ApplyCeedOperator_Core()
241 PetscErrorCode ApplyCeedOperatorGlobalToGlobal(Vec X, Vec Y, OperatorApplyContext ctx) { in ApplyCeedOperatorGlobalToGlobal() argument
251 PetscCall(ApplyCeedOperator_Core(X, X_loc, ctx->x_ceed, ctx->y_ceed, Y_loc, Y, ctx, false)); in ApplyCeedOperatorGlobalToGlobal()
275 PetscErrorCode ApplyCeedOperatorGlobalToLocal(Vec X, Vec Y_loc, OperatorApplyContext ctx) { in ApplyCeedOperatorGlobalToLocal() argument
282 PetscCall(ApplyCeedOperator_Core(X, X_loc, ctx->x_ceed, ctx->y_ceed, Y_loc, NULL, ctx, false)); in ApplyCeedOperatorGlobalToLocal()
/libCEED/examples/fluids/include/
H A Dmat-ceed-impl.h43 PETSC_CEED_EXTERN PetscErrorCode MatMult_Ceed(Mat A, Vec X, Vec Y);
44 PETSC_CEED_EXTERN PetscErrorCode MatMultTranspose_Ceed(Mat A, Vec Y, Vec X);

12