# MatH2OpusMapVec
Maps a vector between PETSc and H2Opus ordering 
## Synopsis
```
PetscErrorCode MatH2OpusMapVec(Mat A, PetscBool nativetopetsc, Vec in, Vec *out)
```

## Input Parameters

- ***A -*** the matrix
- ***nativetopetsc -*** if true, maps from H2Opus ordering to PETSc ordering. If false, applies the reverse map
- ***in -*** the vector to be mapped



## Output Parameter

- ***out -*** the newly created mapped vector





## See Also
 `MatCreate()`, `MATH2OPUS`, `MatCreateH2OpusFromMat()`, `MatCreateH2OpusFromKernel()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/h2opus/cuda/math2opus.cu.html#MatH2OpusMapVec">src/mat/impls/h2opus/cuda/math2opus.cu</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/impls/h2opus/cuda/math2opus.cu)


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