#include <vtkoutput.h>
SMASH output in a paraview format, intended for simple visualization.
Definition at line 28 of file vtkoutput.h.
Public Member Functions | |
| VtkOutput (const bf::path &path, const std::string &name, const OutputParameters &out_par) | |
| Create a new VTK output. More... | |
| ~VtkOutput () | |
| void | at_eventstart (const Particles &particles, const int event_number) override |
| Writes the initial particle information list of an event to the VTK output. More... | |
| void | at_eventend (const Particles &particles, const int event_number, double impact_parameter, bool empty_event) override |
| Writes the final particle information list of an event to the VTK output. More... | |
| void | at_intermediate_time (const Particles &particles, const std::unique_ptr< Clock > &clock, const DensityParameters &dens_param) override |
| Writes out all current particles. More... | |
| void | thermodynamics_output (const ThermodynamicQuantity tq, const DensityType dt, RectangularLattice< DensityOnLattice > &lattice) override |
| Prints the density lattice in VTK format on a grid. More... | |
| void | thermodynamics_output (const ThermodynamicQuantity tq, const DensityType dt, RectangularLattice< EnergyMomentumTensor > &lattice) override |
| Prints the energy-momentum-tensor lattice in VTK format on a grid. More... | |
| void | thermodynamics_output (const GrandCanThermalizer &gct) override |
| Printout of all thermodynamic quantities from the thermalizer class. More... | |
Public Member Functions inherited from smash::OutputInterface | |
| OutputInterface (std::string name) | |
| Construct output interface. More... | |
| virtual | ~OutputInterface ()=default |
| virtual void | at_interaction (const Action &action, const double density) |
| Called whenever an action modified one or more particles. More... | |
| bool | is_dilepton_output () const |
| Get, whether this is the dilepton output? More... | |
| bool | is_photon_output () const |
| Get, whether this is the photon output? More... | |
| bool | is_IC_output () const |
| Get, whether this is the IC output? More... | |
| const char * | to_string (const ThermodynamicQuantity tq) |
| Convert thermodynamic quantities to strings. More... | |
| const char * | to_string (const DensityType dens_type) |
| Convert density types to strings. More... | |
Private Member Functions | |
| void | write (const Particles &particles) |
| Write the given particles to the output. More... | |
| std::string | make_filename (const std::string &description, int counter) |
| Make a file name given a description and a counter. More... | |
| std::string | make_varname (const ThermodynamicQuantity tq, const DensityType dens_type) |
| Make a variable name given quantity and density type. More... | |
| template<typename T > | |
| void | write_vtk_header (std::ofstream &file, RectangularLattice< T > &lat, const std::string &description) |
| Write the VTK header. More... | |
| template<typename T , typename F > | |
| void | write_vtk_scalar (std::ofstream &file, RectangularLattice< T > &lat, const std::string &varname, F &&function) |
| Write a VTK scalar. More... | |
| template<typename T , typename F > | |
| void | write_vtk_vector (std::ofstream &file, RectangularLattice< T > &lat, const std::string &varname, F &&function) |
| Write a VTK vector. More... | |
Private Attributes | |
| const bf::path | base_path_ |
| filesystem path for output More... | |
| int | current_event_ = 0 |
| Event number. More... | |
| int | vtk_output_counter_ = 0 |
| Number of vtk output in current event. More... | |
| int | vtk_density_output_counter_ = 0 |
| Number of density lattice vtk output in current event. More... | |
| int | vtk_tmn_output_counter_ = 0 |
| Number of energy-momentum tensor lattice vtk output in current event. More... | |
| int | vtk_tmn_landau_output_counter_ = 0 |
| Number of Landau frame energy-momentum tensor vtk output in current event. More... | |
| int | vtk_v_landau_output_counter_ = 0 |
| Number of Landau rest frame velocity vtk output in current event. More... | |
| int | vtk_fluidization_counter_ = 0 |
| Number of fluidization output. More... | |
| bool | is_thermodynamics_output_ |
| Is the VTK output a thermodynamics output. More... | |
Additional Inherited Members | |
Protected Attributes inherited from smash::OutputInterface | |
| const bool | is_dilepton_output_ |
| Is this the dilepton output? More... | |
| const bool | is_photon_output_ |
| Is this the photon output? More... | |
| const bool | is_IC_output_ |
| Is this the IC output? More... | |
| smash::VtkOutput::VtkOutput | ( | const bf::path & | path, |
| const std::string & | name, | ||
| const OutputParameters & | out_par | ||
| ) |
Create a new VTK output.
| path | Path to the output file. |
| name | Name of the output. |
| out_par | Additional information on the configured output. |
Definition at line 22 of file vtkoutput.cc.
| smash::VtkOutput::~VtkOutput | ( | ) |
Definition at line 33 of file vtkoutput.cc.
|
overridevirtual |
Writes the initial particle information list of an event to the VTK output.
| particles | Current list of all particles. |
| event_number | Number of the current event. |
Implements smash::OutputInterface.
Definition at line 59 of file vtkoutput.cc.
|
overridevirtual |
Writes the final particle information list of an event to the VTK output.
This currently does not do anything, because it is not required for the VTK output.
| particles | Unused. Current list of particles. |
| event_number | Unused. Number of event. |
| impact_parameter | Unused. Impact parameter of this event. |
| empty_event | Unused. Whether the projectile and target did not collide. |
Implements smash::OutputInterface.
Definition at line 75 of file vtkoutput.cc.
|
overridevirtual |
Writes out all current particles.
| particles | Current list of particles. |
| clock | Unused, needed since inherited. |
| dens_param | Unused, needed since inherited. |
Reimplemented from smash::OutputInterface.
Definition at line 80 of file vtkoutput.cc.
|
overridevirtual |
Prints the density lattice in VTK format on a grid.
| tq | The quantity whose density should be written, see ThermodynamicQuantity. |
| dt | The type of the density, see DensityType. |
| lattice | The lattice from which the quantity is taken. |
Reimplemented from smash::OutputInterface.
Definition at line 229 of file vtkoutput.cc.
|
overridevirtual |
Prints the energy-momentum-tensor lattice in VTK format on a grid.
| tq | The quantity whose density should be written, see ThermodynamicQuantity. |
| dt | The type of the density, see DensityType |
| lattice | The lattice from which the quantity is taken. |
Reimplemented from smash::OutputInterface.
Definition at line 260 of file vtkoutput.cc.
|
overridevirtual |
Printout of all thermodynamic quantities from the thermalizer class.
| gct | Grand-canonical thermalizer from which the quantities are taken. |
Reimplemented from smash::OutputInterface.
Definition at line 308 of file vtkoutput.cc.
|
private |
Write the given particles to the output.
| particles | The particles. |
Definition at line 89 of file vtkoutput.cc.
|
private |
Make a file name given a description and a counter.
| description | The description. |
| counter | The counter enumerating the outputs. |
Definition at line 216 of file vtkoutput.cc.
|
private |
Make a variable name given quantity and density type.
| tq | The quantity. |
| dens_type | The density type. |
Definition at line 223 of file vtkoutput.cc.
|
private |
Write the VTK header.
| file | Output file. |
| lat | Lattice corresponding to output. |
| description | Description of the output. |
Definition at line 168 of file vtkoutput.cc.
|
private |
Write a VTK scalar.
| file | Output file. |
| lat | Lattice corresponding to output. |
| varname | Name of the output variable. |
| function | Function that gets the scalar given a lattice node. |
Definition at line 185 of file vtkoutput.cc.
|
private |
Write a VTK vector.
| file | Output file. |
| lat | Lattice corresponding to output. |
| varname | Name of the output variable. |
| function | Function that gets the vector given a lattice node. |
Definition at line 203 of file vtkoutput.cc.
|
private |
filesystem path for output
Definition at line 169 of file vtkoutput.h.
|
private |
Event number.
Definition at line 172 of file vtkoutput.h.
|
private |
Number of vtk output in current event.
Definition at line 174 of file vtkoutput.h.
|
private |
Number of density lattice vtk output in current event.
Definition at line 177 of file vtkoutput.h.
|
private |
Number of energy-momentum tensor lattice vtk output in current event.
Definition at line 179 of file vtkoutput.h.
|
private |
Number of Landau frame energy-momentum tensor vtk output in current event.
Definition at line 181 of file vtkoutput.h.
|
private |
Number of Landau rest frame velocity vtk output in current event.
Definition at line 183 of file vtkoutput.h.
|
private |
Number of fluidization output.
Definition at line 185 of file vtkoutput.h.
|
private |
Is the VTK output a thermodynamics output.
Definition at line 187 of file vtkoutput.h.