4 #include <fwk/CentralConfig.h>
5 #include <fwk/LocalCoordinateSystem.h>
6 #include <fwk/CoordinateSystemRegistry.h>
7 #include <fwk/MagneticFieldModel.h>
9 #include <det/Detector.h>
10 #include <rdet/RDetector.h>
11 #include <sdet/SDetector.h>
12 #include <sdet/SDetectorConstants.h>
14 #include <evt/Event.h>
15 #include <evt/ShowerRecData.h>
16 #include <evt/ShowerSRecData.h>
17 #include <evt/ShowerRRecData.h>
18 #include <evt/Header.h>
19 #include <revt/REvent.h>
20 #include <revt/Header.h>
22 #include <utl/Point.h>
23 #include <utl/UTMPoint.h>
24 #include <utl/ReferenceEllipsoid.h>
25 #include <utl/AugerUnits.h>
26 #include <utl/Reader.h>
27 #include <utl/TimeStamp.h>
28 #include <utl/UTCDateTime.h>
30 #include <utl/GeometryUtilities.h>
31 #include <utl/RadioGeometryUtilities.h>
32 #include <utl/System.h>
39 #include <boost/algorithm/string.hpp>
40 #include <boost/tokenizer.hpp>
56 using std::stringstream;
57 using std::ostringstream;
65 typedef boost::tokenizer<boost::char_separator<char>>
mytok;
84 topBranch.
GetChild(
"MonthlyAtmosphericModel").
GetData(fMonthlyAtmosphericModel);
89 topBranch.
GetChild(
"GetMagneticFieldFromModel").
GetData(fGetMagneticFieldFromModel);
90 topBranch.
GetChild(
"MagneticFieldDeclination").
GetData(fMagneticFieldDeclination);
91 topBranch.
GetChild(
"MaxAntennaDistance").
GetData(fMaxAntennaDistanceFromCore);
92 topBranch.
GetChild(
"SeaLevelRefractivity").
GetData(fSeaLevelRefractivity);
97 topBranch.
GetChild(
"ObserverLevelOffset").
GetData(fObserverLevelOffset);
98 fUseCoreDistance = (topBranch.
GetChild(
"DistanceTo").
Get<
string>() ==
"core");
113 info <<
"\n-------RdReasSimPreparator::Init\n"
114 " WorkingDir : "<< fWorkingDir <<
"\n"
115 " Corsika : " << fCorsikapath <<
'/' << fCorsikaBin <<
"\n"
116 " SEED : " << fSeed <<
" RUNNumber " << fRunNumber <<
'\n';
119 info <<
"Conex is not activated\n";
121 info <<
"Conex is active\n Conex : " << fConexDir<<
"/"<<fConexBin<<
"\n";
131 RdREASSimPreparator::Run(
Event& event)
135 const Header& head =
event.GetHeader();
136 eventHeader = head.
GetId();
144 if (fUseGeometry ==
"SD") {
148 if (fUseGeometry ==
"RD") {
164 sqrt(
pow(theMagneticFieldVector.
GetX(zeCoreCS), 2) +
pow(theMagneticFieldVector.
GetY(zeCoreCS), 2));
165 fBFieldVertical = theMagneticFieldVector.
GetZ(zeCoreCS);
168 unsigned int fmodatm = fMonthlyAtmosphericModel;
169 if (fMonthlyAtmosphericModel < 0 || fMonthlyAtmosphericModel > 29) {
172 fmodatm = month + 17;
176 const vector<string> v_detectorfiles = WriteDetectorFile(zeCore, zeaxis);
177 const string corsikainp = CorsikaInpFileWriter(zeShower, zeCore, fmodatm);
178 const string corsikascript = LaunchCorsikaSim(corsikainp);
179 const string reassim = REASFileWriter(zeCore, zeShower, corsikainp, head, rHead);
186 RdREASSimPreparator::Finish()
188 INFO(
"RdREASSimPreparator::Finish()");
199 ofstream
out(fWorkingDir +
"SdId-SimId_relation.txt", std::ios::app);
200 out << eventHeader <<
" --> " << AddZero(fRunNumber, 6) << endl;
204 filename <<
"RUN" << AddZero(fRunNumber, 6) <<
".inp";
205 ofstream inpfile(fWorkingDir + filename.str());
211 if (fUseGeometry ==
"SD") {
215 if (fUseGeometry ==
"RD") {
221 az += fGetMagneticFieldFromModel ? fMagneticFieldDeclinationFromModel : fMagneticFieldDeclination;
229 if (fUseEnergy ==
"SD")
231 if (fUseEnergy ==
"RD")
235 UTMPoint utmcore(core, ReferenceEllipsoid::GetWGS84());
238 inpfile <<
"RUNNR\t" << AddZero(fRunNumber, 6) <<
"\n"
240 "SEED\t" << fSeed <<
"\t0\t0\n";
242 inpfile <<
"SEED\t" << (fSeed + fSeed*2) <<
"\t0\t0\n";
244 inpfile <<
"SEED\t" << (fSeed + fSeed/3) <<
"\t0\t0\n";
246 inpfile <<
"NSHOW\t1\n";
249 const string cnxfile = LaunchConexSim(show, core);
250 double firstintheight = 0;
251 long firstinttarget = 0;
253 ExtractTypicalShower(fWorkingDir, cnxfile, firstintheight, firstinttarget, showername,
"00000");
254 cout <<
" MM : After Conex\n"
255 " First interactrion " << firstintheight <<
"\n"
256 " First interaction target " << firstinttarget <<
"\n"
257 " Shower Name " << showername << endl;
258 inpfile <<
"INFILE\t" << fWorkingDir <<
'/' <<cnxfile << showername
259 <<
" first interaction secondaries\n"
260 "FIXHEI\t" << firstintheight <<
" " << firstinttarget <<
" height and target\n";
262 inpfile <<
"ERANGE\t" << energy/
GeV <<
'\t' << energy/
GeV << endl;
264 if (fprim ==
"Proton")
265 inpfile <<
"PRMPAR\t14\n";
266 else if (fprim ==
"Iron")
267 inpfile <<
"PRMPAR\t5626\n";
270 inpfile <<
"THETAP\t" << zen <<
"\t" << zen <<
"\n"
271 "PHIP\t" << az <<
"\t" << az <<
"\n"
272 "ECUTS\t0.3\t1.000E-02\t2.500E-04\t2.500E-04\n"
274 "THIN\t" << fThinningLevel <<
"\t" << (energy /
GeV * fThinningLevel) <<
"\t100E+02\n"
275 "THINH\t1.000E+00\t1.000E+02\n"
276 "OBSLEV\t" << (utmcore.
GetHeight()/
cm - fObserverLevelOffset/
cm) <<
"\n"
278 "STEPFC\t" << fStepfc <<
"\n"
284 if (fGetMagneticFieldFromModel)
285 inpfile <<
"MAGNET\t" << fBFieldHorizontal/
micro/
tesla <<
"\t\t" << -1*fBFieldVertical/
micro/
tesla <<
'\n';
287 inpfile <<
"MAGNET\t"<< fMagneticFieldX/
micro/
tesla <<
"\t" << fMagneticFieldY/
micro/
tesla <<
"\n";
289 inpfile <<
"ATMOD\t" << modatm <<
"\n"
291 "LONGI\tT\t5.\tT\tT\n"
293 "DIRECT\t" << fWorkingDir<<
"/\n"
295 "USER\t"<< fUserName <<
"\n"
298 return filename.str();
304 RdREASSimPreparator::LaunchCorsikaSim(
const string& corsikaparameterfile)
307 filename <<
"RUN" << AddZero(fRunNumber, 6) <<
".sh";
308 ofstream scriptfile(fWorkingDir + filename.str());
309 scriptfile <<
"#!/bin/bash\n"
312 "cd " << fCorsikapath <<
"\n"
314 "export FLUPRO=" << fFLUPRO <<
"\n"
315 "./" << fCorsikaBin <<
" < " << fWorkingDir <<
'/' << corsikaparameterfile
316 <<
" > " << fWorkingDir <<
"/RUN" << AddZero(fRunNumber, 6) <<
".log 2>&1\n";
317 return filename.str();
331 if (fUseGeometry ==
"SD") {
335 if (fUseGeometry ==
"RD") {
339 az += fGetMagneticFieldFromModel ? fMagneticFieldDeclinationFromModel : fMagneticFieldDeclination;
344 filename <<
"Conex" << AddZero(fRunNumber, 6) <<
".sh";
345 ostringstream conexout;
348 conexModel =
"qgsjetII";
349 else if (fModel == 2)
350 conexModel =
"qgsjet";
354 conexout <<
"conex_" << conexModel <<
'_' << AddZero(fSeed, 9) <<
'_';
356 ofstream conexfile(filename.str());
358 if (fUseEnergy ==
"SD")
360 if (fUseEnergy ==
"RD")
362 conexfile <<
"#!/bin/sh\n"
363 "cd "<< fConexDir <<
'\n'
364 << fConexDir <<
'/' << fConexBin
367 <<
" -e " << log10(energy/
eV)
368 <<
" -E " << log10(energy/
eV)
373 <<
" -n " << fNConexShower;
375 if (fprim ==
"Proton")
376 conexfile <<
" -p 100";
377 else if (fprim ==
"Iron")
378 conexfile <<
" -p 5626";
380 conexfile <<
" > "<< fWorkingDir << conexout.str() << fRunNumber <<
".log\n"
381 "mv " << conexout.str() <<
"100.root " << fWorkingDir <<
'\n';
384 cmd <<
"chmod +x " << filename.str();
388 cmd <<
"./" << filename.str();
389 cout <<
" MM " << cmd.str() << endl;
393 return conexout.str() +
"100.root";
407 if (fUseGeometry ==
"SD") {
411 if (fUseGeometry ==
"RD") {
415 az += fGetMagneticFieldFromModel ? fMagneticFieldDeclinationFromModel : fMagneticFieldDeclination;
419 UTMPoint utmcore(zeCore, ReferenceEllipsoid::GetWGS84());
420 filename <<
"SIM" << AddZero(fRunNumber, 6) <<
".reas";
421 ofstream reasfile(fWorkingDir + filename.str());
424 if (fUseEnergy ==
"SD")
426 if (fUseEnergy ==
"RD")
429 reasfile <<
"# CoREAS V1 parameter file\n"
432 "# parameters setting up the spatial observer configuration:\n"
434 "CoreCoordinateNorth = 0 ; in cm\n"
435 "CoreCoordinateWest = 0 ; in cm\n"
436 "CoreCoordinateVertical = " << utmcore.
GetHeight()/
cm<<
" ; in cm\n"
438 "# parameters setting up the temporal observer configuration:\n"
440 "AutomaticTimeBoundaries = 4e-07 ; 0: off, x: automatic boundaries with width x in s\n"
441 "TimeLowerBoundary = -1 ; in s, only if AutomaticTimeBoundaries set to 0\n"
442 "TimeUpperBoundary = 1 ; in s, only if AutomaticTimeBoundaries set to 0\n"
443 "TimeResolution = 5e-10 ; in s\n"
444 "ResolutionReductionScale = 0 ; 0: off, x: decrease time resolution linearly every x cm in radius\n"
445 "GroundLevelRefractiveIndex = " << std::setprecision(7) << fSeaLevelRefractivity << std::setprecision(6) <<
" ; specify refractive index at 0 m asl\n"
447 "# parameters read from CORSIKA files, these are not interpreted by CoREAS but stated here for your convenience\n"
449 "PrimaryParticleEnergy = " << energy/
electronvolt <<
" ; in eV\n"
450 "ShowerZenithAngle = " << zen <<
" ; in degrees\n"
451 "ShowerAzimuthAngle = " << az <<
" ; in degrees, 0: shower propagates to north, 90: to west\n"
453 "# book-keeping parameters needed for read-in to Offline\n"
455 "CorsikaFilePath = ./ ; path to the CORSIKA files (cannot include space characters!)\n"
456 "CorsikaParameterFile = " << corsikaparameterfile <<
"; specify CORSIKA card file\n"
457 "EventNumber = " << rHead.
GetId() <<
"\n"
461 "CoreEastingOffline = " << zeCore.
GetX(PampaAmarillaCS)/
meter <<
"; in meters\n"
462 "CoreNorthingOffline = " << zeCore.
GetY(PampaAmarillaCS)/
meter <<
"; in meters\n"
463 "CoreVerticalOffline = " << zeCore.
GetZ(PampaAmarillaCS)/
meter <<
"; in meters\n";
465 if (fGetMagneticFieldFromModel)
466 reasfile <<
"RotationAngleForMagfieldDeclination = " << fMagneticFieldDeclinationFromModel/
degree <<
"; in degrees\n";
468 reasfile <<
"RotationAngleForMagfieldDeclination = " << fMagneticFieldDeclination/
degree <<
"; in degrees\n";
471 reasfile <<
"Comment = Event " << GetEventNumber(head.
GetId()) <<
" at "
473 "created by RdREASSimPreparator, Offline coordinates are in PampaAmarilla coordinate system\n";
475 return filename.str();
482 RdREASSimPreparator::WriteDetectorFile(
const Point& core,
const Vector& axis)
484 cout <<
" RdREASSimPreparator::WriteDetectorFile" << endl;
486 int AntennaInFile = -1;
488 UTMPoint utmcore(core, ReferenceEllipsoid::GetWGS84());
489 Detector& Det = Detector::GetInstance();
493 vector<Point> antenna_positions;
494 vector<string> antenna_names;
496 if (fWriteAERAlist) {
500 if (AntennaInFile >= fAntennaPerJob)
502 if (!rdIt->IsInGrid())
504 Point Position = rdIt->GetPosition();
505 Vector VecAntenna = Position-core;
506 if (fUseCoreDistance) {
507 if (VecAntenna.
GetR(coreCS) > fMaxAntennaDistanceFromCore)
510 Line axisline(core, axis);
511 if (
Distance(axisline, Position) > fMaxAntennaDistanceFromCore)
515 antenna_names.push_back(rdIt->GetName());
516 antenna_positions.push_back(rdIt->GetPosition());
530 for (
const auto& station : sdetector.GridStationsRange(gridtype)) {
531 const double axisDistance = RadioGeometryUtilities::GetDistanceToAxis(axis, core, station.GetPosition());
532 if (axisDistance < fMaxAxisDistance) {
533 string station_name = station.GetName();
534 replace(station_name.begin(), station_name.end(),
' ',
'_');
535 antenna_names.push_back(station_name);
536 antenna_positions.push_back(station.GetPosition());
542 filename <<
"SIM" << AddZero(fRunNumber, 6) <<
".list";
544 vector<string> v_filelist;
545 v_filelist.push_back(filename.str());
547 ofstream aeralist(fWorkingDir + filename.str());
549 for (
unsigned int i = 0; i < antenna_positions.size(); ++i) {
550 double antX = antenna_positions[i].GetX(coreCS);
551 double antY = antenna_positions[i].GetY(coreCS);
552 double antZ = utmcore.
GetHeight() + antenna_positions[i].GetZ(coreCS);
557 if (fGetMagneticFieldFromModel) {
558 rotX = cos(fMagneticFieldDeclinationFromModel)*antX - sin(fMagneticFieldDeclinationFromModel)*antY;
559 rotY = sin(fMagneticFieldDeclinationFromModel)*antX + cos(fMagneticFieldDeclinationFromModel)*antY;
561 rotX = cos(fMagneticFieldDeclination)*antX - sin(fMagneticFieldDeclination)*antY;
562 rotY = sin(fMagneticFieldDeclination)*antX + cos(fMagneticFieldDeclination)*antY;
565 aeralist <<
"AntennaPosition = " << rotY/
cm <<
" " << -rotX/
cm <<
" " << antZ/
cm
566 <<
' ' << antenna_names[i] << endl;
575 RdREASSimPreparator::GetEventNumber(
const std::string& eventId)
577 vector<string> zetokens;
579 boost::char_separator<char> sep(
"_");
581 mytok tok(eventId, sep);
583 for (mytok::const_iterator titer = tok.begin(); titer != tok.end(); ++titer)
584 zetokens.push_back(*titer);
585 if (zetokens.size() >= 4)
594 RdREASSimPreparator::AddZero(
const int RunID,
const int numberofdigit)
596 ostringstream runnumb;
597 for (
int i = 0; i < numberofdigit - 1 - floor(log10(
float(RunID))); ++i)
600 return runnumb.str();
606 RdREASSimPreparator::ExtractTypicalShower(
const string& workdir,
const string&
filename,
607 double& firstintheight,
long& firstinttarget,
608 string& selshowstring,
const string& runnrstring)
610 const float maximumenergyfractioninfirstparticle = 0.10;
614 TFile*
const f =
new TFile((workdir + filename).c_str());
620 TTree*
const Shower = (TTree*)(f->Get(
"Shower"));
621 TTree*
const Header = (TTree*)(f->Get(
"Header"));
622 TTree*
const FirstInteraction = (TTree*)(f->Get(
"FirstInteraction"));
623 int nevent =
static_cast<int>(Shower->GetEntries());
625 const int maxX = 4000;
626 float X[maxX], H[maxX], D[maxX], N[maxX],dEdX[maxX],
Mu[maxX], dMu[maxX];
627 float fitpars[11], EGround[3], muThr, hadThr, emThr;
628 int nX, iPart, iseed1, iseed2, iseed3, HEModel;
629 const int maxNInt = 100;
633 double gkinel1[maxNInt];
635 double gpEnergy1[maxNInt];
637 double gDepth1[maxNInt];
638 double gHeight1[maxNInt];
641 const int maxNPart = 100000;
642 double gEnergy1[maxNPart];
643 double gpx1[maxNPart];
644 double gpy1[maxNPart];
645 double gpz1[maxNPart];
646 int gType1[maxNPart];
647 int gIdInt1[maxNPart];
649 Shower->SetBranchAddress(
"lgE", &fitpars[0]);
650 Shower->SetBranchAddress(
"zenith", &fitpars[1]);
651 Shower->SetBranchAddress(
"azimuth", &fitpars[10]);
652 Shower->SetBranchAddress(
"Xfirst", &fitpars[2]);
653 Shower->SetBranchAddress(
"X0", &fitpars[4]);
654 Shower->SetBranchAddress(
"Xmax", &fitpars[9]);
655 Shower->SetBranchAddress(
"Nmax", &fitpars[3]);
656 Shower->SetBranchAddress(
"p1", &fitpars[5]);
657 Shower->SetBranchAddress(
"p2", &fitpars[6]);
658 Shower->SetBranchAddress(
"p3", &fitpars[7]);
659 Shower->SetBranchAddress(
"chi2", &fitpars[8]);
660 Shower->SetBranchAddress(
"nX", &nX);
661 Shower->SetBranchAddress(
"N", N);
662 Shower->SetBranchAddress(
"dEdX", dEdX);
663 Shower->SetBranchAddress(
"Mu", Mu);
664 Shower->SetBranchAddress(
"dMu", dMu);
665 Shower->SetBranchAddress(
"EGround", EGround);
666 Header->SetBranchAddress(
"muThr", &muThr);
667 Header->SetBranchAddress(
"emThr", &emThr);
668 Header->SetBranchAddress(
"hadThr", &hadThr);
669 Header->SetBranchAddress(
"HEModel", &HEModel);
670 Shower->SetBranchAddress(
"X", X);
671 Shower->SetBranchAddress(
"H", H);
672 Shower->SetBranchAddress(
"D", D);
673 Header->SetBranchAddress(
"Particle", &iPart);
674 Header->SetBranchAddress(
"Seed1", &iseed1);
675 Shower->SetBranchAddress(
"Seed2", &iseed2);
676 Shower->SetBranchAddress(
"Seed3", &iseed3);
677 FirstInteraction->SetBranchAddress(
"nPart", &nParticles);
678 FirstInteraction->SetBranchAddress(
"mult", gMult1);
679 FirstInteraction->SetBranchAddress(
"nInt", &gnInt1);
680 FirstInteraction->SetBranchAddress(
"kinel", gkinel1);
681 FirstInteraction->SetBranchAddress(
"pId", gpId1);
682 FirstInteraction->SetBranchAddress(
"pEnergy", gpEnergy1);
683 FirstInteraction->SetBranchAddress(
"mult", gMult1);
684 FirstInteraction->SetBranchAddress(
"matg", gMatg1);
685 FirstInteraction->SetBranchAddress(
"depth", gDepth1);
686 FirstInteraction->SetBranchAddress(
"height", gHeight1);
688 FirstInteraction->SetBranchAddress(
"nPart", &gNParticles1);
689 FirstInteraction->SetBranchAddress(
"Energy", gEnergy1);
690 FirstInteraction->SetBranchAddress(
"px", gpx1);
691 FirstInteraction->SetBranchAddress(
"py", gpy1);
692 FirstInteraction->SetBranchAddress(
"pz", gpz1);
693 FirstInteraction->SetBranchAddress(
"Type", gType1);
694 FirstInteraction->SetBranchAddress(
"idInt", gIdInt1);
696 ofstream fout(workdir + filename +
".longprofiles");
698 cout <<
"Error writing to file " << workdir+filename <<
".longprofiles. Aborting ... \n" << endl;
702 ofstream gout(workdir + filename +
".xmaxs");
704 cout <<
"Error writing to file " << workdir+filename <<
".xmaxs. Aborting ... \n" << endl;
708 vector<tupel> showers;
710 for (
int i = 0; i < nevent; ++i) {
711 fout <<
"\n\n#shower number " << i <<
'\n';
714 FirstInteraction->GetEntry(i);
716 for (
long n = 0; n < nX; ++n) {
717 fout << X[n] <<
'\t' << N[n] <<
'\n';
719 showers.push_back(
tupel(i, fitpars[9], gMult1[0], gpEnergy1[0], gEnergy1[0], gEnergy1[1], gEnergy1[2], gEnergy1[3]));
722 sort(showers.begin(), showers.end());
724 double averageXmax = 0;
725 for (vector<tupel>::const_iterator j = showers.begin(); j != showers.end(); ++j) {
726 gout <<
"Shower\t" << j->num <<
"\thas Xmax at:\t" << j->xmax <<
"\tg/cm^2 and of\t" << j->eg <<
"\tGeV first parts. have:\t" << j->e1 <<
", " << j->e2 <<
", " << j->e3 <<
", " << j->e4 <<
'\n';
727 averageXmax += j->xmax/
static_cast<double>(nevent);
730 gout <<
"\nAverage Xmax is:\t" << averageXmax <<
" g/cm^2\n" << endl;
735 for (vector<tupel>::iterator j=showers.begin(); j!=showers.end(); ++j) {
736 j->avgxmax = averageXmax;
739 sort(showers.begin(), showers.end(), showers.front());
747 vector<tupel>::const_iterator selshower = showers.begin();
748 while ((selshower != showers.end()-1) && (selshower->e1/selshower->eg > maximumenergyfractioninfirstparticle)) {
752 cout << std::setprecision(5) <<
"Shower " << selshower->num <<
" has xmax of " << selshower->xmax
753 <<
" (avg: " << averageXmax <<
") and of " << selshower->eg <<
" GeV "
754 "first parts. have: " << selshower->e1 <<
", " << selshower->e2 <<
", "
755 << selshower->e3 <<
", " << selshower->e4 << std::setprecision(12) <<
'\n';
757 ofstream hout(workdir + filename +
".gnu");
759 cout <<
"Error writing to file " << workdir+filename <<
".gnu. Aborting ... \n" << endl;
763 hout <<
"set term post enh col\nset outp \"" << filename <<
".eps\"\n"
764 "set xlabel \"atmospheric depth [g cm^{-2}]\"\n"
765 "set ylabel \"num elec + posi\"\n"
766 "plot \"" << filename <<
".longprofiles\" notitle, \"" << filename
767 <<
".longprofiles\" index " << selshower->num <<
" lt 3, \"DAT"
768 << runnrstring <<
".long\" using 1:($3+$4) lt 4\n";
773 FirstInteraction->GetEntry(selshower->num);
774 stringstream selshowstringstream;
775 selshowstringstream <<
".sh" << selshower->num;
776 selshowstring = selshowstringstream.str();
778 ofstream sout(workdir + filename+selshowstring);
780 cout <<
"Error writing to file " << workdir+filename+selshowstring <<
". Aborting ... \n" << endl;
784 sout <<
" " << gMult1[0] <<
" " <<gpEnergy1[0] << endl;
787 for (
int i = 0; i < gNParticles1; ++i) {
790 sout << setw(5) << i+1 << setw(5) << gType1[i]
791 << setw(16) << gEnergy1[i]
792 << setw(16) << gpz1[i]
793 << setw(16) << gpx1[i]
794 << setw(16) << gpy1[i] <<
'\n';
796 sout <<
" Height (cm) : " << gHeight1[0]*100 <<
"\n"
797 " Target : " << gMatg1[0] << endl;
799 firstintheight = gHeight1[0]*100;
801 if (gMatg1[0] == 16) {
Branch GetTopBranch() const
boost::transform_iterator< InternalStationFunctor, InternalStationIterator, const Station & > StationIterator
StationIterator returns a pointer to a station.
utl::Vector GetAxis() const
Returns vector of the shower axis.
void System(const char *const command, const bool throwOnError, const bool notify)
Interface class to access Shower Reconstructed parameters.
Interface class to access to the Radio part of an event.
double GetR(const CoordinateSystemPtr &coordinateSystem) const
radius r in spherical coordinates coordinates (distance to origin)
double GetTheta(const CoordinateSystemPtr &coordinateSystem) const
zenith (theta) angle in spherical coordinates
Class to hold and convert a point in geodetic coordinates.
StationIterator StationsEnd() const
End of the collection of pointers to commissioned stations.
StationIterator StationsBegin() const
Beginning of the collection of pointers to commissioned stations.
#define INFO(message)
Macro for logging informational messages.
static double GetDeclination(const utl::Point &position, const utl::TimeStamp &time)
returns declination in radians
void Init()
Initialise the registry.
vector< t2list > out
output of the algorithm: a list of clusters
Branch GetChild(const std::string &childName) const
Get child of this Branch by child name.
double pow(const double x, const unsigned int i)
ShowerRRecData & GetRRecShower()
ShowerSRecData & GetSRecShower()
A TimeStamp holds GPS second and nanosecond for some event.
Detector description interface for RDetector-related data.
boost::shared_ptr< const CoordinateTransformer > CoordinateSystemPtr
Shared pointer for coordinate systems.
Class representing a document branch.
double GetHeight() const
Get the height.
double GetX(const CoordinateSystemPtr &coordinateSystem) const
static MagneticFieldModel & instance()
Header & GetHeader()
access to REvent Header
Top of the hierarchy of the detector description interface.
const sdet::SDetector & GetSDetector() const
static utl::Vector GetMagneticFieldVector(const utl::Point &position, const utl::TimeStamp &time)
returns the magnetic field at a specific place at a specific time
const utl::Vector & GetAxis() const
void GetData(bool &b) const
Overloads of the GetData member template function.
double GetY(const CoordinateSystemPtr &coordinateSystem) const
double Distance(const Point &p, const sdet::Station &s)
ResultFlag
Flag returned by module methods to the RunController.
boost::tokenizer< boost::char_separator< char > > mytok
unsigned long GetGPSSecond() const
GPS second.
double GetGPSNanoSecond() const
GPS nanosecond.
Detector description interface for SDetector-related data.
const utl::Point & GetCorePosition() const
utl::Point GetCorePosition() const
returns pointer of the position vector of the core in the reference coor system
const rdet::RDetector & GetRDetector() const
utl::CoordinateSystemPtr Get(const std::string &id)
Get a well-known Coordinate System.
double GetParameter(const Parameter i) const
double GetZ(const CoordinateSystemPtr &coordinateSystem) const
static Policy::type Create(const utl::Point &theOrigin)
Create the standard local coordinate system for a Point.
double Mu(const double energy, const double massNumber, const HadronicInteractionModel hadModel)
constexpr double electronvolt