:orphan:
# PetscSectionGetOffset
Return the offset into an array or `Vec` for the dof associated with the given point. 
## Synopsis
```
#include "petscsection.h"   
PetscErrorCode PetscSectionGetOffset(PetscSection s, PetscInt point, PetscInt *offset)
```
Not Collective


## Input Parameters

- ***s -*** the `PetscSection`
- ***point -*** the point



## Output Parameter

- ***offset -*** the offset





## Notes
In a global section, this offset will be negative for points not owned by this process.

This is for the unnamed default field in the `PetscSection` not the named fields

The `offset` values are different depending on a value set with `PetscSectionSetPointMajor()`


## See Also
 [PetscSection](sec_petscsection), `PetscSection`, `PetscSectionGetFieldOffset()`, `PetscSectionCreate()`, `PetscSectionSetPointMajor()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/vec/is/section/interface/section.c.html#PetscSectionGetOffset">src/vec/is/section/interface/section.c</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/snes/tutorials/ex13.c.html">src/snes/tutorials/ex13.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/snes/tutorials/ex7.c.html">src/snes/tutorials/ex7.c</A><BR>
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/tao/tutorials/ex3.c.html">src/tao/tutorials/ex3.c</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/vec/is/section/interface/section.c)


[Index of all PetscSection routines](index.md)  
[Table of Contents for all manual pages](/manualpages/index.md)  
[Index of all manual pages](/manualpages/singleindex.md)  
