Geant4 11.1.1
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4PhysicsVector.cc File Reference
#include "G4PhysicsVector.hh"
#include <iomanip>

Go to the source code of this file.

Functions

std::ostream & operator<< (std::ostream &out, const G4PhysicsVector &pv)
 

Function Documentation

◆ operator<<()

std::ostream & operator<< ( std::ostream &  out,
const G4PhysicsVector pv 
)

Definition at line 412 of file G4PhysicsVector.cc.

413{
414 // binning
415 G4long prec = out.precision();
416 out << std::setprecision(12) << pv.edgeMin << " " << pv.edgeMax << " "
417 << pv.numberOfNodes << G4endl;
418
419 // contents
420 out << pv.dataVector.size() << G4endl;
421 for(std::size_t i = 0; i < pv.dataVector.size(); ++i)
422 {
423 out << pv.binVector[i] << " " << pv.dataVector[i] << G4endl;
424 }
425 out.precision(prec);
426
427 return out;
428}
long G4long
Definition: G4Types.hh:87
#define G4endl
Definition: G4ios.hh:57
std::size_t numberOfNodes
std::vector< G4double > dataVector
std::vector< G4double > binVector