]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Implement g3 behaviour for metal surface.
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 7 Feb 2005 11:21:08 +0000 (11:21 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 7 Feb 2005 11:21:08 +0000 (11:21 +0000)
TFluka/TFlukaCerenkov.cxx
TFluka/rflctv.cxx

index 5eb019b6a2c8c66d2a2e2aea5c6c22a4c76f93b1..8e7c15d1393d08e37d6fc66b1d7eaaff606789f7 100644 (file)
@@ -59,7 +59,7 @@ TFlukaCerenkov::TFlukaCerenkov(Int_t npckov, Float_t *ppckov, Float_t *absco, Fl
     fAbsorptionCoefficient = new Float_t[fSamples];
     fRefractionIndex       = new Float_t[fSamples];
     fQuantumEfficiency     = new Float_t[fSamples];
-    
+    fReflectivity          = new Float_t[fSamples];    
     
     for (Int_t i = 0; i < fSamples; i++) {
        fEnergy[i]             = ppckov[i];
@@ -77,6 +77,11 @@ TFlukaCerenkov::TFlukaCerenkov(Int_t npckov, Float_t *ppckov, Float_t *absco, Fl
        //
        // Flag is sensitive if quantum efficiency 0 < eff < 1 for at least one value.
        if (effic[i] < 1. && effic[i] > 0.) fIsSensitive = 1;
+       // G3 way to define metal
+       if (rindex[0] == 0.) {
+           fIsMetal = kTRUE;
+           fReflectivity[i] = absco[i];
+       }
     }
     // Find global  maximum quantum efficiency
     if (fMaximumEfficiency > GetGlobalMaximumEfficiency()) {
@@ -111,6 +116,8 @@ TFlukaCerenkov::TFlukaCerenkov(Int_t npckov, Float_t *ppckov, Float_t *absco, Fl
        //
        // Flag is sensitive if quantum efficiency 0 < eff < 1 for at least one value.
        if (effic[i] < 1. && effic[i] > 0.) fIsSensitive = 1;
+       //
+
     }
     // Find global  maximum quantum efficiency
     if (fMaximumEfficiency > GetGlobalMaximumEfficiency()) {
index a3aaa6acda727862dd90d423670e4defa6bac418..5d24f95ed280c7db03e976a374741f193e75ee71 100644 (file)
@@ -20,7 +20,8 @@ Double_t rflctv(Double_t& wvlngt, Double_t& /*omgpho*/, Int_t& mmat)
     TFluka* fluka =  (TFluka*) gMC;
     TGeoMaterial*    material =  (TGeoMaterial*) (fluka->GetFlukaMaterials())->At(fluka->GetMaterialIndex(mmat));
     TFlukaCerenkov*  cerenkov = dynamic_cast<TFlukaCerenkov*> (material->GetCerenkovProperties());
-    Double_t y =  (cerenkov->GetReflectivityByWaveLength(wvlngt));
+    Double_t y = 0.;
+    if (cerenkov->IsMetal()) y =  (cerenkov->GetReflectivityByWaveLength(wvlngt));
     return (y);
 }
 }