]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - HMPID/api.txt
Modifications in CMake* files to export all required headers.
[u/mrichter/AliRoot.git] / HMPID / api.txt
index 3012ac5c6a53b0dfe5ec7c3115291c1295eb723b..2ae22f063e67755269a67ff46edd6445176eb8ba 100644 (file)
@@ -31,7 +31,8 @@ How to deal with the stack of particles?
        - total amount of primary particles in stack for a given event (after LoadHeader()): 
                AliStack::GetNprimary() 
 How to retrieve hits:
-       Hits are stored on primary by primary basis. Hits for the given primary is TClonesArray.
+       Hits are stored on primary by primary basis (hits corresponding to primary particles stored in a single entry; total number of entries in hits tree equals
+        to number of primaries; order of primaries is not preserved). Hits for the given primary is TClonesArray.
        To retrieve all hits one needs to do:
        -initialize the root tree and containers:   pRich->GetLoader()->LoadHits();  (AliLoader::LoadHits() returns 0 on success)
        -read number of entries in TreeH:           pRich->GetLoader()->TreeH()->GetEntries()
@@ -66,7 +67,6 @@ What are the meanings of different VMC flags:
        gMC->IsTrackDisappeared()
 How to get pad number for a local position:
        use static TVector AliHMPIDParam::Loc2Pad(TVector2 position);
-Why list of chambers belongs to AliHMPIDParam:
 
 How to check if a given stack particle is primary:
        Stack is TClonesArray of TParticle. TParticle::GetMother(0) returns -1 if it's primary (no mother)         
@@ -75,7 +75,7 @@ How to loop over all possible object:
     for(Int_t iEntryN=0;iEntryN < GetLoader()->TreeH()->GetEntries();iEntryN++){//TreeH loop
       GetLoader()->TreeH()->GetEntry(iEntryN);//get current entry (prim)  
       for(Int_t iHitN=0;iHitN<Hits()->GetEntries();iHitN++){//hits loop
-        AliVHMPIDHit *pHit=(AliVHMPIDHit*)Hits()->At(iHitN);//get current hit 
+        AliHMPIDHit *pHit=(AliHMPIDHit*)Hits()->At(iHitN);//get current hit 
         
       }//hits loop
     }//TreeH loop
@@ -84,29 +84,32 @@ How to loop over all possible object:
 
 HMPID full simulation-reconstruction sequence
 
+hits creation:
+        HMPID uses 2 types fo hits: MIP hit and photon hit. Both types are implemented in the same class AliHMPIDHit.
+        The difference in ctor patterns is only in energy variable: for photon it is full energy, whereas for MIP it's energy lost in amplification gap gas.
+        Hit for photon is created when photon enters the volume representing a single pad of segmeneted photocathode and survives QE test.
+        Hit for MIP is created when MIP exits amplification gap (or disappired for whatever reason). The responsible code is AliHMPIDv1::StepManager().
+        Internally in ctor, the energy is converted to the total charge accamulated for this hit expressed in QCD channels. This is done in a honest manner for photon:
+        photon always produces a single electron, and the response of the chamber to a single electron pulse is parametrized out of test beam data for few HV sets.
+        For MIP the same procedure is generally wrong: the total energy lost by particle is devided by ionization potential, this value is interpreted as number of electrons
+        created, then each electon contribution is sampled according to puasonian distribution with the same single electron pulse mean as fro photons. The final charge is
+        then a sum of all single electon's contributions, it substitutes the value of energy.
 hits->sdigit:
-       Responsible method is AliHMPID::Hits2SDigits
-       One hit may affect one or more pads.
-        Hit position is taken on the anode wires plane as the most of avalanche is developed there.
-        This position is not directly available, track intersections with entrance and exit of amplification gap are only stored.
-        So the position in the middle of the gap is calculated as average out of pHit->In() and pHit->Out() positions.
-        Then, total charge collected for this hit is calculated by AliHMPIDParam::Hit2Qdc.    
-        Area of disintegration is a list of pads affected by current hit. This is a parameter of Mathienson    
+       Due to segmented photocathode, single hit might affect few neighboring pads (up to 9 in our default parametrization). The total charge collected by a single pad
+        is the answer to electrostatic problem solved in article by Mathieson (see ref ???). Actual disintegration is implemented in AliHMPIDHit::Hit2Sdi().
+        The implementation creates by default sdigits only for closest neighbours of a pad containing hit positon (further neighbours might also be checked subject to
+        parameterization flag ?????? but the contribution to them from single hit is such a tiny that only large nubmer of close hits may provide something not negligable). 
 sdigits->digits:
        The necessety of sdigits is dictated by the fact that transport engine transports tracks in a continuous sequence track by track. 
-  It means that it may happen that the same pad is affected by few tracks. But this might be known only after the transport of full event is finished. 
-
+       It means that it may happen that the same pad is affected by few tracks. But this might be known only after the transport of full event is finished. 
+       So the task of this convertion is to collect all the sdigits for the same pad and sum them up. This is done in AliHMPIDDigitizer::Exec(). This technique also provides
+        the possibility to mix events from seperate simulations facilitating studies of rare signals on top of huge background.
 digits->clusters
-       A set of neighboring digits compose cluster. The aim of this transformation is to construct a list of clusters out of digits list.
-  The calling sequence is:
-  AliReconstruction::Run()
-  
-       AliHMPIDReconstructor::Reconstruct() creates an empty clusters list,  loops on chambers, retrieves a list of digits for a given chamber, gives it to the method Dig2Clu() and finally serializes
-                                        the list 
-                                        
-       AliHMPIDReconstructor::Dig2Clu() which knows no details about 
-
-
+       The aim of this conversion is to try to reconstruct the initial position of hits.
+        This it done by 2 steps procedure. On first step so called raw cluster is formed as a composition of all neighboring pads (diagonal pads are not allowed).
+        Then center of gravity of the cluster is calculated and used as a naive estimate of hit position. 
+        On second step, the code tries to improve the hit position  knowledge by fitting by local maxima number of Mathieson shapes. If the procedure failes, the cog
+        position is preserved as hit position.
 clusters+tracks->theta cerenkov 
 
        
