5 added + 4 removed + 1 modified, total 10 files
GeomConverter
diff -u -r1.2 -r1.3
--- build.sh 5 Jun 2006 20:54:28 -0000 1.2
+++ build.sh 6 Oct 2006 19:11:27 -0000 1.3
@@ -13,3 +13,4 @@
maven -Drun.install=${install_dir} \
-Dmaven.test.skip=true clean \
eclipse jar:install run:install
+maven
GeomConverter/src/org/lcsim/geometry/compact/converter/lcdd
diff -N SiTrackerBarrel.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ SiTrackerBarrel.java 6 Oct 2006 19:11:28 -0000 1.1
@@ -0,0 +1,463 @@
+package org.lcsim.geometry.compact.converter.lcdd;
+
+import static java.lang.Math.cos;
+import static java.lang.Math.sin;
+
+import java.util.Iterator;
+import java.util.Map;
+import java.util.HashMap;
+
+import org.jdom.Element;
+import org.jdom.JDOMException;
+import org.lcsim.geometry.compact.converter.lcdd.util.Box;
+import org.lcsim.geometry.compact.converter.lcdd.util.LCDD;
+import org.lcsim.geometry.compact.converter.lcdd.util.Material;
+import org.lcsim.geometry.compact.converter.lcdd.util.PhysVol;
+import org.lcsim.geometry.compact.converter.lcdd.util.Position;
+import org.lcsim.geometry.compact.converter.lcdd.util.Rotation;
+import org.lcsim.geometry.compact.converter.lcdd.util.SensitiveDetector;
+import org.lcsim.geometry.compact.converter.lcdd.util.Solids;
+import org.lcsim.geometry.compact.converter.lcdd.util.Structure;
+import org.lcsim.geometry.compact.converter.lcdd.util.Tube;
+import org.lcsim.geometry.compact.converter.lcdd.util.Volume;
+
+/**
+ *
+ * Convert an SiTrackerBarrel subdetector to the LCDD format.
+ *
+ * @author Jeremy McCormick <[log in to unmask]>
+ * @author Tim Nelson <[log in to unmask]>
+ *
+ */
+public class SiTrackerBarrel extends LCDDSubdetector
+{
+ Map<String,Volume> modules = new HashMap<String,Volume>();
+
+ public SiTrackerBarrel(Element node) throws JDOMException
+ {
+ super(node);
+ }
+
+ /**
+ * Build the LCDD for the subdetector.
+ * @param lcdd The LCDD file being created.
+ * @param sens The SD for this subdetector.
+ */
+ public void addToLCDD(LCDD lcdd, SensitiveDetector sens) throws JDOMException
+ {
+ // ID of the detector.
+ int id = this.node.getAttribute("id").getIntValue();
+
+ // Name of the detector.
+ String detector_name = this.node.getAttributeValue("name");
+
+ // Get air from LCDD materials DB.
+ Material air = lcdd.getMaterial("Air");
+
+ // Get solids collection from LCDD.
+ Solids solids = lcdd.getSolids();
+
+ // Get structure collection from LCDD.
+ Structure structure = lcdd.getStructure();
+
+ // Pick the mother volume (tracking volume).
+ Volume tracking_logvol = lcdd.pickMotherVolume(this);
+
+ // Loop over the modules and put them into a map for lookup later.
+ for (Iterator i = node.getChildren("module").iterator(); i.hasNext(); )
+ {
+ Element module = (Element) i.next();
+ String module_name = module.getAttributeValue("name");
+ Volume module_envelope;
+ try {
+ module_envelope = buildModule(node, module_name, lcdd, sens);
+ modules.put(module_name, module_envelope);
+ }
+ catch (Exception x)
+ {
+ throw new RuntimeException(x);
+ }
+ }
+
+ // Build the layers.
+ int nlayer = 0;
+ for (Iterator i = node.getChildren("layer").iterator(); i.hasNext(); nlayer++)
+ {
+ // Get the next layer element.
+ Element layer = (Element) i.next();
+
+ // Get the reference to the module from the layer.
+ String module_name = layer.getAttributeValue("module");
+
+ // Get the logical volume for the module.
+ Volume module_envelope = modules.get(module_name);
+
+ // Get the barrel_envelope for this layer.
+ Element barrel_envelope = layer.getChild("barrel_envelope");
+
+ // Inner radius of layer.
+ double ir = barrel_envelope.getAttribute("inner_r").getDoubleValue();
+
+ // Outer radius of layer.
+ double or = barrel_envelope.getAttribute("outer_r").getDoubleValue();
+
+ // Full length in z of layer.
+ double oz = barrel_envelope.getAttribute("z_length").getDoubleValue();
+
+ // Name of this layer including layer number.
+ String layer_name = detector_name + "_layer" + nlayer;
+
+ //System.out.println("layer_name=" + layer_name);
+
+ // Create the layer tube solid.
+ Tube layer_tube = new Tube(layer_name + "_tube");
+ layer_tube.setRMin(ir);
+ layer_tube.setRMax(or);
+ layer_tube.setZ(oz);
+ solids.addContent(layer_tube);
+
+ // Create the layer envelope volume.
+ Volume layer_envelope_logvol = new Volume(layer_name);
+ layer_envelope_logvol.setMaterial(air);
+ layer_envelope_logvol.setSolid(layer_tube);
+
+ // Get the rphi_layout element.
+ Element rphi_layout = layer.getChild("rphi_layout");
+
+ // Starting phi of first module.
+ double phi0 = rphi_layout.getAttribute("phi0").getDoubleValue();
+
+ // Number of modules in phi.
+ int nphi = rphi_layout.getAttribute("nphi").getIntValue();
+ assert (nphi > 0);
+
+ // Phi tilt of a module.
+ double phi_tilt = rphi_layout.getAttribute("phi_tilt").getDoubleValue();
+
+ // Radius of the module center.
+ double rc = rphi_layout.getAttribute("rc").getDoubleValue();
+
+ // The delta radius of every other module.
+ double rphi_dr = 0.0;
+ if (rphi_layout.getAttribute("dr") != null)
+ {
+ rphi_dr = rphi_layout.getAttribute("dr").getDoubleValue();
+ }
+
+ // Phi increment for one module.
+ double phi_incr = (Math.PI * 2) / nphi;
+
+ // Phi of the module center.
+ double phic = 0;
+ phic += phi0;
+
+ // Get the <z_layout> element.
+ Element z_layout = layer.getChild("z_layout");
+
+ // Z position of first module in phi.
+ double z0 = z_layout.getAttribute("z0").getDoubleValue();
+
+ // Number of modules to place in z.
+ double nz = z_layout.getAttribute("nz").getIntValue();
+ assert (nz > 0);
+
+ // Radial displacement parameter, of every other module.
+ double z_dr = z_layout.getAttribute("dr").getDoubleValue();
+
+ // Z increment for module placement along Z axis.
+ // Adjust for z0 at center of module rather than
+ // the end of cylindrical envelope.
+ double z_incr = (2.0 * z0) / (nz - 1);
+
+ // Starting z for module placement along Z axis.
+ double module_z = -z0;
+
+ // DEBUG
+ //System.out.println("layer ir=" + ir);
+ //System.out.println("layer or=" + or);
+ //System.out.println("layer oz=" + oz);
+ //System.out.println("phi_tilt=" + phi_tilt);
+ //System.out.println("rc=" + rc);
+ //System.out.println("phi0=" + phi0);
+ //System.out.println("module z_incr=" + z_incr);
+ //System.out.println("module z0=" + z0);
+ //System.out.println("module nz=" + nz);
+ //System.out.println("module dr=" + dr);
+ //
+
+ //String module_lkp_name = layer.getAttributeValue("module");
+
+ // Loop over the number of modules in phi.
+ for (int ii = 0; ii < nphi; ii++)
+ {
+ // Delta x of module position.
+ double dx = z_dr * cos(phic + phi_tilt);
+
+ // Delta y of module position.
+ double dy = z_dr * sin(phic + phi_tilt);
+
+ // Basic x module position.
+ double x = rc * cos(phic);
+
+ // Basic y module position.
+ double y = rc * sin(phic);
+
+ // Loop over the number of modules in z.
+ for (int j = 0; j < nz; j++)
+ {
+ // Create a unique name for the module in this logical volume, layer, phi, and z.
+ String module_place_name =
+ detector_name + "_layer" + nlayer + "_phi" + ii + "_z" + j;
+
+ double z = module_z;
+
+ // DEBUG
+ //System.out.println("module build...");
+ //System.out.println("module nphi=" + ii);
+ //System.out.println("module nz" + j);
+ //System.out.println("module x=" + x);
+ //System.out.println("module y=" + y);
+ //System.out.println("module z=" + z);
+ // DEBUG
+
+ // Position of module.
+ Position module_position = new Position(module_place_name + "_position");
+ module_position.setX(x);
+ module_position.setY(y);
+ module_position.setZ(z);
+ lcdd.getDefine().addPosition(module_position);
+
+ // Rotation of module.
+ Rotation module_rotation = new Rotation(module_place_name + "_rotation");
+ double rotx = Math.PI / 2;
+ double roty = -((Math.PI / 2) - phic - phi_tilt);
+ double rotz = 0;
+ module_rotation.setX(rotx);
+ module_rotation.setY(roty);
+ module_rotation.setZ(rotz);
+ lcdd.getDefine().addRotation(module_rotation);
+
+ //System.out.println("module rotx=" + rotx);
+ ////System.out.println("module roty=" + roty);
+ //System.out.println("module rotz=" + rotz);
+
+ // Module PhysicalVolume.
+ PhysVol module_physvol = new PhysVol(module_envelope);
+ module_physvol.setPosition(module_position);
+ module_physvol.setRotation(module_rotation);
+ module_physvol.addPhysVolID("phi", ii);
+ module_physvol.addPhysVolID("z", j);
+ layer_envelope_logvol.addPhysVol(module_physvol);
+
+ // Adjust the x and y coordinates of the module.
+ x += dx;
+ y += dy;
+
+ // Flip sign of x and y adjustments.
+ dx *= -1;
+ dy *= -1;
+
+ // Add z increment to get next z placement pos.
+ module_z += z_incr;
+
+ //System.out.println();
+ }
+
+ // Increment the phi placement of module.
+ phic += phi_incr;
+
+ // Increment the center radius according to dr parameter.
+ rc += rphi_dr;
+
+ // Flip sign of dr parameter.
+ rphi_dr *= -1;
+
+ // Reset the Z placement parameter for module.
+ module_z = -z0;
+ }
+
+ // Set the layer envelope to invisible to help Geant4 visualization.
+ if (lcdd.getVisAttributes("InvisibleWithDaughters") != null)
+ {
+ layer_envelope_logvol.setVisAttributes(lcdd.getVisAttributes("InvisibleWithDaughters"));
+ }
+
+ // Add the layer volume to LCDD.
+ structure.addVolume(layer_envelope_logvol);
+
+ // Create the PhysicalVolume for the layer.
+ PhysVol layer_envelope_physvol = new PhysVol(layer_envelope_logvol);
+
+ // Set the subdetector system ID.
+ layer_envelope_physvol.addPhysVolID("system", id);
+
+ // Flag this as a barrel subdetector.
+ layer_envelope_physvol.addPhysVolID("barrel",0);
+
+ // Set the layer ID.
+ layer_envelope_physvol.addPhysVolID("layer", nlayer);
+
+ // Put the layer into the mother volume.
+ tracking_logvol.addPhysVol(layer_envelope_physvol);
+ }
+ }
+
+ /**
+ * Build a module logical volume.
+ * @param detector The detector XML node.
+ * @param name The name of the module for lookup.
+ * @param lcdd The LCDD being processed.
+ * @return
+ * @throws Exception
+ */
+ Volume buildModule(Element detector, String name, LCDD lcdd, SensitiveDetector sens) throws Exception
+ {
+ String detector_name = detector.getAttributeValue("name");
+ Volume module_logvol = null;
+
+ int sensor_number=0;
+
+ for (Iterator i = detector.getChildren("module").iterator(); i.hasNext();)
+ {
+ Element module = (Element) i.next();
+
+ if (module.getAttributeValue("name").compareTo(name) == 0)
+ {
+ Element module_envelope = module.getChild("module_envelope");
+
+ String module_name = detector_name + "_" + module.getAttributeValue("name");
+
+ // Create the module box.
+ double module_length = module_envelope.getAttribute("length").getDoubleValue();
+ double module_width = module_envelope.getAttribute("width").getDoubleValue();
+ double module_thickness = module_envelope.getAttribute("thickness").getDoubleValue();
+ Box module_box = new Box(module_name + "_box");
+ module_box.setX(module_width);
+ module_box.setY(module_length);
+ module_box.setZ(module_thickness);
+ lcdd.getSolids().addSolid(module_box);
+
+ // Create the module logical volume.
+ module_logvol = new Volume(module_name);
+ module_logvol.setMaterial(lcdd.getMaterial("Air"));
+ module_logvol.setSolid(module_box);
+
+ // Build module components.
+ int ncomponents = 0;
+ for (Iterator j = module.getChildren("module_component").iterator(); j.hasNext(); ++ncomponents)
+ {
+ Element component = (Element) j.next();
+
+ boolean sensitive = ( (component.getAttribute("sensitive") == null) ? false : component.getAttribute("sensitive").getBooleanValue());
+
+ String component_name = module_name + "_component" + ncomponents;
+
+ // DEBUG
+ //System.out.println("component_name=" + component_name);
+ //System.out.println("build component="+ncomponents);
+ //
+
+ // Create the box solid for the module component.
+ double component_length = component.getAttribute("length").getDoubleValue();
+ double component_width = component.getAttribute("width").getDoubleValue();
+ double component_thickness = component.getAttribute("thickness").getDoubleValue();
+ Box component_box = new Box(component_name + "_box");
+ component_box.setX(component_width);
+ component_box.setY(component_length);
+ component_box.setZ(component_thickness);
+ lcdd.getSolids().addSolid(component_box);
+
+ // Create the volume for the module component.
+ Volume component_logvol = new Volume(component_name);
+ Material component_material = lcdd.getMaterial(component.getAttributeValue("material"));
+ component_logvol.setMaterial(component_material);
+ component_logvol.setSolid(component_box);
+ lcdd.getStructure().addVolume(component_logvol);
+
+ PhysVol component_physvol = new PhysVol(component_logvol);
+
+ // Set component position.
+ // FIXME: Processing of positions should be generalized in compact description.
+ if (component.getChild("position") != null)
+ {
+ Element pos_elem = component.getChild("position");
+
+ Position component_position = new Position(component_name + "_position");
+
+ if (pos_elem.getAttribute("x") != null)
+ {
+ component_position.setX(pos_elem.getAttribute("x").getDoubleValue());
+ }
+
+ if (pos_elem.getAttribute("y") != null)
+ {
+ component_position.setY(pos_elem.getAttribute("y").getDoubleValue());
+ }
+
+ if (pos_elem.getAttribute("z") != null)
+ {
+ component_position.setZ(pos_elem.getAttribute("z").getDoubleValue());
+ }
+
+ lcdd.getDefine().addPosition(component_position);
+ component_physvol.setPosition(component_position);
+ }
+
+ // Set component rotation.
+ // FIXME: Processing of rotations should be generalized in compact description.
+ if (component.getChild("rotation") != null)
+ {
+ Element rot_elem = component.getChild("rotation");
+
+ Rotation component_rotation = new Rotation(component_name + "_rotation");
+
+ if (rot_elem.getAttribute("x") != null)
+ {
+ component_rotation.setX(rot_elem.getAttribute("x").getDoubleValue());
+ }
+
+ if (rot_elem.getAttribute("y") != null)
+ {
+ component_rotation.setY(rot_elem.getAttribute("y").getDoubleValue());
+ }
+
+ if (rot_elem.getAttribute("z") != null)
+ {
+ component_rotation.setZ(rot_elem.getAttribute("z").getDoubleValue());
+ }
+
+ component_physvol.setRotation(component_rotation);
+
+ lcdd.getDefine().addRotation(component_rotation);
+ }
+
+ if (sensitive)
+ {
+ component_logvol.setSensitiveDetector(sens);
+ component_physvol.addPhysVolID("sensor",sensor_number);
+ ++sensor_number;
+ }
+
+ module_logvol.addPhysVol(component_physvol);
+ }
+
+ break;
+ }
+ }
+
+ if (module_logvol == null)
+ {
+ throw new RuntimeException("Failed to find module " + name);
+ }
+
+ // Add module logical volume to LCDD.
+ lcdd.getStructure().addVolume(module_logvol);
+
+ return module_logvol;
+ }
+
+ public boolean isTracker()
+ {
+ return true;
+ }
+}
\ No newline at end of file
GeomConverter/src/org/lcsim/geometry/compact/converter/lcdd
diff -N SiStripTrackerBarrel.java
--- SiStripTrackerBarrel.java 3 Oct 2006 21:34:47 -0000 1.7
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,463 +0,0 @@
-package org.lcsim.geometry.compact.converter.lcdd;
-
-import static java.lang.Math.cos;
-import static java.lang.Math.sin;
-
-import java.util.Iterator;
-import java.util.Map;
-import java.util.HashMap;
-
-import org.jdom.Element;
-import org.jdom.JDOMException;
-import org.lcsim.geometry.compact.converter.lcdd.util.Box;
-import org.lcsim.geometry.compact.converter.lcdd.util.LCDD;
-import org.lcsim.geometry.compact.converter.lcdd.util.Material;
-import org.lcsim.geometry.compact.converter.lcdd.util.PhysVol;
-import org.lcsim.geometry.compact.converter.lcdd.util.Position;
-import org.lcsim.geometry.compact.converter.lcdd.util.Rotation;
-import org.lcsim.geometry.compact.converter.lcdd.util.SensitiveDetector;
-import org.lcsim.geometry.compact.converter.lcdd.util.Solids;
-import org.lcsim.geometry.compact.converter.lcdd.util.Structure;
-import org.lcsim.geometry.compact.converter.lcdd.util.Tube;
-import org.lcsim.geometry.compact.converter.lcdd.util.Volume;
-
-/**
- *
- * Convert an SiStripTrackerBarrel subdetector to the LCDD format.
- *
- * @author Jeremy McCormick <[log in to unmask]>
- * @author Tim Nelson <[log in to unmask]>
- *
- */
-public class SiStripTrackerBarrel extends LCDDSubdetector
-{
- Map<String,Volume> modules = new HashMap<String,Volume>();
-
- public SiStripTrackerBarrel(Element node) throws JDOMException
- {
- super(node);
- }
-
- /**
- * Build the LCDD for the subdetector.
- * @param lcdd The LCDD file being created.
- * @param sens The SD for this subdetector.
- */
- public void addToLCDD(LCDD lcdd, SensitiveDetector sens) throws JDOMException
- {
- // ID of the detector.
- int id = this.node.getAttribute("id").getIntValue();
-
- // Name of the detector.
- String detector_name = this.node.getAttributeValue("name");
-
- // Get air from LCDD materials DB.
- Material air = lcdd.getMaterial("Air");
-
- // Get solids collection from LCDD.
- Solids solids = lcdd.getSolids();
-
- // Get structure collection from LCDD.
- Structure structure = lcdd.getStructure();
-
- // Pick the mother volume (tracking volume).
- Volume tracking_logvol = lcdd.pickMotherVolume(this);
-
- // Loop over the modules and put them into a map for lookup later.
- for (Iterator i = node.getChildren("module").iterator(); i.hasNext(); )
- {
- Element module = (Element) i.next();
- String module_name = module.getAttributeValue("name");
- Volume module_envelope;
- try {
- module_envelope = buildModule(node, module_name, lcdd, sens);
- modules.put(module_name, module_envelope);
- }
- catch (Exception x)
- {
- throw new RuntimeException(x);
- }
- }
-
- // Build the layers.
- int nlayer = 0;
- for (Iterator i = node.getChildren("layer").iterator(); i.hasNext(); nlayer++)
- {
- // Get the next layer element.
- Element layer = (Element) i.next();
-
- // Get the reference to the module from the layer.
- String module_name = layer.getAttributeValue("module");
-
- // Get the logical volume for the module.
- Volume module_envelope = modules.get(module_name);
-
- // Get the barrel_envelope for this layer.
- Element barrel_envelope = layer.getChild("barrel_envelope");
-
- // Inner radius of layer.
- double ir = barrel_envelope.getAttribute("inner_r").getDoubleValue();
-
- // Outer radius of layer.
- double or = barrel_envelope.getAttribute("outer_r").getDoubleValue();
-
- // Full length in z of layer.
- double oz = barrel_envelope.getAttribute("z_length").getDoubleValue();
-
- // Name of this layer including layer number.
- String layer_name = detector_name + "_layer" + nlayer;
-
- //System.out.println("layer_name=" + layer_name);
-
- // Create the layer tube solid.
- Tube layer_tube = new Tube(layer_name + "_tube");
- layer_tube.setRMin(ir);
- layer_tube.setRMax(or);
- layer_tube.setZ(oz);
- solids.addContent(layer_tube);
-
- // Create the layer envelope volume.
- Volume layer_envelope_logvol = new Volume(layer_name);
- layer_envelope_logvol.setMaterial(air);
- layer_envelope_logvol.setSolid(layer_tube);
-
- // Get the rphi_layout element.
- Element rphi_layout = layer.getChild("rphi_layout");
-
- // Starting phi of first module.
- double phi0 = rphi_layout.getAttribute("phi0").getDoubleValue();
-
- // Number of modules in phi.
- int nphi = rphi_layout.getAttribute("nphi").getIntValue();
- assert (nphi > 0);
-
- // Phi tilt of a module.
- double phi_tilt = rphi_layout.getAttribute("phi_tilt").getDoubleValue();
-
- // Radius of the module center.
- double rc = rphi_layout.getAttribute("rc").getDoubleValue();
-
- // The delta radius of every other module.
- double rphi_dr = 0.0;
- if (rphi_layout.getAttribute("dr") != null)
- {
- rphi_dr = rphi_layout.getAttribute("dr").getDoubleValue();
- }
-
- // Phi increment for one module.
- double phi_incr = (Math.PI * 2) / nphi;
-
- // Phi of the module center.
- double phic = 0;
- phic += phi0;
-
- // Get the <z_layout> element.
- Element z_layout = layer.getChild("z_layout");
-
- // Z position of first module in phi.
- double z0 = z_layout.getAttribute("z0").getDoubleValue();
-
- // Number of modules to place in z.
- double nz = z_layout.getAttribute("nz").getIntValue();
- assert (nz > 0);
-
- // Radial displacement parameter, of every other module.
- double z_dr = z_layout.getAttribute("dr").getDoubleValue();
-
- // Z increment for module placement along Z axis.
- // Adjust for z0 at center of module rather than
- // the end of cylindrical envelope.
- double z_incr = (2.0 * z0) / (nz - 1);
-
- // Starting z for module placement along Z axis.
- double module_z = -z0;
-
- // DEBUG
- //System.out.println("layer ir=" + ir);
- //System.out.println("layer or=" + or);
- //System.out.println("layer oz=" + oz);
- //System.out.println("phi_tilt=" + phi_tilt);
- //System.out.println("rc=" + rc);
- //System.out.println("phi0=" + phi0);
- //System.out.println("module z_incr=" + z_incr);
- //System.out.println("module z0=" + z0);
- //System.out.println("module nz=" + nz);
- //System.out.println("module dr=" + dr);
- //
-
- //String module_lkp_name = layer.getAttributeValue("module");
-
- // Loop over the number of modules in phi.
- for (int ii = 0; ii < nphi; ii++)
- {
- // Delta x of module position.
- double dx = z_dr * cos(phic + phi_tilt);
-
- // Delta y of module position.
- double dy = z_dr * sin(phic + phi_tilt);
-
- // Basic x module position.
- double x = rc * cos(phic);
-
- // Basic y module position.
- double y = rc * sin(phic);
-
- // Loop over the number of modules in z.
- for (int j = 0; j < nz; j++)
- {
- // Create a unique name for the module in this logical volume, layer, phi, and z.
- String module_place_name =
- detector_name + "_layer" + nlayer + "_phi" + ii + "_z" + j;
-
- double z = module_z;
-
- // DEBUG
- //System.out.println("module build...");
- //System.out.println("module nphi=" + ii);
- //System.out.println("module nz" + j);
- //System.out.println("module x=" + x);
- //System.out.println("module y=" + y);
- //System.out.println("module z=" + z);
- // DEBUG
-
- // Position of module.
- Position module_position = new Position(module_place_name + "_position");
- module_position.setX(x);
- module_position.setY(y);
- module_position.setZ(z);
- lcdd.getDefine().addPosition(module_position);
-
- // Rotation of module.
- Rotation module_rotation = new Rotation(module_place_name + "_rotation");
- double rotx = Math.PI / 2;
- double roty = -((Math.PI / 2) - phic - phi_tilt);
- double rotz = 0;
- module_rotation.setX(rotx);
- module_rotation.setY(roty);
- module_rotation.setZ(rotz);
- lcdd.getDefine().addRotation(module_rotation);
-
- //System.out.println("module rotx=" + rotx);
- ////System.out.println("module roty=" + roty);
- //System.out.println("module rotz=" + rotz);
-
- // Module PhysicalVolume.
- PhysVol module_physvol = new PhysVol(module_envelope);
- module_physvol.setPosition(module_position);
- module_physvol.setRotation(module_rotation);
- module_physvol.addPhysVolID("phi", ii);
- module_physvol.addPhysVolID("z", j);
- layer_envelope_logvol.addPhysVol(module_physvol);
-
- // Adjust the x and y coordinates of the module.
- x += dx;
- y += dy;
-
- // Flip sign of x and y adjustments.
- dx *= -1;
- dy *= -1;
-
- // Add z increment to get next z placement pos.
- module_z += z_incr;
-
- //System.out.println();
- }
-
- // Increment the phi placement of module.
- phic += phi_incr;
-
- // Increment the center radius according to dr parameter.
- rc += rphi_dr;
-
- // Flip sign of dr parameter.
- rphi_dr *= -1;
-
- // Reset the Z placement parameter for module.
- module_z = -z0;
- }
-
- // Set the layer envelope to invisible to help Geant4 visualization.
- if (lcdd.getVisAttributes("InvisibleWithDaughters") != null)
- {
- layer_envelope_logvol.setVisAttributes(lcdd.getVisAttributes("InvisibleWithDaughters"));
- }
-
- // Add the layer volume to LCDD.
- structure.addVolume(layer_envelope_logvol);
-
- // Create the PhysicalVolume for the layer.
- PhysVol layer_envelope_physvol = new PhysVol(layer_envelope_logvol);
-
- // Set the subdetector system ID.
- layer_envelope_physvol.addPhysVolID("system", id);
-
- // Flag this as a barrel subdetector.
- layer_envelope_physvol.addPhysVolID("barrel",0);
-
- // Set the layer ID.
- layer_envelope_physvol.addPhysVolID("layer", nlayer);
-
- // Put the layer into the mother volume.
- tracking_logvol.addPhysVol(layer_envelope_physvol);
- }
- }
-
- /**
- * Build a module logical volume.
- * @param detector The detector XML node.
- * @param name The name of the module for lookup.
- * @param lcdd The LCDD being processed.
- * @return
- * @throws Exception
- */
- Volume buildModule(Element detector, String name, LCDD lcdd, SensitiveDetector sens) throws Exception
- {
- String detector_name = detector.getAttributeValue("name");
- Volume module_logvol = null;
-
- int sensor_number=0;
-
- for (Iterator i = detector.getChildren("module").iterator(); i.hasNext();)
- {
- Element module = (Element) i.next();
-
- if (module.getAttributeValue("name").compareTo(name) == 0)
- {
- Element module_envelope = module.getChild("module_envelope");
-
- String module_name = detector_name + "_" + module.getAttributeValue("name");
-
- // Create the module box.
- double module_length = module_envelope.getAttribute("length").getDoubleValue();
- double module_width = module_envelope.getAttribute("width").getDoubleValue();
- double module_thickness = module_envelope.getAttribute("thickness").getDoubleValue();
- Box module_box = new Box(module_name + "_box");
- module_box.setX(module_width);
- module_box.setY(module_length);
- module_box.setZ(module_thickness);
- lcdd.getSolids().addSolid(module_box);
-
- // Create the module logical volume.
- module_logvol = new Volume(module_name);
- module_logvol.setMaterial(lcdd.getMaterial("Air"));
- module_logvol.setSolid(module_box);
-
- // Build module components.
- int ncomponents = 0;
- for (Iterator j = module.getChildren("module_component").iterator(); j.hasNext(); ++ncomponents)
- {
- Element component = (Element) j.next();
-
- boolean sensitive = ( (component.getAttribute("sensitive") == null) ? false : component.getAttribute("sensitive").getBooleanValue());
-
- String component_name = module_name + "_component" + ncomponents;
-
- // DEBUG
- //System.out.println("component_name=" + component_name);
- //System.out.println("build component="+ncomponents);
- //
-
- // Create the box solid for the module component.
- double component_length = component.getAttribute("length").getDoubleValue();
- double component_width = component.getAttribute("width").getDoubleValue();
- double component_thickness = component.getAttribute("thickness").getDoubleValue();
- Box component_box = new Box(component_name + "_box");
- component_box.setX(component_width);
- component_box.setY(component_length);
- component_box.setZ(component_thickness);
- lcdd.getSolids().addSolid(component_box);
-
- // Create the volume for the module component.
- Volume component_logvol = new Volume(component_name);
- Material component_material = lcdd.getMaterial(component.getAttributeValue("material"));
- component_logvol.setMaterial(component_material);
- component_logvol.setSolid(component_box);
- lcdd.getStructure().addVolume(component_logvol);
-
- PhysVol component_physvol = new PhysVol(component_logvol);
-
- // Set component position.
- // FIXME: Processing of positions should be generalized in compact description.
- if (component.getChild("position") != null)
- {
- Element pos_elem = component.getChild("position");
-
- Position component_position = new Position(component_name + "_position");
-
- if (pos_elem.getAttribute("x") != null)
- {
- component_position.setX(pos_elem.getAttribute("x").getDoubleValue());
- }
-
- if (pos_elem.getAttribute("y") != null)
- {
- component_position.setY(pos_elem.getAttribute("y").getDoubleValue());
- }
-
- if (pos_elem.getAttribute("z") != null)
- {
- component_position.setZ(pos_elem.getAttribute("z").getDoubleValue());
- }
-
- lcdd.getDefine().addPosition(component_position);
- component_physvol.setPosition(component_position);
- }
-
- // Set component rotation.
- // FIXME: Processing of rotations should be generalized in compact description.
- if (component.getChild("rotation") != null)
- {
- Element rot_elem = component.getChild("rotation");
-
- Rotation component_rotation = new Rotation(component_name + "_rotation");
-
- if (rot_elem.getAttribute("x") != null)
- {
- component_rotation.setX(rot_elem.getAttribute("x").getDoubleValue());
- }
-
- if (rot_elem.getAttribute("y") != null)
- {
- component_rotation.setY(rot_elem.getAttribute("y").getDoubleValue());
- }
-
- if (rot_elem.getAttribute("z") != null)
- {
- component_rotation.setZ(rot_elem.getAttribute("z").getDoubleValue());
- }
-
- component_physvol.setRotation(component_rotation);
-
- lcdd.getDefine().addRotation(component_rotation);
- }
-
- if (sensitive)
- {
- component_logvol.setSensitiveDetector(sens);
- component_physvol.addPhysVolID("sensor",sensor_number);
- ++sensor_number;
- }
-
- module_logvol.addPhysVol(component_physvol);
- }
-
- break;
- }
- }
-
- if (module_logvol == null)
- {
- throw new RuntimeException("Failed to find module " + name);
- }
-
- // Add module logical volume to LCDD.
- lcdd.getStructure().addVolume(module_logvol);
-
- return module_logvol;
- }
-
- public boolean isTracker()
- {
- return true;
- }
-}
\ No newline at end of file
GeomConverter/src/org/lcsim/geometry/subdetector
diff -N SiTrackerBarrel.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ SiTrackerBarrel.java 6 Oct 2006 19:11:29 -0000 1.1
@@ -0,0 +1,36 @@
+package org.lcsim.geometry.subdetector;
+
+import hep.graphics.heprep.HepRep;
+import hep.graphics.heprep.HepRepFactory;
+
+import org.jdom.DataConversionException;
+import org.jdom.Element;
+import org.jdom.JDOMException;
+
+/**
+ *
+ * @author Jeremy McCormick <[log in to unmask]>
+ * @author Tim Nelson <[log in to unmask]>
+ *
+ */
+public class SiTrackerBarrel extends AbstractTracker
+{
+ SiTrackerBarrel(Element node) throws JDOMException
+ {
+ super(node);
+ build(node);
+ }
+
+ private void build(Element node) throws DataConversionException
+ {
+ System.out.println("SiTrackerBarrel.build");
+ }
+
+ public void appendHepRep(HepRepFactory factory, HepRep heprep)
+ {}
+
+ public boolean isBarrel()
+ {
+ return true;
+ }
+}
\ No newline at end of file
GeomConverter/src/org/lcsim/geometry/subdetector
diff -N SiStripTrackerBarrel.java
--- SiStripTrackerBarrel.java 29 Sep 2006 01:00:09 -0000 1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,35 +0,0 @@
-package org.lcsim.geometry.subdetector;
-
-import hep.graphics.heprep.HepRep;
-import hep.graphics.heprep.HepRepFactory;
-
-import org.jdom.DataConversionException;
-import org.jdom.Element;
-import org.jdom.JDOMException;
-
-/**
- *
- * @author tonyj
- *
- */
-public class SiStripTrackerBarrel extends AbstractTracker
-{
- SiStripTrackerBarrel(Element node) throws JDOMException
- {
- super(node);
- build(node);
- }
-
- private void build(Element node) throws DataConversionException
- {
- System.out.println("SiStripTrackerBarrel.build");
- }
-
- public void appendHepRep(HepRepFactory factory, HepRep heprep)
- {}
-
- public boolean isBarrel()
- {
- return true;
- }
-}
\ No newline at end of file
GeomConverter/test/org/lcsim/geometry/compact/converter/lcdd
diff -N SiTrackerBarrelTest.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ SiTrackerBarrelTest.java 6 Oct 2006 19:11:29 -0000 1.1
@@ -0,0 +1,33 @@
+package org.lcsim.geometry.compact.converter.lcdd;
+
+import java.io.BufferedOutputStream;
+import java.io.FileOutputStream;
+import java.io.InputStream;
+import java.io.OutputStream;
+
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+/**
+ *
+ * @author jeremym
+ */
+public class SiTrackerBarrelTest extends TestCase
+{
+ public SiTrackerBarrelTest(String name)
+ {
+ super(name);
+ }
+
+ public static TestSuite suite()
+ {
+ return new TestSuite(SiTrackerBarrelTest.class);
+ }
+
+ public void test_converter() throws Exception
+ {
+ InputStream in = SiTrackerBarrel.class.getResourceAsStream("/org/lcsim/geometry/subdetector/SiTrackerBarrelTest.xml");
+ OutputStream out = new BufferedOutputStream(new FileOutputStream("SiTrackerBarrelTest.lcdd"));
+ new Main(true).convert("SiTrackerBarrelTest",in,out);
+ }
+}
GeomConverter/test/org/lcsim/geometry/compact/converter/lcdd
diff -N SiStripTrackerBarrelTest.java
--- SiStripTrackerBarrelTest.java 29 Sep 2006 01:00:09 -0000 1.1
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,33 +0,0 @@
-package org.lcsim.geometry.compact.converter.lcdd;
-
-import java.io.BufferedOutputStream;
-import java.io.FileOutputStream;
-import java.io.InputStream;
-import java.io.OutputStream;
-
-import junit.framework.TestCase;
-import junit.framework.TestSuite;
-
-/**
- *
- * @author jeremym
- */
-public class SiStripTrackerBarrelTest extends TestCase
-{
- public SiStripTrackerBarrelTest(String name)
- {
- super(name);
- }
-
- public static TestSuite suite()
- {
- return new TestSuite(SiStripTrackerBarrelTest.class);
- }
-
- public void test_SiStripTrackerBarrelConverter() throws Exception
- {
- InputStream in = SiStripTrackerBarrel.class.getResourceAsStream("/org/lcsim/geometry/subdetector/SiStripTrackerBarrelTest.xml");
- OutputStream out = new BufferedOutputStream(new FileOutputStream("SiStripTrackerBarrelTest.lcdd"));
- new Main(true).convert("SiStripTrackerBarrelTest",in,out);
- }
-}
GeomConverter/test/org/lcsim/geometry/subdetector
diff -N SiTrackerBarrelTest.java
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ SiTrackerBarrelTest.java 6 Oct 2006 19:11:30 -0000 1.1
@@ -0,0 +1,42 @@
+/*
+ * CylindricalBarrelCalorimeterTest.java
+ *
+ * Created on June 15, 2005, 12:00 PM
+ */
+
+package org.lcsim.geometry.subdetector;
+
+import java.io.InputStream;
+
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+import org.lcsim.geometry.GeometryReader;
+import org.lcsim.geometry.compact.Detector;
+
+/**
+ *
+ * @author jeremym
+ */
+public class SiTrackerBarrelTest extends TestCase
+{
+ public SiTrackerBarrelTest(String name)
+ {
+ super(name);
+ }
+
+ protected void setUp() throws java.lang.Exception
+ {
+ InputStream in = this.getClass().getResourceAsStream("/org/lcsim/geometry/subdetector/SiTrackerBarrelTest.xml");
+ GeometryReader reader = new GeometryReader();
+ Detector det = reader.read(in);
+ }
+
+ public static junit.framework.Test suite()
+ {
+ return new TestSuite(SiTrackerBarrelTest.class);
+ }
+
+ public void test_Dummy()
+ {}
+}
GeomConverter/test/org/lcsim/geometry/subdetector
diff -N SiTrackerBarrelTest.xml
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ SiTrackerBarrelTest.xml 6 Oct 2006 19:11:30 -0000 1.1
@@ -0,0 +1,164 @@
+<lccdd xmlns:compact="http://www.lcsim.org/schemas/compact/1.0" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="http://www.lcsim.org/schemas/compact/1.0/compact.xsd">
+ <info name="subdetectors_test">
+ <comment/>
+ </info>
+ <define>
+ <constant name="cm" value="10"/>
+ <constant name="world_side" value="30000"/>
+ <constant name="world_x" value="world_side"/>
+ <constant name="world_y" value="world_side"/>
+ <constant name="world_z" value="world_side"/>
+ <constant name="tracking_region_radius" value="180.0 * cm"/>
+ <constant name="tracking_region_zmax" value="300.0 * cm"/>
+ </define>
+ <materials>
+ </materials>
+ <display>
+ <vis name="TestVis" alpha="1.0" r="1.0" g="0.0" b="0.0" drawingStyle="wireframe" lineStyle="unbroken" showDaughters="true" visible="true"/>
+ </display>
+ <detectors>
+ <detector id="1" name="VtxBarrel" type="SiTrackerBarrel" readout="VtxBarrel_RO" vis="TestVis">
+ <module name="VtxBarrelModuleInner">
+ <module_envelope width="9.8" length="63.0 * 2" thickness="0.6"/>
+ <module_component width="7.6" length="125.0" thickness="0.26" material="CarbonFiber" sensitive="false">
+ <position z="-0.08"/>
+ </module_component>
+ <module_component width="7.6" length="125.0" thickness="0.05" material="Epoxy" sensitive="false">
+ <position z="0.075"/>
+ </module_component>
+ <module_component width="9.6" length="125.0" thickness="0.1" material="Silicon" sensitive="true">
+ <position z="0.150"/>
+ </module_component>
+ </module>
+ <module name="VtxBarrelModuleOuter">
+ <module_envelope width="14.0" length="126.0" thickness="0.6"/>
+ <module_component width="11.6" length="125.0" thickness="0.26" material="CarbonFiber" sensitive="false">
+ <position z="-0.08"/>
+ </module_component>
+ <module_component width="11.6" length="125.0" thickness="0.05" material="Epoxy" sensitive="false">
+ <position z="0.075"/>
+ </module_component>
+ <module_component width="13.8" length="125.0" thickness="0.1" material="Silicon" sensitive="true">
+ <position z="0.150"/>
+ </module_component>
+ </module>
+ <layer module="VtxBarrelModuleInner" id="1">
+ <barrel_envelope inner_r="13.0" outer_r="17.0" z_length="63 * 2"/>
+ <rphi_layout phi_tilt="0.0" nphi="12" phi0="0.2618" rc="15.05" dr="-1.15"/>
+ <z_layout dr="0.0" z0="0.0" nz="1"/>
+ </layer>
+ <layer module="VtxBarrelModuleOuter" id="2">
+ <barrel_envelope inner_r="21.0" outer_r="25.0" z_length="63 * 2"/>
+ <rphi_layout phi_tilt="0.0" nphi="12" phi0="0.2618" rc="23.03" dr="-1.13"/>
+ <z_layout dr="0.0" z0="0.0" nz="1"/>
+ </layer>
+ <layer module="VtxBarrelModuleOuter" id="3">
+ <barrel_envelope inner_r="34.0" outer_r="38.0" z_length="63 * 2"/>
+ <rphi_layout phi_tilt="0.0" nphi="18" phi0="0.0" rc="35.79" dr="-0.89"/>
+ <z_layout dr="0.0" z0="0.0" nz="1"/>
+ </layer>
+ <layer module="VtxBarrelModuleOuter" id="4">
+ <barrel_envelope inner_r="46.6" outer_r="50.6" z_length="63 * 2"/>
+ <rphi_layout phi_tilt="0.0" nphi="24" phi0="0.1309" rc="47.5" dr="0.81"/>
+ <z_layout dr="0.0" z0="0.0" nz="1"/>
+ </layer>
+ <layer module="VtxBarrelModuleOuter" id="5">
+ <barrel_envelope inner_r="59.0" outer_r="63.0" z_length="63 * 2"/>
+ <rphi_layout phi_tilt="0.0" nphi="30" phi0="0.0" rc="59.9" dr="0.77"/>
+ <z_layout dr="0.0" z0="0.0" nz="1"/>
+ </layer>
+ </detector>
+ <detector id="2" name="SiTrackerBarrel" type="SiTrackerBarrel" readout="SiTrackerBarrel_RO" vis="TestVis">
+ <module name="SiTrackerModule">
+ <module_envelope width="97.79" length="97.79" thickness="5.5"/>
+ <module_component width="97.79" length="97.79" thickness="0.228" material="CarbonFiber" sensitive="false">
+ <position z="-1.702"/>
+ </module_component>
+ <module_component width="97.79" length="97.79" thickness="3.175" material="Rohacell31" sensitive="false">
+ <position z="0.0"/>
+ </module_component>
+ <module_component width="97.79" length="97.79" thickness="0.228" material="CarbonFiber" sensitive="false">
+ <position z="1.702"/>
+ </module_component>
+ <module_component width="93.531" length="93.031" thickness="0.3" material="Silicon" sensitive="true">
+ <position z="2.082"/>
+ </module_component>
+ <module_component width="63.8" length="6.67" thickness="0.3" material="Silicon" sensitive="false">
+ <position z="2.492"/>
+ </module_component>
+ <module_component width="97.79" length="97.79" thickness="0.1" material="Kapton" sensitive="false">
+ <position z="2.692"/>
+ </module_component>
+ </module>
+ <layer module="SiTrackerModule">
+ <barrel_envelope inner_r="195.0" outer_r="245.0" z_length="267.0 * 2.0"/>
+ <rphi_layout phi_tilt="0.19" nphi="16" phi0="0.196" rc="205.0" dr="0"/>
+ <z_layout dr="5.5" z0="218.0" nz="7"/>
+ </layer>
+ <layer module="SiTrackerModule">
+ <barrel_envelope inner_r="451.0" outer_r="501.0" z_length="608.0 * 2.0"/>
+ <rphi_layout phi_tilt="0.19" nphi="36" phi0="0.087" rc="461.0" dr="0.0"/>
+ <z_layout dr="5.5" z0="559.0" nz="15"/>
+ </layer>
+ <layer module="SiTrackerModule">
+ <barrel_envelope inner_r="706.0" outer_r="756.0" z_length="948.0 * 2.0"/>
+ <rphi_layout phi_tilt="0.19" nphi="54" phi0="0.058" rc="716.0" dr="0.0"/>
+ <z_layout dr="5.5" z0="899.0" nz="23"/>
+ </layer>
+ <layer module="SiTrackerModule">
+ <barrel_envelope inner_r="962.0" outer_r="1012.0" z_length="1289.0 * 2.0"/>
+ <rphi_layout phi_tilt="0.19" nphi="72" phi0="0.0436" rc="972.0" dr="0.0"/>
+ <z_layout dr="5.5" z0="1240.0" nz="29"/>
+ </layer>
+ <layer module="SiTrackerModule">
+ <barrel_envelope inner_r="1218.0" outer_r="1265.0" z_length="3260.0"/>
+ <rphi_layout phi_tilt="0.19" nphi="90" phi0="0.01745" rc="1228.0" dr="0.0"/>
+ <z_layout dr="5.5" z0="1581.0" nz="37"/>
+ </layer>
+ </detector>
+ </detectors>
+ <readouts>
+ <readout name="SiTrackerBarrel_RO">
+ <id>system:6,barrel:2,layer:4,phi:8,z:8,sensor:1</id>
+ </readout>
+ <readout name="VtxBarrel_RO">
+ <id>system:6,barrel:2,layer:4,phi:8,z:8,sensor:1</id>
+ </readout>
+ </readouts>
+ <fields>
+ </fields>
+</lccdd>
+
+ <!--
+ <module_component width="97.79" length="97.79" thickness="0.1" material="Kapton" sensitive="false">
+ <position z="-2.692"/>
+ </module_component>
+
+ <module_component width="63.8" length="6.67" thickness="0.3" material="Silicon" sensitive="false">
+ <position z="-2.492"/>
+ </module_component>
+
+ <module_component width="93.031" length="93.031" thickness="0.3" material="Silicon" sensitive="true">
+ <position z="-2.082"/>
+ <rotation z="0.04" />
+ </module_component>
+ -->
+<!--
+ <detector id="1" name="SiTrackerBarrel" type="SiTrackerBarrel" readout="SiTrackerBarrel_RO" vis="TestVis">
+ <module name="MyModule">
+ <module_envelope width="100.0" length="100.0" thickness="5.0"/>
+ <module_component zc="-2.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="true"/>
+ <module_component zc="-1.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
+ <module_component zc="0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
+ <module_component zc="1.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
+ <module_component zc="2.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="true">
+ <rotation x="0.0"/>
+ </module_component>
+ </module>
+ <layer module="MyModule">
+ <barrel_envelope inner_r="900.0" outer_r="1100.0" z_length="1000.0" />
+ <rphi_layout phi_tilt="0.2" nphi="50" phi0="0.2" rc="1000.0" />
+ <z_layout dr="10" z0="450" nz="10"/>
+ </layer>
+ </detector>
+ -->
GeomConverter/test/org/lcsim/geometry/subdetector
diff -N SiStripTrackerBarrelTest.xml
--- SiStripTrackerBarrelTest.xml 3 Oct 2006 21:35:14 -0000 1.5
+++ /dev/null 1 Jan 1970 00:00:00 -0000
@@ -1,164 +0,0 @@
-<lccdd xmlns:compact="http://www.lcsim.org/schemas/compact/1.0" xmlns:xs="http://www.w3.org/2001/XMLSchema-instance" xs:noNamespaceSchemaLocation="http://www.lcsim.org/schemas/compact/1.0/compact.xsd">
- <info name="subdetectors_test">
- <comment/>
- </info>
- <define>
- <constant name="cm" value="10"/>
- <constant name="world_side" value="30000"/>
- <constant name="world_x" value="world_side"/>
- <constant name="world_y" value="world_side"/>
- <constant name="world_z" value="world_side"/>
- <constant name="tracking_region_radius" value="180.0 * cm"/>
- <constant name="tracking_region_zmax" value="300.0 * cm"/>
- </define>
- <materials>
- </materials>
- <display>
- <vis name="TestVis" alpha="1.0" r="1.0" g="0.0" b="0.0" drawingStyle="wireframe" lineStyle="unbroken" showDaughters="true" visible="true"/>
- </display>
- <detectors>
- <detector id="1" name="VtxBarrel" type="SiStripTrackerBarrel" readout="VtxBarrel_RO" vis="TestVis">
- <module name="VtxBarrelModuleInner">
- <module_envelope width="9.8" length="63.0 * 2" thickness="0.6"/>
- <module_component width="7.6" length="125.0" thickness="0.26" material="CarbonFiber" sensitive="false">
- <position z="-0.08"/>
- </module_component>
- <module_component width="7.6" length="125.0" thickness="0.05" material="Epoxy" sensitive="false">
- <position z="0.075"/>
- </module_component>
- <module_component width="9.6" length="125.0" thickness="0.1" material="Silicon" sensitive="true">
- <position z="0.150"/>
- </module_component>
- </module>
- <module name="VtxBarrelModuleOuter">
- <module_envelope width="14.0" length="126.0" thickness="0.6"/>
- <module_component width="11.6" length="125.0" thickness="0.26" material="CarbonFiber" sensitive="false">
- <position z="-0.08"/>
- </module_component>
- <module_component width="11.6" length="125.0" thickness="0.05" material="Epoxy" sensitive="false">
- <position z="0.075"/>
- </module_component>
- <module_component width="13.8" length="125.0" thickness="0.1" material="Silicon" sensitive="true">
- <position z="0.150"/>
- </module_component>
- </module>
- <layer module="VtxBarrelModuleInner" id="1">
- <barrel_envelope inner_r="13.0" outer_r="17.0" z_length="63 * 2"/>
- <rphi_layout phi_tilt="0.0" nphi="12" phi0="0.2618" rc="15.05" dr="-1.15"/>
- <z_layout dr="0.0" z0="0.0" nz="1"/>
- </layer>
- <layer module="VtxBarrelModuleOuter" id="2">
- <barrel_envelope inner_r="21.0" outer_r="25.0" z_length="63 * 2"/>
- <rphi_layout phi_tilt="0.0" nphi="12" phi0="0.2618" rc="23.03" dr="-1.13"/>
- <z_layout dr="0.0" z0="0.0" nz="1"/>
- </layer>
- <layer module="VtxBarrelModuleOuter" id="3">
- <barrel_envelope inner_r="34.0" outer_r="38.0" z_length="63 * 2"/>
- <rphi_layout phi_tilt="0.0" nphi="18" phi0="0.0" rc="35.79" dr="-0.89"/>
- <z_layout dr="0.0" z0="0.0" nz="1"/>
- </layer>
- <layer module="VtxBarrelModuleOuter" id="4">
- <barrel_envelope inner_r="46.6" outer_r="50.6" z_length="63 * 2"/>
- <rphi_layout phi_tilt="0.0" nphi="24" phi0="0.1309" rc="47.5" dr="0.81"/>
- <z_layout dr="0.0" z0="0.0" nz="1"/>
- </layer>
- <layer module="VtxBarrelModuleOuter" id="5">
- <barrel_envelope inner_r="59.0" outer_r="63.0" z_length="63 * 2"/>
- <rphi_layout phi_tilt="0.0" nphi="30" phi0="0.0" rc="59.9" dr="0.77"/>
- <z_layout dr="0.0" z0="0.0" nz="1"/>
- </layer>
- </detector>
- <detector id="2" name="SiStripTrackerBarrel" type="SiStripTrackerBarrel" readout="SiStripTrackerBarrel_RO" vis="TestVis">
- <module name="SiTrackerModule">
- <module_envelope width="97.79" length="97.79" thickness="5.5"/>
- <module_component width="97.79" length="97.79" thickness="0.228" material="CarbonFiber" sensitive="false">
- <position z="-1.702"/>
- </module_component>
- <module_component width="97.79" length="97.79" thickness="3.175" material="Rohacell31" sensitive="false">
- <position z="0.0"/>
- </module_component>
- <module_component width="97.79" length="97.79" thickness="0.228" material="CarbonFiber" sensitive="false">
- <position z="1.702"/>
- </module_component>
- <module_component width="93.031" length="93.031" thickness="0.3" material="Silicon" sensitive="true">
- <position z="2.082"/>
- </module_component>
- <module_component width="63.8" length="6.67" thickness="0.3" material="Silicon" sensitive="false">
- <position z="2.492"/>
- </module_component>
- <module_component width="97.79" length="97.79" thickness="0.1" material="Kapton" sensitive="false">
- <position z="2.692"/>
- </module_component>
- </module>
- <layer module="SiTrackerModule">
- <barrel_envelope inner_r="195.0" outer_r="245.0" z_length="267.0 * 2.0"/>
- <rphi_layout phi_tilt="0.19" nphi="16" phi0="0.196" rc="205.0" dr="0"/>
- <z_layout dr="5.5" z0="218.0" nz="7"/>
- </layer>
- <layer module="SiTrackerModule">
- <barrel_envelope inner_r="451.0" outer_r="501.0" z_length="608.0 * 2.0"/>
- <rphi_layout phi_tilt="0.19" nphi="36" phi0="0.087" rc="461.0" dr="0.0"/>
- <z_layout dr="5.5" z0="559.0" nz="15"/>
- </layer>
- <layer module="SiTrackerModule">
- <barrel_envelope inner_r="706.0" outer_r="756.0" z_length="948.0 * 2.0"/>
- <rphi_layout phi_tilt="0.19" nphi="54" phi0="0.058" rc="716.0" dr="0.0"/>
- <z_layout dr="5.5" z0="899.0" nz="23"/>
- </layer>
- <layer module="SiTrackerModule">
- <barrel_envelope inner_r="962.0" outer_r="1012.0" z_length="1289.0 * 2.0"/>
- <rphi_layout phi_tilt="0.19" nphi="72" phi0="0.0436" rc="972.0" dr="0.0"/>
- <z_layout dr="5.5" z0="1240.0" nz="29"/>
- </layer>
- <layer module="SiTrackerModule">
- <barrel_envelope inner_r="1218.0" outer_r="1265.0" z_length="3260.0"/>
- <rphi_layout phi_tilt="0.19" nphi="90" phi0="0.01745" rc="1228.0" dr="0.0"/>
- <z_layout dr="5.5" z0="1581.0" nz="37"/>
- </layer>
- </detector>
- </detectors>
- <readouts>
- <readout name="SiStripTrackerBarrel_RO">
- <id>system:6,barrel:2,layer:4,phi:8,z:8,sensor:1</id>
- </readout>
- <readout name="VtxBarrel_RO">
- <id>system:6,barrel:2,layer:4,phi:8,z:8,sensor:1</id>
- </readout>
- </readouts>
- <fields>
- </fields>
-</lccdd>
-
- <!--
- <module_component width="97.79" length="97.79" thickness="0.1" material="Kapton" sensitive="false">
- <position z="-2.692"/>
- </module_component>
-
- <module_component width="63.8" length="6.67" thickness="0.3" material="Silicon" sensitive="false">
- <position z="-2.492"/>
- </module_component>
-
- <module_component width="93.031" length="93.031" thickness="0.3" material="Silicon" sensitive="true">
- <position z="-2.082"/>
- <rotation z="0.04" />
- </module_component>
- -->
-<!--
- <detector id="1" name="SiStripTrackerBarrel" type="SiStripTrackerBarrel" readout="SiStripTrackerBarrel_RO" vis="TestVis">
- <module name="MyModule">
- <module_envelope width="100.0" length="100.0" thickness="5.0"/>
- <module_component zc="-2.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="true"/>
- <module_component zc="-1.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
- <module_component zc="0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
- <module_component zc="1.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="false"/>
- <module_component zc="2.0" width="100" length="100" thickness="1.0" material="Silicon" sensitive="true">
- <rotation x="0.0"/>
- </module_component>
- </module>
- <layer module="MyModule">
- <barrel_envelope inner_r="900.0" outer_r="1100.0" z_length="1000.0" />
- <rphi_layout phi_tilt="0.2" nphi="50" phi0="0.2" rc="1000.0" />
- <z_layout dr="10" z0="450" nz="10"/>
- </layer>
- </detector>
- -->
CVSspam 0.2.8