15.3.2010 Kamil Sedlak

1) Implemented a posibility to add "Models" to physics processes
     (this should be a first step towards the implementation of the
     Meyer scattering.  The documentation has not been updated yet.
  2) Minor change - implementation of a special volume for GPD
This commit is contained in:
2010-03-15 13:19:31 +00:00
parent a71842dd81
commit 29e49736ea
2 changed files with 89 additions and 3 deletions

View File

@ -354,9 +354,49 @@ G4VPhysicalVolume* musrDetectorConstruction::Construct() {
<<" orientation="<<orientation<<G4endl;
ReportGeometryProblem(line);
}
solid = new G4IntersectionSolid(solidName, solidDetTube, solidDetBox, yRot, zTrans);
}
else if (strcmp(tmpString2,"GPDsampleHolderA")==0){
// First part of the GPD sample holder, where posx, posy, posz = centre of the whole (long) tube
// (=111.25mm below the centre of the holes)
// Create a tube, from which center a box is cut out. x1=box half-width; x2,x3,x4,x5 define the tube.
// sscanf(&line[0],"%*s %*s %*s %s %g %g %g %g %g %s %g %g %g %s %s",
// name,&x1,&x2,&x3,&x4,&x5,material,&posx,&posy,&posz,mothersName,rotMatrix);
// sscanf(&line[0],"%*s %*s %*s %*s %*g %*g %*g %*g %*g %*s %*g %*g %*g %*s %*s %s %d %s",sensitiveDet,&volumeID,actualFieldName);
// solidName+=name;
// G4double roundingErr=0.01*mm; // to avoid some displaying problems of the subtracted volumes
// G4Box* solidInnerDetBox = new G4Box("SolidInnerDetBox",x1*mm,x1*mm,x3*mm+roundingErr);
// G4Tubs* solidOuterDetTube = new G4Tubs("SolidOuterDetTube",0.*mm,x2*mm,x3*mm,x4*deg,x5*deg);
// solid = new G4SubtractionSolid(solidName, solidOuterDetTube, solidInnerDetBox);
sscanf(&line[0],"%*s %*s %*s %s %g %g %g %g %g %s %g %g %g %s %s",
name,&x1,&x2,&x3,&x4,&x5,material,&posx,&posy,&posz,mothersName,rotMatrix);
sscanf(&line[0],"%*s %*s %*s %*s %*g %*g %*g %*g %*g %*s %*g %*g %*g %*s %*s %s %d",sensitiveDet,&volumeID);
solidName+=name;
G4double upperPartHalfHeight = 65*mm;
G4double lowerPartHalfHeight = (287.5-65)/2*mm;
G4double halfHeight = upperPartHalfHeight+lowerPartHalfHeight;
G4double innerR = 37.*mm; G4double outerR = 37.5*mm;
// G4Box* solidDetBox = new G4Box("SolidDetBox",x2*mm,x2*mm,x3*mm+roundingErr);
G4Tubs* solidGPDTubeA1 = new G4Tubs("SolidGPDTubeA1",innerR,outerR,halfHeight,0,360);
G4Box* solidGPDBoxA2 = new G4Box ("SolidGPDBoxA2",10*mm,38*mm, 70*mm);
G4Box* solidGPDBoxA5 = new G4Box ("solidGPDBoxA5",5*mm,40*mm,30*mm);
G4RotationMatrix* yRotA12 = new G4RotationMatrix();
G4ThreeVector zTransA12( 30*mm,0, (111.25+20)*mm);
G4ThreeVector zTransA13(-30*mm,0, (111.25+20)*mm);
G4SubtractionSolid* solidA12 = new G4SubtractionSolid("solidA12", solidGPDTubeA1, solidGPDBoxA2, yRotA12, zTransA12);
G4SubtractionSolid* solidA123 = new G4SubtractionSolid("solidA123", solidA12 , solidGPDBoxA2, yRotA12, zTransA13);
G4ThreeVector zTransA5(0,0,111.25*mm);
solid = new G4SubtractionSolid(solidName, solidA123, solidGPDBoxA5, yRotA12, zTransA5);
//G4cout<<"solidName="<<solidName<<" solidA123="<<solidA123<<" solidGPDBoxA5="<<solidGPDBoxA5<<" yRotA12="<<yRotA12<<" zTransA5="<<zTransA5<<G4endl;
//solid = new G4SubtractionSolid(solidName, solidGPDTubeA1, solidGPDBoxA2, yRotA12, zTransA12);
G4cout<<"Debug 80"<<G4endl;
}
else ReportGeometryProblem(line);
G4ThreeVector position = G4ThreeVector (posx*mm,posy*mm,posz*mm);