18const UInt_t nNumbers = 20000000U;
24const auto workSize = nNumbers / nThreads;
30 ntuple.Fill(rndm.
Gaus());
33Int_t mtbb101_fillNtuples()
42 TFile ofile(
"mtbb101_singleCore.root",
"RECREATE");
43 TNtuple randomNumbers(
"singleCore",
"Random Numbers",
"r");
44 fillRandom(randomNumbers, rndm, nNumbers);
45 randomNumbers.Write();
51 auto workItem = [](
UInt_t workerID) {
54 TFile ofile(
Form(
"mtbb101_multiCore_%u.root", workerID),
"RECREATE");
55 TNtuple workerRandomNumbers(
"multiCore",
"Random Numbers",
"r");
56 fillRandom(workerRandomNumbers, workerRndm, workSize);
57 workerRandomNumbers.Write();
char * Form(const char *fmt,...)
Formats a string in a circular formatting buffer.
A pseudo container class which is a generator of indices.
This class provides a simple interface to execute the same task multiple times in parallel threads,...
A ROOT file is composed of a header, followed by consecutive data records (TKey instances) with a wel...
A simple TTree restricted to a list of float variables only.
Random number generator class based on M.
Double_t Gaus(Double_t x, Double_t mean, Double_t sigma)
Gauss.
This file contains a specialised ROOT message handler to test for diagnostic in unit tests.