Lines Matching refs:section
4 …ic PetscErrorCode DMPlexCreateSectionFields(DM dm, const PetscInt numComp[], PetscSection *section) in DMPlexCreateSectionFields() argument
28 PetscCall(PetscSectionCreate(PetscObjectComm((PetscObject)dm), section)); in DMPlexCreateSectionFields()
30 PetscCall(PetscSectionSetNumFields(*section, Nf)); in DMPlexCreateSectionFields()
33 PetscCall(PetscSectionSetFieldComponents(*section, f, numComp[f])); in DMPlexCreateSectionFields()
52 … PetscCall(PetscSectionSymCreateLabel(PetscObjectComm((PetscObject)*section), depthLabel, &sym)); in DMPlexCreateSectionFields()
75 PetscCall(PetscSectionSetFieldSym(*section, f, sym)); in DMPlexCreateSectionFields()
83 PetscCall(PetscSectionSetChart(*section, pStart, pEnd)); in DMPlexCreateSectionFields()
89 …rCode DMPlexCreateSectionDof(DM dm, DMLabel label[], const PetscInt numDof[], PetscSection section) in DMPlexCreateSectionDof() argument
158 PetscCall(PetscSectionSetFieldDof(section, point, f, dof)); in DMPlexCreateSectionDof()
159 PetscCall(PetscSectionAddDof(section, point, dof)); in DMPlexCreateSectionDof()
181 PetscCall(PetscSectionSetFieldDof(section, p, f, dof)); in DMPlexCreateSectionDof()
182 PetscCall(PetscSectionAddDof(section, p, dof)); in DMPlexCreateSectionDof()
194 …Int numBC, const PetscInt bcField[], const IS bcComps[], const IS bcPoints[], PetscSection section) in DMPlexCreateSectionBCDof() argument
201 PetscCall(PetscSectionGetNumFields(section, &Nf)); in DMPlexCreateSectionBCDof()
210 PetscCall(PetscSectionGetFieldComponents(section, field, &Nc)); in DMPlexCreateSectionBCDof()
222 PetscCall(PetscSectionGetFieldDof(section, p, field, &numConst)); in DMPlexCreateSectionBCDof()
224 PetscCall(PetscSectionGetDof(section, p, &numConst)); in DMPlexCreateSectionBCDof()
237 if (Nf) PetscCall(PetscSectionAddFieldConstraintDof(section, p, field, numConst)); in DMPlexCreateSectionBCDof()
238 PetscCall(PetscSectionAddConstraintDof(section, p, numConst)); in DMPlexCreateSectionBCDof()
255 PetscCall(PetscSectionGetDof(section, a, &dof)); in DMPlexCreateSectionBCDof()
256 PetscCall(PetscSectionSetConstraintDof(section, a, dof)); in DMPlexCreateSectionBCDof()
258 PetscCall(PetscSectionGetFieldDof(section, a, f, &dof)); in DMPlexCreateSectionBCDof()
259 PetscCall(PetscSectionSetFieldConstraintDof(section, a, f, dof)); in DMPlexCreateSectionBCDof()
270 …Int numBC, const PetscInt bcField[], const IS bcComps[], const IS bcPoints[], PetscSection section) in DMPlexCreateSectionBCIndicesField() argument
277 PetscCall(PetscSectionGetNumFields(section, &Nf)); in DMPlexCreateSectionBCIndicesField()
280 PetscCall(PetscSectionGetChart(section, &pStart, &pEnd)); in DMPlexCreateSectionBCIndicesField()
282 PetscCall(PetscSectionGetConstraintDof(section, p, &cdof)); in DMPlexCreateSectionBCIndicesField()
288 … for (f = 0; f < Nf; ++f) PetscCall(PetscSectionSetFieldConstraintIndices(section, p, f, indices)); in DMPlexCreateSectionBCIndicesField()
295 PetscCall(PetscSectionGetFieldComponents(section, field, &Nc)); in DMPlexCreateSectionBCIndicesField()
306 PetscCall(PetscSectionGetFieldDof(section, p, field, &fdof)); in DMPlexCreateSectionBCIndicesField()
314 PetscCall(PetscSectionGetFieldConstraintDof(section, p, field, &fcdof)); in DMPlexCreateSectionBCIndicesField()
315 PetscCall(PetscSectionGetFieldConstraintIndices(section, p, field, &find)); in DMPlexCreateSectionBCIndicesField()
327 PetscCall(PetscSectionSetFieldConstraintDof(section, p, field, fcdof)); in DMPlexCreateSectionBCIndicesField()
328 PetscCall(PetscSectionSetFieldConstraintIndices(section, p, field, indices)); in DMPlexCreateSectionBCIndicesField()
347 … for (f = 0; f < Nf; f++) PetscCall(PetscSectionSetFieldConstraintIndices(section, a, f, indices)); in DMPlexCreateSectionBCIndicesField()
356 static PetscErrorCode DMPlexCreateSectionBCIndices(DM dm, PetscSection section) in DMPlexCreateSectionBCIndices() argument
362 PetscCall(PetscSectionGetNumFields(section, &Nf)); in DMPlexCreateSectionBCIndices()
363 PetscCall(PetscSectionGetMaxDof(section, &maxDof)); in DMPlexCreateSectionBCIndices()
364 PetscCall(PetscSectionGetChart(section, &pStart, &pEnd)); in DMPlexCreateSectionBCIndices()
370 PetscCall(PetscSectionGetConstraintDof(section, p, &cdof)); in DMPlexCreateSectionBCIndices()
379 PetscCall(PetscSectionGetFieldDof(section, p, f, &fdof)); in DMPlexCreateSectionBCIndices()
380 PetscCall(PetscSectionGetFieldConstraintDof(section, p, f, &fcdof)); in DMPlexCreateSectionBCIndices()
382 PetscCall(PetscSectionGetFieldConstraintIndices(section, p, f, &find)); in DMPlexCreateSectionBCIndices()
387 if (cdof != numConst) PetscCall(PetscSectionSetConstraintDof(section, p, numConst)); in DMPlexCreateSectionBCIndices()
391 PetscCall(PetscSectionSetConstraintIndices(section, p, indices)); in DMPlexCreateSectionBCIndices()
427 … const PetscInt bcField[], const IS bcComps[], const IS bcPoints[], IS perm, PetscSection *section) in DMPlexCreateSection() argument
432 PetscCall(DMPlexCreateSectionFields(dm, numComp, section)); in DMPlexCreateSection()
433 PetscCall(DMPlexCreateSectionDof(dm, label, numDof, *section)); in DMPlexCreateSection()
434 PetscCall(DMPlexCreateSectionBCDof(dm, numBC, bcField, bcComps, bcPoints, *section)); in DMPlexCreateSection()
435 if (perm) PetscCall(PetscSectionSetPermutation(*section, perm)); in DMPlexCreateSection()
436 PetscCall(PetscSectionSetFromOptions(*section)); in DMPlexCreateSection()
437 PetscCall(PetscSectionSetUp(*section)); in DMPlexCreateSection()
440 PetscCall(DMPlexCreateSectionBCIndicesField(dm, numBC, bcField, bcComps, bcPoints, *section)); in DMPlexCreateSection()
441 PetscCall(DMPlexCreateSectionBCIndices(dm, *section)); in DMPlexCreateSection()
443 PetscCall(PetscSectionViewFromOptions(*section, NULL, "-section_view")); in DMPlexCreateSection()
449 PetscSection section; in DMCreateLocalSection_Plex() local
612 …xCreateSection(dm, labels, numComp, numDof, numBC, bcFields, bcComps, bcPoints, permIS, §ion)); in DMCreateLocalSection_Plex()
613 section->blockStarts = blockStarts; in DMCreateLocalSection_Plex()
622 PetscCall(PetscSectionSetFieldName(section, f, name)); in DMCreateLocalSection_Plex()
624 PetscCall(DMSetLocalSection(dm, section)); in DMCreateLocalSection_Plex()
625 PetscCall(PetscSectionDestroy(§ion)); in DMCreateLocalSection_Plex()