SynAPSE  0.6.0
Synergistic Analysis of Phase Space Evolution
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends
Enumerations | Functions
ReweightBeam.cc File Reference

Reweights the MAUS simulation to reproduce the amplitude distribution observed in data. More...

#include <iostream>
#include <algorithm>
#include <regex>
#include <map>
#include "TStyle.h"
#include "TNtuple.h"
#include "TFile.h"
#include "TCanvas.h"
#include "TRandom3.h"
#include "Globals.hh"
#include "ProgressBar.hh"
#include "InfoBox.hh"
#include "Bunch.hh"

Enumerations

enum  Method { maxdist, binbybin }
 Reweighting method. More...
 
enum  Metric { own, data }
 Reweighting metric. More...
 

Functions

std::vector< double > CustomAmplitudes (const Beam::Bunch &beam, const Matrix< double > &covmat)
 Computes the amplitudes of particles in the metric defined by covmat. More...
 
int main (int argc, char **argv)
 Main function. More...
 

Detailed Description

Reweights the MAUS simulation to reproduce the amplitude distribution observed in data.

Algorithm that reweights the MAUS simulation to faithfully reproduce the amplitude distribution observed in hte corresponding data downstream of the MICE absorber. It uses the requested density estimator to reconstruct the minimum local density as a function of the fraction of the beam included.

Enumeration Type Documentation

enum Method

Reweighting method.

Enumerator
maxdist 

Fixes everything to the largest discrepancy.

binbybin 

Fixes bin by bin from largest to smallest.

enum Metric

Reweighting metric.

Enumerator
own 

Simulation metric.

data 

Data metric.

Function Documentation

std::vector<double> CustomAmplitudes ( const Beam::Bunch &  beam,
const Matrix< double > &  covmat 
)

Computes the amplitudes of particles in the metric defined by covmat.

Parameters
beamParticle beam object
covmatCustom metric
Returns
Vector of amplitudes
int main ( int  argc,
char **  argv 
)

Main function.

Parameters
argcNumber of command line arguments
argvList of command line aguments