BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
|
Wrapper class of BDSFieldQuery that accumulates values for visualisation. More...
#include <BDSFieldQueryForVis.hh>
Public Member Functions | |
const std::vector< std::array< G4double, 9 > > | Values () const |
G4double | MaxFieldE () const |
G4double | MaxFieldB () const |
virtual void | QueryField (const BDSFieldQueryInfo *query) |
Reserve the vector size we need first, then proceed as normal. Avoids big copies. | |
virtual void | CleanUp () |
Call the base class method and also clear the vector of values in this class. | |
virtual void | OpenFiles (const BDSFieldQueryInfo *) |
Replace with empty implementation so no file handling is done for visualisation. | |
virtual void | WriteHeader (std::ofstream &, const BDSFieldQueryInfo *) const |
Replace with empty implementation so no file handling is done for visualisation. | |
virtual void | CloseFiles () |
Replace with empty implementation so no file handling is done for visualisation. | |
virtual void | WriteFieldValue (const G4ThreeVector &, G4double, const G4double[6]) |
Replace with empty implementation so no file handling is done for visualisation. | |
virtual void | PrintBAndEInfo (const BDSFieldQueryInfo *) const |
Replace with empty implementation so no file handling is done for visualisation. | |
![]() | |
virtual void | QueryField (const BDSFieldQueryInfo *query) |
Query the field in the Geant4 model according to information in query. | |
void | QueryFields (const std::vector< BDSFieldQueryInfo * > &fieldQueries) |
Vector version of above function. Unique output files for each query. | |
virtual void | CleanUp () |
Reset any member variables used during a query. Closes any files if open. | |
Static Public Member Functions | |
static G4double | SimpleMag (G4double x, G4double y, G4double z) |
Calculate magnitude of 3-vector without having to construct one. | |
![]() | |
static void | AttachWorldVolumeToNavigator (G4VPhysicalVolume *worldPVIn) |
Setup the navigator w.r.t. to a world volume. | |
Protected Member Functions | |
virtual void | GetFieldValue (const G4ThreeVector &globalXYZ, const G4ThreeVector &globalDirection, G4double tGlobal, G4double fieldValue[6]) |
Call base class method but make a copy of the global position and fields in this class. | |
![]() | |
virtual void | GetFieldValue (const G4ThreeVector &globalXYZ, const G4ThreeVector &globalDirection, G4double tGlobal, G4double fieldValue[6]) |
virtual void | CheckIfFieldObjectSpecified (const BDSFieldQueryInfo *query) const |
Warn the user if the fieldObject variable is use when it shouldn't be. | |
Private Attributes | |
std::vector< std::array< G4double, 9 > > | values |
G4double | maxFieldB |
G4double | maxFieldE |
G4bool | drawZeroValuePoints |
Wrapper class of BDSFieldQuery that accumulates values for visualisation.
Definition at line 37 of file BDSFieldQueryForVis.hh.
BDSFieldQueryForVis::BDSFieldQueryForVis | ( | ) |
Definition at line 32 of file BDSFieldQueryForVis.cc.
|
virtual |
Definition at line 38 of file BDSFieldQueryForVis.cc.
|
virtual |
Call the base class method and also clear the vector of values in this class.
Reimplemented from BDSFieldQuery.
Definition at line 41 of file BDSFieldQueryForVis.cc.
References BDSFieldQuery::CleanUp().
|
inlinevirtual |
Replace with empty implementation so no file handling is done for visualisation.
Reimplemented from BDSFieldQuery.
Definition at line 59 of file BDSFieldQueryForVis.hh.
|
protectedvirtual |
Call base class method but make a copy of the global position and fields in this class.
Reimplemented from BDSFieldQuery.
Definition at line 57 of file BDSFieldQueryForVis.cc.
References BDSFieldQuery::GetFieldValue(), and SimpleMag().
|
inline |
Definition at line 45 of file BDSFieldQueryForVis.hh.
|
inline |
Definition at line 44 of file BDSFieldQueryForVis.hh.
|
inlinevirtual |
Replace with empty implementation so no file handling is done for visualisation.
Reimplemented from BDSFieldQuery.
Definition at line 57 of file BDSFieldQueryForVis.hh.
|
inlinevirtual |
Replace with empty implementation so no file handling is done for visualisation.
Reimplemented from BDSFieldQuery.
Definition at line 63 of file BDSFieldQueryForVis.hh.
|
virtual |
Reserve the vector size we need first, then proceed as normal. Avoids big copies.
Reimplemented from BDSFieldQuery.
Definition at line 49 of file BDSFieldQueryForVis.cc.
References BDSFieldQuery::QueryField().
|
static |
Calculate magnitude of 3-vector without having to construct one.
Definition at line 74 of file BDSFieldQueryForVis.cc.
Referenced by GetFieldValue().
|
inline |
Definition at line 43 of file BDSFieldQueryForVis.hh.
|
inlinevirtual |
Replace with empty implementation so no file handling is done for visualisation.
Reimplemented from BDSFieldQuery.
Definition at line 60 of file BDSFieldQueryForVis.hh.
|
inlinevirtual |
Replace with empty implementation so no file handling is done for visualisation.
Reimplemented from BDSFieldQuery.
Definition at line 58 of file BDSFieldQueryForVis.hh.
|
private |
Definition at line 77 of file BDSFieldQueryForVis.hh.
|
private |
Definition at line 75 of file BDSFieldQueryForVis.hh.
|
private |
Definition at line 76 of file BDSFieldQueryForVis.hh.
|
private |
Definition at line 74 of file BDSFieldQueryForVis.hh.