#include "CTwobody.h"

CTwobody


class description - source file - inheritance tree (.pdf)

class CTwobody

Inheritance Chart:
CTwobody

    public:
CTwobody(string currentTagEgyCalibFileName, const vector<Float_t>& tag_egy) CTwobody(const CTwobody&) virtual ~CTwobody() static TClass* Class() void GenerateKinematics(string nameX, string nameY) Float_t GetP3_from_U3__g_p_pi0_n(Int_t tagbin, const Float_t& U3) const Float_t GetP3_from_U3__g_p_pi0_p(Int_t tagbin, const Float_t& U3) const Float_t GetP3_from_U3__g_p_pip_n(Int_t tagbin, const Float_t& U3) const Float_t GetP4_from_U4__g_p_pi0_n(Int_t tagbin, const Float_t& U4) const Float_t GetP4_from_U4__g_p_pi0_p(Int_t tagbin, const Float_t& U4) const Float_t GetP4_from_U4__g_p_pip_n(Int_t tagbin, const Float_t& U4) const Float_t GetT3_from_U3__g_p_pi0_n(Int_t tagbin, const Float_t& U3) const Float_t GetT3_from_U3__g_p_pi0_p(Int_t tagbin, const Float_t& U3) const Float_t GetT3_from_U3__g_p_pip_n(Int_t tagbin, const Float_t& U3) const Float_t GetT3_from_U4__g_p_pi0_n(Int_t tagbin, const Float_t& U4) const Float_t GetT3_from_U4__g_p_pi0_p(Int_t tagbin, const Float_t& U4) const Float_t GetT3_from_U4__g_p_pip_n(Int_t tagbin, const Float_t& U4) const Float_t GetT4_from_U4__g_p_pi0_n(Int_t tagbin, const Float_t& U4) const Float_t GetT4_from_U4__g_p_pi0_p(Int_t tagbin, const Float_t& U4) const Float_t GetT4_from_U4__g_p_pip_n(Int_t tagbin, const Float_t& U4) const Float_t GetThetaCM_from_U3__g_p_pi0_n(Int_t tagbin, const Float_t& U3) const Float_t GetThetaCM_from_U3__g_p_pi0_p(Int_t tagbin, const Float_t& U3) const Float_t GetThetaCM_from_U3__g_p_pip_n(Int_t tagbin, const Float_t& U3) const Float_t GetThetaCM_from_U4__g_p_pi0_n(Int_t tagbin, const Float_t& U4) const Float_t GetThetaCM_from_U4__g_p_pi0_p(Int_t tagbin, const Float_t& U4) const Float_t GetThetaCM_from_U4__g_p_pip_n(Int_t tagbin, const Float_t& U4) const Float_t GetU3_from_T3__g_p_pi0_n(Int_t tagbin, const Float_t& U3) const Float_t GetU3_from_T3__g_p_pi0_p(Int_t tagbin, const Float_t& U3) const Float_t GetU3_from_T3__g_p_pip_n(Int_t tagbin, const Float_t& U3) const Float_t GetU3_from_ThetaCM__g_p_pi0_n(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU3_from_ThetaCM__g_p_pi0_p(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU3_from_ThetaCM__g_p_pip_n(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU4_from_T3__g_p_pi0_n(Int_t tagbin, const Float_t& T3) const Float_t GetU4_from_T3__g_p_pi0_p(Int_t tagbin, const Float_t& T3) const Float_t GetU4_from_T3__g_p_pip_n(Int_t tagbin, const Float_t& T3) const Float_t GetU4_from_ThetaCM__g_p_pi0_n(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU4_from_ThetaCM__g_p_pi0_p(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU4_from_ThetaCM__g_p_pip_n(Int_t tagbin, const Float_t& thetaCM) const Float_t GetU4_from_U3__g_p_pi0_n(Int_t tagbin, const Float_t& U3) const Float_t GetU4_from_U3__g_p_pi0_p(Int_t tagbin, const Float_t& U3) const Float_t GetU4_from_U3__g_p_pip_n(Int_t tagbin, const Float_t& U3) const void Init(string X, string Y) virtual TClass* IsA() const CTwobody& operator=(const CTwobody&) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b) void StreamerNVirtual(TBuffer& b) void Test()

Data Members

    private:
vector<Float_t> U4_from_U3__g_p_pip_n[65] ! vector<Float_t> U4_from_T3__g_p_pip_n[65] ! vector<Float_t> T3_from_U3__g_p_pip_n[65] ! vector<Float_t> U3_from_T3__g_p_pip_n[65] ! vector<Float_t> T3_from_U4__g_p_pip_n[65] ! vector<Float_t> T4_from_U4__g_p_pip_n[65] ! vector<Float_t> ThetaCM_from_U3__g_p_pip_n[65] ! vector<Float_t> U4_from_U3__g_p_pi0_p[65] ! vector<Float_t> U4_from_T3__g_p_pi0_p[65] ! vector<Float_t> T3_from_U3__g_p_pi0_p[65] ! vector<Float_t> U3_from_T3__g_p_pi0_p[65] ! vector<Float_t> T3_from_U4__g_p_pi0_p[65] ! vector<Float_t> T4_from_U4__g_p_pi0_p[65] ! vector<Float_t> ThetaCM_from_U3__g_p_pi0_p[65] ! vector<Float_t> U4_from_U3__g_p_pi0_n[65] ! vector<Float_t> U4_from_T3__g_p_pi0_n[65] ! vector<Float_t> T3_from_U3__g_p_pi0_n[65] ! vector<Float_t> U3_from_T3__g_p_pi0_n[65] ! vector<Float_t> T3_from_U4__g_p_pi0_n[65] ! vector<Float_t> T4_from_U4__g_p_pi0_n[65] ! vector<Float_t> ThetaCM_from_U3__g_p_pi0_n[65] ! string fCurrentTagEgyCalibFileName ! vector<Float_t> fT1 ! energy of tagger bins Float_t fMaxU3 Float_t fMaxU4 Float_t fMaxT3 Float_t fMaxT4 Float_t fMaxP3 Float_t fMaxP4 string fPart[4] public:
static const enum CTwobody:: vector_size static const enum CTwobody:: vector_size_MINUS_ONE static const enum CTwobody:: kNumberOfTestGraphs TGraph* testGraph[12]

Class Description

Creates and maintains twobody kinematics lookup tables. The reason
it exists is because I don't want to reca833lculate same values over
and over through use of twobody kinematics programs. I also don't
want to search through generated arrays every time I need a
value. What I do is I generate arrays (once) in such a way that key
value is equal to index * vector_size and keep them in files. At the
beginning of program I read them in. Precision may be set by
specifying size of vector ( array) containing lookup values. The
larger the size - the higher precision. I have found that size
greater than 1000 is not worth because precision becomes much better
than detector resolution already. Perhaps later for a final run one
may increase the precision. Also, some parameters must be set based
on knowledge of ranges of variables being looked up. Say, I know
that energy is never higher than 500 Mev, so I set EMAX to
500. Approximately, my precision in energy becomes 500/1000 = 0.5
MeV.  When I lookup energies in an aray I interpolate linearly if I
hit right in between two element indexes. So, precision is actually
several times better than 0.5 MeV. I would say, maximum 0.2. It
depends on slope of course. Similarly for angles. It is in the order
of 180/1000 = 0.18 degrees. Alternative to this class would be
keeping maps of lookup tables - 2 orders slower, or searching
through arrays every lookup - even slower. So, some complexity here
is exclusively to save CPU cycles (and waste memory instead ;-)). In
future, if size of arrays kept in memory simultenuosly becomes a
problem I might make it such that only arrays of interest are loaded
into memory. For now, if one is needed - all are loaded. Number of
tagger chanels at LEGS is 64. Variable NumTagChanels defined to be
64 in CTwobody.h. It may be changed (together with calibration files
of course) and everything should still work. Therefore I do not call
this class LegsTwobody, but rather CTwobody to underline it's
generality.
 $Log: CTwobody.cxx,v $
 Revision 1.17  2003/10/13 14:06:32  ardashev
 4.03

 Revision 1.16  2001/09/18 23:09:42  ardashev
 *** empty log message ***

 Revision 1.15  2001/06/13 21:46:42  ardashev
 *** empty log message ***

 Revision 1.14  2001/04/27 08:32:16  ardashev
 *** empty log message ***

 Revision 1.13  2001/04/24 21:49:53  ardashev
 made some variables double to improve precision

 Revision 1.12  2001/04/12 04:48:07  ardashev
 introdiced Float_t

 Revision 1.11  2001/03/26 07:42:20  ardashev
 fixed bugs

 Revision 1.10  2001/03/10 09:24:18  ardashev
 *** empty log message ***

 Revision 1.9  2001/03/06 01:49:09  ardashev
 changed to float from double

 Revision 1.8  2001/02/08 21:44:14  ardashev
 added GetP4 GetT4

 Revision 1.7  2000/11/15 03:54:30  ardashev
 made vector size 2000

 Revision 1.6  2000/11/15 00:44:08  ardashev
 made lookup arrays size 10000 and increased precision by one order.

 Revision 1.5  2000/11/14 20:45:30  ardashev
 use map and not very precise delta for linear search

 Revision 1.4  2000/11/07 21:51:44  ardashev
 reduced precision of GetThetaCM to 0.003 rad due to slow CPU


CTwobody(string currentTagEgyCalibFileName, const vector<Float_t>& tag_egy) : fCurrentTagEgyCalibFileName(currentTagEgyCalibFileName),fT1(tag_egy), fMaxU3(M_PI),fMaxU4(M_PI),fMaxT3(500),fMaxT4(500),fMaxP3(1000),fMaxP4(1000)

void Init(string X, string Y)

void Test()

Float_t GetT3_from_U3__g_p_pip_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_T3__g_p_pip_n(Int_t tagbin,const Float_t& T3) const

Float_t GetT3_from_U4__g_p_pip_n(Int_t tagbin,const Float_t& U4) const

Float_t GetT4_from_U4__g_p_pip_n(Int_t tagbin,const Float_t& U4) const

Float_t GetP3_from_U3__g_p_pip_n(Int_t tagbin,const Float_t& U3) const

Float_t GetP4_from_U4__g_p_pip_n(Int_t tagbin,const Float_t& U4) const

Float_t GetU4_from_U3__g_p_pip_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU4_from_T3__g_p_pip_n(Int_t tagbin,const Float_t& T3) const

Float_t GetThetaCM_from_U3__g_p_pip_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_ThetaCM__g_p_pip_n(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

Float_t GetThetaCM_from_U4__g_p_pip_n(Int_t tagbin,const Float_t& U4) const

Float_t GetU4_from_ThetaCM__g_p_pip_n(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

Float_t GetT3_from_U3__g_p_pi0_p(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_T3__g_p_pi0_p(Int_t tagbin,const Float_t& T3) const

Float_t GetT3_from_U4__g_p_pi0_p(Int_t tagbin,const Float_t& U4) const

Float_t GetT4_from_U4__g_p_pi0_p(Int_t tagbin,const Float_t& U4) const

Float_t GetP3_from_U3__g_p_pi0_p(Int_t tagbin,const Float_t& U3) const
 calculates P3 of pi0 from U3 of pi0. Saves space by looking up T3 and then calculating P3 from it.

Float_t GetP4_from_U4__g_p_pi0_p(Int_t tagbin,const Float_t& U4) const
 calculates P4 of proton from U4 of proton. Saves space by looking up T4 and then calculating P4 from it.

Float_t GetU4_from_U3__g_p_pi0_p(Int_t tagbin,const Float_t& U3) const

Float_t GetU4_from_T3__g_p_pi0_p(Int_t tagbin,const Float_t& T3) const

Float_t GetThetaCM_from_U3__g_p_pi0_p(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_ThetaCM__g_p_pi0_p(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

Float_t GetThetaCM_from_U4__g_p_pi0_p(Int_t tagbin,const Float_t& U4) const

Float_t GetU4_from_ThetaCM__g_p_pi0_p(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

Float_t GetT3_from_U3__g_p_pi0_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_T3__g_p_pi0_n(Int_t tagbin,const Float_t& T3) const

Float_t GetT3_from_U4__g_p_pi0_n(Int_t tagbin,const Float_t& U4) const

Float_t GetT4_from_U4__g_p_pi0_n(Int_t tagbin,const Float_t& U4) const

Float_t GetP3_from_U3__g_p_pi0_n(Int_t tagbin,const Float_t& U3) const
 calculates P3 of pi0 from U3 of pi0. Saves space by looking up T3 and then calculating P3 from it.

Float_t GetP4_from_U4__g_p_pi0_n(Int_t tagbin,const Float_t& U4) const
 calculates P4 of proton from U4 of proton. Saves space by looking up T4 and then calculating P4 from it.

Float_t GetU4_from_U3__g_p_pi0_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU4_from_T3__g_p_pi0_n(Int_t tagbin,const Float_t& T3) const

Float_t GetThetaCM_from_U3__g_p_pi0_n(Int_t tagbin,const Float_t& U3) const

Float_t GetU3_from_ThetaCM__g_p_pi0_n(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

Float_t GetThetaCM_from_U4__g_p_pi0_n(Int_t tagbin,const Float_t& U4) const

Float_t GetU4_from_ThetaCM__g_p_pi0_n(Int_t tagbin,const Float_t& thetaCM) const
 directly calculate

void GenerateKinematics(string nameX, string nameY)



Inline Functions


               void ~CTwobody()
            TClass* Class()
            TClass* IsA() const
               void ShowMembers(TMemberInspector& insp, char* parent)
               void Streamer(TBuffer& b)
               void StreamerNVirtual(TBuffer& b)
           CTwobody CTwobody(const CTwobody&)
          CTwobody& operator=(const CTwobody&)


Last update: Wed May 18 13:31:54 2005


ROOT page - Home page - Class index - Class Hierarchy - Top of the page

This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.