3 modified files
GeomConverter/src/org/lcsim/material
diff -u -r1.9 -r1.10
--- Material.java 1 Jul 2005 22:54:07 -0000 1.9
+++ Material.java 2 Jul 2005 00:28:34 -0000 1.10
@@ -59,7 +59,7 @@
private List<Double> _nAtomsPerVolume = new ArrayList<Double>();
/* electrons per element */
- double _totalElectronsPerVolume;
+ //double _totalElectronsPerVolume;
/* radiation length */
double _radiationLength;
@@ -467,10 +467,12 @@
return "Material=" + getName() + "; nComponents=" + _nComponents +
"; nElements=" + _nElements + "; temp=" + _temp + "\t\n" +
"pressure=" + _pressure + "; density=" + _density +
- "; state=" + _state.toString() + "\t\n" + "elecPerVol=" +
- _totalElectronsPerVolume + "; NIL=" + _nuclearInteractionLength +
- "; NILmat=" + getNuclearInteractionLengthForMaterial() +
- "; RL=" + _radiationLength;
+ "; state=" + _state.toString() + "\t\n" + "NIL=" +
+ _nuclearInteractionLength + "; RL=" + _radiationLength +
+ "; NILmat=" + getNuclearInteractionLengthForMaterial();
+
+ //+ "elecPerVol=" +
+ // _totalElectronsPerVolume
// +
// "; NILestimate: " + estimateNuclearInteractionLength() +
// "; RLestimate: " + estimateRadiationLength();
GeomConverter/src/org/lcsim/material
diff -u -r1.2 -r1.3
--- MaterialCalculator.java 1 Jul 2005 22:54:07 -0000 1.2
+++ MaterialCalculator.java 2 Jul 2005 00:28:34 -0000 1.3
@@ -16,15 +16,16 @@
abstract public class MaterialCalculator
{
/* Coulomb correction factors from G4Element via Phys Rev. D50 3-1 (1994) page 1254 */
- public static final double[] COULOMB_CORRECTIONS = { 0.0083, 0.20206, 0.0020, 0.0369 };
+ //public static final double[] COULOMB_CORRECTIONS = { 0.0083, 0.20206, 0.0020, 0.0369 };
- /* Fine structure constant from PDG July 2004, Table 1.1 */
+ /* Fine structure constant from PDG July 2004 */
public static final double FINE_STRUCTURE_CONSTANT = 1 / 137.03599911;
/* Tsai constants from G4Element::ComputeLradTsaiFactor() via Phys Rev. D50 3-1 (1994) page 1254 */
- public static final double[] TSAI_LRAD_LIGHT = { 5.31, 4.79, 4.74, 4.71 };
- public static final double[] TSAI_LPRAD_LIGHT = { 6.144, 5.621, 5.805, 5.924 };
+ //public static final double[] TSAI_LRAD_LIGHT = { 5.31, 4.79, 4.74, 4.71 };
+ //public static final double[] TSAI_LPRAD_LIGHT = { 6.144, 5.621, 5.805, 5.924 };
+ /*
public static double computeCoulombCorrection(double Z)
{
if ( Z <= 0 )
@@ -40,7 +41,9 @@
return coulomb;
}
+ */
+ /*
public static double computeTsaiFactor(double Z, double coulombCorrection)
{
double logZ3 = log(Z) / 3.0;
@@ -57,26 +60,104 @@
lrad = log(184.15) - logZ3;
lprad = log(1194.0) - 2 * logZ3;
}
+ */
/**
* FINE_STRUCTURE_CONSTANT is actually 'alpha_rcl2' in G4Element but this is same as F.S.C. in CLHEP.
*/
- double tsai = 4 * FINE_STRUCTURE_CONSTANT * Z * ( Z * (lrad * coulombCorrection) + lprad);
- return tsai;
- }
+// double tsai = 4 * FINE_STRUCTURE_CONSTANT * Z * ( Z * (lrad * coulombCorrection) + lprad);
+// return tsai;
+// }
- public static double computeTsaiFactor(double Z)
- {
- return computeTsaiFactor(Z, computeCoulombCorrection(Z) );
- }
+// public static double computeTsaiFactor(double Z)
+// {
+// return computeTsaiFactor(Z, computeCoulombCorrection(Z) );
+// }
- public static double computeNuclearInteractionLengthEstimate(double A)
- {
- return ( Material.LAMBDA0 * pow(A, 0.33333));
- }
+// public static double computeNuclearInteractionLengthEstimate(double A)
+// {
+// return ( Material.LAMBDA0 * pow(A, 0.33333));
+// }
public static double computeRadiationLengthEstimate(double A, double Z)
{
return (180.0 * A / ( Z * Z));
+ }
+
+ /**
+ * Compute radiation length using Tsai formula
+ *
+ * Based on LELAPS CEPack/ceelement::setIntLength()
+ *
+ */
+ public static double computeRadiationLengthTsai(double A, double Z)
+ {
+ double azsq = FINE_STRUCTURE_CONSTANT * Z;
+ azsq *= azsq;
+ double f = azsq * ( 1.0 / (1.0 + azsq) + 0.20206 - 0.0369 * azsq + 0.0083 * azsq * azsq
+ - 0.002 * azsq * azsq * azsq);
+
+ double Lrad, LradP;
+ if (Z==1)
+ {
+ Lrad = 5.31;
+ LradP = 6.144;
+ }
+ else if (Z==2)
+ {
+ Lrad = 4.79;
+ LradP = 5.621;
+ }
+ else if (Z==3)
+ {
+ Lrad = 4.74;
+ LradP = 5.805;
+ }
+ else if (Z==4)
+ {
+ Lrad = 4.71;
+ LradP = 5.924;
+ }
+ else
+ {
+ Lrad = log(184.15 / pow(Z, 0.333333333));
+ LradP = log(1194.0 / pow (Z, 0.666666667));
+ }
+ double rlen = 716.408 * A / ((Z * Z * (Lrad - f) + Z * LradP));
+ return rlen;
+ }
+
+ /**
+ * Compute NIL, using hard-coded values for Z <= 2 from PDG.
+ *
+ * Above helium, use a simple fit.
+ *
+ * Base on LELAPS CEPack/ceelement::setIntLength()
+ *
+ */
+ public static double computeNuclearInteractionLength(double A, double Z)
+ {
+ double NIL = 0;
+ if (Z==1)
+ {
+ if (A<1.5)
+ {
+ NIL = 50.8;
+ }
+ else
+ {
+ NIL = 54.7;
+ }
+ }
+ else if (Z==2)
+ {
+ NIL = 65.2;
+ }
+ else
+ {
+ NIL = 40.8 * pow(A, 0.289);
+ }
+
+ return NIL;
}
}
GeomConverter/src/org/lcsim/material
diff -u -r1.6 -r1.7
--- MaterialElement.java 1 Jul 2005 22:54:07 -0000 1.6
+++ MaterialElement.java 2 Jul 2005 00:28:34 -0000 1.7
@@ -11,23 +11,10 @@
private double _meltingPoint; // Melting point (K)
private double _boilingPoint; // Boiling point (K)
private double _ionizationPotential; // Ionization potential (eV)
- private double _coulombCorrection;
- private double _tsai;
+ //private double _coulombCorrection;
+ //private double _tsai;
private double _nuclearInteractionLength;
- private double _radiationLength;
-
- /*
- private static String[] ElementNotes = {
- "Density measured at 15 degrees C",
- "Density measured at 20 degrees C",
- "Density measured at 26 degrees C",
- "Melting point represents critical temperature",
- "Boiling point represents sublimation temperature",
- "Density is calculated",
- "Density is estimated",
- "Melting point is estimated",
- };
- */
+ private double _radiationLength;
MaterialElement(String name,
String fullName,
@@ -112,10 +99,10 @@
return _name;
}
- public double getTsaiFactor()
- {
- return _tsai;
- }
+// public double getTsaiFactor()
+// {
+// return _tsai;
+// }
public double getNuclearInteractionLength()
{
@@ -127,41 +114,43 @@
return _radiationLength;
}
- public void computeCoulombFactor()
- {
+// public void computeCoulombFactor()
+// {
/* calculate radiation length */
- _coulombCorrection = MaterialCalculator.computeCoulombCorrection(_Z);
- }
+// _coulombCorrection = MaterialCalculator.computeCoulombCorrection(_Z);
+// }
- public void computeTsaiFactor()
- {
+// public void computeTsaiFactor()
+// {
/* compute Tsai factor, using Z plus coulomb (so it doesn't need to be recomputed) */
- _tsai = MaterialCalculator.computeTsaiFactor(_Z, _coulombCorrection);
- }
+// _tsai = MaterialCalculator.computeTsaiFactor(_Z, _coulombCorrection);
+// }
public void computeDerivedQuantities()
{
- computeCoulombFactor();
- computeTsaiFactor();
+// computeCoulombFactor();
+// computeTsaiFactor();
computeNuclearInteractionLength();
computeRadiationLength();
}
void computeNuclearInteractionLength()
{
- _nuclearInteractionLength = MaterialCalculator.computeNuclearInteractionLengthEstimate( getZ() );
+ _nuclearInteractionLength = MaterialCalculator.computeNuclearInteractionLength( getA(), getZ() );
}
void computeRadiationLength()
{
- _radiationLength = MaterialCalculator.computeRadiationLengthEstimate( getA(), getZ() );
+ //_radiationLength = MaterialCalculator.computeRadiationLengthEstimate( getA(), getZ() );
+ _radiationLength = MaterialCalculator.computeRadiationLengthTsai( getA(), getZ() );
}
public String toString()
{
return "Element=" + name() + "; Z=" + _Z + "; A=" + _A + "; N=" + _N + "; density=" + _density + "\n" +
"MP=" + _meltingPoint + "; BP=" + _boilingPoint + "; IonPoten=" + _ionizationPotential + "\n" +
- "NILest=" + _nuclearInteractionLength + "; RLest=" + _radiationLength + "; coulomb=" + _coulombCorrection
- + "; tsai=" + _tsai;
+ "NIL=" + _nuclearInteractionLength + "; RL=" + _radiationLength;
+// + "; tsai=" + _tsai;
+// + "; coulomb=" + _coulombCorrection
}
}
\ No newline at end of file
CVSspam 0.2.8