2008/12/15

How to draw and view data when PETSc running

Example solve AX=B
vec X;
  • In source code
VecView(Vec vec,PetscViewer viewer)
VecView(X,PETSC_VIEW_STDOUT_SELF)
  • In command
VecViewFromOptions(Vec vec, char *title)
VecViewFromOptions(X,"TEST")


petscmpiexec -n 2 ./a.out -vec_view_draw -draw_pause 1