10 #include <boost/format.hpp>
11 #include <boost/foreach.hpp>
12 #include <boost/algorithm/string.hpp>
17 #include <G4LogicalVolume.hh>
18 #include <G4PVPlacement.hh>
19 #include <G4LogicalSkinSurface.hh>
20 #include <G4OpticalSurface.hh>
23 #include <G4SubtractionSolid.hh>
24 #include <G4Material.hh>
28 #include <arich/geometry/GeoARICHBtestCreator.h>
29 #include <arich/geometry/ARICHGeometryPar.h>
30 #include <arich/geometry/ARICHBtestGeometryPar.h>
32 #include <geometry/Materials.h>
33 #include <geometry/CreatorFactory.h>
34 #include <geometry/utilities.h>
35 #include <framework/gearbox/GearDir.h>
36 #include <framework/gearbox/Unit.h>
37 #include <framework/logging/Logger.h>
39 #include <framework/datastore/StoreObjPtr.h>
40 #include <framework/dataobjects/EventMetaData.h>
42 #include <arich/simulation/SensitiveDetector.h>
43 #include <arich/simulation/SensitiveAero.h>
46 using namespace boost;
54 using namespace geometry;
62 geometry::CreatorFactory<GeoARICHBtestCreator> GeoARICHBtestFactory(
"ARICHBtestCreator");
68 GeoARICHBtestCreator::GeoARICHBtestCreator():
92 B2INFO(
"GeoARICHBtestCreator::create");
96 PyObject* m = PyImport_AddModule(strdup(
"__main__"));
98 PyObject* v = PyObject_GetAttrString(m, strdup(
"runno"));
100 run = PyLong_AsLong(v);
103 B2INFO(
"GeoARICHBtestCreator::create runno = " << run);
106 B2INFO(
"eventMetaDataPtr run:" << run);
112 string Type = content.getString(
"@type",
"");
115 sprintf(nodestr,
"run[runno=%d]", run);
116 if (Type ==
"beamtest") {
117 BOOST_FOREACH(
const GearDir & runparam, content.getNodes(nodestr)) {
136 B2INFO(
"neve : " <<
m_neve);
142 B2INFO(
"rx : " <<
m_rx);
143 B2INFO(
"ry : " <<
m_ry);
152 sprintf(nodestr,
"setup/aerogel/row[@id=\"%s\"]",
m_aerogelID.c_str());
154 GearDir runparam(content, nodestr);
155 B2INFO(
"id : " << runparam.
getString(
"@id",
""));
156 BOOST_FOREACH(
const GearDir & aeroparam, runparam.
getNodes(
"aerogel")) {
157 aerogelname = aeroparam.
getString(
".",
"");
158 string stype = aeroparam.
getString(
"@type",
"");
159 B2INFO(stype <<
" aerogelname : " << aerogelname);
160 sprintf(nodestr,
"setup/aerogelinfo/row[@id=\"%s\"]", aerogelname.c_str());
161 GearDir infoparam(content, nodestr);
163 double agelrefind = infoparam.
getDouble(
"refind", 1);
164 double ageltrlen = infoparam.
getLength(
"trlen", 0);
165 double agelthickness = infoparam.
getLength(
"thickness", 0);
166 if (stype !=
string(
"left")) {
171 B2INFO(
"refind : " << agelrefind);
172 B2INFO(
"trlen : " << ageltrlen /
Unit::mm);
173 B2INFO(
"thickness : " << agelthickness /
Unit::mm);
180 char agelsupport =
m_hapdID.at(size - 1);
186 sprintf(nodestr,
"setup/hapd/row[@id=\"%s\"]",
m_hapdID.substr(0, size).c_str());
187 B2INFO(
"nodestr : " << nodestr);
189 GearDir hapdparam(content, nodestr);
205 GearDir setup(content,
"setup");
213 G4MaterialPropertiesTable* mTable = material->GetMaterialPropertiesTable();
214 if (!mTable)
return 0;
215 G4MaterialPropertyVector* mVector = mTable->GetProperty(
"RINDEX");
216 if (!mVector)
return 0;
227 string wallMat =
Module.getString(
"wallMaterial");
228 string winMat =
Module.getString(
"windowMaterial");
229 string botMat =
Module.getString(
"Bottom/material");
237 if (!wref) B2WARNING(
"Material '" << winMat <<
238 "', required for ARICH photon detector window as no specified refractive index. Continuing, but no photons in ARICH will be detected.");
244 double wallThick =
Module.getLength(
"moduleWallThickness") /
Unit::mm;
245 double winThick =
Module.getLength(
"windowThickness") /
Unit::mm ;
247 double botThick =
Module.getLength(
"Bottom/thickness") /
Unit::mm;
250 if (sensXsize > modXsize - 2 * wallThick)
251 B2FATAL(
"ARICH photon detector module: Sensitive surface is too big. Doesn't fit into module box.");
252 if (winThick + botThick > modZsize)
253 B2FATAL(
"ARICH photon detector module: window + bottom thickness larger than module thickness.");
256 G4Box* moduleBox =
new G4Box(
"Box", modXsize / 2., modXsize / 2., modZsize / 2.);
257 G4LogicalVolume* lmoduleBox =
new G4LogicalVolume(moduleBox, boxFill,
"moduleBox");
260 G4Box* tempBox =
new G4Box(
"tempBox", modXsize / 2. - wallThick, modXsize / 2. - wallThick,
261 modZsize / 2. + 0.1);
262 G4SubtractionSolid* moduleWall =
new G4SubtractionSolid(
"Box-tempBox", moduleBox, tempBox);
263 G4LogicalVolume* lmoduleWall =
new G4LogicalVolume(moduleWall, wallMaterial,
"moduleWall");
264 setColor(*lmoduleWall,
"rgb(1.0,0.0,0.0,1.0)");
265 new G4PVPlacement(G4Transform3D(), lmoduleWall,
"moduleWall", lmoduleBox,
false, 1);
268 G4Box* winBox =
new G4Box(
"winBox", modXsize / 2. - wallThick, modXsize / 2. - wallThick, winThick / 2.);
269 G4LogicalVolume* lmoduleWin =
new G4LogicalVolume(winBox, windowMaterial,
"moduleWindow");
270 setColor(*lmoduleWin,
"rgb(0.7,0.7,0.7,1.0)");
271 G4Transform3D transform = G4Translate3D(0., 0., (-modZsize + winThick) / 2.);
272 new G4PVPlacement(transform, lmoduleWin,
"moduleWindow", lmoduleBox,
false, 1);
275 G4Box* botBox =
new G4Box(
"botBox", modXsize / 2. - wallThick, modXsize / 2. - wallThick, botThick / 2.);
276 G4LogicalVolume* lmoduleBot =
new G4LogicalVolume(botBox, bottomMaterial,
"moduleBottom");
278 setColor(*lmoduleBot,
"rgb(0.0,1.0,0.0,1.0)");
279 G4Transform3D transform1 = G4Translate3D(0., 0., (modZsize - botThick) / 2.);
285 new G4LogicalSkinSurface(
"bottomSurface", lmoduleBot, optSurf);
286 }
else B2INFO(
"ARICH: No optical properties are specified for detector module bottom surface.");
287 new G4PVPlacement(transform1, lmoduleBot,
"moduleBottom", lmoduleBox,
false, 1);
290 G4Box* sensBox =
new G4Box(
"sensBox", sensXsize / 2., sensXsize / 2., 0.1 *
Unit::mm);
291 G4LogicalVolume* lmoduleSens =
new G4LogicalVolume(sensBox, boxFill,
"moduleSensitive");
293 setColor(*lmoduleSens,
"rgb(0.5,0.5,0.5,1.0)");
294 G4Transform3D transform2 = G4Translate3D(0., 0., (-modZsize + 0.1) / 2. + winThick);
295 new G4PVPlacement(transform2, lmoduleSens,
"moduleSensitive", lmoduleBox,
false, 1);
306 G4double density = (RefractiveIndex - 1) / 0.21 * CLHEP::g / CLHEP::cm3;
307 B2INFO(
"Creating ARICH " << aeroname <<
" n=" << RefractiveIndex <<
" density=" << density / CLHEP::g * CLHEP::cm3 <<
" g/cm3");
309 G4Material* _aerogel =
new G4Material(aeroname, density, 4);
310 _aerogel->AddElement(materials.
getElement(
"O"), 0.665);
311 _aerogel->AddElement(materials.
getElement(
"H"), 0.042);
312 _aerogel->AddElement(materials.
getElement(
"Si"), 0.292);
313 _aerogel->AddElement(materials.
getElement(
"C"), 0.001);
316 const G4double AerogelAbsorbtionLength = 1000 *
Unit::mm;
318 const G4int NBins = 40;
319 G4double MomentumBins[NBins];
321 G4double AerogelRindex[NBins];
322 G4double AerogelAbsorption[NBins];
323 G4double AerogelRayleigh[NBins];
325 G4double MaxPhotonEnergy = 5 * CLHEP::eV;
326 G4double MinPhotonEnergy = 1.5 * CLHEP::eV;
328 for (G4int i = 0; i < NBins; i++) {
330 const G4double energy = float(i) / NBins * (MaxPhotonEnergy - MinPhotonEnergy) + MinPhotonEnergy;
332 MomentumBins[i] = energy;
333 AerogelRindex[i] = RefractiveIndex;
334 AerogelAbsorption[i] = AerogelAbsorbtionLength;
336 const G4double Lambda0 = 400 * 1e-6 * CLHEP::mm;
337 const G4double Lambda = 1240 * CLHEP::eV / energy * 1e-6 * CLHEP::mm;
338 G4double x = Lambda / Lambda0;
339 AerogelRayleigh[i] = AerogelTransmissionLength * x * x * x * x;
343 G4MaterialPropertiesTable* AeroProperty =
new G4MaterialPropertiesTable();
344 AeroProperty->AddProperty(
"RINDEX", MomentumBins, AerogelRindex, NBins);
345 AeroProperty->AddProperty(
"ABSLENGTH", MomentumBins, AerogelAbsorption, NBins);
346 AeroProperty->AddProperty(
"RAYLEIGH", MomentumBins, AerogelRayleigh, NBins);
349 _aerogel->SetMaterialPropertiesTable(AeroProperty);
359 B2INFO(
"ARICH Btest geometry will be built.");
366 GearDir boxParams(content,
"ExperimentalBox");
373 double zoffset = boxParams.
getLength(
"beamcenter/z") * CLHEP::mm /
Unit::mm - zBox / 2.;
374 G4ThreeVector roffset(xoffset, yoffset, zoffset);
380 string boxMat = boxParams.
getString(
"material");
382 G4Box* expBox =
new G4Box(
"ExperimentalBox", xBox / 2., yBox / 2., zBox / 2.);
383 G4LogicalVolume* topVolume =
new G4LogicalVolume(expBox, boxMaterial,
"ARICH.experimentalbox");
384 new G4PVPlacement(G4Transform3D(), topVolume,
"ARICH.experimentalbox", &topWorld,
false, 1);
387 TVector3 trackingshift(content.getLength(
"tracking/shift/x"),
388 content.getLength(
"tracking/shift/y"),
389 content.getLength(
"tracking/shift/z"));
392 sprintf(mnodestr,
"tracking/shift/run[@id=\"%d\"]",
m_runno);
393 if (content.exists(mnodestr)) {
394 GearDir runtrackingshift(content, mnodestr);
395 trackingshift[0] = runtrackingshift.
getLength(
"x");
396 trackingshift[1] = runtrackingshift.
getLength(
"y");
397 trackingshift[2] = runtrackingshift.
getLength(
"z");
402 BOOST_FOREACH(
const GearDir & mwpc, content.getNodes(
"tracking/mwpc")) {
411 G4Box* mwpcBox =
new G4Box(
"MwpcBox", x / 2., y / 2., z / 2.);
412 G4LogicalVolume* mwpcVol =
new G4LogicalVolume(mwpcBox,
Materials::get(mwpc.
getString(
"material")),
"ARICH.mwpc");
413 new G4PVPlacement(G4Transform3D(G4RotationMatrix(), G4ThreeVector(px, py, pz) + roffset), mwpcVol,
"ARICH.mwpc", topVolume,
false,
417 int id = mwpc.
getInt(
"@id", -1);
418 B2INFO(
"GeoARICHBtestCreator::" <<
LogVar(
"MWPC ID",
id));
419 if (id < 4 && id >= 0) {
420 m_mwpc[id].
tdc[0] = mwpc.
getInt(
"tdc/y/up");
421 m_mwpc[id].
tdc[1] = mwpc.
getInt(
"tdc/y/down");
422 m_mwpc[id].
tdc[2] = mwpc.
getInt(
"tdc/x/left");
423 m_mwpc[id].
tdc[3] = mwpc.
getInt(
"tdc/x/right");
424 m_mwpc[id].
atdc = mwpc.
getInt(
"tdc/anode", 0);
442 istringstream mapstream;
444 mapstream.str(content.getString(
"hapdmap"));
445 while (mapstream >> mx >> my) {
452 mapstream.str(content.getString(
"hapdchmap"));
453 while (mapstream >> ipx >> ipy) {
458 GearDir frameParams(content,
"Frame");
462 string envMat = frameParams.
getString(
"material");
471 G4Box* envBox =
new G4Box(
"FrameBox", xFrame / 2., yFrame / 2., zFrame / 2.);
472 G4LogicalVolume* lenvBox =
new G4LogicalVolume(envBox, envMaterial,
"ARICH.frame");
473 G4ThreeVector frameOrigin0(
m_framedx + px, py, pz);
474 G4ThreeVector frameOrigin = frameOrigin0 + roffset;
475 G4RotationMatrix frameRotation;
476 frameRotation.rotateY(-
m_rotation1 * CLHEP::degree);
477 G4Transform3D frameTransformation = G4Transform3D(frameRotation, frameOrigin);
479 new G4PVPlacement(frameTransformation, lenvBox,
"ARICH.frame", topVolume,
false, 1);
482 TVector3 rotationCenter = TVector3(frameOrigin0.x() *
Unit::mm / CLHEP::mm, frameOrigin0.y() *
Unit::mm / CLHEP::mm,
483 frameOrigin0.z() *
Unit::mm / CLHEP::mm);
489 B2INFO(content.getPath());
491 GearDir hapdcontent(content, nodestr);
496 char mirrornodestr[256];
497 sprintf(mirrornodestr,
"Mirrors/setup[@id=\"%s\"]",
m_mirrorID.c_str());
499 GearDir mirrorcontent(content, mirrornodestr);
500 B2INFO(mirrorcontent.
getPath());
503 m_arichgp->
Initialize(hapdcontent, mirrorcontent);
506 GearDir moduleParam(hapdcontent,
"Detector/Module");
507 G4LogicalVolume* detModule =
buildModule(moduleParam);
509 double detZpos = hapdcontent.
getLength(
"Detector/Plane/zPosition") * CLHEP::mm /
Unit::mm;
510 double detThick = hapdcontent.
getLength(
"Detector/Module/moduleZSize") * CLHEP::mm /
Unit::mm;
513 for (
int i = 1; i <= nModules; i++) {
515 origin.setZ(detZpos + detThick / 2.);
519 G4Transform3D trans = G4Transform3D(Ra, origin);
520 new G4PVPlacement(G4Transform3D(Ra, origin), detModule,
"detModule", lenvBox,
false, i);
521 B2INFO(nodestr <<
"Module " << i <<
" is build ");
525 BOOST_FOREACH(
const double & ch, hapdcontent.
getArray(
"HotChannels")) {
526 int channelID = (int) ch;
527 int moduleID = (npx) ? channelID / (npx * npx) : 0;
528 channelID %= (npx * npx);
529 m_arichgp->
setActive(moduleID, channelID,
false);
530 B2INFO(
"HotChannel " << ch <<
" : Module " << moduleID <<
"channelID " << channelID <<
" disabled");
533 BOOST_FOREACH(
const double & ch, hapdcontent.
getArray(
"DeadChannels")) {
534 int channelID = (int) ch;
535 int moduleID = (npx) ? channelID / (npx * npx) : 0;
536 channelID %= (npx * npx);
537 m_arichgp->
setActive(moduleID, channelID,
false);
538 B2INFO(
"DeadChannel " << ch <<
" : Module " << moduleID <<
"channelID " << channelID <<
" disabled");
541 GearDir aerogelParam(content,
"Aerogel");
548 double meanrefind = 0;
549 double meantrlen = 0;
552 PyObject* m = PyImport_AddModule(strdup(
"__main__"));
555 PyObject* v = PyObject_GetAttrString(m, strdup(
"averageagel"));
557 averageagel = PyLong_AsLong(v);
560 B2INFO(
"Python averageagel = " << averageagel);
564 for (
unsigned int ilayer = 0; ilayer <
m_agelthickness.size(); ilayer++) {
566 sprintf(aeroname,
"Aerogel%u", ilayer + 1);
579 G4Box* tileBox =
new G4Box(
"tileBox", sizeX / 2., sizeY / 2., sizeZ / 2.);
580 G4LogicalVolume* lTile =
new G4LogicalVolume(tileBox, tileMaterial,
"Tile", 0, ilayer == 0 ?
m_sensitiveAero : 0);
581 setColor(*lTile,
"rgb(0.0, 1.0, 1.0,1.0)");
582 G4Transform3D trans = G4Translate3D(posX, posY, posZ + sizeZ / 2. - zFrame / 2.);
583 new G4PVPlacement(trans, lTile,
"ARICH.tile", lenvBox,
false, ilayer + 1);
587 B2INFO(
"Average aerogel will be used in the reconstruction ");
591 if (meantrlen > 0 && posZ > 0) meantrlen = 1 / meantrlen / posZ;
597 GearDir mirrorsParam(mirrorcontent,
"Mirrors");
601 string mirrMat = mirrorsParam.
getString(
"material");
603 G4Box* mirrBox =
new G4Box(
"mirrBox", thickness / 2., height / 2., width / 2.);
604 G4LogicalVolume* lmirror =
new G4LogicalVolume(mirrBox, mirrMaterial,
"mirror");
607 GearDir surface(mirrorsParam,
"Surface");
609 new G4LogicalSkinSurface(
"mirrorsSurface", lmirror, optSurf);
611 BOOST_FOREACH(
const GearDir & mirror, mirrorsParam.
getNodes(
"Mirror")) {
616 G4ThreeVector origin(xpos, ypos, zpos + width / 2. - zFrame / 2.);
619 G4Transform3D trans = G4Transform3D(Ra, origin);
620 new G4PVPlacement(G4Transform3D(Ra, origin), lmirror,
"ARICH.mirror", lenvBox,
false, iMirror);
624 m_arichbtgp->
Print();
The Class for ARICH Beamtest Geometry Parameters.
The Class for ARICH Geometry Parameters.
Beamtest ARICH Geometry Tracking Class.
float slp[2]
Calibration constants of the MWPC (\delta x= slope \delta t + offset) - slopes for x an y direction.
int cutll[2]
Cuts on the tdc sums - lower levels.
float pos[3]
MWPC chamber position.
int tdc[4]
TDC of the 4 cathode signals.
int atdc
TDC of the anode signal.
float offset[2]
Calibration constants of the MWPC - offsets for x an y direction.
int cutul[2]
Cuts on the tdc sums - upper levels.
GearDir is the basic class used for accessing the parameter store.
virtual std::string getString(const std::string &path="") const noexcept(false) override
Get the parameter path as a string.
Type-safe access to single objects in the data store.
static const double mm
[millimeters]
static const double rad
Standard of [angle].
static const double eV
[electronvolt]
static const double MeV
[megaelectronvolt]
std::string m_comment
comment in the runlog
double m_framedx
shift of the frame
int m_aerosupport
Type of aerogel support - not used at the moment.
std::string m_aerogelID
ID of the aerogel configuration setup.
double m_rotation1
rotation angle of the frame
std::string m_runtype
Type of the beamtest run.
std::vector< double > m_agelrefind
vector of aerogel refractive indices
std::string m_comment1
tbc
void createBtestGeometry(const GearDir &content, G4LogicalVolume &topVolume)
Creation of the beamtest geometry.
int m_runno
Beamtest Run number.
std::string m_mytype
type of the run
G4Material * createAerogel(const char *aeroname, double rind, double trl)
create aerogel material
double m_ry
y shift of the prototype ARICH frame
std::vector< double > m_ageltrlen
vector of aerogel transmission lengths
virtual ~GeoARICHBtestCreator()
The destructor of the GeoPXDCreator class.
G4LogicalVolume * buildModule(GearDir Module)
Build the module.
double getAvgRINDEX(G4Material *material)
Get the average refractive index if the material.
std::string m_mirrorID
ID of the mirror configuration setup.
virtual void create(const GearDir &content, G4LogicalVolume &topVolume, geometry::GeometryTypes type)
Creates the ROOT Objects for the ARICH Beamtest 2011 geometry.
double m_aerogeldx
shift of the aerogel center
std::string m_datum
datum of the runlog
SensitiveAero * m_sensitiveAero
pointer to the sesnitive aerogel
std::string m_author
Beamtest runlog record author.
std::string m_daqqa
classification of the run
std::string m_hapdID
ID of the HAPD configuration setup.
std::vector< double > m_agelthickness
vector of aerogel thicknesses
double m_rotation
rotation angle of the setup
SensitiveDetector * m_sensitive
pointer to the sensitive detector
double m_rx
x shift of the prototype ARICH frame
int m_neve
Number of event in the beamtest run.
int m_configuration
configuration number of the HAPD
This is optional (temporary) class that provides information on track parameters on aerogel plane,...
The Class for ARICH Sensitive Detector.
double getAngle(const std::string &path="") const noexcept(false)
Get the parameter path as a double converted to the standard angle unit.
std::vector< double > getArray(const std::string &path) const noexcept(false)
Get the parameter path as a list of double values converted to the standard unit.
double getDouble(const std::string &path="") const noexcept(false)
Get the parameter path as a double.
std::string getPath() const
Return path of the current interface.
double getLength(const std::string &path="") const noexcept(false)
Get the parameter path as a double converted to the standard length unit.
std::vector< GearDir > getNodes(const std::string &path="") const
Get vector of GearDirs which point to all the nodes the given path evaluates to.
int getInt(const std::string &path="") const noexcept(false)
Get the parameter path as a int.
Thin wrapper around the Geant4 Material system.
static G4Material * get(const std::string &name)
Find given material.
static Materials & getInstance()
Get a reference to the singleton instance.
G4OpticalSurface * createOpticalSurface(const gearbox::Interface ¶meters)
Create an optical surface from parameters, will abort on error.
G4Element * getElement(const std::string &name)
Find given chemical element.
Class to store variables with their name which were sent to the logging service.
int getDetectorXPadNumber()
get number of pads of detector module (in one direction)
void setRotationCenter(const TVector3 &)
Set the rotation center of the Aerogel RICH frame.
void setAeroTransLength(int ilayer, double trlen)
set transmission length of "ilayer" aerogel layer
int AddHapdElectronicMapPair(int, int)
Set the mapping of the electronic channel to the HAPD module nr and the channel number.
void setAerogelThickness(int ilayer, double thick)
set thickness of "ilayer" aerogel layer
double getSensitiveSurfaceSize() const
get size of detector sensitive surface (size of two chips + gap between)
void setTrackingShift(const TVector3 &)
Set the tracking shift.
bool getAverageAgel()
Get the flag for the reconstruction by using the average aerogel refractive index.
void setFrameRotation(double)
Set the rotation angle of the Aerogel RICH frame.
void setMwpc(ARICHTracking *m_mwpc)
Set the pointer of the tracking MWPCs.
void Initialize(const GearDir &content)
calculates detector parameters needed for geometry build and reconstruction.
void setAerogelZPosition(int ilayer, double zPos)
set z position of "ilayer" aerogel layer
static ARICHBtestGeometryPar * Instance()
Static method to get a reference to the ARICHBtestGeometryPar instance.
void Print(void) const
Print some debug information.
static ARICHGeometryPar * Instance()
Static method to get a reference to the ARICHGeometryPar instance.
void setAeroRefIndex(int ilayer, double n)
set refractive index of "ilayer" aerogel layer
double getModAngle(int copyno)
get the angle of copyno-th HAPD rotation
G4ThreeVector getOriginG4(int copyNo)
get the position of copyNo-th HAPD module origin (returns G4ThreeVector)
void setOffset(const TVector3 &)
Set of the setup global offset.
void setAverageAgel(bool)
Set the flag for the reconstruction by using the average aerogel refractive index.
int getNMCopies() const
get the total number of HAPD modules
void setActive(int module, int channel, bool val)
set the channel on/off
int AddHapdChannelPositionPair(double, double)
Set the position of the HAPD channel.
void setWindowRefIndex(double refInd)
set detector module window refractive index
void setVisibility(G4LogicalVolume &volume, bool visible)
Helper function to quickly set the visibility of a given volume.
void setColor(G4LogicalVolume &volume, const std::string &color)
Set the color of a logical volume.
GeometryTypes
Flag indiciating the type of geometry to be used.
Abstract base class for different kinds of events.