KaliVeda
Toolkit for HIC analysis
KVDBSystem.cpp
1 /***************************************************************************
2  * *
3  * This program is free software; you can redistribute it and/or modify *
4  * it under the terms of the GNU General Public License as published by *
5  * the Free Software Foundation; either version 2 of the License, or *
6  * (at your option) any later version. *
7  * *
8  ***************************************************************************/
9 #include "KVDBSystem.h"
10 #include "KVDBRun.h"
11 #include "KV2Body.h"
12 #include "KVNumberList.h"
13 #include "KVUnits.h"
14 #include "TROOT.h"
15 #include "KVDBKey.h"
16 #include "KVDBTable.h"
17 #include <KVUnownedList.h>
18 
19 using namespace std;
20 
22 
23 
28 
30  "Physical System")
31 {
32  // Constructor with name of system.
33  //
34  // No other properties are set.
35  KVDBKey* dbk = AddKey("Runs", "List of Runs");
36  dbk->SetUniqueStatus(kTRUE);
37 }
38 
39 
40 
45 
46 KVDBSystem::KVDBSystem(int zp, int ap, int zt, int at, Float_t eb)
47  : KVDBSystem(KVNucleus{zp,ap,ap*eb}, KVNucleus{zt,at})
48 {
49  // Delegating constructor with (Z,A) of beam and target and beam energy in MeV/A.
50  //
51  // Sets default name to "X + Y E MeV/A"
52 }
53 
54 
55 
62 
63 KVDBSystem::KVDBSystem(const KVNucleus& X, const KVNucleus& Y, const KVString& targname)
64  : KVDBRecord(Form("%s + %s %.1f MeV/A", X.GetSymbol(),
65  targname.IsNull() ? Y.GetSymbol() : targname.Data(), X.GetAMeV()),
66  "Physical System"),
67  fZbeam(X.GetZ()), fAbeam(X.GetA()), fZtarget(Y.GetZ()), fAtarget(Y.GetA()), fEbeam(X.GetAMeV())
68 {
69  // Constructor with beam X(E MeV/A) and target Y.
70  //
71  // Sets default name to "X + Y E MeV/A"
72  //
73  // If targname is given, it used as the name of the target instead of Y
74  KVDBKey* dbk = AddKey("Runs", "List of Runs");
75  dbk->SetUniqueStatus(kTRUE);
76 }
77 
78 
79 
82 
83 KVDBSystem::~KVDBSystem()
84 {
85  //Delete kinematics, target and associated runlist if they exist
86  if (fCinema) {
87  delete fCinema;
88  fCinema = 0;
89  }
90  delete fTarget;
91 }
92 
93 
94 
95 
102 
104 {
105  // Create (if it doesn't already exist) and return pointer to a KV2Body object initialised
106  // with the entrance channel corresponding to this system. Use this to obtain information
107  // such as the recoil velocity of the CM, available energy, etc. (see KV2Body).
108  //
109  // If no projectile and/or target are defined for the system, we return 0x0.
110 
111  if (GetZbeam()*GetZtarget() == 0) return nullptr;
112 
113  if (!fCinema) {
114  fCinema = new KV2Body();
119  }
120  return fCinema;
121 }
122 
123 
124 
127 
129 {
130  //retourne kTRUE, si le systeme est une collision ie projectile+cible
131  return (GetZbeam() * GetZtarget() != 0);
132 
133 }
134 
135 
136 
138 
140 {
141  if(fRunlist.IsEmpty())
142  {
143  auto _rlist = GetLinks("Runs");
144  TIter nxt(_rlist);
145  KVDBRun* db;
146  while ((db = (KVDBRun*) nxt()))
147  fRunlist.Add(db);
148  fRunlist.Sort();
149  }
150  return fRunlist;
151 }
152 
153 
154 
157 
159 {
160  // \return total number of runfiles for system which are not considered 'bad'
161 
162  Int_t not_bad(0);
163  for(auto it : GetRuns())
164  {
165  auto run = dynamic_cast<KVDBRun*>(it);
166  not_bad += run->GetNGoodRunFiles();
167  }
168  return not_bad;
169 }
170 
171 
172 
173 
177 
179 {
180  //Returns product of atomic number and velocity component parallel to beam axis of projectile nucleus in laboratory frame
181  //Units are cm/ns (velocity units)
182  KV2Body* kin = const_cast < KVDBSystem* >(this)->GetKinematics();
183  if (!kin) return 0.;
184  return (fZbeam * kin->GetNucleus(1)->GetVpar());
185 }
186 
187 
188 
189 
193 
195 {
196  //Returns momentum component parallel to beam axis of projectile nucleus in laboratory frame
197  //Units are MeV/c
198  KV2Body* kin = const_cast < KVDBSystem* >(this)->GetKinematics();
199  if (!kin) return 0.;
200  return (kin->GetNucleus(1)->GetMomentum().Z());
201 }
202 
203 
204 
205 
209 
211 {
212  //Returns total (mass + kinetic) energy of entrance channel corresponding to system
213  //Units are MeV
214  KV2Body* kin = const_cast < KVDBSystem* >(this)->GetKinematics();
215  if (!kin) return 0.;
216  return (kin->GetNucleus(1)->E() + kin->GetNucleus(2)->E());
217 }
218 
219 
220 
221 
225 
227 {
228  //Returns total available (CM) kinetic energy of entrance channel corresponding to system
229  //Units are MeV
230  KV2Body* kin = const_cast < KVDBSystem* >(this)->GetKinematics();
231  if (!kin) return 0.;
232  return (kin->GetCMEnergy());
233 }
234 
235 
236 
237 
243 
245 {
246  //Function used to sort lists of systems.
247  //Systems are sorted according to the number of the first run in the
248  //(sorted) list of runs associated to the system.
249  //Systems with lower first run numbers appear earlier in the list.
250 
251  if (!GetRuns())
252  return 0;
253  KVDBSystem* other_sys =
254  dynamic_cast < KVDBSystem* >(const_cast < TObject* >(obj));
255  if (!other_sys)
256  return 0;
257  auto other_runs = other_sys->GetRuns();
258  if (!other_runs)
259  return 0;
260  Int_t first = ((KVDBRecord*) fRunlist.At(0))->GetNumber();
261  Int_t other_first = ((KVDBRecord*) other_runs.At(0))->GetNumber();
262  return (first == other_first ? 0 : (other_first > first ? -1 : 1));
263 }
264 
265 
266 
267 
268 
271 
273 {
274  //Fills the KVNumberList object with the list of all run numbers associated with this system
275  list.Clear();
276  for(auto run : GetRuns())
277  {
278  list.Add(dynamic_cast<KVDBRun*>(run)->GetNumber());
279  }
280 }
281 
282 
283 
286 
288 {
289  //Fills a KVNumberList with the list of all run numbers associated with this system
290  KVNumberList list;
291  for(auto run : GetRuns())
292  {
293  list.Add(dynamic_cast<KVDBRun*>(run)->GetNumber());
294  }
295  return list;
296 }
297 
298 
299 
300 
311 
312 void KVDBSystem::Save(ostream& f) const
313 {
314  //Write informations on system in the format used in Systems.dat files:
315  //
316  //+155Gd + 238U 36 MeV/A '+' followed by name of system
317  //155 64 238 92 36.0 Aproj Zproj Atarg Ztarg Ebeam
318  //Target: 3 0.0 target with 3 layers, angle 0 degrees
319  //C 0.02 1st layer : carbon, 20 g/cm2
320  //238U 0.1 2nd layer : uranium-238, 100 g/cm2
321  //C 0.023 3rd layer : carbon, 23 g/cm2
322  //Runs: 770-804 list of runs in KVNumberList format
323 
324  f << "+" << GetName() << endl;
325  if (fZbeam) f << fAbeam << " " << fZbeam << " " << fAtarget << " " << fZtarget << " " << fEbeam << endl;
326  if (fTarget) {
327  f << "Target: " << fTarget->NumberOfLayers() << " " << fTarget->GetAngleToBeam() << endl;
328  TIter next(fTarget->GetLayers());
329  KVMaterial* lay;
330  while ((lay = (KVMaterial*)next())) {
331  if (lay->IsIsotopic()) f << Form("%d%s", (Int_t)lay->GetMass(), lay->GetType());
332  else f << lay->GetType();
333  f << " " << lay->GetAreaDensity() / KVUnits::mg << endl;
334  }
335  }
336  KVNumberList runlist;
337  GetRunList(runlist);
338  f << "Runs: " << runlist.AsString() << endl;
339 }
340 
341 
342 
343 
359 
360 void KVDBSystem::Load(istream& f, int idx_mult)
361 {
362  //Read and set informations on system in the format used in Systems.dat files:
363  //
364  //~~~
365  //+155Gd + 238U 36 MeV/A '+' followed by name of system
366  //155 64 238 92 36.0 Aproj Zproj Atarg Ztarg Ebeam
367  //Target: 3 0.0 target with 3 layers, angle 0 degrees
368  //C 0.02 1st layer : carbon, 20 ug/cm2
369  //238U 0.1 2nd layer : uranium-238, 100 ug/cm2
370  //C 0.023 3rd layer : carbon, 23 ug/cm2
371  //Runs: 770-804 list of runs in KVNumberList format
372  //~~~
373  //
374  // idx_mult is a run multiplier: if needed, it is used to divide all run numbers
375  // which may have been artificially generated as (run*idx_mult + index)
376 
377  TString line;
378  Float_t target_thickness;
379  fAbeam = fZbeam = fAtarget = fZtarget = 0;
380  fEbeam = target_thickness = 0;
381  KVNumberList runlist;
382  //'peek' at first character of next line
383  char next_char = f.peek();
384  if (next_char == '+') {
385  line.ReadLine(f, kFALSE);
386  line.Remove(0, 1);
387  SetName(line.Data());
388  cout << "New System : " << line.Data() << endl;
389  }
390  else {
391  Error("Load", "Should read system name : %s\n", line.Data());
392  return;
393  }
394  next_char = f.peek();
395  while (next_char != '+' && f.good() && !f.eof()) {
396  if ((next_char >= '0') && (next_char <= '9')) {
397  line.ReadLine(f, kFALSE);
398  if (sscanf(line.Data(), "%u %u %u %u %f %f", &fAbeam, &fZbeam, &fAtarget, &fZtarget, &target_thickness, &fEbeam) == 6) {
399  cout << "Zproj = " << fZbeam << " Ztarg = " << fZtarget << " targ_thick = " << target_thickness << " Ebeam = " << fEbeam << endl;
400  }
401  else if (sscanf(line.Data(), "%u %u %u %u %f", &fAbeam, &fZbeam, &fAtarget, &fZtarget, &fEbeam) == 5) {
402  cout << "Zproj = " << fZbeam << " Ztarg = " << fZtarget << " Ebeam = " << fEbeam << endl;
403  }
404  }
405  else {
406  line.ReadLine(f, kFALSE);
407  if (line.BeginsWith("Target")) {
408  fTarget = new KVTarget;
409  line.Remove(0, line.Index(":") + 1);
410  Int_t nlay;
411  Float_t angle;
412  sscanf(line.Data(), "%d %f", &nlay, &angle);
413  Char_t mat[255];
414  Float_t thick;
415  for (int i = 0; i < nlay; i++) {
416  line.ReadLine(f);
417  sscanf(line.Data(), "%s %f", mat, &thick);
418  fTarget->AddLayer(mat, thick);
419  }
421  fTarget->Print();
422  }
423  else if (line.BeginsWith("Runs")) {
424  line.Remove(0, line.Index(":") + 1);
425  runlist.SetList(line.Data());
426  cout << "Runs : " << line.Data() << endl;
427  }
428  else if (line.BeginsWith("Run Range")) {
429  line.Remove(0, line.Index(":") + 1);
430  Int_t frun, lrun;
431  sscanf(line.Data(), "%i %i", &frun, &lrun);
432  runlist.Add(Form("%i-%i", frun, lrun));
433  cout << "Run range : " << line.Data() << endl;
434  }
435  }
436  next_char = f.peek();
437  }
438  if (runlist.GetNValues()) {
439  SetRuns(runlist,idx_mult);
440  }
441  //set target if not already done (old versions)
442  if (!fTarget && target_thickness > 0 && fZtarget > 0) {
444  fTarget = new KVTarget(n.GetSymbol(), target_thickness);
445  fTarget->Print();
446  }
447 }
448 
449 
450 
451 
457 
458 void KVDBSystem::SetRuns(const KVNumberList& rl, int idx_mult)
459 {
460  //Associate this system with the runs in the list.
461  //Any previously associated runs are first removed (links in the runs will be removed too).
462  //
463  // idx_mult may be used to convert run numbers generated as (run*idx_mult + index)
464 
465  Info("SetRuns", "Setting runs for system %s : %s", GetName(), rl.AsString());
466  RemoveAllRuns();
467  rl.Begin();
468  KVDBTable* runtable = GetRunsTable();
469  if(!runtable)
470  Error("SetRuns", "runtable does not exist");
471  Int_t run_number;
472  std::map<int,KVDBRun*> run_map;
473  while (!rl.End()) {
474  run_number = rl.Next();
475  if(run_number>=idx_mult) run_number/=idx_mult;
476  if(run_map[run_number]) continue;// treat each run only once
477  auto run = run_map[run_number] = (KVDBRun*)runtable->GetRecord(run_number);
478  if (run) {
479  if (run->GetSystem()) {
480 // Error("SetRuns", "Associating run %d with system \"%s\" : run already associated with system \"%s\"",
481 // run_number, GetName(), run->GetSystem()->GetName());
482  }
483  else {
484  if (AddLink("Runs", run)) {
485  //use name of system as title of run
486  run->SetTitle(GetName());
487  }
488  else {
489  Info("SetRuns", "Could not add link for run %d", run_number);
490  }
491  }
492  }
493  else {
494  //Info("SetRuns", "Run %d not found in database", run_number);
495  }
496  }
497 }
498 
499 
500 
501 
506 
508 {
509  //Associate the given run with this system.
510  //If the run was previously associated with another system, this association
511  //will be removed.
512  if (!rec) return;
513  if (!rec->InheritsFrom("KVDBRun")) {
514  Error("AddRun", "Called with pointer to an object of class %s; should inherit from KVDBRun!",
515  rec->ClassName());
516  return;
517  }
518  KVDBRun* run = (KVDBRun*)rec;
519  if (run->GetSystem()) run->GetSystem()->RemoveRun(run);
520  if (AddLink("Runs", run)) {
521  //Info("AddRun", "Added link for run %d", run->GetNumber());
522  //use name of system as title of run
523  run->SetTitle(GetName());
524  }
525  else {
526  Info("AddRun", "Could not add link for run %d", run->GetNumber());
527  }
528 }
529 
530 
531 
532 
537 
539 {
540  //Associate the given run with this system.
541  //If the run was previously associated with another system, this association
542  //will be removed.
543  AddRun(GetRunsTable()->GetRecord(run));
544 }
545 
546 
547 
548 
552 
554 {
555  //Unassociate the given run from this system. Cross-reference link to this system
556  //is removed from the run at the same time.
557  RemoveLink("Runs", run);
558 }
559 
560 
561 
562 
566 
568 {
569  //Unassociate the given run from this system. Cross-reference link to this system
570  //is removed from the run at the same time.
571  RemoveRun(GetRunsTable()->GetRecord(run));
572 }
573 
574 
575 
576 
580 
582 {
583  //Unassociate all runs from this system. Cross-reference links to this system
584  //are removed from the runs at the same time.
585  RemoveAllLinks("Runs");
586 }
587 
588 
589 
591 
593 {
594  cout << "________________________________________________________" <<
595  endl << "System : " << GetName() << endl;
596  KVNumberList r;
597  GetRunList(r);
598  cout << "Runs : " << r.AsString() << endl;
599  cout << " Zbeam : " << fZbeam
600  << endl << " Abeam : " << fAbeam << endl << " Ebeam : " << fEbeam
601  << " A.MeV" << endl << " Ztarget : " << fZtarget << endl <<
602  " Atarget : " << fAtarget << endl << " Target Thickness : " <<
603  const_cast <
604  KVDBSystem*
605  >(this)->
606  GetTargetThickness() << " mg/cm2" << endl <<
607  "________________________________________________________" << endl;
608 
609 }
610 
611 
612 
614 
616 {
617  KVNumberList r;
618  GetRunList(r);
619  cout << "KVDBSystem : " << GetName() << " Runs : " << r.AsString() << endl;
620 }
621 
622 
623 
633 
635 {
636  //Deduce path to runs table in database from full path to parent table of this record.
637  //
638  //The systems are stored in a table called "Systems"
639  //
640  //The runs are stored in a table called "Runs"
641  //
642  //Therefore if we take the full path to the Systems table and replace Systems with Runs,
643  //we can then use gROOT->FindObject() to get the pointer to the Runs table.
644 
645  TString path = fFullPathTable.Data();
646  path.ReplaceAll("Systems", "Runs");
647  return (KVDBTable*)gROOT->FindObject(path.Data());
648 }
649 
650 
651 
652 
656 
658 {
659  // Gives name of system in compact form with all (unix-)illegal characters
660  // replaced by '_'. Can be used for naming batch jobs, files, etc.
661 
662  TString tmp;
663  tmp = "";
664  if (GetKinematics()) {
665  if (GetKinematics()->GetNucleus(1)) {
666  tmp = GetKinematics()->GetNucleus(1)->GetSymbol();
667  }
668  if (GetKinematics()->GetNucleus(2)) {
669  tmp += GetKinematics()->GetNucleus(2)->GetSymbol();
670  }
671  if (GetEbeam() > 0) {
672  tmp += TMath::Nint(GetEbeam());
673  }
674  }
675  if (tmp == "") {
676  tmp = GetName();
677  tmp.ReplaceAll(" ", "_");
678  tmp.ReplaceAll("/", "_");
679  }
680  return tmp;
681 }
682 
683 
684 
689 
691 {
692  // Gives name of system in compact form with all (unix-)illegal characters
693  // replaced by '_'. Can be used for naming batch jobs, files, etc.
694  // Only symbols of projectile and target are used, not the beam energy
695 
696  TString tmp;
697  tmp = "";
698  if (GetKinematics()) {
699  if (GetKinematics()->GetNucleus(1)) {
700  tmp = GetKinematics()->GetNucleus(1)->GetSymbol();
701  }
702  if (GetKinematics()->GetNucleus(2)) {
703  tmp += GetKinematics()->GetNucleus(2)->GetSymbol();
704  }
705  }
706  if (tmp == "") {
707  tmp = GetName();
708  tmp.ReplaceAll(" ", "_");
709  tmp.ReplaceAll("/", "_");
710  }
711  return tmp;
712 }
713 
714 
715 
720 
722 {
723  // Returns name of reaction without the beam energy i.e. just projectile + target.
724  //
725  // E.g. for system "129Xe + natSn 50 MeV/A" we return "129Xe + natSn"
726 
727  KVString name(GetName());
728  name.Begin(" ");
729  TString tmp;
730  int i = 0;
731  while (i < 3 && !name.End()) {
732  tmp += name.Next(kTRUE);
733  if (i < 2) tmp += " ";
734  ++i;
735  }
736  return tmp;
737 }
738 
739 
740 
745 
747 {
748  // Returns beam energy of reaction as it appears in the title,
749  //
750  // E.g. for system "129Xe + natSn 50 MeV/A" we return "50 MeV/A"
751 
752  TString name(GetName());
753  auto reac = GetReactionNameWithoutEnergy();
754  name.Remove(name.Index(reac), reac.Length() + 1);
755  return name;
756 }
757 
758 
759 
int Int_t
ROOT::R::TRInterface & r
#define f(i)
bool Bool_t
char Char_t
float Float_t
constexpr Bool_t kFALSE
double Double_t
constexpr Bool_t kTRUE
const char Option_t
#define X(type, name)
Option_t Option_t TPoint TPoint angle
char name[80]
#define gROOT
char * Form(const char *fmt,...)
Relativistic binary kinematics calculator.
Definition: KV2Body.h:166
void SetTarget(const KVNucleus &)
Set target for reaction.
Definition: KV2Body.cpp:314
void SetProjectile(const KVNucleus &)
Set projectile for reaction.
Definition: KV2Body.cpp:339
void CalculateKinematics()
Definition: KV2Body.cpp:677
KVNucleus * GetNucleus(Int_t i) const
Definition: KV2Body.cpp:456
Double_t GetCMEnergy() const
Return available kinetic energy in centre of mass.
Definition: KV2Body.cpp:522
virtual const Char_t * GetType() const
Definition: KVBase.h:176
Cross-reference in a KVDataBase.
Definition: KVDBKey.h:38
virtual void SetUniqueStatus(Bool_t unique)
Definition: KVDBKey.h:73
Record folder for the database.
Definition: KVDBRecord.h:43
virtual Bool_t AddKey(KVDBKey *key, Bool_t check=kTRUE)
Definition: KVDBRecord.cpp:65
TString fFullPathTable
full path to parent table in folder structure
Definition: KVDBRecord.h:47
virtual Bool_t AddLink(const Char_t *key_name, KVDBRecord *rec, Bool_t linkback=kTRUE)
Definition: KVDBRecord.cpp:122
virtual void RemoveLink(const Char_t *key_name, KVDBRecord *rec, Bool_t linkback=kTRUE)
Remove the link between this record and the record "rec" in the DB table"key_name".
Definition: KVDBRecord.cpp:145
virtual KVRList * GetLinks(const Char_t *key) const
Returns the list of records linked to this record in table "key".
Definition: KVDBRecord.cpp:206
virtual void RemoveAllLinks(const Char_t *key)
Remove all links between this record and the records in the DB table"key_name".
Definition: KVDBRecord.cpp:166
virtual Int_t GetNumber() const
Definition: KVDBRecord.h:73
Description of an experimental run in database ,,.
Definition: KVDBRun.h:41
KVDBSystem * GetSystem() const
Definition: KVDBRun.cpp:239
Int_t GetNGoodRunFiles() const
Definition: KVDBRun.h:159
Database class used to store information on different colliding systems studied during an experiment....
Definition: KVDBSystem.h:51
Int_t Compare(const TObject *) const override
Definition: KVDBSystem.cpp:244
UInt_t GetZtarget() const
.............. inline functions ...............
Definition: KVDBSystem.h:167
Bool_t IsCollision() const
retourne kTRUE, si le systeme est une collision ie projectile+cible
Definition: KVDBSystem.cpp:128
UInt_t GetAtarget() const
Definition: KVDBSystem.h:172
void ls(Option_t *option="*") const override
Definition: KVDBSystem.cpp:615
Float_t fEbeam
Definition: KVDBSystem.h:68
Int_t GetNGoodRunFiles() const
Definition: KVDBSystem.cpp:158
void RemoveRun(KVDBRecord *)
Definition: KVDBSystem.cpp:553
Double_t GetPtot() const
Definition: KVDBSystem.cpp:194
TString GetBatchName()
Definition: KVDBSystem.cpp:657
void Save(std::ostream &) const
Definition: KVDBSystem.cpp:312
Double_t GetECM() const
Definition: KVDBSystem.cpp:226
void SetRuns(const KVNumberList &, int=1)
Definition: KVDBSystem.cpp:458
Float_t GetTargetThickness() const
Definition: KVDBSystem.h:217
void AddRun(KVDBRecord *)
Definition: KVDBSystem.cpp:507
TString GetBatchNameWithoutEnergy()
Definition: KVDBSystem.cpp:690
KV2Body * GetKinematics()
Definition: KVDBSystem.cpp:103
Float_t GetEbeam() const
Definition: KVDBSystem.h:207
UInt_t fAbeam
Definition: KVDBSystem.h:65
Double_t GetZVtot() const
Definition: KVDBSystem.cpp:178
UInt_t GetZbeam() const
Definition: KVDBSystem.h:187
UInt_t GetAbeam() const
Definition: KVDBSystem.h:192
TString GetReactionNameWithoutEnergy()
Definition: KVDBSystem.cpp:721
TString GetReactionEnergyWithoutName()
Definition: KVDBSystem.cpp:746
KVDBTable * GetRunsTable()
Definition: KVDBSystem.cpp:634
KV2Body * fCinema
Definition: KVDBSystem.h:55
UInt_t fZtarget
Definition: KVDBSystem.h:66
KVTarget * fTarget
used to calculate kinematics of entrance channel
Definition: KVDBSystem.h:57
void Load(std::istream &, int=1)
Definition: KVDBSystem.cpp:360
KVUnownedList fRunlist
temporary used to store sorted list of runs
Definition: KVDBSystem.h:59
UInt_t fZbeam
temporary variable used to stock number of available events
Definition: KVDBSystem.h:64
KVUnownedList GetRuns() const
Returns a sorted list of all the runs associated with this system.
Definition: KVDBSystem.cpp:139
UInt_t fAtarget
Definition: KVDBSystem.h:67
void RemoveAllRuns()
Definition: KVDBSystem.cpp:581
Double_t GetEtot() const
Definition: KVDBSystem.cpp:210
KVNumberList GetRunList() const
Fills a KVNumberList with the list of all run numbers associated with this system.
Definition: KVDBSystem.cpp:287
void Print(Option_t *option="") const override
Definition: KVDBSystem.cpp:592
Table in a database.
Definition: KVDBTable.h:34
virtual KVDBRecord * GetRecord(const Char_t *rec_name) const
Definition: KVDBTable.h:58
Description of physical materials used to construct detectors & targets; interface to range tables.
Definition: KVMaterial.h:89
Double_t GetAreaDensity() const
Definition: KVMaterial.cpp:553
Bool_t IsIsotopic() const
Definition: KVMaterial.cpp:324
Double_t GetMass() const
Definition: KVMaterial.cpp:302
Description of properties and kinematics of atomic nuclei.
Definition: KVNucleus.h:123
const Char_t * GetSymbol(Option_t *opt="") const
Definition: KVNucleus.cpp:71
Strings used to represent a set of ranges of values.
Definition: KVNumberList.h:85
void Clear(Option_t *="") override
Empty number list, reset it to initial state.
const Char_t * AsString(Int_t maxchars=0) const
Bool_t End(void) const
Definition: KVNumberList.h:199
Int_t GetNValues() const
void Begin(void) const
void SetList(const TString &)
void Add(Int_t)
Add value 'n' to the list.
Int_t Next(void) const
TVector3 GetMomentum() const
Definition: KVParticle.h:607
Double_t GetVpar() const
Definition: KVParticle.h:678
void SetEnergy(Double_t e)
Definition: KVParticle.h:602
void Add(TObject *obj) override
TObject * At(Int_t idx) const override
Extension of ROOT TString class which allows backwards compatibility with ROOT v3....
Definition: KVString.h:73
Calculation/correction of energy losses of particles through an experimental target.
Definition: KVTarget.h:128
void Print(Option_t *opt="") const override
Definition: KVTarget.cpp:737
void SetAngleToBeam(Double_t a)
Definition: KVTarget.cpp:179
Int_t NumberOfLayers() const
Definition: KVTarget.h:167
void AddLayer(const Char_t *material, Double_t thick)
Definition: KVTarget.cpp:112
KVList * GetLayers() const
Definition: KVTarget.h:171
Double_t GetAngleToBeam()
Gives angle of target to incident beam direction in degrees.
Definition: KVTarget.cpp:194
Extended TList class which does not own its objects by default.
Definition: KVUnownedList.h:20
void Sort(Bool_t order=kSortAscending)
Definition: KVUnownedList.h:37
virtual Bool_t IsEmpty() const
Double_t E() const
virtual void SetTitle(const char *title="")
const char * GetName() const override
virtual void SetName(const char *name)
virtual void Error(const char *method, const char *msgfmt,...) const
virtual void Info(const char *method, const char *msgfmt,...) const
const char * Data() const
TString & ReplaceAll(const char *s1, const char *s2)
Double_t Z() const
TLine * line
const Int_t n
rec
Int_t Nint(T x)
ClassImp(TPyArg)