* provided "as is" without express or implied warranty. *
**************************************************************************/
-/*
-$Log$
-Revision 1.11 2003/04/08 08:16:50 morsch
-AliTrackReference constructor without passing pointer to VMC.
-
-Revision 1.10 2003/02/12 10:39:08 hristov
-Updated AliTrackReference class (S.Radomski)
-
-Revision 1.9 2002/11/21 23:05:28 alibrary
-Removing AliMC and AliMCProcess
-
-Revision 1.8 2002/11/14 15:09:58 nilsen
-Fixed problem of elements of a Mixture having zero concentration. This was
-done by reordering some of the elements such that those which may have
-zero concentration were at the end of the array and the array size passed
-would thereby exclude those zero concentrations.
-
-Revision 1.7 2002/11/02 15:15:58 hristov
-Corrected with respect to the previous versions
-
-Revision 1.6 2002/11/01 19:48:35 nilsen
-Fixed bug in material numbering for new FMD part of code. Removed large part
-of commented code (if still needed it is in AliITSvPPRasymm.cxx).
-
-Revision 1.3 2002/10/05 00:12:39 nilsen
-Added material to simulate services in front of the SPD, SDD, and SSD support
-structures. Modified folumes I212, I200, and I099 so that they do not go
-beyond the volume they are creating holes for. This was nessesary so that
-the material added to these volumes would be correct.
-
-Revision 1.2 2002/10/02 17:56:37 barbera
-Bug in copy 37 of volume I570 corrected (thanks to J. Belikov)
-
-Revision 1.1 2002/09/16 14:45:31 barbera
-Updated detailed geometry needed by FMD people for some studies
-
-
-*/
-
+/* $Id$ */
///////////////////////////////////////////////////////////////////////////////
// //
// Inner Traking System version PPR asymmetric for the FMD //
///////////////////////////////////////////////////////////////////////////////
// See AliITSvPPRasymmFMD::StepManager().
+
#include <Riostream.h>
#include <stdio.h>
#include <stdlib.h>
-#include <TMath.h>
+
+#include <TBRIK.h>
+#include <TCanvas.h>
+#include <TClonesArray.h>
+#include <TFile.h> // only required for Tracking function?
#include <TGeometry.h>
+#include <TLorentzVector.h>
+#include <TMath.h>
#include <TNode.h>
-#include <TTUBE.h>
-#include <TTUBS.h>
-#include <TPCON.h>
-#include <TFile.h> // only required for Tracking function?
-#include <TCanvas.h>
#include <TObjArray.h>
-#include <TLorentzVector.h>
#include <TObjString.h>
-#include <TClonesArray.h>
-#include <TBRIK.h>
+#include <TPCON.h>
#include <TSystem.h>
+#include <TTUBE.h>
+#include <TTUBS.h>
+#include <TVirtualMC.h>
-#include "AliRun.h"
-#include "AliMagF.h"
#include "AliConst.h"
-#include "AliITSGeant3Geometry.h"
-#include "AliTrackReference.h"
-#include "AliITShit.h"
#include "AliITS.h"
-#include "AliITSvPPRasymmFMD.h"
+#include "AliITSClusterFinderSDD.h"
+#include "AliITSClusterFinderSPD.h"
+#include "AliITSClusterFinderSSD.h"
+#include "AliITSDetType.h"
+#include "AliITSGeant3Geometry.h"
#include "AliITSgeom.h"
-#include "AliITSgeomSPD.h"
#include "AliITSgeomSDD.h"
+#include "AliITSgeomSPD.h"
#include "AliITSgeomSSD.h"
-#include "AliITSDetType.h"
-#include "AliITSresponseSPD.h"
+#include "AliITShit.h"
#include "AliITSresponseSDD.h"
+#include "AliITSresponseSPD.h"
#include "AliITSresponseSSD.h"
-#include "AliITSsegmentationSPD.h"
#include "AliITSsegmentationSDD.h"
+#include "AliITSsegmentationSPD.h"
#include "AliITSsegmentationSSD.h"
-#include "AliITSsimulationSPD.h"
#include "AliITSsimulationSDD.h"
+#include "AliITSsimulationSPD.h"
#include "AliITSsimulationSSD.h"
-#include "AliITSClusterFinderSPD.h"
-#include "AliITSClusterFinderSDD.h"
-#include "AliITSClusterFinderSSD.h"
+#include "AliITSvPPRasymmFMD.h"
+#include "AliMagF.h"
+#include "AliRun.h"
+#include "AliTrackReference.h"
+#define GEANTGEOMETRY kTRUE
ClassImp(AliITSvPPRasymmFMD)
fIdSens = 0;
fEuclidOut = kFALSE; // Don't write Euclide file
fGeomDetOut = kFALSE; // Don't write .det file
- fGeomDetIn = kFALSE; // Don't Read .det file
+ fGeomDetIn = kTRUE; // Read .det file
fMajorVersion = IsVersion();
fMinorVersion = -1;
for(i=0;i<60;i++) fRead[i] = '\0';
for(i=0;i<60;i++) fWrite[i] = '\0';
for(i=0;i<60;i++) fEuclidGeomDet[i] = '\0';
+ strncpy(fRead,"$ALICE_ROOT/ITS/ITSgeometry_vPPRasymmFMD.det",60);
}
//______________________________________________________________________
AliITSvPPRasymmFMD::AliITSvPPRasymmFMD(const char *name, const char *title)
fIdN = 6;
fIdName = new TString[fIdN];
+ fIdName[0] = name; // removes warning message
fIdName[0] = "ITS1";
fIdName[1] = "ITS2";
fIdName[2] = "ITS3";
fMinorVersion = 2;
fEuclidOut = kFALSE; // Don't write Euclide file
fGeomDetOut = kFALSE; // Don't write .det file
- fGeomDetIn = kFALSE; // Don't Read .det file
+ fGeomDetIn = kTRUE; // Read .det file
SetThicknessDet1();
SetThicknessDet2();
SetThicknessChip1();
strncpy(fEuclidGeomDet,"$ALICE_ROOT/ITS/ITSgeometry_vPPRasymm2.det",60);
strncpy(fRead,fEuclidGeomDet,60);
strncpy(fWrite,fEuclidGeomDet,60);
+ strncpy(fRead,"$ALICE_ROOT/ITS/ITSgeometry_vPPRasymmFMD.det",60);
}
//______________________________________________________________________
-AliITSvPPRasymmFMD::AliITSvPPRasymmFMD(const AliITSvPPRasymmFMD &source){
+AliITSvPPRasymmFMD::AliITSvPPRasymmFMD(const AliITSvPPRasymmFMD &source) :
+ AliITS(source){
// Copy Constructor for ITS version 10. This function is not to be
// used. If any other instance of this function, other than "this" is
// passed, an error message is returned.
// none.
// Return:
// none.
-
+//#if GEANTGEOMETRY
if(strcmp(gMC->GetName(),"TGeant3")) {
Error("InitAliITSgeom",
"Wrong Monte Carlo. InitAliITSgeom uses TGeant3 calls");
// tree its self.
cout << "Reading Geometry informaton from Geant3 common blocks" << endl;
for(i=0;i<20;i++) lnam[i] = lnum[i] = 0;
- for(i=0;i<nlayers;i++)for(j=0;j<ndeep;j++)
- itsGeomTreeNames[i][j] = ig->StringToInt(names[i][j]);
+ for(i=0;i<nlayers;i++)for(j=0;j<ndeep;j++)
+ strncpy((char*) &itsGeomTreeNames[i][j],names[i][j],4);
+ // itsGeomTreeNames[i][j] = ig->StringToInt(names[i][j]);
mod = 0;
for(i=0;i<nlayers;i++){
k = 1;
break;
} // end switch
} // end for lay
+//#endif
return;
}
//______________________________________________________________________
cout << endl;
for(i=0;i<26;i++) cout << "*";
- cout << " ITSvPPRasymm" << fMinorVersion << "_Init ";
+ cout << " ITSvPPRasymmFMD" << fMinorVersion << "_Init ";
for(i=0;i<25;i++) cout << "*";cout << endl;
//
if(fRead[0]=='\0') strncpy(fRead,fEuclidGeomDet,60);
if(fITSgeom!=0) delete fITSgeom;
fITSgeom = new AliITSgeom();
if(fGeomDetIn) fITSgeom->ReadNewFile(fRead);
- if(!fGeomDetIn) this->InitAliITSgeom();
+ else this->InitAliITSgeom();
if(fGeomDetOut) fITSgeom->WriteNewFile(fWrite);
AliITS::Init();
//
TLorentzVector position, momentum;
static TLorentzVector position0;
static Int_t stat0=0;
- if((id=gMC->CurrentVolID(copy) == fIDMother)&&
- (gMC->IsTrackEntering()||gMC->IsTrackExiting())){
+
+ if(!(this->IsActive())){
+ return;
+ } // end if !Active volume.
+
+ if(!(gMC->TrackCharge())) return;
+
+ id=gMC->CurrentVolID(copy);
+
+ Bool_t sensvol = kFALSE;
+ for(Int_t kk=0;kk<6;kk++)if(id == fIdSens[kk])sensvol=kTRUE;
+ if(sensvol && (gMC->IsTrackExiting())){
copy = fTrackReferences->GetEntriesFast();
TClonesArray &lTR = *fTrackReferences;
// Fill TrackReference structure with this new TrackReference.
- new(lTR[copy]) AliTrackReference(gAlice->CurrentTrack());
+ new(lTR[copy]) AliTrackReference(gAlice->GetCurrentTrackNumber());
} // if Outer ITS mother Volume
- if(!(this->IsActive())){
- return;
- } // end if !Active volume.
+
+
Int_t copy1,copy2;
-// Float_t hits[8];
Int_t vol[5];
TClonesArray &lhits = *fHits;
//
//
gMC->TrackPosition(position);
gMC->TrackMomentum(momentum);
-/*
- hits[0]=position[0];
- hits[1]=position[1];
- hits[2]=position[2];
- hits[3]=momentum[0];
- hits[4]=momentum[1];
- hits[5]=momentum[2];
- hits[6]=gMC->Edep();
- hits[7]=gMC->TrackTime();
-*/
vol[4] = stat0;
if(gMC->IsTrackEntering()){
position0 = position;
stat0 = vol[3];
+ return;
} // end if IsEntering
// Fill hit structure with this new hit.
-// new(lhits[fNhits++]) AliITShit(fIshunt,gAlice->CurrentTrack(),vol,hits);
- new(lhits[fNhits++]) AliITShit(fIshunt,gAlice->CurrentTrack(),vol,
+ new(lhits[fNhits++]) AliITShit(fIshunt,gAlice->GetCurrentTrackNumber(),vol,
gMC->Edep(),gMC->TrackTime(),position,
position0,momentum);
//