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_DIST MatMultConstrained
MATBAIJ MAT_SOLVER_UMFPACK MatMultTranspose
MATCRL Mat MatMultTransposeAdd
MATCSRPERM MatAssemblyBegin MatMultTransposeConstrained
MATDENSE MatAssemblyEnd MatOption
MATMPIADJ MatAssemblyType MatOrderingType
MATMPIAIJ MatColoringType MatPartitioning
MATMPIBAIJ MatCreate MatPartitioningType
MATMPIROWBS MatDestroy MatReuse
MATMPISBAIJ MatDuplicateOption MatSORType
MATSBAIJ MatFDColoring MatSetFromOptions
MATSEQAIJ MatFactorType MatSetSizes
MATSEQBAIJ MatGetLocalSize MatSetStencil
MATSEQDENSE MatGetOwnershipRange MatSetUpPreallocation
MATSEQSBAIJ MatGetOwnershipRanges MatSetValue
MAT_SOLVER_DSCPACK MatGetOwnershipRangesColumn MatSetValues
MAT_SOLVER_ESSL MatGetSize MatSetValuesBlockedStencil
MAT_SOLVER_LUSOL MatGetSubMatrixOption MatSetValuesStencil
MAT_SOLVER_MATLAB MatInfoType MatSolverPackage
MAT_SOLVER_MUMPS MatLoad MatStencil
MAT_SOLVER_PASTIX MatMFFDType MatStructure
MAT_SOLVER_SPOOLES MatMult MatType
MAT_SOLVER_SUPERLU MatMultAdd MatView
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 MatGetSubMatrices MatNullSpace
MATCOMPOSITE MatGetSubMatrix MatNullSpaceCreate
MATIS MatGetSubMatrixRaw MatNullSpaceDestroy
MATMAIJ MatGetValues MatNullSpaceRemove
MATMFFD MatGetVecs MatNullSpaceSetFunction
MATSCATTER MatHasOperation MatNullSpaceTest
MATSHELL MatISGetLocalMat MatPermute
MatAppendOptionsPrefix MatImaginaryPart MatPermuteSparsify
MatAssembled MatInodeGetInodeSizes MatRealPart
MatCompositeAddMat MatIsHermitianKnown MatRegister
MatCompositeMerge MatIsSymmetricKnown MatRegisterAll
MatCompositeSetType MatMFFDAddNullSpace MatRegisterDAAD
MatCompress MatMFFDCheckPositivity MatRegisterDestroy
MatComputeExplicitOperator MatMFFDDSSetUmin MatRegisterDynamic
MatConjugate MatMFFDGetH MatRestoreArray
MatCreateComposite MatMFFDResetHHistory MatRestoreArrayF90
MatCreateIS MatMFFDSetBase MatRestoreRow
MatCreateMAIJ MatMFFDSetCheckh MatRestoreRowUpperTriangular
MatCreateMFFD MatMFFDSetFromOptions MatRetrieveValues
MatCreateMPIAIJWithSplitArrays MatMFFDSetFunction MatScatterSetVecScatter
MatCreateShell MatMFFDSetFunctionError MatSeqAIJSetColumnIndices
MatDestroyMatrices MatMFFDSetFunctioni MatSeqBAIJInvertBlockDiagonal
MatDestroySeqNonzeroStructure MatMFFDSetFunctioniBase MatSeqBAIJSetColumnIndices
MatGetArray MatMFFDSetHHistory MatSeqSBAIJSetColumnIndices
MatGetArrayF90 MatMFFDSetPeriod MatSetOptionsPrefix
MatGetColumnVector MatMFFDSetType MatSetUp
MatGetDiagonalBlock MatMFFDWPSetComputeNormU MatShellGetContext
MatGetInertia MatMPIBAIJSetHashTableFactor MatShellGetOperation
MatGetOptionsPrefix MatMPIBAIJSetValuesBlocked MatShellSetContext
MatGetRedundantMatrix MatMerge MatShellSetOperation
MatGetRow MatMerge_SeqsToMPI MatStashGetInfo
MatGetRowUpperTriangular MatMissingDiagonal MatStoreValues
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
MatBackwardSolve MatILUDTFactor MatRestoreColumnIJ
MatCholeskyCheckShift_inline MatILUFactor MatRestoreRowIJ
MatCholeskyFactor MatILUFactorSymbolic MatScaleSystem
MatCholeskyFactorNumeric MatIncreaseOverlap MatSeqAIJSetPreallocationCSR
MatCholeskyFactorSymbolic MatInitializePackage MatSeqBAIJSetPreallocationCSR
MatColoringPatch MatLUCheckShift_inline MatSetColoring
MatColoringRegisterDynamic MatLUFactor MatSetUnfactored
MatDiagonalScaleLocal MatLUFactorNumeric MatSetValuesAdic
MatFactorInfo MatLUFactorSymbolic MatSetValuesAdifor
MatFactorInfoInitialize MatMFFDInitializePackage MatSolve
MatForwardSolve MatMFFDRegisterAll MatSolveAdd
MatGetBrowsOfAcols MatMFFDRegisterDestroy MatSolveTranspose
MatGetBrowsOfAoCols MatMFFDRegisterDynamic MatSolveTransposeAdd
MatGetColumnIJ MatMPIAIJSetPreallocationCSR MatSolves
MatGetCommunicationStructs MatMPIBAIJSetPreallocationCSR MatUnScaleSystem
MatGetLocalMat MatMatSolve MatUseScaledForm
MatGetLocalMatCondensed MatNullSpaceAttach MatValid
MatGetOwnershipRangeColumn MatOrderingRegisterDynamic Mat_CheckCompressedRow
MatGetRowIJ MatPBRelax PetscPLAPACKFinalizePackage
MatICCFactor MatPartitioningRegisterDynamic PetscPLAPACKInitializePackage
MatICCFactorSymbolic MatRelax
No deprecated routines
None: Not yet cataloged
MAT_SOLVER_PLAPACK

Table of Contents