![]() |
Project
|
Audits a placed geometry against the magnetic field it will be transported in. More...
#include "DetectorsBase/GeometryManager.h"#include "Field/MagneticField.h"#include <TFile.h>#include <TGeoBBox.h>#include <TGeoCone.h>#include <TGeoEltu.h>#include <TGeoManager.h>#include <TGeoMatrix.h>#include <TGeoMedium.h>#include <TGeoNavigator.h>#include <TGeoNode.h>#include <TGeoPcon.h>#include <TGeoPgon.h>#include <TGeoShape.h>#include <TGeoTube.h>#include <TGeoVolume.h>#include <TRandom3.h>#include <TVectorD.h>#include <boost/program_options.hpp>#include <nlohmann/json.hpp>#include <algorithm>#include <atomic>#include <cmath>#include <cstdio>#include <cstring>#include <ctime>#include <fstream>#include <iostream>#include <map>#include <set>#include <string>#include <thread>#include <utility>#include <vector>Go to the source code of this file.
Typedefs | |
| using | json = nlohmann::json |
Functions | |
| int | main (int argc, char **argv) |
Audits a placed geometry against the magnetic field it will be transported in.
The tool reads a geometry file and a magnetic field, and answers two questions that cannot be answered by looking at either one alone:
It also answers one question about the geometry alone, and therefore runs that part without a field under –reachability-only: does every placement actually occupy the space it was built in? A daughter outside its mother, or one shadowed by an overlapping sibling, is never reached by the navigator, carries no material and produces no hits, and nothing in the construction code says so.
It detects and proposes. It never modifies a geometry.
The field enters in two ways. A support model (an outer bound on where |B| exceeds a threshold, maximised over phi) supplies the geometric argument: a placement whose extent misses every band of the model is field-free, and that is the only way this tool ever concludes "field-free". Sampling enters only in the opposite direction, to disprove – finding field inside a volume settles the question, finding none does not.
Reading the geometry needs no detector code: a medium's ifield flag and its sensitivity are GSTMED parameters 1 and 0 of the TGeoMedium, and are recovered from the file itself.
Definition in file o2sim_geometry_doctor.cxx.
| using json = nlohmann::json |
Definition at line 83 of file o2sim_geometry_doctor.cxx.
Definition at line 1973 of file o2sim_geometry_doctor.cxx.