Hi geant4ers:
Hello experts, I have recently been using the DICOM example to test a radioactive seed I designed, which I plan to implant into a model created by DICOM as a way to simulate the radiotherapy process. I followed Ms. guatelli’s suggestion to simulate this implantation process through parallel geometry to avoid the problem that the G4PVParameterised parent can only have a unique child.
I managed to build a test box and place it successfully, and when the program runs, I get this message on the terminal
Parallel World `parallelWorld’ constructed.
— G4CoupledTransportation is used
I was thinking that maybe the parallel world was created, but I can’t see the created box in the results displayed by QT.
Here is the program I used to create the parallel geometry
G4VPhysicalVolume* physicalParallelWorld = GetWorld();
G4LogicalVolume* logicalParallelWorld = physicalParallelWorld->GetLogicalVolume();
//get back the logical volume of phantomContainer
G4LogicalVolume*Containerlv = G4LogicalVolumeStore::GetInstance()->GetVolume("phantomContainer");
G4Box*Containers = (G4Box*)Containerlv->GetSolid();
auto*testboxmother = new G4LogicalVolume(Containers,nullptr,"testboxmother");
auto*testboxs = new G4Box("testboxs",5*cm,5*cm,0.5*mm);
auto*testboxlv = new G4LogicalVolume(testboxs,nullptr,"testboxlv");
new G4PVPlacement(
0,
G4ThreeVector(),
testboxlv,
"testbox",
testboxmother,
false,
0);
G4VPhysicalVolume*
shieldPhysical = G4PhysicalVolumeStore::GetInstance()->GetVolume("phantomContainer");
G4ThreeVector translation = shieldPhysical->GetObjectTranslation();
new G4PVPlacement( nullptr, // no rotation
translation, // translate as for the shield
testboxmother, // its logical volume
"motherForSlices.physical", // its name
logicalParallelWorld, // its mother volume
false, // no boolean operation
0); // copy number
auto visAttributes = new G4VisAttributes(G4Colour(1.0,1.0,1.0));
visAttributes = new G4VisAttributes(G4Colour(0.0,255.0,0.0));
testboxlv->SetVisAttributes(visAttributes);
fVisAttributes.push_back(visAttributes);
I am truly looking forward to the answers and opinions of all the experts here, you have no idea how precious even a word would be to me. Here’s wishing you all a happy life.