Matrices Mat: : Examples

PETSc matrices (Mat objects) are used to store Jacobians and other sparse matrices in PDE-based (or other) simulations.

Beginner - Basic usage
MATAIJ MAT_SOLVER_SUPERLU MatMultConstrained
MATAIJMUMPS MAT_SOLVER_SUPERLU_DIST MatMultTranspose
MATBAIJ MAT_SOLVER_UMFPACK MatMultTransposeAdd
MATCRL Mat MatMultTransposeConstrained
MATCSRPERM MatAssemblyBegin MatOption
MATDENSE MatAssemblyEnd MatOrderingType
MATMPIADJ MatAssemblyType MatPartitioning
MATMPIAIJ MatColoringType MatPartitioningType
MATMPIAIJSPOOLES MatCreate MatReuse
MATMPIBAIJ MatDestroy MatSORType
MATMPIROWBS MatDuplicateOption MatSetFromOptions
MATMPISBAIJ MatFDColoring MatSetSizes
MATSBAIJ MatFactorType MatSetStencil
MATSEQAIJ MatGetLocalSize MatSetUpPreallocation
MATSEQBAIJ MatGetOwnershipRange MatSetValue
MATSEQDENSE MatGetOwnershipRanges MatSetValues
MATSEQSBAIJ MatGetOwnershipRangesColumn MatSetValuesBlockedStencil
MAT_SOLVER_DSCPACK MatGetSize MatSetValuesStencil
MAT_SOLVER_ESSL MatGetSubMatrixOption MatSolverPackage
MAT_SOLVER_LUSOL MatInfoType MatStencil
MAT_SOLVER_MATLAB MatLoad MatStructure
MAT_SOLVER_MUMPS MatMFFDType MatType
MAT_SOLVER_PASTIX MatMult MatView
MAT_SOLVER_SPOOLES MatMultAdd
Intermediate - Setting options for algorithms and data structures
MATDAAD MatDuplicate MatPreallocateLocation
MATMFFD_DS MatEqual MatPreallocateSet
MATMFFD_WP MatFactorGetSolverPackage MatPreallocateSetLocal
MatAXPY MatGetBlockSize MatPreallocateSymmetricInitialize
MatAYPX MatGetDiagonal MatPreallocateSymmetricSet
MatBlockMatSetPreallocation MatGetFactor MatPreallocateSymmetricSetLocal
MatConvert MatGetFactorAvailable MatPtAP
MatCopy MatGetInfo MatPtAPNumeric
MatCreateBlockMat MatGetRowMax MatPtAPSymbolic
MatCreateDAAD MatGetRowMaxAbs MatPythonCreate
MatCreateLRC MatGetRowMin MatPythonSetType
MatCreateMPIAIJ MatGetRowMinAbs MatReorderForNonzeroDiagonal
MatCreateMPIAIJWithArrays MatGetRowSum MatRestrict
MatCreateMPIAdj MatGetSeqNonzeroStructure MatScale
MatCreateMPIBAIJ MatGetType MatScatterGetVecScatter
MatCreateMPICRL MatInfo MatSeqAIJSetPreallocation
MatCreateMPICSRPERM MatInterpolate MatSeqBAIJSetPreallocation
MatCreateMPIDense MatInterpolateAdd MatSeqDenseSetLDA
MatCreateMPIRowbs MatIsHermitian MatSeqDenseSetPreallocation
MatCreateMPISBAIJ MatIsHermitianTranspose MatSeqSBAIJSetPreallocation
MatCreateNormal MatIsStructurallySymmetric MatSetBlockSize
MatCreateScatter MatIsSymmetric MatSetLocalToGlobalMapping
MatCreateSeqAIJ MatIsTranspose MatSetLocalToGlobalMappingBlock
MatCreateSeqAIJWithArrays MatMPIAIJSetPreallocation MatSetOption
MatCreateSeqBAIJ MatMPIAdjSetPreallocation MatSetType
MatCreateSeqBAIJWithArrays MatMPIBAIJSetPreallocation MatSetValuesBlocked
MatCreateSeqCRL MatMPIDenseSetPreallocation MatSetValuesBlockedLocal
MatCreateSeqCSRPERM MatMPISBAIJSetPreallocation MatSetValuesLocal
MatCreateSeqDense MatMatMult MatSetValuesRow
MatCreateSeqFFTW MatMatMultNumeric MatSetValuesRowLocal
MatCreateSeqSBAIJ MatMatMultSymbolic MatShift
MatCreateSeqSBAIJWithArrays MatMatMultTranspose MatStashSetInitialSize
MatCreateTranspose MatMultAddEqual MatTranspose
MatDAADSetCtx MatMultEqual MatZeroEntries
MatDAADSetDA MatMultTransposeAddEqual MatZeroRows
MatDAADSetSNES MatMultTransposeEqual MatZeroRowsIS
MatDenseGetLocalMatrix MatNorm MatZeroRowsLocal
MatDiagonalScale MatPreallocateFinalize MatZeroRowsLocalIS
MatDiagonalSet MatPreallocateInitialize
Advanced - Setting more advanced options and customization
MATBLOCKMAT MatGetSubMatrix MatNullSpaceCreate
MATCOMPOSITE MatGetSubMatrixRaw MatNullSpaceDestroy
MATIS MatGetValues MatNullSpaceRemove
MATMAIJ MatGetVecs MatNullSpaceSetFunction
MATMFFD MatHasOperation MatNullSpaceTest
MATSCATTER MatISGetLocalMat MatPermute
MATSHELL MatImaginaryPart MatPermuteSparsify
MatAppendOptionsPrefix MatInodeGetInodeSizes MatRealPart
MatAssembled MatIsHermitianKnown MatRegister
MatCompositeAddMat MatIsSymmetricKnown MatRegisterAll
MatCompositeMerge MatMFFDAddNullSpace MatRegisterDAAD
MatCompositeSetType MatMFFDCheckPositivity MatRegisterDestroy
MatCompress MatMFFDDSSetUmin MatRegisterDynamic
MatComputeExplicitOperator MatMFFDGetH MatRestoreArray
MatConjugate MatMFFDResetHHistory MatRestoreArrayF90
MatCreateComposite MatMFFDSetBase MatRestoreRow
MatCreateIS MatMFFDSetCheckh MatRestoreRowUpperTriangular
MatCreateMAIJ MatMFFDSetFromOptions MatRetrieveValues
MatCreateMFFD MatMFFDSetFunction MatScatterSetVecScatter
MatCreateMPIAIJWithSplitArrays MatMFFDSetFunctionError MatSeqAIJSetColumnIndices
MatCreateShell MatMFFDSetFunctioni MatSeqBAIJInvertBlockDiagonal
MatDestroyMatrices MatMFFDSetFunctioniBase MatSeqBAIJSetColumnIndices
MatDestroySeqNonzeroStructure MatMFFDSetHHistory MatSeqSBAIJSetColumnIndices
MatGetArray MatMFFDSetPeriod MatSetOptionsPrefix
MatGetArrayF90 MatMFFDSetType MatSetUp
MatGetColumnVector MatMFFDWPSetComputeNormU MatShellGetContext
MatGetInertia MatMPIBAIJSetHashTableFactor MatShellGetOperation
MatGetOptionsPrefix MatMPIBAIJSetValuesBlocked MatShellSetContext
MatGetRedundantMatrix MatMerge MatShellSetOperation
MatGetRow MatMerge_SeqsToMPI MatStashGetInfo
MatGetRowUpperTriangular MatMissingDiagonal MatStoreValues
MatGetSubMatrices MatNullSpace
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
MatCholeskyCheckShift_inline MatILUFactor MatRestoreColumnIJ
MatCholeskyFactor MatILUFactorSymbolic MatRestoreRowIJ
MatCholeskyFactorNumeric MatIncreaseOverlap MatScaleSystem
MatCholeskyFactorSymbolic MatInitializePackage MatSeqAIJSetPreallocationCSR
MatColoringPatch MatLUCheckShift_inline MatSeqBAIJSetPreallocationCSR
MatColoringRegisterDynamic MatLUFactor MatSetColoring
MatDiagonalScaleLocal MatLUFactorNumeric MatSetUnfactored
MatFactorInfo MatLUFactorSymbolic MatSetValuesAdic
MatFactorInfoInitialize MatMFFDInitializePackage MatSetValuesAdifor
MatGetBrowsOfAcols MatMFFDRegisterAll MatSolve
MatGetBrowsOfAoCols MatMFFDRegisterDestroy MatSolveAdd
MatGetColumnIJ MatMFFDRegisterDynamic MatSolveTranspose
MatGetCommunicationStructs MatMPIAIJSetPreallocationCSR MatSolveTransposeAdd
MatGetLocalMat MatMPIBAIJSetPreallocationCSR MatSolves
MatGetLocalMatCondensed MatMatSolve MatUnScaleSystem
MatGetOwnershipRangeColumn MatNullSpaceAttach MatUseScaledForm
MatGetRowIJ MatOrderingRegisterDynamic MatValid
MatICCFactor MatPBRelax Mat_CheckCompressedRow
MatICCFactorSymbolic MatPartitioningRegisterDynamic PetscPLAPACKFinalizePackage
MatILUDTFactor MatRelax PetscPLAPACKInitializePackage
No deprecated routines
None: Not yet cataloged
MAT_SOLVER_PLAPACK

Table of Contents