Skip to main content
Ctrl+K
PETSc v3.26.0-2-g3c5cfaeaff0b documentation - Home
  • Overview
  • Install
  • Tutorials
  • User-Guide
  • C/Fortran API
  • petsc4py API
  • FAQ
  • Community
  • Developers
  • Misc.
  • GitLab
  • Overview
  • Install
  • Tutorials
  • User-Guide
  • C/Fortran API
  • petsc4py API
  • FAQ
  • Community
  • Developers
  • Misc.
  • GitLab
  • PetscViewerA...

PetscViewerASCIIGetStdout#

Creates a PETSCVIEWERASCII PetscViewer shared by all processes in a communicator that prints to stdout. Error returning version of PETSC_VIEWER_STDOUT_()

Synopsis#

#include "petscviewer.h" 
PetscErrorCode PetscViewerASCIIGetStdout(MPI_Comm comm, PetscViewer *viewer)

Collective

Input Parameter#

  • comm - the MPI communicator to share the PetscViewer

Output Parameter#

  • viewer - the viewer

Note#

Use PetscViewerDestroy() to destroy it

Developer Note#

This should be used in all PETSc source code instead of PETSC_VIEWER_STDOUT_() since it allows error checking

See Also#

Viewers: Looking at PETSc Objects, PetscViewerASCIIGetStderr(), PETSC_VIEWER_DRAW_(), PetscViewerASCIIOpen(), PETSC_VIEWER_STDERR_, PETSC_VIEWER_STDOUT_WORLD, PETSC_VIEWER_STDOUT_SELF

Level#

beginner

Location#

src/sys/classes/viewer/impls/ascii/filev.c

Examples#

src/sys/objects/device/tests/ex11.cxx
src/sys/tests/ex64.cxx
src/sys/tests/ex65.c
src/snes/tutorials/ex6.c
src/ts/tutorials/ex14.c
src/mat/tests/ex134.c
src/mat/tests/ex151.c
src/mat/tests/ex166.c
src/mat/tests/ex68.c
src/vec/is/tests/ex7.c


Index of all Viewer routines
Table of Contents for all manual pages
Index of all manual pages

On this page
  • Synopsis
  • Input Parameter
  • Output Parameter
  • Note
  • Developer Note
  • See Also
  • Level
  • Location
  • Examples
Edit on GitLab
Show Source

© Copyright 1991-2026, UChicago Argonne, LLC and the PETSc Development Team.

Created using Sphinx 7.3.7.

Built with the PyData Sphinx Theme 0.15.1.

Last updated on 2026-09-28T23:19:25-0500 (v3.26.0-2-g3c5cfaeaff0b).