petsc-master 2020-07-10
Report Typos and Errors

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 MATSOLVERSUPERLU_DIST MatMumpsGetInverseTranspose
MATAIJCRL MATSOLVERUMFPACK MatMumpsGetRinfo
MATAIJCUSPARSE Mat MatMumpsGetRinfog
MATAIJMKL MatAssemblyBegin MatMumpsSetCntl
MATAIJPERM MatAssemblyEnd MatMumpsSetIcntl
MATAIJSELL MatAssemblyType MatOption
MATAIJVIENNACL MatColoring MatOrderingType
MATBAIJ MatColoringType MatPartitioning
MATBAIJMKL MatComputeBandwidth MatPartitioningType
MATDENSE MatCreate MatProductAlgorithm
MATDENSECUDA MatCreateSubMatrixOption MatProductType
MATELEMENTAL MatDestroy MatPropagateSymmetryOptions
MATMPIADJ MatDuplicateOption MatResetPreallocation
MATMPIAIJ MatFDColoring MatReuse
MATMPIBAIJ MatFactorError MatSORType
MATMPIDENSECUDA MatFactorShiftType MatSTRUMPACKSetColPerm
MATMPISBAIJ MatFactorType MatSTRUMPACKSetHSSAbsTol
MATMPISELL MatGetLocalSize MatSTRUMPACKSetHSSLeafSize
MATSBAIJ MatGetOwnershipRange MatSTRUMPACKSetHSSMaxRank
MATSCALAPACK MatGetOwnershipRanges MatSTRUMPACKSetHSSMinSepSize
MATSELL MatGetOwnershipRangesColumn MatSTRUMPACKSetHSSRelTol
MATSEQAIJ MatGetSize MatSTRUMPACKSetReordering
MATSEQAIJCUSPARSE MatHasCongruentLayouts MatSetFromOptions
MATSEQAIJVIENNACL MatInfoType MatSetSizes
MATSEQBAIJ MatLoad MatSetStencil
MATSEQDENSE MatMFFDType MatSetUp
MATSEQDENSECUDA MatMkl_PardisoSetCntl MatSetValue
MATSEQSBAIJ MatMult MatSetValues
MATSOLVERCHOLMOD MatMultAdd MatSetValuesBlockedStencil
MATSOLVERCUSPARSE MatMultConstrained MatSetValuesStencil
MATSOLVERESSL MatMultHermitianTranspose MatSolverType
MATSOLVERKLU MatMultHermitianTransposeAdd MatStencil
MATSOLVERLUSOL MatMultTranspose MatStructure
MATSOLVERMATLAB MatMultTransposeAdd MatSuperluSetILUDropTol
MATSOLVERMKL_PARDISO MatMultTransposeConstrained MatTransposeColoring
MATSOLVERMUMPS MatMumpsGetCntl MatType
MATSOLVERPASTIX MatMumpsGetIcntl MatView
MATSOLVERSPARSEELEMENTAL MatMumpsGetInfo MatXAIJSetPreallocation
MATSOLVERSSTRUMPACK MatMumpsGetInfog
MATSOLVERSUPERLU MatMumpsGetInverse
Intermediate - Setting options for algorithms and data structures
MATHYPRE MatDenseSetLDA MatProductReplaceMats
MATMFFD_DS MatDiagonalScale MatProductSetAlgorithm
MATMFFD_WP MatDiagonalSet MatProductSetFill
MATNEST MatDuplicate MatProductSetFromOptions
MATSOLVERBAS MatEqual MatProductSetType
MatAXPY MatFDColoringSetValues MatProductSymbolic
MatAYPX MatFactorGetSolverType MatProductView
MatBindToCPU MatFindNonzeroRows MatPtAP
MatBlockMatSetPreallocation MatFindZeroRows MatPtAPMultEqual
MatCUSPARSEFormatOperation MatGetBlockSize MatPythonCreate
MatCUSPARSESetFormat MatGetBlockSizes MatPythonSetType
MatCUSPARSEStorageFormat MatGetColumnNorms MatRARt
MatChop MatGetDiagonal MatRARtMultEqual
MatColoringWeightType MatGetFactor MatReorderForNonzeroDiagonal
MatConvert MatGetFactorAvailable MatRestoreLocalSubMatrix
MatCopy MatGetFactorType MatRestrict
MatCreateAIJ MatGetInfo MatSTRUMPACKReordering
MatCreateAIJCUSPARSE MatGetLocalSubMatrix MatScaLAPACKGetBlockSizes
MatCreateAIJViennaCL MatGetNonzeroState MatScaLAPACKSetBlockSizes
MatCreateBAIJ MatGetOption MatScale
MatCreateBAIJMKL MatGetOwnershipIS MatScatterGetVecScatter
MatCreateBlockMat MatGetRowMax MatSeqAIJCUSPARSESetGenerateTranspose
MatCreateDense MatGetRowMaxAbs MatSeqAIJGetArray
MatCreateDenseCUDA MatGetRowMin MatSeqAIJGetArrayRead
MatCreateFFT MatGetRowMinAbs MatSeqAIJGetMaxRowNonzeros
MatCreateHermitianTranspose MatGetRowSum MatSeqAIJRestoreArray
MatCreateLRC MatGetSeqNonzeroStructure MatSeqAIJRestoreArrayRead
MatCreateMPIAIJCRL MatGetType MatSeqAIJSetPreallocation
MatCreateMPIAIJMKL MatGetVariableBlockSizes MatSeqAIJSetType
MatCreateMPIAIJPERM MatGetVecType MatSeqBAIJGetArray
MatCreateMPIAIJSELL MatHYPRESetPreallocation MatSeqBAIJRestoreArray
MatCreateMPIAIJWithArrays MatHermitianTranspose MatSeqBAIJSetPreallocation
MatCreateMPIAdj MatHermitianTransposeGetMat MatSeqDenseSetPreallocation
MatCreateMPIBAIJWithArrays MatISSetPreallocation MatSeqSBAIJGetArray
MatCreateMPISBAIJWithArrays MatInfo MatSeqSBAIJRestoreArray
MatCreateNormal MatInterpolate MatSeqSBAIJSetPreallocation
MatCreateNormalHermitian MatInterpolateAdd MatSeqSELLRestoreArray
MatCreateSBAIJ MatIsHermitian MatSeqSELLSetPreallocation
MatCreateSELL MatIsHermitianTranspose MatSetBlockSize
MatCreateScaLAPACK MatIsLinear MatSetBlockSizes
MatCreateScatter MatIsStructurallySymmetric MatSetFactorType
MatCreateSeqAIJ MatIsSymmetric MatSetLocalToGlobalMapping
MatCreateSeqAIJCRL MatIsTranspose MatSetOption
MatCreateSeqAIJCUSPARSE MatLRCGetMats MatSetRandom
MatCreateSeqAIJFromTriple MatMPIAIJGetSeqAIJ MatSetType
MatCreateSeqAIJMKL MatMPIAIJSetPreallocation MatSetValuesBlocked
MatCreateSeqAIJPERM MatMPIAdjSetPreallocation MatSetValuesBlockedLocal
MatCreateSeqAIJSELL MatMPIAdjToSeq MatSetValuesLocal
MatCreateSeqAIJViennaCL MatMPIBAIJSetPreallocation MatSetValuesRowLocal
MatCreateSeqAIJWithArrays MatMPIDenseSetPreallocation MatSetVariableBlockSizes
MatCreateSeqBAIJ MatMPISBAIJSetPreallocation MatSetVecType
MatCreateSeqBAIJMKL MatMPISELLSetPreallocation MatShift
MatCreateSeqCUFFT MatMatMatMult MatSolvePackageGet
MatCreateSeqDense MatMatMult MatSolvePackageRegister
MatCreateSeqDenseCUDA MatMatMultEqual MatStashSetInitialSize
MatCreateSeqSBAIJ MatMatTransposeMult MatTranspose
MatCreateSeqSELL MatMatTransposeMultEqual MatTransposeColoringCreate
MatCreateTranspose MatMkl_CPardisoSetCntl MatTransposeColoringDestroy
MatDenseGetArray MatMultAddEqual MatTransposeGetMat
MatDenseGetArrayRead MatMultEqual MatTransposeMatMult
MatDenseGetArrayWrite MatMultTransposeAddEqual MatTransposeMatMultEqual
MatDenseGetColumn MatMultTransposeEqual MatUpdateMPIAIJWithArrays
MatDenseGetColumnVec MatNorm MatViewFromOptions
MatDenseGetColumnVecRead MatPreallocateFinalize MatZeroEntries
MatDenseGetColumnVecWrite MatPreallocateInitialize MatZeroRows
MatDenseGetLDA MatPreallocateLocation MatZeroRowsColumns
MatDenseGetLocalMatrix MatPreallocateSet MatZeroRowsColumnsIS
MatDenseGetSubMatrix MatPreallocateSetLocal MatZeroRowsColumnsLocal
MatDenseRestoreArray MatPreallocateSetLocalBlock MatZeroRowsColumnsLocalIS
MatDenseRestoreArrayRead MatPreallocateSetLocalRemoveDups MatZeroRowsColumnsStencil
MatDenseRestoreArrayWrite MatPreallocateSymmetricSetBlock MatZeroRowsIS
MatDenseRestoreColumn MatPreallocateSymmetricSetLocalBlock MatZeroRowsLocal
MatDenseRestoreColumnVec MatProductClear MatZeroRowsLocalIS
MatDenseRestoreColumnVecRead MatProductCreate MatZeroRowsStencil
MatDenseRestoreColumnVecWrite MatProductCreateWithMat VecScatterFFTWToPetsc
MatDenseRestoreSubMatrix MatProductNumeric VecScatterPetscToFFTW
Advanced - Setting more advanced options and customization
MATBLOCKMAT MatFactorSolveSchurComplementTranspose MatMFFDWPSetComputeNormU
MATCOMPOSITE MatGetColumnVector MatMPIAIJSetUseScalableIncreaseOverlap
MATIS MatGetDiagonalBlock MatMPIBAIJSetHashTableFactor
MATKAIJ MatGetGhosts MatMPIBAIJSetPreallocationCSR
MATMAIJ MatGetInertia MatMPIBAIJSetValuesBlocked
MATMFFD MatGetLayouts MatMPISBAIJSetPreallocationCSR
MATPREALLOCATOR MatGetLocalToGlobalMapping MatMissingDiagonal
MATSCATTER MatGetMultiProcBlock MatNestGetISs
MATSHELL MatGetOptionsPrefix MatNestGetLocalISs
MatAppendOptionsPrefix MatGetRow MatNestSetSubMats
MatAssembled MatGetRowUpperTriangular MatNullSpace
MatCompositeAddMat MatGetTrace MatNullSpaceCreate
MatCompositeGetMat MatGetValues MatNullSpaceCreateRigidBody
MatCompositeGetMatStructure MatGetValuesLocal MatNullSpaceDestroy
MatCompositeGetNumberMat MatHasOperation MatNullSpaceRemove
MatCompositeGetType MatISFixLocalEmpty MatNullSpaceSetFunction
MatCompositeMerge MatISGetLocalMat MatNullSpaceTest
MatCompositeSetMatStructure MatISRestoreLocalMat MatNullSpaceView
MatCompositeSetMergeType MatISSetLocalMat MatPermute
MatCompositeSetScalings MatISSetLocalMatType MatPreallocatorPreallocate
MatCompositeSetType MatISStoreL2L MatRealPart
MatComputeOperator MatImaginaryPart MatRegister
MatComputeOperatorTranspose MatInodeGetInodeSizes MatRegisterAll
MatConjugate MatInvertBlockDiagonal MatRestoreRow
MatCreateComposite MatInvertBlockDiagonalMat MatRestoreRowUpperTriangular
MatCreateConstantDiagonal MatInvertVariableBlockDiagonal MatRetrieveValues
MatCreateIS MatIsHermitianKnown MatScatterSetVecScatter
MatCreateKAIJ MatIsSymmetricKnown MatSeqAIJGetArrayF90
MatCreateMAIJ MatKAIJGetAIJ MatSeqAIJRegister
MatCreateMFFD MatKAIJGetS MatSeqAIJRegisterAll
MatCreateMPIAIJSumSeqAIJ MatKAIJGetSRead MatSeqAIJRestoreArrayF90
MatCreateMPIAIJWithSeqAIJ MatKAIJGetScaledIdentity MatSeqAIJSetColumnIndices
MatCreateMPIAIJWithSplitArrays MatKAIJGetT MatSeqBAIJSetColumnIndices
MatCreateMPIMatConcatenateSeqMat MatKAIJGetTRead MatSeqBAIJSetPreallocationCSR
MatCreateNest MatKAIJRestoreS MatSeqSBAIJSetColumnIndices
MatCreateRedundantMatrix MatKAIJRestoreSRead MatSeqSBAIJSetPreallocationCSR
MatCreateSeqBAIJWithArrays MatKAIJRestoreT MatSetErrorIfFailure
MatCreateSeqSBAIJWithArrays MatKAIJRestoreTRead MatSetNearNullSpace
MatCreateShell MatKAIJSetAIJ MatSetNullSpace
MatCreateSubMatrices MatKAIJSetS MatSetOptionsPrefix
MatCreateSubMatricesMPI MatKAIJSetT MatSetTransposeNullSpace
MatCreateSubMatrix MatMAIJGetAIJ MatSetValuesBatch
MatCreateVecs MatMAIJRedimension MatSetValuesRow
MatCreateVecsFFTW MatMFFDCheckPositivity MatShellGetContext
MatDenseGetArrayF90 MatMFFDDSSetUmin MatShellGetOperation
MatDenseRestoreArrayF90 MatMFFDGetH MatShellSetContext
MatDestroyMatrices MatMFFDResetHHistory MatShellSetManageScalingShifts
MatDestroySeqNonzeroStructure MatMFFDSetBase MatShellSetMatProductOperation
MatDestroySubMatrices MatMFFDSetCheckh MatShellSetOperation
MatFactorCreateSchurComplement MatMFFDSetFunction MatShellSetVecType
MatFactorFactorizeSchurComplement MatMFFDSetFunctionError MatShellTestMult
MatFactorGetError MatMFFDSetFunctioni MatShellTestMultTranpose
MatFactorGetErrorZeroPivot MatMFFDSetFunctioniBase MatStashGetInfo
MatFactorGetSchurComplement MatMFFDSetHHistory MatStoreValues
MatFactorInvertSchurComplement MatMFFDSetOptionsPrefix MatSubdomainsCreateCoalesce
MatFactorRestoreSchurComplement MatMFFDSetPeriod MatTransColoringApplyDenToSp
MatFactorSolveSchurComplement MatMFFDSetType MatTransColoringApplySpToDen
Developer - Interfaces intended primarily for library developers, not for typical applications programmers
MATDUMMY MatForwardSolve MatMPIAIJSetPreallocationCSR
MatBackwardSolve MatGalerkin MatMPIAdjCreateNonemptySubcommMat
MatCheckCompressedRow MatGetBrowsOfAcols MatMPISELLGetLocalMatCondensed
MatCholeskyFactor MatGetColumnIJ MatMatSolve
MatCholeskyFactorNumeric MatGetCommunicationStructs MatMatSolveTranspose
MatCholeskyFactorSymbolic MatGetNearNullSpace MatMatTransposeSolve
MatColoringPatch MatGetNullSpace MatMultDiagonalBlock
MatCreateLocalRef MatGetOperation MatNestGetSize
MatCreateSubMatrixVirtual MatGetOwnershipRangeColumn MatNestGetSubMat
MatDenseCUDAGetArray MatGetRowIJ MatNestGetSubMats
MatDenseCUDAGetArrayRead MatGetTransposeNullSpace MatNestSetSubMat
MatDenseCUDAGetArrayWrite MatICCFactor MatNestSetVecType
MatDenseCUDAPlaceArray MatICCFactorSymbolic MatNullSpaceGetVecs
MatDenseCUDAReplaceArray MatILUFactor MatRegisterRootName
MatDenseCUDAResetArray MatILUFactorSymbolic MatResidual
MatDenseCUDARestoreArray MatISGetMPIXAIJ MatRestoreColumnIJ
MatDenseCUDARestoreArrayRead MatIncreaseOverlap MatRestoreRowIJ
MatDenseCUDARestoreArrayWrite MatIncreaseOverlapSplit MatSOR
MatDensePlaceArray MatInitializePackage MatSeqAIJSetPreallocationCSR
MatDenseReplaceArray MatIsShell MatSetBlockSizesFromMats
MatDenseResetArray MatLUFactor MatSetOperation
MatDiagonalScaleLocal MatLUFactorNumeric MatSetUnfactored
MatFactorClearError MatLUFactorSymbolic MatSolve
MatFactorGetUseOrdering MatMFFD MatSolveAdd
MatFactorInfo MatMFFDFinalizePackage MatSolveTranspose
MatFactorInfoInitialize MatMFFDInitializePackage MatSolveTransposeAdd
MatFactorSetSchurIS MatMFFDRegister MatSolves
MatFinalizePackage MatMFFDRegisterAll MatSubMatrixVirtualUpdate
MatFindOffBlockDiagonalEntries MatMPIAIJGetLocalMat
MatFindZeroDiagonals MatMPIAIJGetLocalMatCondensed
No deprecated routines

Table of Contents