90 tubsLogical, tubsName+
"0", worldLogical,
false, 0);
95 G4String layerName[2] = {tubsName +
"1", tubsName +
"2"};
101 layerSolid[0] =
new G4Tubs(layerName[0],
121 G4cerr <<
"G4ScoringCylinder::SetupGeometry() : invalid parameter ("
123 <<
"in placement of the first nested layer." <<
G4endl;
128 layerSolid[1] =
new G4Tubs(layerName[1],
149 G4cerr <<
"ERROR : G4ScoringCylinder::SetupGeometry() : invalid parameter ("
151 <<
"in placement of the second nested layer." <<
G4endl;
155 G4String elementName = tubsName +
"3";
179 G4cerr <<
"G4ScoringCylinder::SetupGeometry() : "
181 <<
"in mesh element placement." <<
G4endl;
201 G4cout <<
" Size (R, Dz): ("
217 std::vector<double> ephi;
218 for(
int phi = 0; phi <
fNSegment[
IPHI]; phi++) ephi.push_back(0.);
220 std::vector<std::vector<double> > zphicell;
221 for(
int z = 0;
z < fNSegment[
IZ];
z++) zphicell.push_back(ephi);
223 std::vector<std::vector<double> > rphicell;
224 for(
int r = 0; r < fNSegment[
IR]; r++) rphicell.push_back(ephi);
228 std::map<G4int, G4StatDouble*>::iterator itr = map->
GetMap()->begin();
229 for(; itr != map->
GetMap()->end(); itr++) {
242 G4double zphimax = 0., rphimax = 0.;
243 for(
int iphi = 0; iphi < fNSegment[
IPHI]; iphi++) {
244 for(
int iz = 0; iz < fNSegment[
IZ]; iz++) {
245 if(zphimin > zphicell[iz][iphi]) zphimin = zphicell[iz][iphi];
246 if(zphimax < zphicell[iz][iphi]) zphimax = zphicell[iz][iphi];
248 for(
int ir = 0; ir < fNSegment[
IR]; ir++) {
249 if(rphimin > rphicell[ir][iphi]) rphimin = rphicell[ir][iphi];
250 if(rphimax < rphicell[ir][iphi]) rphimax = rphicell[ir][iphi];
271 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
272 for(
int z = 0;
z < fNSegment[
IZ];
z++) {
279 angle, dphi*0.99999);
296 pVisManager->
Draw(*poly);
309 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
310 for(
int r = 0; r < fNSegment[
IR]; r++) {
312 G4double rs[2] = {rsize*r, rsize*(r+1)};
315 G4Tubs cylindern(
"z-phi", rs[0], rs[1], 0.001,
316 angle, dphi*0.99999);
317 G4Tubs cylinderp = cylindern;
338 pVisManager->
Draw(*polyn);
343 pVisManager->
Draw(*polyp);
373 if(idxColumn<0 || idxColumn>=
fNSegment[projAxis])
375 G4cerr <<
"Warning : Column number " << idxColumn <<
" is out of scoring mesh [0," <<
fNSegment[projAxis]-1 <<
376 "]. Method ignored." <<
G4endl;
383 std::vector<std::vector<std::vector<double> > > cell;
384 std::vector<double> ephi;
385 for(
int phi = 0; phi <
fNSegment[
IPHI]; phi++) ephi.push_back(0.);
386 std::vector<std::vector<double> > ezphi;
387 for(
int z = 0;
z < fNSegment[
IZ];
z++) ezphi.push_back(ephi);
388 for(
int r = 0; r < fNSegment[
IR]; r++) cell.push_back(ezphi);
390 std::vector<std::vector<double> > rzcell;
391 std::vector<double> ez;
392 for(
int z = 0;
z < fNSegment[
IZ];
z++) ez.push_back(0.);
393 for(
int r = 0; r < fNSegment[
IR]; r++) rzcell.push_back(ez);
395 std::vector<std::vector<double> > zphicell;
396 for(
int z = 0;
z < fNSegment[
IZ];
z++) zphicell.push_back(ephi);
398 std::vector<std::vector<double> > rphicell;
399 for(
int r = 0; r < fNSegment[
IR]; r++) rphicell.push_back(ephi);
403 std::map<G4int,G4StatDouble*>::iterator itr = map->
GetMap()->begin();
404 for(; itr != map->
GetMap()->end(); itr++) {
411 if(projAxis ==
IR && q[
IR] == idxColumn) {
414 if(projAxis ==
IZ && q[
IZ] == idxColumn) {
417 if(projAxis ==
IPHI && q[
IPHI] == idxColumn) {
424 G4double rzmax = 0., zphimax = 0., rphimax = 0.;
425 for(
int r = 0; r < fNSegment[
IR]; r++) {
426 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
427 if(rphimin > rphicell[r][phi]) rphimin = rphicell[r][phi];
428 if(rphimax < rphicell[r][phi]) rphimax = rphicell[r][phi];
430 for(
int z = 0;
z < fNSegment[
IZ];
z++) {
431 if(rzmin > rzcell[r][
z]) rzmin = rzcell[r][
z];
432 if(rzmax < rzcell[r][z]) rzmax = rzcell[r][
z];
435 for(
int z = 0;
z < fNSegment[
IZ];
z++) {
436 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
437 if(zphimin > zphicell[
z][phi]) zphimin = zphicell[
z][phi];
438 if(zphimax < zphicell[
z][phi]) zphimax = zphicell[
z][phi];
457 fSize[0]/fNSegment[
IR]*(idxColumn+1)};
458 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
459 for(
int z = 0;
z < fNSegment[
IZ];
z++) {
463 G4Tubs cylinder(
"z-phi", rsize[0], rsize[1], zhalf,
464 angle, dphi*0.99999);
481 pVisManager->
Draw(*poly);
486 }
else if(projAxis ==
IZ) {
490 for(
int phi = 0; phi < fNSegment[
IPHI]; phi++) {
491 for(
int r = 0; r < fNSegment[
IR]; r++) {
493 G4double rs[2] = {rsize*r, rsize*(r+1)};
497 G4Tubs cylinder(
"r-phi", rs[0], rs[1], dz,
498 angle, dphi*0.99999);
515 pVisManager->
Draw(*poly);
520 }
else if(projAxis ==
IPHI) {
527 for(
int z = 0;
z < fNSegment[
IZ];
z++) {
528 for(
int r = 0; r < fNSegment[
IR]; r++) {
530 G4double rs[2] = {rsize*r, rsize*(r+1)};
531 G4Tubs cylinder(
"z-phi", rs[0], rs[1], zhalf,
550 pVisManager->
Draw(*poly);
570 G4int jk = fNSegment[j]*fNSegment[k];
572 q[j] = (index - q[i]*jk)/fNSegment[k];
573 q[k] = index - q[j]*fNSegment[k] - q[i]*jk;
virtual void BeginDraw(const G4Transform3D &objectTransformation=G4Transform3D())=0
CLHEP::Hep3Vector G4ThreeVector
void SetForceAuxEdgeVisible(G4bool=true)
G4ThreeVector fCenterPosition
virtual void Draw(const G4Circle &, const G4Transform3D &objectTransformation=G4Transform3D())=0
G4LogicalVolume * GetLogicalVolume() const
virtual void DrawColorChart(G4int nPoint=5)
G4bool IfFloatMinMax() const
virtual void SetupGeometry(G4VPhysicalVolume *fWorldPhys)
virtual void List() const
static G4VVisManager * GetConcreteInstance()
virtual void GetMapColor(G4double val, G4double color[4])=0
void SetPSUnit(G4String &unit)
void SetPSName(G4String &psName)
virtual void List() const
HepPolyhedron & Transform(const G4Transform3D &t)
static constexpr double twopi
static constexpr double rad
G4ScoringCylinder(G4String wName)
void SetVisAttributes(const G4VisAttributes *pVA)
virtual void DrawColumn(RunScore *map, G4VScoreColorMap *colorMap, G4int idxProj, G4int idxColumn)
G4GLOB_DLL std::ostream G4cerr
void GetRZPhi(G4int index, G4int q[3]) const
void SetForceSolid(G4bool=true)
void SetVisibility(G4bool=true)
G4RotationMatrix * fRotationMatrix
virtual void Draw(RunScore *map, G4VScoreColorMap *colorMap, G4int axflg=111)
virtual G4Polyhedron * GetPolyhedron() const
static constexpr double radian
static constexpr double cm
G4GLOB_DLL std::ostream G4cout
void SetColour(const G4Colour &)
G4LogicalVolume * fMeshElementLogical
G4String fDivisionAxisNames[3]
static G4int GetReplicaLevel()
G4MultiFunctionalDetector * fMFD
void SetVisAttributes(const G4VisAttributes *)
void SetMinMax(G4double minVal, G4double maxVal)
void SetSensitiveDetector(G4VSensitiveDetector *pSDetector)