Examples Examples Development and application of CATIA- GDML geometry builder Introduction Introduction 1- Institute for Theoretical and Experimental Physics (ITEP), Moscow, Russia 2- Bauman Moscow State Technical University, (BMSTU) Moscow, Russia 3- GSI - Helmholtzzentrum für Schwerionenforschung GmbH , Darmstadt, Germany S. Belogurov 1,2 ([email protected]), Yu. Berchun 2 , A. Chernogorov 1 , P. Malzacher 3 , E. Ovcharenko 1 , V. Schetinin 1,2 For mechanical, thermal, and some of For mechanical, thermal, and some of electromagnetic software the transfer is electromagnetic software the transfer is automated. automated. For radiation simulation packages For radiation simulation packages that’s not a case that’s not a case . . Design optimization of complex, densely packed Design optimization of complex, densely packed systems in severe radiation conditions (like systems in severe radiation conditions (like FAIR experiments) requires iterative exchange FAIR experiments) requires iterative exchange of geometry and material info of geometry and material info Geometry representations in CAD systems Geometry representations in CAD systems and G4/ROOT [2,3] are rather different and G4/ROOT [2,3] are rather different from each other from each other The difference is twofold: in the description of solid The difference is twofold: in the description of solid bodies and in the hierarchy of assemblies. For this bodies and in the hierarchy of assemblies. For this reason the automated geometry transfer can not be widely reason the automated geometry transfer can not be widely used. In some cases it is possible, but the result is used. In some cases it is possible, but the result is not optimized for simulations and computations are too not optimized for simulations and computations are too slow for big assemblies and complex shapes. slow for big assemblies and complex shapes. Solids: Solids: In CAD systems quasi arbitrary boundary representation In CAD systems quasi arbitrary boundary representation is used is used In G4/ROOT a Boolean combination of primitives In G4/ROOT a Boolean combination of primitives (Constructive Solid Geometry - CSG) is implemented. (Constructive Solid Geometry - CSG) is implemented. The method The method CBM STS CBM STS CBM RICH CBM RICH CBM and R3B CBM and R3B Dipole magnets Dipole magnets [1] S. Belogurov, Yu. Berchun, A.Chernogorov, P. [1] S. Belogurov, Yu. Berchun, A.Chernogorov, P. Malzacher, E. Ovcharenko, Malzacher, E. Ovcharenko, ‘ ‘ CATIA-GDML GEOMETRY BUILDER’, JPCS, V. 331, N3, 2011 , CATIA-GDML GEOMETRY BUILDER’, JPCS, V. 331, N3, 2011 , p. 32035 p. 32035 [2] Allison J et al. 2006 Geant4 developments and [2] Allison J et al. 2006 Geant4 developments and applications IEEE Trans. on Nucl. Sci. 53 270-8 applications IEEE Trans. on Nucl. Sci. 53 270-8 [3] Naumann A, Offermann E, Onuchin V, Panacek S, [3] Naumann A, Offermann E, Onuchin V, Panacek S, Rademakers F, Russo P and Tadel M 2009 ROOT – a C++ Rademakers F, Russo P and Tadel M 2009 ROOT – a C++ framework for petabyte data storage, statistical analysis framework for petabyte data storage, statistical analysis and visualization Computer Physics Communications 180 and visualization Computer Physics Communications 180 2499-512 2499-512 [4] Chytracek R, McCormick J, Pokorski W and Santin G [4] Chytracek R, McCormick J, Pokorski W and Santin G 2006 Geometry description markup language for physics 2006 Geometry description markup language for physics simulation and analysis applications IEEE Trans. Nucl. simulation and analysis applications IEEE Trans. Nucl. Plans Plans In CAD hierarchy a minimal unit is a In CAD hierarchy a minimal unit is a solid body ( solid body ( part). part). Products (assemblies) and subproducts are only Products (assemblies) and subproducts are only logical units – all the materials are assigned logical units – all the materials are assigned to solid bodies inside the part files or to to solid bodies inside the part files or to parts parts The task The task - Extension of the pickpoint definition to other Extension of the pickpoint definition to other primitives primitives - handling of inaccuracies in the pick-point handling of inaccuracies in the pick-point primitive definition primitive definition - Overcoming limitations of poly-primitives Overcoming limitations of poly-primitives - Adaptation of the CATIA Digital Mockup (DMU) Adaptation of the CATIA Digital Mockup (DMU) optimizer for automatic fit of parameterized optimizer for automatic fit of parameterized CSG models to existing parts CSG models to existing parts - Acceleration of GDML2CATIA converter Acceleration of GDML2CATIA converter - Visualization of several hierarchical levels Visualization of several hierarchical levels - Case study and best practice elaboration Case study and best practice elaboration In the G4/ROOT hierarchy there are three In the G4/ROOT hierarchy there are three conceptual layers conceptual layers : : - G4VSolid: - G4VSolid: shape, size shape, size - G4LogicalVolume: - G4LogicalVolume: material, MF, sensitivity, material, MF, sensitivity, daughter volumes, etc. daughter volumes, etc. - G4VPhysicalVolume: - G4VPhysicalVolume: position and rotation of position and rotation of an instance of the logical volume inside its mother an instance of the logical volume inside its mother The problem The problem We are presenting an update on the development We are presenting an update on the development and application of a tool for manual building and application of a tool for manual building of an optimized simulation geometry based on a of an optimized simulation geometry based on a CAD model. Earlier version of the tool was CAD model. Earlier version of the tool was presented at CHEP2010 [1] presented at CHEP2010 [1] 1. Mapping the G4/ROOT like geometry into CATIA product 1. Mapping the G4/ROOT like geometry into CATIA product tree tree a) a) Solid (TGeoShape): Solid (TGeoShape): - Implementation of primitives as parameterized User Defined - Implementation of primitives as parameterized User Defined Features (UDF) in CATIA. The UDFs are placed into G4Catalog. The Features (UDF) in CATIA. The UDFs are placed into G4Catalog. The following primitives are realized: following primitives are realized: G4Box; G4Cons; G4Ellipsoid; G4EllipticalCone; G4EllipticalTube; G4Orb; G4Box; G4Cons; G4Ellipsoid; G4EllipticalCone; G4EllipticalTube; G4Orb; G4Para; G4Sphere; G4Torus; G4Trap; G4Trd; G4Tubs; G4TwistedBox; G4Para; G4Sphere; G4Torus; G4Trap; G4Trd; G4Tubs; G4TwistedBox; G4TwistedTrap; G4TwistedTrd; G4TwistedTubs. Pilot versions of G4TwistedTrap; G4TwistedTrd; G4TwistedTubs. Pilot versions of G4Polycone and G4Polyhedra are also available. G4Polycone and G4Polyhedra are also available. - Realization of Boolean combinations using CATIA Realization of Boolean combinations using CATIA operations operations Add, Remove Add, Remove and and Intersect Intersect b) b) LogicalVolume (TGeoVolume) LogicalVolume (TGeoVolume) - File structure is realized in a template. - File structure is realized in a template. - Name of the material is introduced as a parameter. - Name of the material is introduced as a parameter. - PartBody - PartBody contains a parameterized CSG solid. contains a parameterized CSG solid. - Unparameterized copy of the - Unparameterized copy of the PartBody PartBody is published is published c) c) PhysicalVolume (TGeoNode) PhysicalVolume (TGeoNode) - Solids, published in files corresponding each to a smaller Solids, published in files corresponding each to a smaller LogicalVolume (TGeoVolume) LogicalVolume (TGeoVolume) can be inserted into the tree with positioning. can be inserted into the tree with positioning. They represent daughter volumes They represent daughter volumes - Linear and circular G4PVReplica (TGeoVolume * Divide) are implemented Linear and circular G4PVReplica (TGeoVolume * Divide) are implemented for multiple instantiation for multiple instantiation - G4AssemblyVolume (TGeoVolumeAssembly) are marked by G4AssemblyVolume (TGeoVolumeAssembly) are marked by material=assembly material=assembly and are able to manifest representations of daughters at the upper and are able to manifest representations of daughters at the upper level level 2. Developing the VBA tools facilitating creation of the G4/ROOT 2. Developing the VBA tools facilitating creation of the G4/ROOT like geometry like geometry - Inserter: Inserter: places a daughter volume inside the mother one and creates a places a daughter volume inside the mother one and creates a template for rotations and translations. A dedicated checkbox allows to template for rotations and translations. A dedicated checkbox allows to transform the mother volume into assembly. transform the mother volume into assembly. - Array maker: Array maker: Creates a circular or linear array of individual placements Creates a circular or linear array of individual placements of daughter or “granddaughter” volumes or generates G4PVReplica (TGeoVolume of daughter or “granddaughter” volumes or generates G4PVReplica (TGeoVolume * Divide). * Divide). - PtPa: PtPa: Allows to translate a Boolean operand or a daughter volume by clicking Allows to translate a Boolean operand or a daughter volume by clicking initial and final points. initial and final points. - Measure: Measure: Allows to measure length (radius) of an object or a distance Allows to measure length (radius) of an object or a distance (angle) between two objects. and put th result into any parameter of a (angle) between two objects. and put th result into any parameter of a G4/ROOT like model. G4/ROOT like model. - Mover: Mover: Allows to translate simultaneously a set of volumes. Allows to translate simultaneously a set of volumes. - Symmetry: Symmetry: Creates Physical volumes symmetric to selected set w.r.t a given Creates Physical volumes symmetric to selected set w.r.t a given plane. When necessary a chiral partner of an existing volume is generated. So plane. When necessary a chiral partner of an existing volume is generated. So far works only with primitives. far works only with primitives. - PickPoint Trap: PickPoint Trap: Calculates and puts into the tree the values of parameters, Calculates and puts into the tree the values of parameters, translations and rotations for a Trapezoid defined by picking with a mouse 8 translations and rotations for a Trapezoid defined by picking with a mouse 8 vertices. vertices. - Checker: Checker: Allows to check the correctness of G4/ROOT compatible tree and Allows to check the correctness of G4/ROOT compatible tree and overlaps of volumnes overlaps of volumnes - Material reassigner Material reassigner : Allows to assign all the materials from the upper level : Allows to assign all the materials from the upper level of the CATIA product. of the CATIA product. - GDML Parameterization: GDML Parameterization: For exchange of the G4/ROOT compatible geometry For exchange of the G4/ROOT compatible geometry between CATIA and MC packages GDML [4] is used. GDML variables are between CATIA and MC packages GDML [4] is used. GDML variables are implemented using CATIA parameters and relations. implemented using CATIA parameters and relations. - CATIA2GDML: CATIA2GDML: It is a converter from the G4/ROOT compatible CATIA tree to the It is a converter from the G4/ROOT compatible CATIA tree to the GDML file readable by ROOT and GEANT4. GDML file readable by ROOT and GEANT4. - GDML2CATIA GDML2CATIA : It is a converter from GDML to CATIA. It allows to bring any : It is a converter from GDML to CATIA. It allows to bring any simulation geometry into CATIA simulation geometry into CATIA CBM ECAL Frame CBM ECAL Frame The CBM Silicon Tracker is read The CBM Silicon Tracker is read from from cbmroot cbmroot via GDML. It is built via GDML. It is built as a multi level assembly: as a multi level assembly: 1 to 3 sensors and a cable from a module 1 to 3 sensors and a cable from a module 1 to 5 modules form a half ladder 1 to 5 modules form a half ladder 2 half-ladders form a ladder 2 half-ladders form a ladder 6-16 ladders form a station 6-16 ladders form a station References References The authors are grateful I. Ovsyannikov The authors are grateful I. Ovsyannikov (BMSTU) for his contribution into the (BMSTU) for his contribution into the project. This work is supported by SC ROSATOM project. This work is supported by SC ROSATOM and Helmholtz Association (grant IK-RU-002) and Helmholtz Association (grant IK-RU-002) via FAIR-Russia Research Center via FAIR-Russia Research Center Acknowledgements Acknowledgements CAD ROOT Specific Tools used for building G4/ROOT compatible Specific Tools used for building G4/ROOT compatible CBM RICH CBM RICH : : Mirror tilting angle, position and size of Mirror tilting angle, position and size of photodetectors and deflection angle of the beam pipe photodetectors and deflection angle of the beam pipe were were parameterized. parameterized. For rear frame For rear frame PickPoint Trap PickPoint Trap and and Symmetry Symmetry were used were used For mirror supporting belts For mirror supporting belts circular array circular array , , divisions divisions and and assembly assembly were used were used