I have been working on a simulation and reconstruction script for collider events.
This is the final project of my university class in Numerical Analysis and Simulation.
The simulation is run and written onto a TTree via TClonesArray and everything works as expected.
To benchmark the program, I have also tried to use stl classes as std::vector and std::array. The hits are saved by their cylindrical coordinates (angle and z, since radius is fixed), so I have a vector of arrays of two doubles (std::vector<std::array<double,2>>
).
Since this type needs a dictionary to be saved in a TTree, I have added
#ifdef __MAKECINT__
#pragma link C++ class std::array<double,2> +;
#pragma link C++ class std::vector<std::array<double, 2> > +;
#endif
but when I try to compile the macro, I get
Info in <TUnixSystem::ACLiC>: creating shared library /home/albertoperro/unito/TANS/finalProj/bin_std/simulation_std_C.so
Error: It is not necessary to explicitly select class array<double,2>. I/O is supported for it transparently.
Error in <ACLiC>: Dictionary generation failed!
I have seen that this question was posted in a somehow similar example here. I have tried to build ROOT from source since the pull request was merged, but it did not solve the issue.
You can find all of my code here.
ROOT Version: 6.19.0 built from master GitHub
Platform: Ubuntu Linux 18.04.2 LTS
Compiler: C++14