Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
soft:geant4 [2021/02/05 06:19] – created Ce Zhangsoft:geant4 [2021/02/05 07:39] (current) Ce Zhang
Line 1: Line 1:
 ====== Rotation in Geant-4 ====== ====== Rotation in Geant-4 ======
 +
 +Two main ways in the Geant-4 to apply the rotation: G4Rotation matrix and the HepRotation. Here the G4RotationMatrix.hh will be used.
 +
 +Main reference
 +
 +  - [[http://www.apc.univ-paris7.fr/~franco/g4doxy4.10/html/examples_2extended_2geometry_2transforms_2src_2_detector_construction_8cc_source.html]]
 +  - [[https://www-zeuthen.desy.de/geant4/g4course2011/day2/2_material/DetectorConstruction_8cc-source.html]]
 +  - [[http://nucleus.usask.ca/Geant/Exercises/rotations.html]]
 +
  
 In the Geometry.cc, the target is set by In the Geometry.cc, the target is set by
Line 10: Line 19:
  
 <code> <code>
 +
 +#include "G4RotationMatrix.hh"
 +
 Geometry::SetPhysVol( const G4String& name, G4VSolid* solid, Geometry::SetPhysVol( const G4String& name, G4VSolid* solid,
        G4Material* material, G4VPhysicalVolume* mtrVol,        G4Material* material, G4VPhysicalVolume* mtrVol,
        const G4ThreeVector& transVec, G4RotationMatrix* rotm  )        const G4ThreeVector& transVec, G4RotationMatrix* rotm  )
 </code> </code>