Commit 658f597b authored by Morfouace's avatar Morfouace

* Updating PISTA project

parent bc82e07e
Pipeline #99609 passed with stages
in 14 minutes and 13 seconds
......@@ -67,11 +67,9 @@ void TPISTAPhysics::AddDetector(TVector3){
void TPISTAPhysics::AddDetector(double R, double Theta, double Phi){
m_NumberOfDetectors++;
//double Height = 118; // mm
double Height = 61.8; // mm
//double Base = 95; // mm
double Base = 78.1; // mm
double NumberOfStripsX = 122;
double NumberOfStripsX = 62;
double NumberOfStripsY = 97;
double StripPitchHeight = Height / NumberOfStripsY; // mm
......@@ -153,21 +151,21 @@ TVector3 TPISTAPhysics::GetPositionOfInteraction(const int i){
///////////////////////////////////////////////////////////////////////////
TVector3 TPISTAPhysics::GetDetectorNormal(const int i){
TVector3 U = TVector3(GetStripPositionX(DetectorNumber[i],122,1),
GetStripPositionY(DetectorNumber[i],122,1),
GetStripPositionZ(DetectorNumber[i],122,1))
TVector3 U = TVector3(GetStripPositionX(DetectorNumber[i],62,1),
GetStripPositionY(DetectorNumber[i],62,1),
GetStripPositionZ(DetectorNumber[i],62,1))
-TVector3(GetStripPositionX(DetectorNumber[i],122,1),
GetStripPositionY(DetectorNumber[i],122,1),
GetStripPositionZ(DetectorNumber[i],122,1));
-TVector3(GetStripPositionX(DetectorNumber[i],62,1),
GetStripPositionY(DetectorNumber[i],62,1),
GetStripPositionZ(DetectorNumber[i],62,1));
TVector3 V = TVector3(GetStripPositionX(DetectorNumber[i],122,97),
GetStripPositionY(DetectorNumber[i],122,97),
GetStripPositionZ(DetectorNumber[i],122,97))
TVector3 V = TVector3(GetStripPositionX(DetectorNumber[i],62,97),
GetStripPositionY(DetectorNumber[i],62,97),
GetStripPositionZ(DetectorNumber[i],62,97))
-TVector3(GetStripPositionX(DetectorNumber[i],122,1),
GetStripPositionY(DetectorNumber[i],122,1),
GetStripPositionZ(DetectorNumber[i],122,1));
-TVector3(GetStripPositionX(DetectorNumber[i],62,1),
GetStripPositionY(DetectorNumber[i],62,1),
GetStripPositionZ(DetectorNumber[i],62,1));
TVector3 Normal = U.Cross(V);
......
......@@ -350,7 +350,7 @@ void PISTA::InitializeScorers() {
G4VPrimitiveScorer* SecondStageScorer = new DSSDScorers::PS_Rectangle("SecondStageScorer",1,
TrapezoidBaseLarge,
TrapezoidHeight,
122,1);
62,1);
G4VPrimitiveScorer* InteractionFirstStage = new InteractionScorers::PS_Interactions("InteractionFirstStage",ms_InterCoord,0);
G4VPrimitiveScorer* InteractionSecondStage = new InteractionScorers::PS_Interactions("InteractionSecondStage",ms_InterCoord,0);
......
......@@ -58,10 +58,10 @@ void Analysis::Init(){
////////////////////////////////////////////////////////////////////////////////
void Analysis::TreatEvent(){
ReInitValue();
OriginalThetaLab = ReactionConditions->GetTheta(0);
OriginalElab = ReactionConditions->GetKineticEnergy(0);
OriginalBeamEnergy = ReactionConditions->GetBeamEnergy();
OriginalEx = ReactionConditions->GetExcitation4();
//OriginalThetaLab = ReactionConditions->GetTheta(0);
//OriginalElab = ReactionConditions->GetKineticEnergy(0);
//OriginalBeamEnergy = ReactionConditions->GetBeamEnergy();
//OriginalEx = ReactionConditions->GetExcitation4();
int mult = InteractionCoordinates->GetDetectedMultiplicity();
if(mult>0){
......@@ -91,11 +91,15 @@ void Analysis::TreatEvent(){
DeltaE = PISTA->DE[i];
Eres = PISTA->E[i];
PID = pow(Energy,1.78)-pow(PISTA->E[i],1.78);
TVector3 HitDirection = PISTA->GetPositionOfInteraction(i)-PositionOnTarget;
//ThetaLab = HitDirection.Angle(BeamDirection);
ThetaLab = HitDirection.Angle(TVector3(0,0,1));
ThetaDetectorSurface = HitDirection.Angle(-PISTA->GetDetectorNormal(i));
DeltaE = DeltaE/cos(ThetaDetectorSurface);
//PID = pow(Energy,1.78)-pow(PISTA->E[i],1.78);
PID = pow(DeltaE+Eres,1.78)-pow(Eres,1.78);
ThetaNormalTarget = HitDirection.Angle(TVector3(0,0,1));
Elab = Be10C.EvaluateInitialEnergy(Energy,TargetThickness*0.5,ThetaNormalTarget);
OptimumEx = Transfer->ReconstructRelativistic(OriginalElab, OriginalThetaLab*deg);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment