# PETScBaseMatrix¶

class dolfin.cpp.la.PETScBaseMatrix(*args, **kwargs)

This class is a base class for matrices that can be used in PETScKrylovSolver.

init_vector()

Initialize vector to be compatible with the matrix-vector product y = Ax. In the parallel case, both size and layout are important.

Arguments
dim (int)
The dimension (axis): dim = 0 –> z = y, dim = 1 –> z = x
local_range()

Return local range along dimension dim

mat()

Return petsc4py representation of PETSc Mat

mpi_comm()

Return the MPI communicator

size()

thisown