petsc-master 2014-09-30
Report Typos and Errors

MatShift

Computes Y = Y + a I, where a is a PetscScalar and I is the identity matrix.

Synopsis

#include "petscmat.h"  
PetscErrorCode  MatShift(Mat Y,PetscScalar a)
Neighbor-wise Collective on Mat

Input Parameters

Y - the matrices
a - the PetscScalar

Keywords

matrix, add, shift

See Also

MatDiagonalSet()

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

Examples

src/mat/examples/tutorials/ex9.c.html
src/tao/pde_constrained/examples/tutorials/parabolic.c.html
src/tao/pde_constrained/examples/tutorials/hyperbolic.c.html