]> git.uio.no Git - u/mrichter/AliRoot.git/blob - THbtp/THBTprocessor.cxx
Fix coverity defect
[u/mrichter/AliRoot.git] / THbtp / THBTprocessor.cxx
1 #include "THBTprocessor.h"
2 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
3  * See cxx source for full Copyright notice                               */
4
5 /* $Id$ */
6
7 //_____________________________________________________________________________
8 ///////////////////////////////////////////////////////////////////////////////
9 //                                                                           //
10 // class THBTprocessor                                                       //
11 //                                                                           //
12 // Wrapper class to HBT processor fortran code.                              //
13 // For more information see AliGenHBTprocessor class                         //
14 // HBT processor is written by Lanny Ray                                     //
15 //                                                                           //
16 // Comunication is done via COMMON BLOCKS declared in HBTprocCOMMON.h        //
17 // using cfortran.h routines                                                 //
18 // User should use class AliGenHBTprocessor and all their interface          //
19 // see there for more description                                            //
20 //                                                                           //
21 // Wrapper class written by                                                  //
22 // Piotr Krzysztof Skowronski (Piotr.Skowronski@cern.ch)                     //
23 //                                                                           //
24 ///////////////////////////////////////////////////////////////////////////////
25
26
27 #include <Riostream.h>
28 #include <TClonesArray.h>
29 #include <TMath.h>
30 #include <TParticle.h>
31
32 #include "HBTprocCOMMON.h"
33
34 #ifndef WIN32
35 # define hbtprocessor hbtprocessor_
36 # define ctest ctest_
37 # define type_of_call
38 #else
39 # define hbtprocessor HBTPROCESSOR
40 # define ctest CTEST
41 # define type_of_call _stdcall
42 #endif    
43
44
45 ClassImp(THBTprocessor)
46  
47 extern "C" void  type_of_call hbtprocessor();   
48 extern "C" void  type_of_call ctest();
49
50
51 /*************************************************/
52 THBTprocessor::THBTprocessor()// it is better not to intialize it:TGenerator("THBTprocessor","THBTprocessor")
53                               //because it allocates memmory for TObjArray::fParticles which is not used in our case
54                               //and we are using TClonesArray in import paerticles
55  {
56  //constructor
57   PARAMETERS.ALICE            = 1; //flag that we are working in AliRoot (0==STAR stand alone mode)
58   PARAMETERS.pi               = TMath::Pi();//3.141592654;
59   PARAMETERS.rad              = 180.0/TMath::Pi();
60   PARAMETERS.hbc              = 0.19732891;
61   
62   fParticles = 0;
63   Initialize(); //Enforce initialization (cleaning all commons)
64  }
65 /*****************************************************************************************/
66
67 #if ROOT_VERSION_CODE <= ROOT_VERSION(5,11,2)
68 void THBTprocessor::GenerateEvent() const
69 #else
70 void THBTprocessor::GenerateEvent()
71 #endif
72 {
73 //Starts processing
74
75   Info("GenerateEvent","Entering Fortran");
76   ctest();
77   hbtprocessor();
78   Info("GenerateEvent","Exited Fortran");
79   if(PARAMETERS.errorcode)
80     {
81       TString message("HBT Processor (fortran part) finished with errors\n");
82       message+="Error code is ";
83       message+=PARAMETERS.errorcode;
84       message+="\n";
85       message+="See hbt_simulation.out file for more detailed information.";
86       Fatal("GenerateEvent","%s",message.Data());
87     }
88   else
89     Info("GenerateEvent","GOOD ! HBT Processor finished without errors");
90 }
91 /*****************************************************************************************/
92
93 void THBTprocessor::Initialize() const
94
95   //IT RESETS ALL THE PREVIOUS SETTINGS
96   //Call this method to set default values in PARAMETERS & MESH
97   //and zero other common block
98   
99   if(gDebug) 
100    Info("Initialize","Setting Default valuses in all COMMON BLOCKS");
101   
102   PARAMETERS.ref_control      = 2;
103   PARAMETERS.switch_1d        = 3;
104   PARAMETERS.switch_3d        = 1;
105   PARAMETERS.switch_type      = 3;
106   PARAMETERS.switch_coherence = 0;
107   PARAMETERS.switch_coulomb   = 3;
108   PARAMETERS.switch_fermi_bose= 1;
109   PARAMETERS.trk_accep        = 1.0;
110   PARAMETERS.print_full       = 1;
111   PARAMETERS.print_sector_data= 1;
112
113   PARAMETERS.n_pid_types      = 2;
114   PARAMETERS.pid[0]           = 8;
115   PARAMETERS.pid[1]           = 9;
116   PARAMETERS.deltap           = 0.1;
117   PARAMETERS.maxit            = 50;
118   PARAMETERS.delchi           = 1.0;
119   PARAMETERS.irand            = 76564;
120   PARAMETERS.lambda           = 0.6;
121   PARAMETERS.R_1d             = 7.0;
122   PARAMETERS.Rside            = 6.0;
123
124   PARAMETERS.Rout             = 7.0;
125   PARAMETERS.Rlong            = 4.0;
126   PARAMETERS.Rperp            = 6.0;
127   PARAMETERS.Rparallel        = 4.0;
128   PARAMETERS.R0               = 4.0;
129   PARAMETERS.Q0               = 9.0;
130
131   PARAMETERS.n_part_1_trk         = 0;
132   PARAMETERS.n_part_2_trk         = 0;
133   PARAMETERS.n_part_tot_trk       = 0;
134   PARAMETERS.n_part_used_1_trk    = 0;
135
136   PARAMETERS.n_part_used_2_trk    = 0;
137   PARAMETERS.n_part_1_trk2        = 0;
138   PARAMETERS.n_part_2_trk2        = 0;
139   PARAMETERS.n_part_tot_trk2      = 0;
140   PARAMETERS.n_part_used_1_trk2   = 0;
141   PARAMETERS.n_part_used_2_trk2   = 0;
142   PARAMETERS.n_part_used_1_ref    = 0;
143   PARAMETERS.n_part_used_2_ref    = 0;
144   PARAMETERS.n_part_used_1_inc    = 0;
145   PARAMETERS.n_part_used_2_inc    = 0;
146  
147   PARAMETERS.num_pairs_like       = 0;
148   PARAMETERS.num_pairs_unlike     = 0;
149   PARAMETERS.num_pairs_like_ref   = 0;
150   PARAMETERS.num_pairs_like_inc   = 0;
151   PARAMETERS.num_pairs_unlike_inc = 0;
152   PARAMETERS.event_line_counter   = 0;
153   PARAMETERS.file10_line_counter  = 0;
154
155   PARAMETERS.chisq_wt_like_1d         = 1.0;
156   PARAMETERS.chisq_wt_unlike_1d       = 1.0;
157   PARAMETERS.chisq_wt_like_3d_fine    = 1.0;
158
159   PARAMETERS.chisq_wt_unlike_3d_fine  = 1.0;
160   PARAMETERS.chisq_wt_like_3d_coarse  = 1.0;
161   PARAMETERS.chisq_wt_unlike_3d_coarse= 1.0;
162   PARAMETERS.chisq_wt_hist1_1         = 1.0;
163   PARAMETERS.chisq_wt_hist1_2         = 1.0; // /////internal comment 25 fields
164
165 /*********************************************/
166
167  
168   MESH.n_pt_bins        = 50;                            //OK
169   MESH.pt_min           = 0.1;  //Pt in GeV/c            //OK
170   MESH.pt_max           = 0.98; //Pt in GeV/c
171   MESH.n_phi_bins       = 50;                          //OK
172   MESH.phi_min          = 0.0;                              //OK
173   MESH.phi_max          = 360.0;                          //OK
174   MESH.n_eta_bins       = 50;                          //OK
175   MESH.eta_min          =-1.5;                          //OK
176   MESH.eta_max          = 1.5;                          //OK
177   MESH.n_1d_fine        = 10;                          //OK
178   MESH.binsize_1d_fine  = 0.01;                         //ok 
179   MESH.n_1d_coarse      = 2;                          //O
180   MESH.binsize_1d_coarse= 0.05;                       //ok
181   MESH.n_3d_fine        = 8;                          //OK
182   MESH.binsize_3d_fine  = 0.01;                       //ok
183   MESH.n_3d_coarse      = 2;                          //OK
184   MESH.binsize_3d_coarse= 0.08;                       //ok
185   MESH.n_3d_fine_project= 3;                          //OK
186   MESH.n_px_bins        = 20;                          //OK
187   MESH.px_min           =-1.0;                          //OK
188   MESH.px_max           = 1.0;                          //OK
189   MESH.n_py_bins        = 20;                          //OK
190   MESH.py_min           =-1.0;                          //OK
191   MESH.py_max           = 1.0;                          //OK
192   MESH.n_pz_bins        = 70;                          //OK
193   MESH.pz_min           =-3.6;                          //OK
194   MESH.pz_max           = 3.6;                          //OK
195   
196 /*********************************************/
197
198   Int_t i; //loop variable
199   
200   for (i =0; i<TRK_MAXLEN;i++)
201    {
202     TRACK1.trk_id[i] = 0;
203     TRACK1.trk_px_sec[i] = 0; 
204     TRACK1.trk_py_sec[i] = 0;
205     TRACK1.trk_pz_sec[i] = 0;
206     TRACK1.trk_sector[i] = 0;
207     TRACK1.trk_flag[i] = 0;
208     TRACK1.trk_out_flag[i] = 0;
209     TRACK1.trk_merge_flag[i] = 0;
210     TRACK1.trk_ge_pid[i] = 0;
211     TRACK1.trk_start_vertex[i] = 0;
212     TRACK1.trk_stop_vertex[i] = 0;
213     TRACK1.trk_event_line[i] = 0;
214     TRACK1.trk_px[i] = 0;
215     TRACK1.trk_py[i] = 0;
216     TRACK1.trk_pz[i] = 0;
217     TRACK1.trk_E[i] = 0;
218     TRACK1.trk_pt[i] = 0;
219     TRACK1.trk_phi[i] = 0;
220     TRACK1.trk_eta[i] = 0; 
221    }
222   
223 /*********************************************/
224
225   for (i =0; i<TRK2_MAXLEN;i++)
226    {
227     TRACK2.trk2_id[i] = 0;
228     TRACK2.trk2_px_sec[i] = 0; 
229     TRACK2.trk2_py_sec[i] = 0;
230     TRACK2.trk2_pz_sec[i] = 0;
231     TRACK2.trk2_sector[i] = 0;
232     TRACK2.trk2_flag[i] = 0;
233     TRACK2.trk2_out_flag[i] = 0;
234     TRACK2.trk2_merge_flag[i] = 0;
235     TRACK2.trk2_ge_pid[i] = 0;
236     TRACK2.trk2_start_vertex[i] = 0;
237     TRACK2.trk2_stop_vertex[i] = 0;
238     TRACK2.trk2_event_line[i] = 0;
239     TRACK2.trk2_px[i] = 0;
240     TRACK2.trk2_py[i] = 0;
241     TRACK2.trk2_pz[i] = 0;
242     TRACK2.trk2_E[i] = 0;
243     TRACK2.trk2_pt[i] = 0;
244     TRACK2.trk2_phi[i] = 0;
245     TRACK2.trk2_eta[i] = 0; 
246    }
247
248 /*********************************************/
249
250   for (i =0; i<SEC_MAXLEN;i++)
251    {
252     SEC_TRK_MAP.stm_sec_id [i] = 0;
253     SEC_TRK_MAP.stm_n_trk_sec[i] = 0; 
254     SEC_TRK_MAP.stm_flag[i] = 0;
255     
256     for (Int_t j=0; j<MAX_TRK_SEC;j++)
257        SEC_TRK_MAP.stm_track_id[i][j] = 0;
258    }
259
260 /*********************************************/
261
262   for (i =0; i<SEC_MAXLEN2;i++)
263    {
264     SEC_TRK_MAP2.stm_sec_id2[i] = 0;
265     SEC_TRK_MAP2.stm_n_trk_sec2[i] = 0; 
266     SEC_TRK_MAP2.stm_flag2[i] = 0;
267     
268     for (Int_t j=0; j<MAX_TRK_SEC;j++)
269        SEC_TRK_MAP2.stm_track_id2[i][j] = 0;
270    }
271
272 /*********************************************/
273
274   for (i =0; i<PART_MAXLEN;i++)
275    {
276      PARTICLE.part_id[i] = 0;
277      PARTICLE.part_charge[i] = 0;
278      PARTICLE.part_mass[i] = 0;
279      PARTICLE.part_lifetime[i] = 0;
280    }
281
282
283 /*********************************************/
284   for (i =0; i<MAX_C2_1D;i++)
285    {
286      CORRELATIONS.c2mod_like_1d[i] = 0; 
287      CORRELATIONS.c2mod_unlike_1d[i] = 0;
288      CORRELATIONS.c2fit_like_1d[i] = 0;
289      CORRELATIONS.c2fit_unlike_1d[i] = 0;
290      CORRELATIONS.c2err_like_1d[i] = 0;
291      CORRELATIONS.c2err_unlike_1d[i] = 0;
292    }
293 /*********************************************/
294   for (i =0; i<MAX_C2_3D;i++)
295    for (Int_t j =0; j<MAX_C2_3D;j++)
296     for (Int_t k =0; k<MAX_C2_3D;k++)
297      {
298       CORRELATIONS.c2mod_like_3d_fine[i][j][k] = 0.0;
299       CORRELATIONS.c2mod_unlike_3d_fine[i][j][k] = 0.0;
300       CORRELATIONS.c2mod_like_3d_coarse[i][j][k] = 0.0;
301       CORRELATIONS.c2mod_unlike_3d_coarse[i][j][k] = 0.0;
302       CORRELATIONS.c2fit_like_3d_fine[i][j][k] = 0.0;
303       CORRELATIONS.c2fit_unlike_3d_fine[i][j][k] = 0.0;
304       CORRELATIONS.c2fit_like_3d_coarse[i][j][k] = 0.0;
305       CORRELATIONS.c2fit_unlike_3d_coarse[i][j][k] = 0.0;
306       CORRELATIONS.c2err_like_3d_fine[i][j][k] = 0.0;
307       CORRELATIONS.c2err_unlike_3d_fine[i][j][k] = 0.0;
308       CORRELATIONS.c2err_like_3d_coarse[i][j][k] = 0.0;
309       CORRELATIONS.c2err_unlike_3d_coarse[i][j][k] = 0.0;
310      }
311 /*********************************************/
312
313    EVENT_SUMMARY.niter_mean = 0.0; 
314    EVENT_SUMMARY.niter_rms = 0.0;
315  
316    EVENT_SUMMARY.npart1_mean = 0.0; 
317    EVENT_SUMMARY.npart1_rms = 0.0;
318  
319    EVENT_SUMMARY.npart2_mean = 0.0; 
320    EVENT_SUMMARY.npart2_rms = 0.0;
321  
322    EVENT_SUMMARY.npart_tot_mean = 0.0; 
323    EVENT_SUMMARY.npart_tot_rms = 0.0;
324  
325    EVENT_SUMMARY.nsec_flag_mean = 0.0; 
326    EVENT_SUMMARY.nsec_flag_rms = 0.0;
327  
328    EVENT_SUMMARY.frac_trks_out_mean = 0.0;
329    EVENT_SUMMARY.frac_trks_out_rms = 0.0;
330  
331    EVENT_SUMMARY.frac_trks_flag_mean = 0.0;
332    EVENT_SUMMARY.frac_trks_flag_rms = 0.0;
333  
334    EVENT_SUMMARY.chi_l1d_mean = 0.0;
335    EVENT_SUMMARY.chi_l1d_rms = 0.0;
336
337    EVENT_SUMMARY.chi_u1d_mean = 0.0;
338    EVENT_SUMMARY.chi_u1d_rms = 0.0;
339
340  for (i =0; i<MAX_EVENTS;i++) 
341   {
342     EVENT_SUMMARY.n_part_used_1_store[i] = 0.0; 
343     EVENT_SUMMARY.n_part_used_2_store[i] = 0.0; 
344     EVENT_SUMMARY.n_part_tot_store[i] = 0.0; 
345     EVENT_SUMMARY.num_sec_flagged_store[i] = 0.0; 
346     EVENT_SUMMARY.frac_trks_out[i] = 0.0; 
347     EVENT_SUMMARY.frac_trks_flag[i] = 0.0;
348     EVENT_SUMMARY.chisq_like_1d_store[i] = 0.0;         
349     EVENT_SUMMARY.num_iter[i] = 0.0; 
350     EVENT_SUMMARY.chisq_unlike_1d_store[i] = 0.0;       
351   } 
352 /*********************************************/
353  for (i =0; i<MAX_C2_COUL;i++) 
354   {
355       COULMB.c2_coul_like[i] = 0.0;
356       COULMB.c2_coul_unlike[i] = 0.0;
357       COULMB.q_coul[i] = 0.0; 
358  
359   }
360 /*********************************************/
361  for (i =0; i<MAX_H_1D;i++) 
362    {  
363       HISTOGRAMS.hist1_pt_1[i] = 0;
364       HISTOGRAMS.hist1_phi_1[i] = 0;
365       HISTOGRAMS.hist1_eta_1[i] = 0;
366       HISTOGRAMS.hist1_pt_2[i] = 0;
367       HISTOGRAMS.hist1_phi_2[i] = 0;
368       HISTOGRAMS.hist1_eta_2[i] = 0;
369       HISTOGRAMS.htmp1_pt_1[i] = 0;
370       HISTOGRAMS.htmp1_phi_1[i] = 0;
371       HISTOGRAMS.htmp1_eta_1[i] = 0;
372       HISTOGRAMS.htmp1_pt_2[i] = 0;
373       HISTOGRAMS.htmp1_phi_2[i] = 0;
374       HISTOGRAMS.htmp1_eta_2[i] = 0;
375       HISTOGRAMS.href1_pt_1[i] = 0;
376       HISTOGRAMS.href1_phi_1[i] = 0;
377       HISTOGRAMS.href1_eta_1[i] = 0;
378       HISTOGRAMS.href1_pt_2[i] = 0;
379       HISTOGRAMS.href1_phi_2[i] = 0;
380       HISTOGRAMS.href1_eta_2[i] = 0;
381       HISTOGRAMS.hinc1_pt_1[i] = 0;
382       HISTOGRAMS.hinc1_phi_1[i] = 0;
383       HISTOGRAMS.hinc1_eta_1[i] = 0;
384       HISTOGRAMS.hinc1_pt_2[i] = 0;
385       HISTOGRAMS.hinc1_phi_2[i] = 0;
386       HISTOGRAMS.hinc1_eta_2[i] = 0;
387       HISTOGRAMS.hist_like_1d[i] = 0;
388       HISTOGRAMS.hist_unlike_1d[i] = 0;
389       HISTOGRAMS.htmp_like_1d[i] = 0;
390       HISTOGRAMS.htmp_unlike_1d[i] = 0;
391       HISTOGRAMS.href_like_1d[i] = 0;
392       HISTOGRAMS.href_unlike_1d[i] = 0;
393       HISTOGRAMS.hinc_like_1d[i] = 0;
394       HISTOGRAMS.hinc_unlike_1d[i] = 0;
395   }
396
397  for (i =0; i<MAX_H_3D;i++) 
398    for (Int_t j =0; j<MAX_H_3D;j++) 
399      for (Int_t k =0; k<MAX_H_3D;k++) 
400        {
401           HISTOGRAMS.hist_like_3d_fine[i][j][k] = 0;
402           HISTOGRAMS.hist_unlike_3d_fine[i][j][k] = 0;
403           HISTOGRAMS.hist_like_3d_coarse[i][j][k] = 0;
404           HISTOGRAMS.hist_unlike_3d_coarse[i][j][k] = 0;
405           HISTOGRAMS.htmp_like_3d_fine[i][j][k] = 0;
406           HISTOGRAMS.htmp_unlike_3d_fine[i][j][k] = 0;
407           HISTOGRAMS.htmp_like_3d_coarse[i][j][k] = 0;
408           HISTOGRAMS.htmp_unlike_3d_coarse[i][j][k] = 0;
409           HISTOGRAMS.href_like_3d_fine[i][j][k] = 0;
410           HISTOGRAMS.href_unlike_3d_fine[i][j][k] = 0;
411           HISTOGRAMS.href_like_3d_coarse[i][j][k] = 0;
412           HISTOGRAMS.href_unlike_3d_coarse[i][j][k] = 0;
413           HISTOGRAMS.hinc_like_3d_fine[i][j][k] = 0;
414           HISTOGRAMS.hinc_unlike_3d_fine[i][j][k] = 0;
415           HISTOGRAMS.hinc_like_3d_coarse[i][j][k] = 0;
416           HISTOGRAMS.hinc_unlike_3d_coarse[i][j][k] = 0;
417        }
418 /*********************************************/
419
420
421 /*********************************************/
422
423 //  cout<<" FINISHED"<<endl;
424   
425 }
426
427
428 /*****************************************************************************************/
429
430
431 Int_t THBTprocessor::ImportParticles(TClonesArray *particles, Option_t */*option*/)
432  {
433   //Copy particle data into TClonesArray
434   if (particles == 0) return 0;
435   TClonesArray &rparticles = *particles;
436   rparticles.Clear();
437  
438   Int_t nrpart = 0;
439   for (Int_t i=0; i < TRK_MAXLEN; i++) 
440    {
441    
442     
443       if (TRACK1.trk_E[i] == 0.) continue;
444     
445       Float_t px   = TRACK1.trk_px[i];
446       Float_t py   = TRACK1.trk_py[i];
447       Float_t pz   = TRACK1.trk_pz[i];
448 //    Float_t pE   = TRACK.trk_E[i];
449       Float_t mass = PARTICLE.part_mass[TRACK1.trk_ge_pid[i]];
450     
451       new(rparticles[nrpart++]) TParticle(0,0,0,0,0,0,px,py,pz,
452                                          TMath::Sqrt(mass*mass+px*px+py*py+pz*pz),
453                                          0,0,0,0);
454    }
455   return nrpart;        
456  }
457
458 /*****************************************************************************************/
459 TObjArray * THBTprocessor::ImportParticles(Option_t */*option*/)
460  {
461   //Copy particle data into TObjArray
462   fParticles->Clear();
463  
464   for (Int_t i=0; i < TRK_MAXLEN; i++) 
465    {
466    
467     
468       if (TRACK1.trk_E[i] == 0.) continue;
469     
470       Float_t px   = TRACK1.trk_px[i];
471       Float_t py   = TRACK1.trk_py[i];
472       Float_t pz   = TRACK1.trk_pz[i];
473 //    Float_t pE   = TRACK.trk_E[i];
474       Float_t mass = PARTICLE.part_mass[TRACK1.trk_ge_pid[i]];
475     
476       TParticle * p =new TParticle(0,0,0,0,0,0,px,py,pz,
477                                    TMath::Sqrt(mass*mass+px*px+py*py+pz*pz),
478                                    0,0,0,0);
479       fParticles->Add(p);
480    }
481   return fParticles;        
482  }
483
484 /*****************************************************************************************/
485
486 void THBTprocessor::PrintEvent() const
487  {
488  //Prints all particles (common block data)  
489    cout<<"Print Event"<<endl;
490    for (Int_t i=0; i<TRK_MAXLEN;i++)
491     {
492       if(TRACK1.trk_E[i]==0.) continue;
493
494       cout<<"trk_id: "<<TRACK1.trk_id[i]<<"  trk_px :"<<TRACK1.trk_px[i]<<"  trk_py :"<<TRACK1.trk_py[i]<<"  trk_pz :"<<TRACK1.trk_pz[i]<<endl;
495       cout<<"                trk_E: "<<TRACK1.trk_E[i]<<"  trk_pt: "<<TRACK1.trk_pt[i]<<"  trk_phi: "<<TRACK1.trk_phi[i]<<"  trk_eta: "<<TRACK1.trk_eta[i]<<endl;
496     }
497  }
498
499
500 /*****************************************************************************************/
501 void THBTprocessor::DumpSettings() const
502 {
503  //prints values set in common blocks
504   ctest();
505 }
506 void THBTprocessor::SetTrackRejectionFactor(Float_t trf) const 
507 {
508  //setter
509  PARAMETERS.trk_accep = trf;
510 }
511 void THBTprocessor::SetRefControl(Int_t rc) const 
512 {
513  //setter
514  PARAMETERS.ref_control = rc;
515 }
516 void THBTprocessor::SetPIDs(Int_t pid1,Int_t pid2) const 
517 {
518  //setter
519  PARAMETERS.pid[0]=pid1; PARAMETERS.pid[1]=pid2;
520 }
521 void THBTprocessor::SetNPIDtypes(Int_t npidt)const 
522 {
523  //setter
524  PARAMETERS.n_pid_types = npidt;
525 }
526 void THBTprocessor::SetDeltap(Float_t deltp) const 
527 {
528  //setter
529  PARAMETERS.deltap=deltp; 
530 }
531 void THBTprocessor::SetMaxIterations(Int_t maxiter) const 
532 {
533  //setter
534  PARAMETERS.maxit = maxiter;
535 }
536 void THBTprocessor::SetDelChi(Float_t dc)const 
537 {
538  //setter
539  PARAMETERS.delchi = dc;
540 }
541 void THBTprocessor::SetIRand(Int_t irnd) const 
542 {
543  //setter
544  PARAMETERS.irand = irnd;
545 }
546 void THBTprocessor::SetLambda(Float_t lam) const 
547
548  //setter
549  PARAMETERS.lambda = lam;
550 }
551 void THBTprocessor::SetR1d(Float_t r) const 
552 {
553  //setter
554  PARAMETERS.R_1d=r;
555 }
556 void THBTprocessor::SetRSide(Float_t rs) const 
557 {
558  //setter
559  PARAMETERS.Rside=rs;
560 }
561 void THBTprocessor::SetROut(Float_t ro) const 
562 {
563  //setter
564  PARAMETERS.Rout=ro;
565 }
566 void THBTprocessor::SetRLong(Float_t rl) const 
567 {
568  //setter
569  PARAMETERS.Rlong=rl;
570 }
571 void THBTprocessor::SetRPerp(Float_t rp) const 
572 {
573  //setter
574  PARAMETERS.Rperp=rp;
575 }
576 void THBTprocessor::SetRParallel(Float_t rprl) const 
577 {
578  //setter
579  PARAMETERS.Rparallel=rprl;
580 }
581 void THBTprocessor::SetR0(Float_t r0) const 
582 {
583  //setter
584  PARAMETERS.R0=r0;
585 }
586 void THBTprocessor::SetQ0(Float_t q0) const 
587 {
588  //setter
589 PARAMETERS.Q0=q0;
590 }
591 void THBTprocessor::SetSwitch1D(Int_t s1d) const 
592 {
593  //setter
594  PARAMETERS.switch_1d = s1d;
595 }
596 void THBTprocessor::SetSwitch3D(Int_t s3d) const 
597 {
598  //setter
599  PARAMETERS.switch_3d = s3d;
600 }
601 void THBTprocessor::SetSwitchType(Int_t st) const 
602 {
603  //setter
604  PARAMETERS.switch_type = st;
605 }
606
607 void THBTprocessor::SetSwitchCoherence(Int_t sc) const 
608 {
609  //setter
610  PARAMETERS. switch_coherence = sc;
611 }
612 void THBTprocessor::SetSwitchCoulomb(Int_t scol) const 
613 {
614  //setter
615  PARAMETERS. switch_coulomb = scol;
616 }
617 void THBTprocessor::SetSwitchFermiBose(Int_t sfb) const 
618 {
619  //setter
620  PARAMETERS.switch_fermi_bose = sfb;
621 }
622       
623 void THBTprocessor::SetPtRange(Float_t ptmin, Float_t ptmax)const  //Pt in GeV/c
624
625  //setter
626   MESH.pt_min=ptmin;MESH.pt_max=ptmax;
627 }
628
629 void THBTprocessor::SetPxRange(Float_t pxmin, Float_t pxmax) const
630
631  //setter
632  MESH.px_min=pxmin;MESH.px_max=pxmax;
633 }
634
635 void THBTprocessor::SetPyRange(Float_t pymin, Float_t pymax)const 
636
637  //setter
638  MESH.py_min=pymin;MESH.py_max=pymax;
639 }
640
641 void THBTprocessor::SetPzRange(Float_t pzmin, Float_t pzmax) const
642
643  //setter
644  MESH.pz_min=pzmin;MESH.pz_max=pzmax;
645 }
646
647 void THBTprocessor::SetPhiRange(Float_t phimin, Float_t phimax)const //Angle in degrees
648
649  //setter
650  MESH.phi_min=phimin;MESH.phi_max=phimax;
651 }
652
653 void THBTprocessor::SetEtaRange(Float_t etamin, Float_t etamax)const //Pseudorapidity  !!!!!!!!!
654
655  //setter
656  MESH.eta_min=etamin;MESH.eta_max=etamax;
657 }
658
659 void THBTprocessor::SetNPtBins(Int_t nptbin)const
660 {
661 //setter
662 MESH.n_pt_bins=nptbin;
663 }
664 void THBTprocessor::SetNPhiBins(Int_t nphibin)const
665 {
666 //setter
667 MESH.n_phi_bins=nphibin;
668 }
669 void THBTprocessor::SetNEtaBins(Int_t netabin)const
670 {
671 //setter
672 MESH.n_eta_bins=netabin;
673 }
674       
675 void THBTprocessor::SetNPxBins(Int_t npxbin)const
676 {
677 //setter
678 MESH.n_px_bins=npxbin;
679 }
680 void THBTprocessor::SetNPyBins(Int_t npybin)const
681 {
682 //setter
683 MESH.n_py_bins=npybin;
684 }
685 void THBTprocessor::SetNPzBins(Int_t npzbin)const
686 {
687 //setter
688 MESH.n_pz_bins=npzbin;
689 }
690
691 void THBTprocessor::SetNBins1DFineMesh(Int_t n)const
692 {
693 //setter
694 MESH.n_1d_fine=n;
695 }
696 void THBTprocessor::SetBinSize1DFineMesh(Float_t x)const
697 {
698 //setter
699 MESH.binsize_1d_fine=x;
700 }
701       
702 void THBTprocessor::SetNBins1DCoarseMesh(Int_t n)const
703 {
704 //setter
705 MESH.n_1d_coarse =n;
706 }
707 void THBTprocessor::SetBinSize1DCoarseMesh(Float_t x)const
708 {
709 //setter
710 MESH.binsize_1d_coarse=x;
711 }
712       
713 void THBTprocessor::SetNBins3DFineMesh(Int_t n)const
714 {
715 //setter
716 MESH.n_3d_fine =n;
717 }
718 void THBTprocessor::SetBinSize3DFineMesh(Float_t x)const
719 {
720 //setter
721 MESH.binsize_3d_fine=x;
722 }
723       
724 void THBTprocessor::SetNBins3DCoarseMesh(Int_t n)const
725 {
726 //setter
727 MESH.n_3d_coarse=n;
728 }
729 void THBTprocessor::SetBinSize3DCoarseMesh(Float_t x)const
730 {
731 //setter
732 MESH.binsize_3d_coarse=x;
733 }      
734       
735 void THBTprocessor::SetNBins3DFineProjectMesh(Int_t n )const
736 {
737 //setter
738 MESH.n_3d_fine_project=n;
739 }
740
741 void THBTprocessor::SetPrintFull(Int_t flag) const 
742 {
743  //setter
744  PARAMETERS.print_full=flag;
745