46 ,
m_head{pset.get<std::vector<double>>(
"Head", {100., 0., 0.})}
47 ,
m_tail{pset.get<std::vector<double>>(
"Tail", {50., 10., 50.})}
48 ,
m_time{pset.get<
double>(
"Time", 0.0)}
49 ,
m_charge{pset.get<
double>(
"ElectronPerCm", 50000)}
50 ,
m_step{pset.get<
double>(
"StepSize", 0.1)}
52 produces<std::vector<sim::SimEnergyDeposit>>(
instance);
59 std::cout <<
"head: " <<
m_head.at(0) <<
" " <<
m_head.at(1) <<
" " <<
m_head.at(2) << std::endl;
60 std::cout <<
"tail: " <<
m_tail.at(0) <<
" " <<
m_tail.at(1) <<
" " <<
m_tail.at(2) << std::endl;
63 auto out = std::make_unique<std::vector<sim::SimEnergyDeposit>>();
67 const double mevpercm = 2.0;
78 const auto vdiff = end - start;
79 const auto vlen = sqrt(vdiff.Mag2());
80 const auto vdir = vdiff.unit();
82 const double stepsize =
m_step;
83 const int nsteps = vlen / stepsize;
86 const double ns = 1.0;
93 for (
double jump : {
m_time * ns} ) {
95 for (
int istep = 1; istep < nsteps; ++istep) {
111 std::cerr <<
"BlipMaker making " << out->size() <<
" depos to instance: " <<
instance 114 event.put(std::move(out),
instance);
code to link reconstructed objects back to the MC truth information
std::vector< double > m_head
EDProducer(fhicl::ParameterSet const &pset)
const std::string instance
decltype(auto) constexpr end(T &&obj)
ADL-aware version of std::end.
#define DEFINE_ART_MODULE(klass)
std::vector< double > m_tail
void produce(art::Event &evt)
contains information for a single step in the detector simulation
Energy deposition in the active material.
Event finding and building.
BlipMaker(fhicl::ParameterSet const &pset)