@@ -191,9 +194,16 @@ affected by any external parameters, while influence of methane temperature to i
 In the rest, the only changeable parameter is refractive index of freon. Temperature influence on freon refractive index was measured experimentally. The parametrization 
 found to be:
   n=n0-0.0005(T-20)                        where T is freon temperature in degrees Celsius
-  n0=Sqrt(1+ 0.554*lamda^2/(lamda^2-5796)) where lamda is photon wavelength in nm taken at 20 degrees Celsius
-Preliminary, the parametrization itself is considered to be permanent one. The only parameter to store and retrieve is freon temperature. Since this value is available from
-DCS DB and expected to be served by a SHUTTLE program which is not yet ready, the following temporarily solution has been adopted.
+  n0=Sqrt(1+ 0.554*lamda^2/(lamda^2-5769)) where lamda is photon wavelength in nm taken at 20 degrees Celsius
+Preliminary, the parametrization of refractive index versus temperature and photon energy is considered to be permanent. 
+As the reconstruction itself is only interested in mean refractive index Nmean C6F14, the most elegant solution is to store in OCDB this value, prcalculated in 
+AliHMPIDPrecprocessor. 2 measurements of temperature is avaiable from DCS: for inlet and outlet. They come in form of TObjArray of AliDCSValue, where AliDCSValue
+holds the value of temperature plus a time stamp at wich the value was taken. Due to organization of DCS, it's not possible to implay that all the points are taken at the same 
+time, hence marked with the same time stamp. So the mean temperature are not calculable from inlet-outlet pair. Instead each sperate temperature data points are fitted.
+The resulting functions provide mean temperature function.
+
+
+
 In local CDB storage (default directory is $ALICE_ROOT) two versions of freon refractive index are written by external macro RichCdb.C :
 Run0_0_v0_s0.root contains DiMauro's parametrization and the temperature is set to 20 degrees. To be used as default for simulation and reconstruction.
 Run0_0_v0_s1.root contains DiMauro's parametrization and the temperature is set to 50 degrees. To be used in special uncalibrated reconstruction to test calibration procedure. 
@@ -270,46 +280,16 @@ HMPID 6
  -0.942641    0.000000    0.333807    Tz = 163.565361
 
 
-Map of all HMPID PC planes, coordinates are in spherical system= distance from IP in cm, Theta and Phi in degrees: 
-_______________________________   _______________________________
-| 506.21                506.21|   | 506.21                506.21|
-|  63.26                 78.07|   |  82.59                 97.41|
-|  58.02                 57.32|   |  57.22                 57.22|
-|                             |   |                             |
-|          498.00             |   |          498.00             | Sensitive area  (130.60,126.16)
-|           70.50             |   |           90.00             | Lors Center     ( 65.30, 63.08)
-|           50.00             |   |           50.00             |
-|                             |   |                             |
-| 506.21                506.21|   | 506.21                506.21|
-|  63.26                 78.07|   |  82.59                 97.41|
-|  41.98      6          42.68|   |  42.78      5          42.78|
--------------------------------   -------------------------------
-
-_______________________________   _______________________________   _______________________________
-| 506.21                506.21|   | 506.21                506.21|   | 506.21                506.21|
-|  63.26                 78.07|   |  82.59                 97.41|   | 101.93                116.74|
-|  38.02                 37.32|   |  37.22                 37.22|   |  37.32                 38.02|
-|                             |   |                             |   |                             |
-|          498.00             |   |          498.00             |   |          498.00             |
-|           70.50             |   |           90.00             |   |          109.50             |
-|           30.00             |   |           30.00             |   |           30.00             |
-|                             |   |                             |   |                             |
-| 506.21                506.21|   | 506.21                506.21|   | 506.21                506.21|
-|  63.26                 78.07|   |  82.59                 97.41|   | 101.93                116.74|
-|  21.98      4          22.68|   |  22.78      3          22.78|   |  37.32     2           38.02|
--------------------------------   -------------------------------   -------------------------------
-
-                                  _______________________________   _______________________________
-                                  | 506.21                506.21|   | 506.21                506.21|
-                                  |  82.59                 97.41|   | 101.93                116.74|
-                                  |  17.22                 17.22|   |  17.32                 18.02|
-                                  |                             |   |                             |
-                                  |          498.00             |   |          498.00             |
-                                  |           90.00             |   |          109.50             |
-                                  |           10.00             |   |           10.00             |
-                                  |                             |   |                             |
-                                  | 506.21                506.21|   | 506.21                506.21|
-                                  |  82.59                 97.41|   | 101.93                116.74|
-                                  |   2.78      1           2.78|   |   2.68      0           1.98|
-                                  -------------------------------   -------------------------------
+
+Manual:
+Diclaimer: We call the operator any persons who wants "to operate" HMPID that is to do something reasonalbe to understand current perfomance coming from the detector. 
+This person is not necesarelly an expert in HMPID hardware and or software. 
+Be also aware that analysis of HMPID data can only be perfomed from AliESD (taking also into acount some info which is not specific to HMPID). The task to plot something from
+hits, digits or clusters is called quality assesment.
+
+From operator point of view, one needs to do 3 different tasks with HMPID: simulation, reconstruction and QA.
+
+
+
+