84 boxLogical, boxName+
"0", worldLogical,
false, 0);
91 G4String layerName[2] = {boxName +
"_1", boxName +
"_2"};
97 layerSolid[0] =
new G4Box(layerName[0],
104 G4cout <<
"G4ScoringBox::Construct() : Replicate to x direction" <<
G4endl;
117 G4cout <<
"G4ScoringBox::Construct() : Placement" <<
G4endl;
119 boxLogical,
false, 0);
121 G4cerr <<
"ERROR : G4ScoringBox::SetupGeometry() : invalid parameter ("
123 <<
"in placement of the first nested layer." <<
G4endl;
129 G4cout << layerName[0] <<
": kXAxis, "
136 layerSolid[1] =
new G4Box(layerName[1],
143 G4cout <<
"G4ScoringBox::Construct() : Replicate to y direction" <<
G4endl;
156 G4cout <<
"G4ScoringBox::Construct() : Placement" <<
G4endl;
158 layerLogical[0],
false, 0);
160 G4cerr <<
"ERROR : G4ScoringBox::SetupGeometry() : invalid parameter ("
162 <<
"in placement of the second nested layer." <<
G4endl;
168 G4cout << layerName[1] <<
": kYAxis, "
175 G4String elementName = boxName +
"_3";
183 G4cout <<
"G4ScoringBox::Construct() : Replicate to z direction" <<
G4endl;
197 G4cout <<
"G4ScoringBox::Construct() : Placement" <<
G4endl;
199 elementName, layerLogical[1],
false, 0);
201 G4cerr <<
"ERROR : G4ScoringBox::SetupGeometry() : "
202 <<
"invalid parameter (" <<
fNSegment[2] <<
") "
203 <<
"in mesh element placement." <<
G4endl;
209 G4cout << elementName <<
": kZAxis, "
231 G4cout <<
" Size (x, y, z): ("
247 std::vector<std::vector<std::vector<double> > > cell;
248 std::vector<double> ez;
250 std::vector<std::vector<double> > eyz;
251 for(
int y = 0;
y < fNSegment[1];
y++) eyz.push_back(ez);
252 for(
int x = 0;
x < fNSegment[0];
x++) cell.push_back(eyz);
254 std::vector<std::vector<double> > xycell;
255 std::vector<double> ey;
256 for(
int y = 0;
y < fNSegment[1];
y++) ey.push_back(0.);
257 for(
int x = 0;
x < fNSegment[0];
x++) xycell.push_back(ey);
259 std::vector<std::vector<double> > yzcell;
260 for(
int y = 0;
y < fNSegment[1];
y++) yzcell.push_back(ez);
262 std::vector<std::vector<double> > xzcell;
263 for(
int x = 0;
x < fNSegment[0];
x++) xzcell.push_back(ez);
267 std::map<G4int, G4StatDouble*>::iterator itr = map->
GetMap()->begin();
268 for(; itr != map->
GetMap()->end(); itr++) {
278 G4double xymax = 0., yzmax = 0., xzmax = 0.;
279 for(
int x = 0;
x < fNSegment[0];
x++) {
280 for(
int y = 0;
y < fNSegment[1];
y++) {
281 if(xymin > xycell[
x][
y]) xymin = xycell[
x][
y];
282 if(xymax < xycell[
x][y]) xymax = xycell[
x][
y];
284 for(
int z = 0;
z < fNSegment[2];
z++) {
285 if(xzmin > xzcell[
x][
z]) xzmin = xzcell[
x][
z];
286 if(xzmax < xzcell[
x][z]) xzmax = xzcell[
x][
z];
289 for(
int y = 0;
y < fNSegment[1];
y++) {
290 for(
int z = 0;
z < fNSegment[2];
z++) {
291 if(yzmin > yzcell[
y][
z]) yzmin = yzcell[
y][
z];
292 if(yzmax < yzcell[
y][z]) yzmax = yzcell[
y][
z];
309 for(
int x = 0;
x < fNSegment[0];
x++) {
310 for(
int y = 0;
y < fNSegment[1];
y++) {
333 pVisManager->
Draw(*poly);
335 G4Box xyplate2 = xyplate;
339 pVisManager->
Draw(*poly2);
372 for(
int y = 0;
y < fNSegment[1];
y++) {
373 for(
int z = 0;
z < fNSegment[2];
z++) {
391 G4Box yzplate(
"yz", thick,
392 fSize[1]/fNSegment[1],
393 fSize[2]/fNSegment[2]);
397 pVisManager->
Draw(*poly);
399 G4Box yzplate2 = yzplate;
403 pVisManager->
Draw(*poly2);
436 for(
int x = 0;
x < fNSegment[0];
x++) {
437 for(
int z = 0;
z < fNSegment[2];
z++) {
455 G4Box xzplate(
"xz",
fSize[0]/fNSegment[0], thick,
456 fSize[2]/fNSegment[2]);
460 pVisManager->
Draw(*poly);
462 G4Box xzplate2 = xzplate;
466 pVisManager->
Draw(*poly2);
504 -
fSize[1] + 2*(y+0.5)*width.
y(),
505 -
fSize[2] + 2*(z+0.5)*width.
z());
526 G4int iColumn[3] = {2, 0, 1};
527 if(idxColumn<0 || idxColumn>=
fNSegment[iColumn[idxProj]])
529 G4cerr <<
"ERROR : Column number " << idxColumn
530 <<
" is out of scoring mesh [0," <<
fNSegment[iColumn[idxProj]]-1
531 <<
"]. Method ignored." <<
G4endl;
539 std::vector<std::vector<std::vector<double> > > cell;
540 std::vector<double> ez;
542 std::vector<std::vector<double> > eyz;
543 for(
int y = 0;
y < fNSegment[1];
y++) eyz.push_back(ez);
544 for(
int x = 0;
x < fNSegment[0];
x++) cell.push_back(eyz);
546 std::vector<std::vector<double> > xycell;
547 std::vector<double> ey;
548 for(
int y = 0;
y < fNSegment[1];
y++) ey.push_back(0.);
549 for(
int x = 0;
x < fNSegment[0];
x++) xycell.push_back(ey);
551 std::vector<std::vector<double> > yzcell;
552 for(
int y = 0;
y < fNSegment[1];
y++) yzcell.push_back(ez);
554 std::vector<std::vector<double> > xzcell;
555 for(
int x = 0;
x < fNSegment[0];
x++) xzcell.push_back(ez);
559 std::map<G4int, G4StatDouble*>::iterator itr = map->
GetMap()->begin();
560 for(; itr != map->
GetMap()->end(); itr++) {
563 if(idxProj == 0 && q[2] == idxColumn) {
566 if(idxProj == 1 && q[0] == idxColumn) {
569 if(idxProj == 2 && q[1] == idxColumn) {
576 G4double xymax = 0., yzmax = 0., xzmax = 0.;
577 for(
int x = 0;
x < fNSegment[0];
x++) {
578 for(
int y = 0;
y < fNSegment[1];
y++) {
579 if(xymin > xycell[
x][
y]) xymin = xycell[
x][
y];
580 if(xymax < xycell[
x][y]) xymax = xycell[
x][
y];
582 for(
int z = 0;
z < fNSegment[2];
z++) {
583 if(xzmin > xzcell[
x][
z]) xzmin = xzcell[
x][
z];
584 if(xzmax < xzcell[
x][z]) xzmax = xzcell[
x][
z];
587 for(
int y = 0;
y < fNSegment[1];
y++) {
588 for(
int z = 0;
z < fNSegment[2];
z++) {
589 if(yzmin > yzcell[
y][
z]) yzmin = yzcell[
y][
z];
590 if(yzmax < yzcell[
y][z]) yzmax = yzcell[
y][
z];
603 for(
int x = 0;
x < fNSegment[0];
x++) {
604 for(
int y = 0;
y < fNSegment[1];
y++) {
606 fSize[2]/fNSegment[2]);
623 pVisManager->
Draw(*poly);
631 for(
int y = 0;
y < fNSegment[1];
y++) {
632 for(
int z = 0;
z < fNSegment[2];
z++) {
634 fSize[2]/fNSegment[2]);
651 pVisManager->
Draw(*poly);
658 for(
int x = 0;
x < fNSegment[0];
x++) {
659 for(
int z = 0;
z < fNSegment[2];
z++) {
661 fSize[2]/fNSegment[2]);
678 pVisManager->
Draw(*poly);
virtual void BeginDraw(const G4Transform3D &objectTransformation=G4Transform3D())=0
G4ThreeVector GetReplicaPosition(G4int x, G4int y, G4int z)
CLHEP::Hep3Vector G4ThreeVector
void SetForceAuxEdgeVisible(G4bool=true)
G4ThreeVector fCenterPosition
virtual void Draw(const G4Circle &, const G4Transform3D &objectTransformation=G4Transform3D())=0
static const G4double pos
G4LogicalVolume * GetLogicalVolume() const
virtual void DrawColorChart(G4int nPoint=5)
G4bool IfFloatMinMax() const
G4int GetIndex(G4int x, G4int y, G4int z) const
virtual void List() const
static G4VVisManager * GetConcreteInstance()
virtual void GetMapColor(G4double val, G4double color[4])=0
void SetPSUnit(G4String &unit)
void SetPSName(G4String &psName)
HepPolyhedron & Transform(const G4Transform3D &t)
G4ScoringBox(G4String wName)
void SetVisAttributes(const G4VisAttributes *pVA)
G4GLOB_DLL std::ostream G4cerr
virtual void SetupGeometry(G4VPhysicalVolume *fWorldPhys)
void SetForceSolid(G4bool=true)
void SetVisibility(G4bool=true)
G4RotationMatrix * fRotationMatrix
void Draw(RunScore *map, G4VScoreColorMap *colorMap, G4int axflg=111)
virtual G4Polyhedron * GetPolyhedron() const
static constexpr double cm
G4GLOB_DLL std::ostream G4cout
void GetXYZ(G4int index, G4int q[3]) const
void SetColour(const G4Colour &)
G4LogicalVolume * fMeshElementLogical
G4String fDivisionAxisNames[3]
static G4int GetReplicaLevel()
G4MultiFunctionalDetector * fMFD
void DrawColumn(RunScore *map, G4VScoreColorMap *colorMap, G4int idxProj, G4int idxColumn)
void SetVisAttributes(const G4VisAttributes *)
void SetMinMax(G4double minVal, G4double maxVal)
void SetSensitiveDetector(G4VSensitiveDetector *pSDetector)