Lines Matching refs:f

113   PetscInt           Nf, numConstants, f;  in PetscDSView_Ascii()  local
122 for (f = 0; f < Nf; ++f) { in PetscDSView_Ascii()
130 PetscCall(PetscDSGetDiscretization(ds, f, &obj)); in PetscDSView_Ascii()
143 …((PetscObject)ds), PETSC_ERR_ARG_WRONG, "Unknown discretization type for field %" PetscInt_FMT, f); in PetscDSView_Ascii()
146 if (ds->implicit[f]) PetscCall(PetscViewerASCIIPrintf(viewer, " (implicit)")); in PetscDSView_Ascii()
152 PetscCall(PetscViewerASCIIPrintf(viewer, " %" PetscInt_FMT "-jet", ds->jetDegree[f])); in PetscDSView_Ascii()
164 if (b->field != f) continue; in PetscDSView_Ascii()
213 …for (f = 0; f < numConstants; ++f) PetscCall(PetscViewerASCIIPrintf(viewer, "%g\n", (double)PetscR… in PetscDSView_Ascii()
366 PetscInt dim, dimEmbed, NbMax = 0, NcMax = 0, NqMax = 0, NsMax = 1, f; in PetscDSSetUp() local
384 for (f = 0; f < Nf; ++f) { in PetscDSSetUp()
390 PetscCall(PetscDSGetDiscretization(prob, f, &obj)); in PetscDSSetUp()
420 for (f = 0; f < Nf; ++f) { in PetscDSSetUp()
426 PetscCall(PetscDSGetDiscretization(prob, f, &obj)); in PetscDSSetUp()
445 for (f = 0; f < Nf; ++f) { in PetscDSSetUp()
451 PetscCall(PetscDSGetDiscretization(prob, f, &obj)); in PetscDSSetUp()
452 if (prob->jetDegree[f] > 1) hasH = PETSC_TRUE; in PetscDSSetUp()
456 prob->T[f] = prob->Tf[f] = NULL; in PetscDSSetUp()
470 …ure order %" PetscInt_FMT " != %" PetscInt_FMT " DS cell quadrature order", f, order, maxOrder[dim… in PetscDSSetUp()
476 …ure order %" PetscInt_FMT " != %" PetscInt_FMT " DS face quadrature order", f, order, maxOrder[dim… in PetscDSSetUp()
481 PetscCall(PetscFEGetCellTabulation(fe, prob->jetDegree[f], &prob->T[f])); in PetscDSSetUp()
482 PetscCall(PetscFEGetFaceTabulation(fe, prob->jetDegree[f], &prob->Tf[f])); in PetscDSSetUp()
489 PetscCall(PetscFVGetCellTabulation(fv, &prob->T[f])); in PetscDSSetUp()
491 …PetscObject)prob), PETSC_ERR_ARG_WRONG, "Unknown discretization type for field %" PetscInt_FMT, f); in PetscDSSetUp()
493 prob->Nc[f] = Nc; in PetscDSSetUp()
494 prob->Nb[f] = Nb; in PetscDSSetUp()
495 prob->off[f + 1] = Nc + prob->off[f]; in PetscDSSetUp()
496 prob->offDer[f + 1] = Nc * dim + prob->offDer[f]; in PetscDSSetUp()
497 prob->offCohesive[0][f + 1] = (prob->cohesive[f] ? Nc : Nc * 2) + prob->offCohesive[0][f]; in PetscDSSetUp()
498 …prob->offDerCohesive[0][f + 1] = (prob->cohesive[f] ? Nc : Nc * 2) * dimEmbed + prob->offDerCohesi… in PetscDSSetUp()
499 prob->offCohesive[1][f] = (prob->cohesive[f] ? 0 : Nc) + prob->offCohesive[0][f]; in PetscDSSetUp()
500 …prob->offDerCohesive[1][f] = (prob->cohesive[f] ? 0 : Nc) * dimEmbed + prob->offDerCohesive[0]… in PetscDSSetUp()
501 prob->offCohesive[2][f + 1] = (prob->cohesive[f] ? Nc : Nc * 2) + prob->offCohesive[2][f]; in PetscDSSetUp()
502 …prob->offDerCohesive[2][f + 1] = (prob->cohesive[f] ? Nc : Nc * 2) * dimEmbed + prob->offDerCohesi… in PetscDSSetUp()
510 if (prob->isCohesive && !prob->cohesive[f]) prob->totDim += Nb; in PetscDSSetUp()
548 PetscInt Nf = prob->Nf, f; in PetscDSEnlarge_Static() local
555 for (f = 0; f < Nf; ++f) { in PetscDSEnlarge_Static()
556 tmpd[f] = prob->disc[f]; in PetscDSEnlarge_Static()
557 tmpi[f] = prob->implicit[f]; in PetscDSEnlarge_Static()
558 tmpc[f] = prob->cohesive[f]; in PetscDSEnlarge_Static()
559 tmpk[f] = prob->jetDegree[f]; in PetscDSEnlarge_Static()
561 for (f = Nf; f < NfNew; ++f) { in PetscDSEnlarge_Static()
562 tmpd[f] = NULL; in PetscDSEnlarge_Static()
563 tmpi[f] = PETSC_TRUE, tmpc[f] = PETSC_FALSE; in PetscDSEnlarge_Static()
564 tmpk[f] = 1; in PetscDSEnlarge_Static()
574 for (f = 0; f < Nf; ++f) tmpup[f] = prob->update[f]; in PetscDSEnlarge_Static()
575 for (f = 0; f < Nf; ++f) tmpctx[f] = prob->ctx[f]; in PetscDSEnlarge_Static()
576 for (f = Nf; f < NfNew; ++f) tmpup[f] = NULL; in PetscDSEnlarge_Static()
577 for (f = Nf; f < NfNew; ++f) tmpctx[f] = NULL; in PetscDSEnlarge_Static()
583 for (f = 0; f < Nf; ++f) tmpexactSol[f] = prob->exactSol[f]; in PetscDSEnlarge_Static()
584 for (f = 0; f < Nf; ++f) tmpexactCtx[f] = prob->exactCtx[f]; in PetscDSEnlarge_Static()
585 for (f = 0; f < Nf; ++f) tmpexactSol_t[f] = prob->exactSol_t[f]; in PetscDSEnlarge_Static()
586 for (f = 0; f < Nf; ++f) tmpexactCtx_t[f] = prob->exactCtx_t[f]; in PetscDSEnlarge_Static()
587 for (f = 0; f < Nf; ++f) tmplowerBound[f] = prob->lowerBound[f]; in PetscDSEnlarge_Static()
588 for (f = 0; f < Nf; ++f) tmplowerCtx[f] = prob->lowerCtx[f]; in PetscDSEnlarge_Static()
589 for (f = 0; f < Nf; ++f) tmpupperBound[f] = prob->upperBound[f]; in PetscDSEnlarge_Static()
590 for (f = 0; f < Nf; ++f) tmpupperCtx[f] = prob->upperCtx[f]; in PetscDSEnlarge_Static()
591 for (f = Nf; f < NfNew; ++f) tmpexactSol[f] = NULL; in PetscDSEnlarge_Static()
592 for (f = Nf; f < NfNew; ++f) tmpexactCtx[f] = NULL; in PetscDSEnlarge_Static()
593 for (f = Nf; f < NfNew; ++f) tmpexactSol_t[f] = NULL; in PetscDSEnlarge_Static()
594 for (f = Nf; f < NfNew; ++f) tmpexactCtx_t[f] = NULL; in PetscDSEnlarge_Static()
595 for (f = Nf; f < NfNew; ++f) tmplowerBound[f] = NULL; in PetscDSEnlarge_Static()
596 for (f = Nf; f < NfNew; ++f) tmplowerCtx[f] = NULL; in PetscDSEnlarge_Static()
597 for (f = Nf; f < NfNew; ++f) tmpupperBound[f] = NULL; in PetscDSEnlarge_Static()
598 for (f = Nf; f < NfNew; ++f) tmpupperCtx[f] = NULL; in PetscDSEnlarge_Static()
626 PetscInt f; in PetscDSDestroy() local
645 for (f = 0; f < (*ds)->Nf; ++f) PetscCall(PetscObjectDereference((*ds)->disc[f])); in PetscDSDestroy()
896 PetscInt f; in PetscDSGetNumCohesive() local
902 for (f = 0; f < ds->Nf; ++f) *numCohesive += ds->cohesive[f] ? 1 : 0; in PetscDSGetNumCohesive()
922 PetscErrorCode PetscDSGetCohesive(PetscDS ds, PetscInt f, PetscBool *isCohesive) in PetscDSGetCohesive() argument
927 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetCohesive()
928 *isCohesive = ds->cohesive[f]; in PetscDSGetCohesive()
946 PetscErrorCode PetscDSSetCohesive(PetscDS ds, PetscInt f, PetscBool isCohesive) in PetscDSSetCohesive() argument
952 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSSetCohesive()
953 ds->cohesive[f] = isCohesive; in PetscDSSetCohesive()
955 …for (i = 0; i < ds->Nf; ++i) ds->isCohesive = ds->isCohesive || ds->cohesive[f] ? PETSC_TRUE : PET… in PetscDSSetCohesive()
1025 PetscErrorCode PetscDSGetDiscretization(PetscDS prob, PetscInt f, PetscObject *disc) in PetscDSGetDiscretization() argument
1030 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetDiscretization()
1031 *disc = prob->disc[f]; in PetscDSGetDiscretization()
1049 PetscErrorCode PetscDSSetDiscretization(PetscDS prob, PetscInt f, PetscObject disc) in PetscDSSetDiscretization() argument
1054 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetDiscretization()
1055 PetscCall(PetscDSEnlarge_Static(prob, f + 1)); in PetscDSSetDiscretization()
1056 PetscCall(PetscObjectDereference(prob->disc[f])); in PetscDSSetDiscretization()
1057 prob->disc[f] = disc; in PetscDSSetDiscretization()
1064 PetscCall(PetscDSSetImplicit(prob, f, PETSC_TRUE)); in PetscDSSetDiscretization()
1066 PetscCall(PetscDSSetImplicit(prob, f, PETSC_FALSE)); in PetscDSSetDiscretization()
1068 PetscCall(PetscDSSetJetDegree(prob, f, 1)); in PetscDSSetDiscretization()
1189 PetscErrorCode PetscDSGetImplicit(PetscDS prob, PetscInt f, PetscBool *implicit) in PetscDSGetImplicit() argument
1194 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetImplicit()
1195 *implicit = prob->implicit[f]; in PetscDSGetImplicit()
1213 PetscErrorCode PetscDSSetImplicit(PetscDS prob, PetscInt f, PetscBool implicit) in PetscDSSetImplicit() argument
1217 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSSetImplicit()
1218 prob->implicit[f] = implicit; in PetscDSSetImplicit()
1238 PetscErrorCode PetscDSGetJetDegree(PetscDS ds, PetscInt f, PetscInt *k) in PetscDSGetJetDegree() argument
1243 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetJetDegree()
1244 *k = ds->jetDegree[f]; in PetscDSGetJetDegree()
1262 PetscErrorCode PetscDSSetJetDegree(PetscDS ds, PetscInt f, PetscInt k) in PetscDSSetJetDegree() argument
1266 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSSetJetDegree()
1267 ds->jetDegree[f] = k; in PetscDSSetJetDegree()
1290 PetscErrorCode PetscDSGetObjective(PetscDS ds, PetscInt f, PetscPointFn **obj) in PetscDSGetObjective() argument
1298 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetObjective()
1299 PetscCall(PetscWeakFormGetObjective(ds->wf, NULL, 0, f, 0, &n, &tmp)); in PetscDSGetObjective()
1321 PetscErrorCode PetscDSSetObjective(PetscDS ds, PetscInt f, PetscPointFn *obj) in PetscDSSetObjective() argument
1326 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetObjective()
1327 PetscCall(PetscWeakFormSetIndexObjective(ds->wf, NULL, 0, f, 0, 0, obj)); in PetscDSSetObjective()
1351 PetscErrorCode PetscDSGetResidual(PetscDS ds, PetscInt f, PetscPointFn **f0, PetscPointFn **f1) in PetscDSGetResidual() argument
1358 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetResidual()
1359 PetscCall(PetscWeakFormGetResidual(ds->wf, NULL, 0, f, 0, &n0, &tmp0, &n1, &tmp1)); in PetscDSGetResidual()
1383 PetscErrorCode PetscDSSetResidual(PetscDS ds, PetscInt f, PetscPointFn *f0, PetscPointFn *f1) in PetscDSSetResidual() argument
1389 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetResidual()
1390 PetscCall(PetscWeakFormSetIndexResidual(ds->wf, NULL, 0, f, 0, 0, f0, 0, f1)); in PetscDSSetResidual()
1414 PetscErrorCode PetscDSGetRHSResidual(PetscDS ds, PetscInt f, PetscPointFn **f0, PetscPointFn **f1) in PetscDSGetRHSResidual() argument
1421 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetRHSResidual()
1422 PetscCall(PetscWeakFormGetResidual(ds->wf, NULL, 0, f, 100, &n0, &tmp0, &n1, &tmp1)); in PetscDSGetRHSResidual()
1446 PetscErrorCode PetscDSSetRHSResidual(PetscDS ds, PetscInt f, PetscPointFn *f0, PetscPointFn *f1) in PetscDSSetRHSResidual() argument
1452 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetRHSResidual()
1453 PetscCall(PetscWeakFormSetIndexResidual(ds->wf, NULL, 0, f, 100, 0, f0, 0, f1)); in PetscDSSetRHSResidual()
1508 PetscErrorCode PetscDSGetJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn **g0, PetscPo… in PetscDSGetJacobian() argument
1515 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetJacobian()
1517 …PetscCall(PetscWeakFormGetJacobian(ds->wf, NULL, 0, f, g, 0, &n0, &tmp0, &n1, &tmp1, &n2, &tmp2, &… in PetscDSGetJacobian()
1551 PetscErrorCode PetscDSSetJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn *g0, PetscPoi… in PetscDSSetJacobian() argument
1559 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetJacobian()
1561 PetscCall(PetscWeakFormSetIndexJacobian(ds->wf, NULL, 0, f, g, 0, 0, g0, 0, g1, 0, g2, 0, g3)); in PetscDSSetJacobian()
1646 PetscErrorCode PetscDSGetJacobianPreconditioner(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn… in PetscDSGetJacobianPreconditioner() argument
1653 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetJacobianPreconditioner()
1655 …PetscCall(PetscWeakFormGetJacobianPreconditioner(ds->wf, NULL, 0, f, g, 0, &n0, &tmp0, &n1, &tmp1,… in PetscDSGetJacobianPreconditioner()
1693 PetscErrorCode PetscDSSetJacobianPreconditioner(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn… in PetscDSSetJacobianPreconditioner() argument
1701 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetJacobianPreconditioner()
1703 …PetscCall(PetscWeakFormSetIndexJacobianPreconditioner(ds->wf, NULL, 0, f, g, 0, 0, g0, 0, g1, 0, g… in PetscDSSetJacobianPreconditioner()
1758 PetscErrorCode PetscDSGetDynamicJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn **g0, … in PetscDSGetDynamicJacobian() argument
1765 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetDynamicJacobian()
1767 …PetscCall(PetscWeakFormGetDynamicJacobian(ds->wf, NULL, 0, f, g, 0, &n0, &tmp0, &n1, &tmp1, &n2, &… in PetscDSGetDynamicJacobian()
1801 PetscErrorCode PetscDSSetDynamicJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscPointJacFn *g0, P… in PetscDSSetDynamicJacobian() argument
1809 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetDynamicJacobian()
1811 …PetscCall(PetscWeakFormSetIndexDynamicJacobian(ds->wf, NULL, 0, f, g, 0, 0, g0, 0, g1, 0, g2, 0, g… in PetscDSSetDynamicJacobian()
1831 PetscErrorCode PetscDSGetRiemannSolver(PetscDS ds, PetscInt f, PetscRiemannFn **r) in PetscDSGetRiemannSolver() argument
1839 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetRiemannSolver()
1840 PetscCall(PetscWeakFormGetRiemannSolver(ds->wf, NULL, 0, f, 0, &n, &tmp)); in PetscDSGetRiemannSolver()
1859 PetscErrorCode PetscDSSetRiemannSolver(PetscDS ds, PetscInt f, PetscRiemannFn *r) in PetscDSSetRiemannSolver() argument
1864 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetRiemannSolver()
1865 PetscCall(PetscWeakFormSetIndexRiemannSolver(ds->wf, NULL, 0, f, 0, 0, r)); in PetscDSSetRiemannSolver()
1885 PetscErrorCode PetscDSGetUpdate(PetscDS ds, PetscInt f, PetscPointFn **update) in PetscDSGetUpdate() argument
1889 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetUpdate()
1892 *update = ds->update[f]; in PetscDSGetUpdate()
1911 PetscErrorCode PetscDSSetUpdate(PetscDS ds, PetscInt f, PetscPointFn *update) in PetscDSSetUpdate() argument
1916 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetUpdate()
1917 PetscCall(PetscDSEnlarge_Static(ds, f + 1)); in PetscDSSetUpdate()
1918 ds->update[f] = update; in PetscDSSetUpdate()
1942 PetscErrorCode PetscDSGetContext(PetscDS ds, PetscInt f, PetscCtxRt ctx) in PetscDSGetContext() argument
1946 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetContext()
1948 *(void **)ctx = ds->ctx[f]; in PetscDSGetContext()
1966 PetscErrorCode PetscDSSetContext(PetscDS ds, PetscInt f, PetscCtx ctx) in PetscDSSetContext() argument
1970 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetContext()
1971 PetscCall(PetscDSEnlarge_Static(ds, f + 1)); in PetscDSSetContext()
1972 ds->ctx[f] = ctx; in PetscDSSetContext()
2000 PetscErrorCode PetscDSGetBdResidual(PetscDS ds, PetscInt f, PetscBdPointFn **f0, PetscBdPointFn **f… in PetscDSGetBdResidual() argument
2007 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetBdResidual()
2008 PetscCall(PetscWeakFormGetBdResidual(ds->wf, NULL, 0, f, 0, &n0, &tmp0, &n1, &tmp1)); in PetscDSGetBdResidual()
2036 PetscErrorCode PetscDSSetBdResidual(PetscDS ds, PetscInt f, PetscBdPointFn *f0, PetscBdPointFn *f1) in PetscDSSetBdResidual() argument
2040 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetBdResidual()
2041 PetscCall(PetscWeakFormSetIndexBdResidual(ds->wf, NULL, 0, f, 0, 0, f0, 0, f1)); in PetscDSSetBdResidual()
2097 PetscErrorCode PetscDSGetBdJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscBdPointJacFn **g0, Pet… in PetscDSGetBdJacobian() argument
2104 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetBdJacobian()
2106 …PetscCall(PetscWeakFormGetBdJacobian(ds->wf, NULL, 0, f, g, 0, &n0, &tmp0, &n1, &tmp1, &n2, &tmp2,… in PetscDSGetBdJacobian()
2140 PetscErrorCode PetscDSSetBdJacobian(PetscDS ds, PetscInt f, PetscInt g, PetscBdPointJacFn *g0, Pets… in PetscDSSetBdJacobian() argument
2148 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetBdJacobian()
2150 PetscCall(PetscWeakFormSetIndexBdJacobian(ds->wf, NULL, 0, f, g, 0, 0, g0, 0, g1, 0, g2, 0, g3)); in PetscDSSetBdJacobian()
2213 PetscErrorCode PetscDSGetBdJacobianPreconditioner(PetscDS ds, PetscInt f, PetscInt g, PetscBdPointJ… in PetscDSGetBdJacobianPreconditioner() argument
2220 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetBdJacobianPreconditioner()
2222 …PetscCall(PetscWeakFormGetBdJacobianPreconditioner(ds->wf, NULL, 0, f, g, 0, &n0, &tmp0, &n1, &tmp… in PetscDSGetBdJacobianPreconditioner()
2260 PetscErrorCode PetscDSSetBdJacobianPreconditioner(PetscDS ds, PetscInt f, PetscInt g, PetscBdPointJ… in PetscDSSetBdJacobianPreconditioner() argument
2268 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetBdJacobianPreconditioner()
2270 …PetscCall(PetscWeakFormSetIndexBdJacobianPreconditioner(ds->wf, NULL, 0, f, g, 0, 0, g0, 0, g1, 0,… in PetscDSSetBdJacobianPreconditioner()
2291 PetscErrorCode PetscDSGetExactSolution(PetscDS prob, PetscInt f, PetscPointExactSolutionFn **sol, v… in PetscDSGetExactSolution() argument
2295 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetExactSolution()
2298 *sol = prob->exactSol[f]; in PetscDSGetExactSolution()
2302 *ctx = prob->exactCtx[f]; in PetscDSGetExactSolution()
2322 PetscErrorCode PetscDSSetExactSolution(PetscDS prob, PetscInt f, PetscPointExactSolutionFn *sol, Pe… in PetscDSSetExactSolution() argument
2326 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetExactSolution()
2327 PetscCall(PetscDSEnlarge_Static(prob, f + 1)); in PetscDSSetExactSolution()
2330 prob->exactSol[f] = sol; in PetscDSSetExactSolution()
2334 prob->exactCtx[f] = ctx; in PetscDSSetExactSolution()
2356 PetscErrorCode PetscDSGetExactSolutionTimeDerivative(PetscDS prob, PetscInt f, PetscPointExactSolut… in PetscDSGetExactSolutionTimeDerivative() argument
2360 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetExactSolutionTimeDerivative()
2363 *sol = prob->exactSol_t[f]; in PetscDSGetExactSolutionTimeDerivative()
2367 *ctx = prob->exactCtx_t[f]; in PetscDSGetExactSolutionTimeDerivative()
2387 PetscErrorCode PetscDSSetExactSolutionTimeDerivative(PetscDS prob, PetscInt f, PetscPointExactSolut… in PetscDSSetExactSolutionTimeDerivative() argument
2391 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetExactSolutionTimeDerivative()
2392 PetscCall(PetscDSEnlarge_Static(prob, f + 1)); in PetscDSSetExactSolutionTimeDerivative()
2395 prob->exactSol_t[f] = sol; in PetscDSSetExactSolutionTimeDerivative()
2399 prob->exactCtx_t[f] = ctx; in PetscDSSetExactSolutionTimeDerivative()
2421 PetscErrorCode PetscDSGetLowerBound(PetscDS ds, PetscInt f, PetscPointBoundFn **lb, void **ctx) in PetscDSGetLowerBound() argument
2425 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetLowerBound()
2428 *lb = ds->lowerBound[f]; in PetscDSGetLowerBound()
2432 *ctx = ds->lowerCtx[f]; in PetscDSGetLowerBound()
2452 PetscErrorCode PetscDSSetLowerBound(PetscDS ds, PetscInt f, PetscPointBoundFn *lb, PetscCtx ctx) in PetscDSSetLowerBound() argument
2456 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetLowerBound()
2457 PetscCall(PetscDSEnlarge_Static(ds, f + 1)); in PetscDSSetLowerBound()
2460 ds->lowerBound[f] = lb; in PetscDSSetLowerBound()
2464 ds->lowerCtx[f] = ctx; in PetscDSSetLowerBound()
2486 PetscErrorCode PetscDSGetUpperBound(PetscDS ds, PetscInt f, PetscPointBoundFn **ub, void **ctx) in PetscDSGetUpperBound() argument
2490 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetUpperBound()
2493 *ub = ds->upperBound[f]; in PetscDSGetUpperBound()
2497 *ctx = ds->upperCtx[f]; in PetscDSGetUpperBound()
2517 PetscErrorCode PetscDSSetUpperBound(PetscDS ds, PetscInt f, PetscPointBoundFn *ub, PetscCtx ctx) in PetscDSSetUpperBound() argument
2521 …PetscCheck(f >= 0, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" PetscInt_FMT " must… in PetscDSSetUpperBound()
2522 PetscCall(PetscDSEnlarge_Static(ds, f + 1)); in PetscDSSetUpperBound()
2525 ds->upperBound[f] = ub; in PetscDSSetUpperBound()
2529 ds->upperCtx[f] = ctx; in PetscDSSetUpperBound()
2655 PetscErrorCode PetscDSGetFieldIndex(PetscDS prob, PetscObject disc, PetscInt *f) in PetscDSGetFieldIndex() argument
2661 PetscAssertPointer(f, 3); in PetscDSGetFieldIndex()
2662 *f = -1; in PetscDSGetFieldIndex()
2667 *f = g; in PetscDSGetFieldIndex()
2687 PetscErrorCode PetscDSGetFieldSize(PetscDS prob, PetscInt f, PetscInt *size) in PetscDSGetFieldSize() argument
2692 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetFieldSize()
2694 *size = prob->Nb[f]; in PetscDSGetFieldSize()
2714 PetscErrorCode PetscDSGetFieldOffset(PetscDS prob, PetscInt f, PetscInt *off) in PetscDSGetFieldOffset() argument
2721 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetFieldOffset()
2723 for (g = 0; g < f; ++g) { in PetscDSGetFieldOffset()
2746 PetscErrorCode PetscDSGetFieldOffsetCohesive(PetscDS ds, PetscInt f, PetscInt *off) in PetscDSGetFieldOffsetCohesive() argument
2753 …heck(!(f < 0) && !(f >= ds->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Petsc… in PetscDSGetFieldOffsetCohesive()
2755 for (g = 0; g < f; ++g) { in PetscDSGetFieldOffsetCohesive()
2831 PetscErrorCode PetscDSGetComponentOffset(PetscDS prob, PetscInt f, PetscInt *off) in PetscDSGetComponentOffset() argument
2836 …eck(!(f < 0) && !(f >= prob->Nf), PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "Field number %" Pets… in PetscDSGetComponentOffset()
2838 *off = prob->off[f]; in PetscDSGetComponentOffset()
3624 PetscInt f; in PetscDSCopyBoundary() local
3626 for (f = 0; f < numFields; ++f) in PetscDSCopyBoundary()
3627 if (b->field == fields[f]) break; in PetscDSCopyBoundary()
3628 if (f == numFields) continue; in PetscDSCopyBoundary()
3629 fieldNew = f; in PetscDSCopyBoundary()
3701 const PetscInt f = fields ? fields[fn] : fn; in PetscDSSelectDiscretizations() local
3705 if (f >= Nf) continue; in PetscDSSelectDiscretizations()
3706 PetscCall(PetscDSGetDiscretization(prob, f, &disc)); in PetscDSSelectDiscretizations()
3750 const PetscInt f = fields ? fields[fn] : fn; in PetscDSSelectEquations() local
3756 if (f >= Nf) continue; in PetscDSSelectEquations()
3757 PetscCall(PetscDSGetObjective(prob, f, &obj)); in PetscDSSelectEquations()
3758 PetscCall(PetscDSGetResidual(prob, f, &f0, &f1)); in PetscDSSelectEquations()
3759 PetscCall(PetscDSGetBdResidual(prob, f, &f0Bd, &f1Bd)); in PetscDSSelectEquations()
3760 PetscCall(PetscDSGetRiemannSolver(prob, f, &r)); in PetscDSSelectEquations()
3772 PetscCall(PetscDSGetJacobian(prob, f, g, &g0, &g1, &g2, &g3)); in PetscDSSelectEquations()
3773 PetscCall(PetscDSGetJacobianPreconditioner(prob, f, g, &g0p, &g1p, &g2p, &g3p)); in PetscDSSelectEquations()
3774 PetscCall(PetscDSGetBdJacobian(prob, f, g, &g0Bd, &g1Bd, &g2Bd, &g3Bd)); in PetscDSSelectEquations()
3862 PetscInt Nf, f; in PetscDSCopyExactSolutions() local
3868 for (f = 0; f < Nf; ++f) { in PetscDSCopyExactSolutions()
3869 PetscCall(PetscDSGetExactSolution(ds, f, &sol, &ctx)); in PetscDSCopyExactSolutions()
3870 PetscCall(PetscDSSetExactSolution(newds, f, sol, ctx)); in PetscDSCopyExactSolutions()
3871 PetscCall(PetscDSGetExactSolutionTimeDerivative(ds, f, &sol, &ctx)); in PetscDSCopyExactSolutions()
3872 PetscCall(PetscDSSetExactSolutionTimeDerivative(newds, f, sol, ctx)); in PetscDSCopyExactSolutions()
3896 PetscInt Nf, f; in PetscDSCopyBounds() local
3902 for (f = 0; f < Nf; ++f) { in PetscDSCopyBounds()
3903 PetscCall(PetscDSGetLowerBound(ds, f, &bound, &ctx)); in PetscDSCopyBounds()
3904 PetscCall(PetscDSSetLowerBound(newds, f, bound, ctx)); in PetscDSCopyBounds()
3905 PetscCall(PetscDSGetUpperBound(ds, f, &bound, &ctx)); in PetscDSCopyBounds()
3906 PetscCall(PetscDSSetUpperBound(newds, f, bound, ctx)); in PetscDSCopyBounds()
3914 PetscInt cdim, Nf, f, d; in PetscDSCopy() local
3925 for (f = 0; f < Nf; ++f) { in PetscDSCopy()
3926 PetscCall(PetscDSGetContext(ds, f, &ctx)); in PetscDSCopy()
3927 PetscCall(PetscDSSetContext(dsNew, f, ctx)); in PetscDSCopy()
3928 PetscCall(PetscDSGetCohesive(ds, f, &isCohesive)); in PetscDSCopy()
3929 PetscCall(PetscDSSetCohesive(dsNew, f, isCohesive)); in PetscDSCopy()
3930 PetscCall(PetscDSGetJetDegree(ds, f, &d)); in PetscDSCopy()
3931 PetscCall(PetscDSSetJetDegree(dsNew, f, d)); in PetscDSCopy()
3948 PetscInt dim, Nf, f; in PetscDSGetHeightSubspace() local
3967 for (f = 0; f < Nf; ++f) { in PetscDSGetHeightSubspace()
3972 PetscCall(PetscDSGetDiscretization(prob, f, &obj)); in PetscDSGetHeightSubspace()
3974 …cObject)prob), PETSC_ERR_ARG_WRONG, "Unsupported discretization type for field %" PetscInt_FMT, f); in PetscDSGetHeightSubspace()
3976 PetscCall(PetscDSSetDiscretization(prob->subprobs[height - 1], f, (PetscObject)subfe)); in PetscDSGetHeightSubspace()
4006 PetscErrorCode PetscDSGetDiscType_Internal(PetscDS ds, PetscInt f, PetscDiscType *disctype) in PetscDSGetDiscType_Internal() argument
4017 …PetscCheck(f < Nf, PetscObjectComm((PetscObject)ds), PETSC_ERR_ARG_SIZ, "Field %" PetscInt_FMT " m… in PetscDSGetDiscType_Internal()
4018 PetscCall(PetscDSGetDiscretization(ds, f, &obj)); in PetscDSGetDiscType_Internal()