Changeset 1347 for trunk/source/geometry/solids/test/OpticalEscape
- Timestamp:
- Dec 22, 2010, 3:52:27 PM (14 years ago)
- Location:
- trunk/source/geometry/solids/test/OpticalEscape
- Files:
-
- 4 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/source/geometry/solids/test/OpticalEscape/AXPETDemonstrator.cc
r1316 r1347 26 26 // 27 27 // $Id: AXPETDemonstrator.cc,v 1.1 2008/09/03 13:34:03 gcosmo Exp $ 28 // GEANT4 tag $Name: geant4-09-04- beta-cand-01$28 // GEANT4 tag $Name: geant4-09-04-ref-00 $ 29 29 // 30 30 // -
trunk/source/geometry/solids/test/OpticalEscape/src/AXPETDetectorConstruction.cc
r1316 r1347 24 24 // ******************************************************************** 25 25 // 26 // $Id: AXPETDetectorConstruction.cc,v 1. 1 2008/09/03 13:34:03 gcosmoExp $26 // $Id: AXPETDetectorConstruction.cc,v 1.2 2010/11/16 13:35:53 tnikitin Exp $ 27 27 // ------------------------------------------------------------ 28 28 // Geant4 class implementation file … … 52 52 #include "G4Trd.hh" 53 53 #include "G4Tet.hh" 54 #include "G4GenericTrap.hh" 55 #include "G4TessellatedSolid.hh" 56 #include "G4ExtrudedSolid.hh" 54 57 55 58 #include "G4Polycone.hh" … … 60 63 #include "G4TwistedTrd.hh" 61 64 #include "G4TwistedTrap.hh" 65 66 #include "G4TwoVector.hh" 67 #include "G4TriangularFacet.hh" 68 #include "G4QuadrangularFacet.hh" 62 69 63 70 #include "G4BooleanSolid.hh" … … 488 495 else if ( val == "Tet" ) 489 496 { 490 491 G4ThreeVector pzero(0,0,0); 492 G4ThreeVector pnt1(1.,0.,0.),pnt2(0,1.,0.), pnt3(0,0.,1.); 493 G4Tet t1( "aTet", pzero, pnt1, pnt2, pnt3); 497 G4ThreeVector anchor = G4ThreeVector( 0, 0, 0); 498 G4ThreeVector p2 = G4ThreeVector(1.0, 0.5, 0); 499 G4ThreeVector p3 = G4ThreeVector(0.5, 1.0, 0); 500 G4ThreeVector p4 = G4ThreeVector(0.5, 0.5, 1.0); 501 502 aVolume = new G4Tet("aTet",anchor,p2,p3,p4); 494 503 } 495 504 else if ( val == "Trap") … … 539 548 540 549 } 550 551 else if (val == "TwistedBox") 552 { 553 aVolume = new G4TwistedBox("aTwistedBox",40*deg,0.5,1.0,1.5); 554 } 555 else if (val == "TwistedTrd") 556 { 557 aVolume = new G4TwistedTrd("aTwistedTrd",0.5,1.0,0.8,1.5,1.8,20*deg); 558 } 559 else if (val == "TwistedTrap") 560 { 561 aVolume = new G4TwistedTrap("aTwistedTrap",40*deg,0.5,1.0,0.8,1.5); 562 } 563 else if ( val == "TwistedTrap2") 564 { 565 aVolume = new G4TwistedTrap("aTwistedTrap2", 566 20*deg, // twist angle 567 0.80, // half z length 568 10*deg, // direction between end planes 569 40*deg, // defined by polar and azimutal angles. 570 0.8, // half y length at -pDz 571 1.1, // half x length at -pDz,-pDy 572 1.6, // half x length at -pDz,+pDy 573 0.8, // half y length at +pDz 574 1.1, // half x length at +pDz,-pDy 575 1.6, // half x length at +pDz,+pDy 576 -50*deg // tilt angle at +pDz 577 ) ; 578 } 579 else if ( val == "TwistedTubs") 580 { 581 aVolume = new G4TwistedTubs("aTwistedTubs",10.*deg,1.0,2.,4.,171.*deg); 582 583 } 584 else if (val == "GenericTrap" ){ 585 std::vector<G4TwoVector> vertices; 586 vertices.push_back(G4TwoVector( -4.5, -4.5)); 587 vertices.push_back(G4TwoVector( -4.5, 4.5)); 588 vertices.push_back(G4TwoVector( 4.5, 4.5)); 589 vertices.push_back(G4TwoVector( 4.5, -4.5)); 590 vertices.push_back(G4TwoVector( -3.5, -3.5)); 591 vertices.push_back(G4TwoVector( -3.5, 3.5)); 592 vertices.push_back(G4TwoVector( 3.5, 3.5)); 593 vertices.push_back(G4TwoVector( 3.5, -2.5)); 594 aVolume = new G4GenericTrap("aGenTrd",4.,vertices); 595 } 596 else if(val == "TessellatedSolid") 597 { 598 G4double targetSize = 2.; 599 G4TessellatedSolid* aVolume1 = new G4TessellatedSolid("aTessellatedSolid"); 600 G4TriangularFacet *facet1 = new 601 G4TriangularFacet (G4ThreeVector(-targetSize,-targetSize, 0.0), 602 G4ThreeVector(+targetSize,-targetSize, 0.0), 603 G4ThreeVector( 0.0, 0.0,+targetSize), 604 ABSOLUTE); 605 G4TriangularFacet *facet2 = new 606 G4TriangularFacet (G4ThreeVector(+targetSize,-targetSize, 0.0), 607 G4ThreeVector(+targetSize,+targetSize, 0.0), 608 G4ThreeVector( 0.0, 0.0,+targetSize), 609 ABSOLUTE); 610 G4TriangularFacet *facet3 = new 611 G4TriangularFacet (G4ThreeVector(+targetSize,+targetSize, 0.0), 612 G4ThreeVector(-targetSize,+targetSize, 0.0), 613 G4ThreeVector( 0.0, 0.0,+targetSize), 614 ABSOLUTE); 615 G4TriangularFacet *facet4 = new 616 G4TriangularFacet (G4ThreeVector(-targetSize,+targetSize, 0.0), 617 G4ThreeVector(-targetSize,-targetSize, 0.0), 618 G4ThreeVector( 0.0, 0.0,+targetSize), 619 ABSOLUTE); 620 G4QuadrangularFacet *facet5 = new 621 G4QuadrangularFacet (G4ThreeVector(-targetSize,-targetSize, 0.0), 622 G4ThreeVector(-targetSize,+targetSize, 0.0), 623 G4ThreeVector(+targetSize,+targetSize, 0.0), 624 G4ThreeVector(+targetSize,-targetSize, 0.0), 625 ABSOLUTE); 626 627 aVolume1->AddFacet((G4VFacet*) facet1); 628 aVolume1->AddFacet((G4VFacet*) facet2); 629 aVolume1->AddFacet((G4VFacet*) facet3); 630 aVolume1->AddFacet((G4VFacet*) facet4); 631 aVolume1->AddFacet((G4VFacet*) facet5); 632 633 aVolume1->SetSolidClosed(true); 634 635 aVolume = aVolume1; 636 637 } 638 else if (val == "ExtrudedSolid") 639 { 640 std::vector<G4TwoVector> polygon; 641 polygon.push_back(G4TwoVector(-3., -3.0)); 642 polygon.push_back(G4TwoVector(-3., 3.0)); 643 polygon.push_back(G4TwoVector( 3., 3.0)); 644 polygon.push_back(G4TwoVector( 3., -3.0)); 645 polygon.push_back(G4TwoVector( 1.5, -3.0)); 646 polygon.push_back(G4TwoVector( 1.5, 1.5)); 647 polygon.push_back(G4TwoVector(-1.5, 1.5)); 648 polygon.push_back(G4TwoVector(-1.5, -3.0)); 649 650 std::vector<G4ExtrudedSolid::ZSection> zsections; 651 zsections.push_back(G4ExtrudedSolid::ZSection(-4.0, G4TwoVector(-2.0, 1.0), 1.5)); 652 zsections.push_back(G4ExtrudedSolid::ZSection( 1.0, G4TwoVector( 0, 0), 0.5)); 653 zsections.push_back(G4ExtrudedSolid::ZSection( 1.5, G4TwoVector( 0, 0), 0.7)); 654 zsections.push_back(G4ExtrudedSolid::ZSection( 4.0, G4TwoVector( 2.0, 2.0), 0.9)); 655 656 aVolume = new G4ExtrudedSolid("aExtrudedSolid", polygon, zsections); 657 } 658 659 541 660 else 542 661 { G4cout <<"DetectorConstruction tried to select "<<val<<G4endl; -
trunk/source/geometry/solids/test/OpticalEscape/src/AXPETDetectorMessenger.cc
r1316 r1347 24 24 // ******************************************************************** 25 25 // 26 // $Id: AXPETDetectorMessenger.cc,v 1. 1 2008/09/03 13:34:03 gcosmoExp $26 // $Id: AXPETDetectorMessenger.cc,v 1.2 2010/11/16 13:36:00 tnikitin Exp $ 27 27 // ------------------------------------------------------------ 28 28 // Geant4 class implementation file … … 56 56 selDetCmd->SetDefaultValue("Tubs"); 57 57 58 selDetCmd->SetCandidates("Trap Trd Tet Sphere HalfSphere HollowSphere HalfHollowSphere Ring Shell Orb Box Cons manyCons Tubs Hype Torus Para Paraboloid Polycone PolyconeGen PolyconeGenComplex Polyhedra PolyhedraGen PolyhedraGenComplex BREPBox Trd b1Ib2 b1Ub2 b1Sb2 b1Ub1 b1Ib1 b1Sb1 Ellipsoid EllipticalCone EllipticalTube ");58 selDetCmd->SetCandidates("Trap Trd Tet Sphere HalfSphere HollowSphere HalfHollowSphere Ring Shell Orb Box Cons manyCons Tubs Hype Torus Para Paraboloid Polycone PolyconeGen PolyconeGenComplex Polyhedra PolyhedraGen PolyhedraGenComplex BREPBox Trd b1Ib2 b1Ub2 b1Sb2 b1Ub1 b1Ib1 b1Sb1 Ellipsoid EllipticalCone EllipticalTube Tet GenericTrap TwistedBox TwistedTrd TwistedTrap TwistedTubs TessellatedSolid ExtrudedSolid"); 59 59 selDetCmd->AvailableForStates(G4State_PreInit,G4State_Idle); 60 60 -
trunk/source/geometry/solids/test/OpticalEscape/src/AXPETPhysicsList.cc
r1316 r1347 24 24 // ******************************************************************** 25 25 // 26 // $Id: AXPETPhysicsList.cc,v 1. 1 2008/09/03 13:34:03 gcosmoExp $26 // $Id: AXPETPhysicsList.cc,v 1.2 2010/11/16 13:38:09 tnikitin Exp $ 27 27 // ------------------------------------------------------------ 28 28 // Geant4 class implementation file … … 129 129 #include "G4PhotoElectricEffect.hh" 130 130 131 #include "G4MultipleScattering.hh" 131 #include "G4eMultipleScattering.hh" 132 #include "G4MuMultipleScattering.hh" 133 #include "G4hMultipleScattering.hh" 132 134 133 135 #include "G4eIonisation.hh" … … 159 161 //electron 160 162 // Construct processes for electron 161 pmanager->AddProcess(new G4 MultipleScattering(),-1, 1, 1);163 pmanager->AddProcess(new G4eMultipleScattering(),-1, 1, 1); 162 164 pmanager->AddProcess(new G4eIonisation(), -1, 2, 2); 163 165 pmanager->AddProcess(new G4eBremsstrahlung(), -1, 3, 3); … … 166 168 //positron 167 169 // Construct processes for positron 168 pmanager->AddProcess(new G4 MultipleScattering(),-1, 1, 1);170 pmanager->AddProcess(new G4eMultipleScattering(),-1, 1, 1); 169 171 pmanager->AddProcess(new G4eIonisation(), -1, 2, 2); 170 172 pmanager->AddProcess(new G4eBremsstrahlung(), -1, 3, 3); … … 175 177 //muon 176 178 // Construct processes for muon 177 pmanager->AddProcess(new G4Mu ltipleScattering(),-1, 1, 1);179 pmanager->AddProcess(new G4MuMultipleScattering(),-1, 1, 1); 178 180 pmanager->AddProcess(new G4MuIonisation(), -1, 2, 2); 179 181 pmanager->AddProcess(new G4MuBremsstrahlung(), -1, 3, 3); … … 184 186 (particle->GetParticleName() != "chargedgeantino")) { 185 187 // all others charged particles except geantino 186 pmanager->AddProcess(new G4 MultipleScattering(),-1,1,1);188 pmanager->AddProcess(new G4hMultipleScattering(),-1,1,1); 187 189 pmanager->AddProcess(new G4hIonisation(), -1,2,2); 188 190 } … … 222 224 G4String particleName = particle->GetParticleName(); 223 225 if (theCerenkovProcess->IsApplicable(*particle)) { 224 // pmanager->AddContinuousProcess(theCerenkovProcess);225 226 pmanager->AddProcess(theCerenkovProcess); 226 227 pmanager->SetProcessOrdering(theCerenkovProcess,idxPostStep);
Note: See TracChangeset
for help on using the changeset viewer.