MatSetBlockSize

Sets the matrix block size; for many matrix types you cannot use this and MUST set the blocksize when you preallocate the matrix

Synopsis

#include "petscmat.h" 
PetscErrorCode  MatSetBlockSize(Mat mat,PetscInt bs)
Logically Collective on Mat

Input Parameters

mat - the matrix
bs - block size

Notes

For BAIJ matrices, this just checks that the block size agrees with the BAIJ size, it is not possible to change BAIJ block sizes after preallocation.

See Also

MatCreateSeqBAIJ(), MatCreateMPIBAIJ(), MatGetBlockSize()

Level:intermediate
Location:
src/mat/interface/matrix.c
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages

Examples

src/ksp/ksp/examples/tutorials/ex55.c.html
src/ksp/ksp/examples/tutorials/ex56.c.html
src/snes/examples/tutorials/ex48.c.html