:orphan:
# MATSCALAPACK
"scalapack" - A matrix type for dense matrices using the ScaLAPACK package Use `./configure --download-scalapack` to install PETSc to use ScaLAPACK


## Options Database Keys

- ***-mat_type scalapack -*** sets the matrix type to `MATSCALAPACK`
- ***-pc_factor_mat_solver_type scalapack -*** to use this direct solver with the option `-pc_type lu`
- ***-mat_scalapack_grid_height -*** sets Grid Height for 2D cyclic ordering of internal matrix
- ***-mat_scalapack_block_sizes -*** size of the blocks to use (one or two integers separated by comma)





## Note
Note unlike most matrix formats, this format does not store all the matrix entries for a contiguous
range of rows on an MPI rank. Use `MatGetOwnershipIS()` to determine what values are stored on
the given rank.


## See Also
 [](ch_matrices), `Mat`, `MATSCALAPACK`, `MATDENSE`, `MATELEMENTAL`, `MatGetOwnershipIS()`, `MatCreateScaLAPACK()`

## Level
intermediate

## Location
<A HREF="PETSC_DOC_OUT_ROOT_PLACEHOLDER/src/mat/impls/scalapack/matscalapack.c.html#MATSCALAPACK">src/mat/impls/scalapack/matscalapack.c</A>


---
[Edit on GitLab](https://gitlab.com/petsc/petsc/-/edit/release/src/mat/impls/scalapack/matscalapack.c)


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