Pluto v6.3.0
Loading...
Searching...
No Matches
PBeamSmearing.h
Go to the documentation of this file.
1// Author: I. Froehlich
2// Written: 18.7.2007
3// Revised:
4
5#ifndef _PBEAMSMEARING_H_
6#define _PBEAMSMEARING_H_
7
8
9#include "TF1.h"
10#include "TF2.h"
11#include "TH1F.h"
12#include "PDistribution.h"
13
14
16
17 public:
20 PBeamSmearing(const Char_t *id, const Char_t *de);
21
22 PDistribution *Clone(const char *delme=NULL) const;
23
24 Bool_t Init(void);
25 Bool_t Prepare(void);
26
27 void Print(const Option_t *delme=NULL) const; //Debug info
28
30 //A function stretching the beam momentum (x=1 means no modification)
31 mom_smearing = f;
32 };
33
35 //A function stretching the beam momentum (x=1 means no modification)
36 mom_smearing_histo = f;
37 };
38
40 //A function which desribes the absolute momentum distribution
41 mom_function = f;
42 };
43
45 //A function which desribes the absolute momentum distribution
46 mom_function_histo = f;
47 };
48
49 void SetBeamParameters(Double_t th, Double_t ph, Double_t sig) {
50 //N.B. these are in units DEGREE because this is more convenient!
51 thetaBeam = th * TMath::Pi() / 180.;
52 phiBeam = ph * TMath::Pi() / 180.;
53 sigmaBeam = sig* TMath::Pi() / 180.;
54 };
55
56 void SetAngularSmearing(TF1 *f) {
57 //smearing distribution in degree
58 ang_smearing=f;
59 };
60
61 void SetReaction(const char *reaction);
62
63 private:
64
65 PParticle *beam, *mybeam;
66 PParticle *target, *mytarget;
67 PParticle *parent;
68
69 TF1 *mom_smearing;
70 TF1 *mom_function;
71 TF1 *ang_smearing;
72 TH1 *mom_smearing_histo;
73 TH1 *mom_function_histo;
74 Double_t thetaBeam; // polar angle of beam
75 Double_t phiBeam; // azimuthal angle of beam
76 Double_t sigmaBeam; // smearing of beam
77 ClassDef(PBeamSmearing, 0) // General purpose beam smearing models
78};
79
80#endif
81
82
TFile * f
Definition analyze_g12C.C:8
void SetMomentumFunction(TH1 *f)
PBeamSmearing(const Char_t *id, const Char_t *de)
void SetAngularSmearing(TF1 *f)
void SetMomentumSmearing(TH1 *f)
Bool_t Prepare(void)
void SetMomentumFunction(TF1 *f)
PDistribution * Clone(const char *delme=NULL) const
Bool_t Init(void)
void SetBeamParameters(Double_t th, Double_t ph, Double_t sig)
void SetReaction(const char *reaction)
void Print(const Option_t *delme=NULL) const
void SetMomentumSmearing(TF1 *f)