Lines Matching refs:field
56 (*s)->field = NULL; in PetscSectionCreate()
390 PetscCall(PetscMalloc1(s->numFields, &s->field)); in PetscSectionSetNumFields()
396 PetscCall(PetscSectionCreate(PetscObjectComm((PetscObject)s), &s->field[f])); in PetscSectionSetNumFields()
425 PetscErrorCode PetscSectionGetFieldName(PetscSection s, PetscInt field, const char *fieldName[]) in PetscSectionGetFieldName() argument
430 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldName()
431 *fieldName = s->fieldNames[field]; in PetscSectionGetFieldName()
452 PetscErrorCode PetscSectionSetFieldName(PetscSection s, PetscInt field, const char fieldName[]) in PetscSectionSetFieldName() argument
457 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldName()
458 PetscCall(PetscFree(s->fieldNames[field])); in PetscSectionSetFieldName()
459 PetscCall(PetscStrallocpy(fieldName, &s->fieldNames[field])); in PetscSectionSetFieldName()
487 PetscErrorCode PetscSectionGetComponentName(PetscSection s, PetscInt field, PetscInt comp, const ch… in PetscSectionGetComponentName() argument
492 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetComponentName()
493 PetscSectionCheckValidFieldComponent(comp, s->numFieldComponents[field]); in PetscSectionGetComponentName()
494 *compName = s->compNames[field][comp]; in PetscSectionGetComponentName()
520 PetscErrorCode PetscSectionSetComponentName(PetscSection s, PetscInt field, PetscInt comp, const ch… in PetscSectionSetComponentName() argument
525 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetComponentName()
526 PetscSectionCheckValidFieldComponent(comp, s->numFieldComponents[field]); in PetscSectionSetComponentName()
527 PetscCall(PetscFree(s->compNames[field][comp])); in PetscSectionSetComponentName()
528 PetscCall(PetscStrallocpy(compName, &s->compNames[field][comp])); in PetscSectionSetComponentName()
552 PetscErrorCode PetscSectionGetFieldComponents(PetscSection s, PetscInt field, PetscInt *numComp) in PetscSectionGetFieldComponents() argument
557 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldComponents()
558 *numComp = s->numFieldComponents[field]; in PetscSectionGetFieldComponents()
588 PetscErrorCode PetscSectionSetFieldComponents(PetscSection s, PetscInt field, PetscInt numComp) in PetscSectionSetFieldComponents() argument
594 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldComponents()
596 for (c = 0; c < s->numFieldComponents[field]; ++c) PetscCall(PetscFree(s->compNames[field][c])); in PetscSectionSetFieldComponents()
597 PetscCall(PetscFree(s->compNames[field])); in PetscSectionSetFieldComponents()
600 s->numFieldComponents[field] = numComp; in PetscSectionSetFieldComponents()
602 PetscCall(PetscMalloc1(numComp, &s->compNames[field])); in PetscSectionSetFieldComponents()
607 PetscCall(PetscStrallocpy(name, &s->compNames[field][c])); in PetscSectionSetFieldComponents()
684 for (f = 0; f < s->numFields; ++f) PetscCall(PetscSectionSetChart(s->field[f], pStart, pEnd)); in PetscSectionSetChart()
1023 PetscErrorCode PetscSectionGetFieldDof(PetscSection s, PetscInt point, PetscInt field, PetscInt *nu… in PetscSectionGetFieldDof() argument
1028 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldDof()
1029 PetscCall(PetscSectionGetDof(s->field[field], point, numDof)); in PetscSectionGetFieldDof()
1059 PetscErrorCode PetscSectionSetFieldDof(PetscSection s, PetscInt point, PetscInt field, PetscInt num… in PetscSectionSetFieldDof() argument
1063 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldDof()
1064 PetscCall(PetscSectionSetDof(s->field[field], point, numDof)); in PetscSectionSetFieldDof()
1094 PetscErrorCode PetscSectionAddFieldDof(PetscSection s, PetscInt point, PetscInt field, PetscInt num… in PetscSectionAddFieldDof() argument
1098 PetscSectionCheckValidField(field, s->numFields); in PetscSectionAddFieldDof()
1099 PetscCall(PetscSectionAddDof(s->field[field], point, numDof)); in PetscSectionAddFieldDof()
1196 PetscErrorCode PetscSectionGetFieldConstraintDof(PetscSection s, PetscInt point, PetscInt field, Pe… in PetscSectionGetFieldConstraintDof() argument
1201 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldConstraintDof()
1202 PetscCall(PetscSectionGetConstraintDof(s->field[field], point, numDof)); in PetscSectionGetFieldConstraintDof()
1221 PetscErrorCode PetscSectionSetFieldConstraintDof(PetscSection s, PetscInt point, PetscInt field, Pe… in PetscSectionSetFieldConstraintDof() argument
1225 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldConstraintDof()
1226 PetscCall(PetscSectionSetConstraintDof(s->field[field], point, numDof)); in PetscSectionSetFieldConstraintDof()
1245 PetscErrorCode PetscSectionAddFieldConstraintDof(PetscSection s, PetscInt point, PetscInt field, Pe… in PetscSectionAddFieldConstraintDof() argument
1249 PetscSectionCheckValidField(field, s->numFields); in PetscSectionAddFieldConstraintDof()
1250 PetscCall(PetscSectionAddConstraintDof(s->field[field], point, numDof)); in PetscSectionAddFieldConstraintDof()
1321 PetscSection sf = s->field[f]; in PetscSectionSetUp()
1330 PetscSection sf = s->field[f]; in PetscSectionSetUp()
1345 for (f = 0; f < s->numFields; ++f) PetscCall(PetscSectionSetUpBC(s->field[f])); in PetscSectionSetUp()
1562 gs->field[f]->includesConstraints = includeConstraints; in PetscSectionCreateGlobalSection()
1581 PetscSection gfs = gs->field[f]; in PetscSectionCreateGlobalSection()
1584 …if (gfs->bcIndices) PetscCall(PetscArraycpy(gfs->bcIndices, s->field[f]->bcIndices, gfs->bc->atlas… in PetscSectionCreateGlobalSection()
1885 PetscErrorCode PetscSectionGetFieldOffset(PetscSection s, PetscInt point, PetscInt field, PetscInt … in PetscSectionGetFieldOffset() argument
1890 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldOffset()
1891 PetscCall(PetscSectionGetOffset(s->field[field], point, offset)); in PetscSectionGetFieldOffset()
1913 PetscErrorCode PetscSectionSetFieldOffset(PetscSection s, PetscInt point, PetscInt field, PetscInt … in PetscSectionSetFieldOffset() argument
1917 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldOffset()
1918 PetscCall(PetscSectionSetOffset(s->field[field], point, offset)); in PetscSectionSetFieldOffset()
1951 PetscErrorCode PetscSectionGetFieldPointOffset(PetscSection s, PetscInt point, PetscInt field, Pets… in PetscSectionGetFieldPointOffset() argument
1958 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldPointOffset()
1960 PetscCall(PetscSectionGetOffset(s->field[field], point, &foff)); in PetscSectionGetFieldPointOffset()
2553 PetscCall(PetscSectionView_ASCII(s->field[f], viewer)); in PetscSectionView()
2730 PetscCall(PetscSectionArrayView_ASCII_Internal(s->field[f], array, data_type, viewer)); in PetscSectionArrayView()
2783 PetscCall(PetscSectionDestroy(&s->field[f])); in PetscSectionReset()
2791 PetscCall(PetscFree(s->field)); in PetscSectionReset()
2872 PetscInt j = -1, field, i; in VecIntSetValuesSection_Private() local
2874 for (field = 0; field < s->numFields; ++field) { in VecIntSetValuesSection_Private()
2875 const PetscInt dim = s->field[field]->atlasDof[p]; in VecIntSetValuesSection_Private()
2909 PetscInt j = 0, field; in VecIntSetValuesSection_Private() local
2912 for (field = 0; field < s->numFields; ++field) { in VecIntSetValuesSection_Private()
2913 const PetscInt dim = s->field[field]->atlasDof[p]; /* PetscSectionGetFieldDof() */ in VecIntSetValuesSection_Private()
2914 … const PetscInt tDim = s->field[field]->bc->atlasDof[p]; /* PetscSectionGetFieldConstraintDof() */ in VecIntSetValuesSection_Private()
3035 PetscErrorCode PetscSectionGetFieldConstraintIndices(PetscSection s, PetscInt point, PetscInt field… in PetscSectionGetFieldConstraintIndices() argument
3040 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetFieldConstraintIndices()
3041 PetscCall(PetscSectionGetConstraintIndices(s->field[field], point, indices)); in PetscSectionGetFieldConstraintIndices()
3060 PetscErrorCode PetscSectionSetFieldConstraintIndices(PetscSection s, PetscInt point, PetscInt field… in PetscSectionSetFieldConstraintIndices() argument
3064 PetscSectionCheckValidField(field, s->numFields); in PetscSectionSetFieldConstraintIndices()
3065 PetscCall(PetscSectionSetConstraintIndices(s->field[field], point, indices)); in PetscSectionSetFieldConstraintIndices()
3405 PetscErrorCode PetscSectionGetField(PetscSection s, PetscInt field, PetscSection *subs) in PetscSectionGetField() argument
3410 PetscSectionCheckValidField(field, s->numFields); in PetscSectionGetField()
3411 *subs = s->field[field]; in PetscSectionGetField()
3650 PetscErrorCode PetscSectionSetFieldSym(PetscSection section, PetscInt field, PetscSectionSym sym) in PetscSectionSetFieldSym() argument
3654 PetscSectionCheckValidField(field, section->numFields); in PetscSectionSetFieldSym()
3655 PetscCall(PetscSectionSetSym(section->field[field], sym)); in PetscSectionSetFieldSym()
3675 PetscErrorCode PetscSectionGetFieldSym(PetscSection section, PetscInt field, PetscSectionSym *sym) in PetscSectionGetFieldSym() argument
3679 PetscSectionCheckValidField(field, section->numFields); in PetscSectionGetFieldSym()
3680 *sym = section->field[field]->sym; in PetscSectionGetFieldSym()
3862 PetscErrorCode PetscSectionGetFieldPointSyms(PetscSection section, PetscInt field, PetscInt numPoin… in PetscSectionGetFieldPointSyms() argument
3866 …field <= section->numFields, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "field %" PetscInt_FMT " g… in PetscSectionGetFieldPointSyms()
3867 PetscCall(PetscSectionGetPointSyms(section->field[field], numPoints, points, perms, rots)); in PetscSectionGetFieldPointSyms()
3890 PetscErrorCode PetscSectionRestoreFieldPointSyms(PetscSection section, PetscInt field, PetscInt num… in PetscSectionRestoreFieldPointSyms() argument
3894 …field <= section->numFields, PETSC_COMM_SELF, PETSC_ERR_ARG_OUTOFRANGE, "field %" PetscInt_FMT " g… in PetscSectionRestoreFieldPointSyms()
3895 PetscCall(PetscSectionRestorePointSyms(section->field[field], numPoints, points, perms, rots)); in PetscSectionRestoreFieldPointSyms()