Commit 4112da49 authored by Alex Ciabattoni's avatar Alex Ciabattoni
Browse files

Geometry COSI updates

parent cacd1e0e
Loading
Loading
Loading
Loading
+35 −1
Original line number Diff line number Diff line
@@ -1366,6 +1366,11 @@ G4VPhysicalVolume* GeometryCOSI_ACS::ConstructGeometry(G4VPhysicalVolume* World_
        gm.config->readInto(setReflSurface2Type, "PHYS.ACS.OPTSURFACE2.WRAPPER");
        G4cout << "PHYS.ACS.OPTSURFACE2.WRAPPER: " << setReflSurface2Type << G4endl;
        /* presence of a lead floor */
        G4int is_floor = 0;
        gm.config->readInto(is_floor, "GEOM.COSI.FLOOR");
        G4cout << "GEOM.COSI.FLOOR: " << is_floor << G4endl;  
        /* set volumes sensitive */
        G4int chamber_sens = 0;
        gm.config->readInto(chamber_sens, "SENSITIVE.CHAMBER");
@@ -1424,6 +1429,9 @@ G4VPhysicalVolume* GeometryCOSI_ACS::ConstructGeometry(G4VPhysicalVolume* World_
        G4int foam_sens = 0;
        gm.config->readInto(foam_sens, "SENSITIVE.FOAM");
        G4cout << "SENSITIVE.FOAM: " << foam_sens << G4endl;   
        G4int floor_sens = 0;
        gm.config->readInto(floor_sens, "SENSITIVE.FLOOR");
        G4cout << "SENSITIVE.FLOOR: " << floor_sens << G4endl;  
        /* geom_type 8 & 9 */ 
        G4int housing_sens = 0;
@@ -4647,9 +4655,13 @@ G4VPhysicalVolume* GeometryCOSI_ACS::ConstructGeometry(G4VPhysicalVolume* World_
            G4double tableY = 431.8;
            G4double tableZ = 63.5;
            G4double table_posX = 0.;
            G4double table_posY = 0.;
            G4double table_posZ = -zlen-plasticZ-AlThick-coatThick-Al_layerZ-tableZ/2.;
            G4Box* solid_table = new G4Box("solid_table", tableX/2., tableY/2., tableZ/2.);
            G4LogicalVolume* log_table = new G4LogicalVolume(solid_table, wood2_mat, "log_table");
            G4VPhysicalVolume* phys_table = new G4PVPlacement(0, G4ThreeVector(0., 0., -zlen-plasticZ-AlThick-coatThick-Al_layerZ-tableZ/2.), log_table, "table", log_chamber, false, table_copy, true);
            G4VPhysicalVolume* phys_table = new G4PVPlacement(0, G4ThreeVector(table_posX, table_posY, table_posZ), log_table, "table", log_chamber, false, table_copy, true);
            G4VisAttributes* VisTable = new G4VisAttributes(G4Colour::Brown());
            log_table->SetVisAttributes(VisTable);
@@ -4766,6 +4778,28 @@ G4VPhysicalVolume* GeometryCOSI_ACS::ConstructGeometry(G4VPhysicalVolume* World_
                    gm.AddXYZDetector(log_foam_source);   
            }
            if (is_floor == 1) {
                G4int floor_copy = 150;
                
                G4double floorX = chamber_side;
                G4double floorY = chamber_side;
                G4double floorZ = 100.;
                G4double floor_posX = table_posX;
                G4double floor_posY = table_posY;
                G4double floor_posZ = table_posZ - 1000.;
                G4Box* solid_floor = new G4Box("solid_floor", floorX/2., floorY/2., floorZ/2.);
                G4LogicalVolume* log_floor = new G4LogicalVolume(solid_floor, coll_mat, "log_floor");
                G4VPhysicalVolume* phys_floor = new G4PVPlacement(0, G4ThreeVector(floor_posX, floor_posY, floor_posZ), log_floor, "floor", log_chamber, false, floor_copy, true);
                G4VisAttributes* VisFloor = new G4VisAttributes(G4Colour::Black());
                log_floor->SetVisAttributes(VisFloor);
                if (floor_sens == 1)
                    gm.AddXYZDetector(log_floor);   
            }
            /* Teflon PTFE */
            G4int tefl_copy = 10;