petsc-3.4.2 2013-07-02

# VecZeroEntries

puts a 0.0 in each element of a vector

### Synopsis

    #include "petscvec.h"
    PetscErrorCode  VecZeroEntries(Vec vec)

Logically Collective on Vec

### Input Parameter

vec -The vector

Developer Note: This routine does not need to exist since the exact functionality is obtained with VecSet(vec,0); I guess someone added it to mirror the functionality of MatZeroEntries() but Mat is nothing like a Vec (one is an operator and one is an element of a vector space, yeah yeah dual blah blah blah) so this routine should not exist.

### Keywords

Vec, set, options, database

### See Also

VecCreate(), VecSetOptionsPrefix(), VecSet(), VecSetValues()

Level:beginner
Location:src/vec/vec/interface/vector.c
Index of all Vec routines
Table of Contents for all manual pages
Index of all manual pages

### Examples

src/ksp/ksp/examples/tutorials/ex42.c.html
src/ksp/ksp/examples/tutorials/ex43.c.html
src/ksp/ksp/examples/tutorials/ex49.c.html
src/ksp/ksp/examples/tutorials/ex56.c.html
src/snes/examples/tutorials/ex10.c.html
src/snes/examples/tutorials/ex28.c.html
src/ts/examples/tutorials/ex9.c.html
src/ts/examples/tutorials/ex10.c.html
src/ts/examples/tutorials/ex14.c.html
src/ts/examples/tutorials/ex24.c.html