1 / 19

U-Solids: new geometrical primitives library for Geant4 and ROOT

U-Solids: new geometrical primitives library for Geant4 and ROOT. Marek Gayer CERN Physics Department (PH) Group Software Development for Experiments (SFT). Introduction, motivation.

jabir
Download Presentation

U-Solids: new geometrical primitives library for Geant4 and ROOT

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. U-Solids: new geometrical primitives library for Geant4 and ROOT Marek Gayer CERN Physics Department (PH) Group Software Development for Experiments(SFT)

  2. Introduction, motivation • Two geometry modellers in ROOT and Geant4 • Solids are 80% of maintenance effort in geometry modeller • Consolidate algorithms into a single, new U-Solids library • Introduce few new solid shapes • Optimized, adapted to new architectures

  3. Solids to be implemented • Union of all solids from Geant4 and ROOT • Simple solids (e.g. box, tube, cone, trapezoid) - mostly ported from the existing implementation, used to provide an initial set for tests within the new library • Complex existing solids (e.g. polycone, extruded polygone) - to be consolidated in the new library (one of the priorities) • New solids to optimize existing use cases: union of many solids using voxelization techniques • The ordering of implementation is to be decided.

  4. Currently implemented solids • For the start, the simplest shapes were selected • Box, Orb (done), Trapezoid (ongoing)

  5. Navigation functionality and library services for each solid • Performance critical methods: • Location of point either inside, outside or on surface • Shortest distance to surface for outside points • Shortest distance to surface for inside points • Distance to surface for inside points with given direction • Distance to surface for outside points with given direction • Normal vector for closest surface from given point • Additional methods: Bounding Box, Capacity, Volume, Generating points on surface/edge/inside of solid, Creating mesh for visualization …

  6. Criteria of inclusion of new and existing codes from Geant4, ROOT • Validity of returned results • Performance • Readability, simplicity of algorithm • Possibility of easy vectorization • Caution about not introducing new errors

  7. Suite of tests • U-Solids codes should pass: • Optical test • Solid Batch Test (SBT) • Original geometry and voxel tests • Results comparison test • Performance test • ROOT tests (Todo)

  8. Optical Escape • Optical photon is generated inside solid • Repeatedly bounces from inner surface • Particle must not escape the solid

  9. Solids Batch Test (SBT) geometry and voxel tests • Random points test (groups of inside, outside and surface points) • Various distance type methods are tested by numerous checks • E.g. for each inside random point p, SafetyFromInside(p) must be > 0 • It also tests random voxels with random inside points

  10. Solids Batch Test (SBT) performance and results comparison tests • Attempt to compare performance of Geant4, ROOT and new U-Solids • Similar performance as one indicator of correct implementation of new methods • Also, values and their differences from different codes can be compared • Plots are used for quick evaluation • Work in progress • Todo: port and measure in Linux

  11. Example plot: performance test Note: preliminary results, to be validated on Linux with standard compilation flags

  12. Example plot: Results comparison test

  13. Example plot: Results comparison test

  14. Example plot: Normal vectors

  15. Example plot: Normal vectors

  16. Example plot: Normal vectors

  17. Future work • Tests consolidation • Finish trapezoid based on test results • From other simple solids up to the more complex ones • Continue work on union of many solids • Polycone is very often used and has room for improvement

  18. Acknowledgment • Part of AIDA project, coordinated by Gabriele Cosmo • Definition / steering in collaboration with Andrei Gheata and John Apostolakis • Other contributors: • Jean-Marie Guyader - Multi-union implementation (summer student) • Tatiana Nikitina - Geant4 integration and testing

  19. Thank you for your attention. ??? Do you have any questions ?

More Related