petsc3.10.3 20181218
MatCreateLRC
Creates a new matrix object that behaves like A + U*C*V'
Synopsis
#include "petscmat.h"
PetscErrorCode MatCreateLRC(Mat A,Mat U,Vec c,Mat V,Mat *N)
Collective on Mat
Input Parameters
 A   the (sparse) matrix (can be NULL)

 U, V   two dense rectangular (tall and skinny) matrices

 c   a sequential vector containing the diagonal of C (can be NULL)

Output Parameter
N the matrix that represents A + U*C*V'
Notes
The matrix A + U*C*V' is not formed! Rather the new matrix
object performs the matrixvector product by first multiplying by
A and then adding the other term.
C is a diagonal matrix (represented as a vector) of order k,
where k is the number of columns of both U and V.
If A is NULL then the new object behaves like a lowrank matrix U*C*V'.
Use V=U (or V=NULL) for a symmetric lowrank correction, A + U*C*U'.
If c is NULL then the lowrank correction is just U*V'.
See Also
MatLRCGetMats()
Level
intermediate
Location
src/mat/impls/lrc/lrc.c
Examples
src/tao/pde_constrained/examples/tutorials/elliptic.c.html
Index of all Mat routines
Table of Contents for all manual pages
Index of all manual pages