Chombo + EB  3.2
Macros | Functions
parstream.H File Reference
#include <iostream>
#include <string>
#include "BaseNamespaceHeader.H"
#include "BaseNamespaceFooter.H"
Include dependency graph for parstream.H:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define _PARSTREAM_H_
 

Functions

std::ostream & pout ()
 Use this in place of std::cout for program output. More...
 
void setPoutBaseName (const std::string &a_Name)
 Changes the base part of the filename for pout() files. More...
 
const std::string & poutFileName ()
 Accesses the filename for the local pout() file. More...
 

Macro Definition Documentation

◆ _PARSTREAM_H_

#define _PARSTREAM_H_

Function Documentation

◆ pout()

std::ostream& pout ( )

Use this in place of std::cout for program output.

Replaces std::cout in most of the Chombo code. In serial this just returns std::cout. In parallel, this creates a separate file for each proc called <basename>.n where n is the procID and <basename> defaults to "pout" but can be set by calling setPoutBaseName(). Output is then directed to these files. This keeps the output from different processors from getting all jumbled up. If you want fewer files, you can do setenv CH_OUTPUT_INTERVAL nproc and it will only output every nproc processors pout.n files (where nnproc == 0).

Referenced by RootSolver::Brent(), IFData< dim >::BrentRootFinder(), GMRESSolver< T >::BuildGMRESSoln(), ComputeCutCellMoments< dim >::computeMoments(), MinimalCCCM< dim >::computeMomentsRecursively(), PetscSolver< LevelData< FArrayBox > >::create_mat_vec(), GMRESSolver< T >::CycleGMRES(), MinimalCCCM< dim >::dump(), CutCellMoments< dim >::dump(), ComputeCutCellMoments< dim >::dump(), SphereTree::findNode(), RefCountedPtr< DataFactory< NodeFArrayBox > >::freeMem(), AMRMultiGrid< LevelData< T > >::getInfo(), IndexedMoments< SpaceDim, CH_EBIS_ORDER >::getMoment(), LSProblem< dim >::invertNormalEq(), PetscSolver< LevelData< FArrayBox > >::ksp_monitor_pout(), BaseIVFAB< Real >::linearIn(), IVSFAB< T >::linearOut(), BaseIVFAB< Real >::linearOut(), AMRTGA< T >::oneStep(), RefCountedPtr< WGSRefinementCriterion >::operator WGSRefinementCriterion *(), RefCountedPtr< DataFactory< NodeFArrayBox > >::operator=(), LayoutIndex::output(), LSProblem< dim >::outputBounds(), LSProblem< dim >::outputMatrix(), LSProblem< dim >::outputRhs(), LSProblem< dim >::outputUnknowns(), IndexTM< Real, GLOBALDIM >::p(), IntVectSet::p(), RefCountedPtr< DataFactory< NodeFArrayBox > >::RefCountedPtr(), RefCountedPtr< DataFactory< NodeFArrayBox > >::refDown(), ComputeCutCellMoments< dim >::refine(), RefCountedPtr< DataFactory< NodeFArrayBox > >::refUp(), AMRMultiGrid< LevelData< T > >::relaxOnlyHomogeneous(), TupleKeyMap< TupleTypenames, ValueT >::report(), AMRTGA< T >::setMu(), BaseIVFAB< Real >::size(), BaseIFFAB< FaceStencil >::size(), MiniIFFAB< Real >::size(), CutCellMoments< dim >::sliceResidual(), BiCGStabSolver< LevelData< T > >::solve(), RelaxSolver< T >::solve(), FASMultiGrid< T >::solve(), GMRESSolver< T >::solve(), MultiGrid< T >::solve(), AMRTGA< T >::solveHelm(), BaseLevelHeatSolver< LevelData< FArrayBox >, FluxBox, LevelFluxRegister >::solveHelm(), AMRFASMultiGrid< T >::solveNoInit(), AMRMultiGrid< LevelData< T > >::solveNoInitResid(), IrregNode::spout(), IndexedMoments< SpaceDim, CH_EBIS_ORDER >::spout(), BaseFab< Real >::testBoxAndComp(), BoxLayoutData< BaseFab< int > >::unpackReceivesToMe_append(), GMRESSolver< T >::UpdateGMRESHessenberg(), BaseIFFAB< FaceStencil >::useThisFace(), write(), and WriteMultiData< T >::writeData().

◆ setPoutBaseName()

void setPoutBaseName ( const std::string &  a_Name)

Changes the base part of the filename for pout() files.

When in parallel, changes the base name of the pout() files. If pout() has already been called, it closes the current output file and opens a new one (unless the name is the same, in which case it does nothing). In serial, ignores the argument and does nothing.

◆ poutFileName()

const std::string& poutFileName ( )

Accesses the filename for the local pout() file.

Returns the name used for the local pout() file. In parallel this is "<pout_basename>.<procID>", where <pout_basename> defaults to "pout" and can be modified by calling setPoutBaseName(), and <procID> is the local proc number. In serial, this always returns the string "cout". It is an error (exit code 111) to call this in parallel before MPI_Initialize().