# PetscSFNode
specifier of owner and index 
## Synopsis
```
typedef struct {
  PetscInt rank;  /* Rank of owner */
  PetscInt index; /* Index of node on rank */
} PetscSFNode;
```



## Sample Usage
```none
PetscSFNode    *remote;
```
```none
PetscCall(PetscMalloc1(nleaves,&remote));
```
```none
for (i=0; i<size; i++) {
```
```none
remote[i].rank = i;
```
```none
remote[i].index = rank;
```
```none
}
```


## Sample Fortran Usage
```none
type(PetscSFNode) remote(6)
```
```none
remote(1)%rank  = modulo(rank+size-1,size)
```
```none
remote(1)%index = 1 * stride
```


## See Also
 `PetscSFSetGraph()`

## Level
beginner

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/include/petscsftypes.h.html#PetscSFNode">include/petscsftypes.h</A>

## Examples
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/vec/is/sf/tutorials/ex1f.F90.html">src/vec/is/sf/tutorials/ex1f.F90.html</A><BR>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/include/petscsftypes.h)


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