394{
395
396 double TCL_BOX_halflength, TCL_BOX_halfwidth, TCL_BOX_halfheight, TCL_BOX_sideThickness, TCL_BOX_topBottomThickness, TCL_BOX_endThickness, TCL_TUBE_halflength, TCL_TUBE_halfapperture, TCL_TUBE_thickness;
397 TCL_BOX_sideThickness = 6*Gaudi::Units::mm;
398 TCL_BOX_topBottomThickness = 18*Gaudi::Units::mm;
399 TCL_BOX_endThickness = 18*Gaudi::Units::mm;
400
401 TCL_BOX_halflength = 621*Gaudi::Units::mm;
402 TCL_BOX_halfwidth = 132*Gaudi::Units::mm;
403 TCL_BOX_halfheight = 60+TCL_BOX_topBottomThickness;
404
405 TCL_TUBE_halflength = 59.5*Gaudi::Units::mm;
406 TCL_TUBE_halfapperture = 53*Gaudi::Units::mm;
407 TCL_TUBE_thickness = 2*Gaudi::Units::mm;
408
409 double TCL_CuBlock_halflength, TCL_CuBlock_halfwidth, TCL_CuBlock_halfheight, TCL_CuBlockCylCut_zDepth, TCL_CuBlockCylCut_angle, TCL_CuBlockCylCut_cylR, TCL_CuBlockCylCut_cylHalflength, TCL_CuBlockCylCut_xDepth, TCL_CuBlockCylCut_xShift;
410 TCL_CuBlock_halflength = 597*Gaudi::Units::mm;
411 TCL_CuBlock_halfwidth = 14.5*Gaudi::Units::mm;
412 TCL_CuBlock_halfheight = 40*Gaudi::Units::mm;
413
414 TCL_CuBlockCylCut_zDepth = 90*Gaudi::Units::mm;
415 TCL_CuBlockCylCut_angle = 12*Gaudi::Units::deg;
416 TCL_CuBlockCylCut_cylR = 40*Gaudi::Units::mm;
417
418 TCL_CuBlockCylCut_cylHalflength = TCL_CuBlockCylCut_zDepth/
cos(TCL_CuBlockCylCut_angle);
419 TCL_CuBlockCylCut_xDepth = TCL_CuBlockCylCut_zDepth*
tan(TCL_CuBlockCylCut_angle);
420 TCL_CuBlockCylCut_xShift = -TCL_CuBlock_halfwidth-TCL_CuBlockCylCut_cylR/
cos(TCL_CuBlockCylCut_angle)+TCL_CuBlockCylCut_xDepth;
421
422 double TCL_CuBeam_halflength, TCL_CuBeam_halfwidth, TCL_CuBeam_halfheight, TCL_Cooling_width;
423 TCL_CuBeam_halflength = 530*Gaudi::Units::mm;
424 TCL_CuBeam_halfwidth = 15*Gaudi::Units::mm;
425 TCL_CuBeam_halfheight = 40*Gaudi::Units::mm;
426
427 TCL_Cooling_width = 9*Gaudi::Units::mm;
428
429
430
431
432 GeoTrf::Transform3D rotateX180 = GeoTrf::RotateX3D(180*Gaudi::Units::deg);
433 GeoTrf::Transform3D rotateY180 = GeoTrf::RotateY3D(180*Gaudi::Units::deg);
434
435
436 const GeoBox * boxIn = new GeoBox(TCL_BOX_halfwidth-TCL_BOX_sideThickness, TCL_BOX_halfheight-TCL_BOX_topBottomThickness, TCL_BOX_halflength-TCL_BOX_endThickness);
437 const GeoTube * tubeIn = new GeoTube(0, TCL_TUBE_halfapperture, TCL_TUBE_halflength+0.5*TCL_BOX_endThickness);
438 GeoTrf::Transform3D moveTubeIn = GeoTrf::Translate3D(0, 0, TCL_BOX_halflength+TCL_TUBE_halflength-0.5*TCL_BOX_endThickness);
439 const GeoShapeShift& tubeIn1 = (*tubeIn)<<moveTubeIn;
440 const GeoShapeShift& tubeIn2 = (*tubeIn)<<moveTubeIn<<rotateY180;
441 const GeoShapeUnion * innerVac0 = new GeoShapeUnion(boxIn,&tubeIn1);
442 GeoShapeUnion * innerVac = new GeoShapeUnion(innerVac0,&tubeIn2);
443
444
445 const GeoBox * boxFull = new GeoBox(TCL_BOX_halfwidth, TCL_BOX_halfheight, TCL_BOX_halflength);
446 const GeoTube * tubeOut = new GeoTube(TCL_TUBE_halfapperture, TCL_TUBE_halfapperture+TCL_TUBE_thickness, TCL_TUBE_halflength);
447 GeoTrf::Transform3D moveTubeOut = GeoTrf::Translate3D(0, 0, TCL_BOX_halflength+TCL_TUBE_halflength);
448 const GeoShapeShift& tubeOut1 = (*tubeOut)<<moveTubeOut;
449 const GeoShapeShift& tubeOut2 = (*tubeOut)<<moveTubeOut<<rotateY180;
450 const GeoShapeUnion * outerSteelFull0 = new GeoShapeUnion(boxFull,&tubeOut1);
451 const GeoShapeUnion * outerSteelFull = new GeoShapeUnion(outerSteelFull0,&tubeOut2);
452 GeoShapeSubtraction * outerSteel = new GeoShapeSubtraction(outerSteelFull,innerVac);
453
454
455 const GeoBox * cuBoxFull = new GeoBox(TCL_CuBlock_halfwidth, TCL_CuBlock_halfheight, TCL_CuBlock_halflength);
456 const GeoTube * cylCut0 = new GeoTube(0, TCL_CuBlockCylCut_cylR, TCL_CuBlockCylCut_cylHalflength);
457 GeoTrf::Transform3D rotateCylCut = GeoTrf::RotateY3D(TCL_CuBlockCylCut_angle);
458 GeoTrf::Transform3D moveCylCut = GeoTrf::Translate3D(TCL_CuBlockCylCut_xShift, 0, TCL_CuBlock_halflength);
459 const GeoShapeShift& cylCut1 = (*cylCut0)<<rotateCylCut<<moveCylCut;
460 const GeoShapeShift& cylCut2 = (*cylCut0)<<rotateCylCut<<moveCylCut<<rotateX180;
461 const GeoShapeSubtraction * cuBox0 = new GeoShapeSubtraction(cuBoxFull, &cylCut1);
462 const GeoShapeSubtraction * cuBox1 = new GeoShapeSubtraction(cuBox0, &cylCut2);
463 GeoTrf::Transform3D moveCuBoxI = GeoTrf::Translate3D(TCLJawDistI+TCL_CuBlock_halfwidth, 0, 0);
464 const GeoShapeShift& cuBoxI = (*cuBox1)<<moveCuBoxI;
465 GeoTrf::Transform3D moveCuBoxO = GeoTrf::Translate3D(+TCLJawDistO+TCL_CuBlock_halfwidth, 0, 0);
466 const GeoShapeShift& cuBoxO = (*cuBox1)<<moveCuBoxO<<rotateY180;
467
468
469 const GeoBox * cuBeamFull = new GeoBox(TCL_CuBeam_halfwidth, TCL_CuBeam_halfheight, TCL_CuBeam_halflength);
470 GeoTrf::Transform3D moveCuBeamI = GeoTrf::Translate3D(TCLJawDistI+2*TCL_CuBlock_halfwidth+TCL_Cooling_width+TCL_CuBeam_halfwidth, 0, 0);
471 const GeoShapeShift& cuBeamI = (*cuBeamFull)<<moveCuBeamI;
472 GeoTrf::Transform3D moveCuBeamO = GeoTrf::Translate3D(+TCLJawDistO+2*TCL_CuBlock_halfwidth+TCL_Cooling_width+TCL_CuBeam_halfwidth, 0, 0);
473 const GeoShapeShift& cuBeamO = (*cuBeamFull)<<moveCuBeamO<<rotateY180;
474
475
476 const GeoBox * waterBox = new GeoBox(0.5*TCL_Cooling_width, TCL_CuBlock_halfheight, TCL_CuBlock_halflength);
477 GeoTrf::Transform3D moveWaterBoxI = GeoTrf::Translate3D(TCLJawDistI+2*TCL_CuBlock_halfwidth+0.5*TCL_Cooling_width, 0, 0);
478 const GeoShapeShift& waterBoxI = (*waterBox)<<moveWaterBoxI;
479 GeoTrf::Transform3D moveWaterBoxO = GeoTrf::Translate3D(+TCLJawDistO+2*TCL_CuBlock_halfwidth+0.5*TCL_Cooling_width, 0, 0);
480 const GeoShapeShift& waterBoxO = (*waterBox)<<moveWaterBoxO<<rotateY180;
481
482
483
484 const GeoLogVol *ringLog =
new GeoLogVol(name+
"Log", outerSteel,
m_MapMaterials[std::string(
"Steel")]);
485 const GeoLogVol *ringLog2 =
new GeoLogVol(name+
"Fill", innerVac,
m_MapMaterials[std::string(
"std::Vacuum")]);
486
487 GeoPhysVol *ringPhys = new GeoPhysVol(ringLog);
488 GeoPhysVol *ringPhys2 = new GeoPhysVol(ringLog2);
489
490 const GeoLogVol *cuBoxLogI =
new GeoLogVol(name+
"CuBoxI", &cuBoxI,
m_MapMaterials[std::string(tungstenInsteadOfCopper ?
"Tungsten" :
"Copper")]);
491 GeoPhysVol *cuBoxPhysI = new GeoPhysVol(cuBoxLogI);
492 const GeoLogVol *cuBoxLogO =
new GeoLogVol(name+
"CuBoxO", &cuBoxO,
m_MapMaterials[std::string(tungstenInsteadOfCopper ?
"Tungsten" :
"Copper")]);
493 GeoPhysVol *cuBoxPhysO = new GeoPhysVol(cuBoxLogO);
494
495 const GeoLogVol *cuBeamLogI =
new GeoLogVol(name+
"CuBeamI", &cuBeamI,
m_MapMaterials[std::string(
"GlidCopAL15")]);
496 GeoPhysVol *cuBeamPhysI = new GeoPhysVol(cuBeamLogI);
497 const GeoLogVol *cuBeamLogO =
new GeoLogVol(name+
"CuBeamO", &cuBeamO,
m_MapMaterials[std::string(
"GlidCopAL15")]);
498 GeoPhysVol *cuBeamPhysO = new GeoPhysVol(cuBeamLogO);
499
500 const GeoLogVol *waterBoxLogI =
new GeoLogVol(name+
"waterBoxI", &waterBoxI,
m_MapMaterials[std::string(
"water")]);
501 GeoPhysVol *waterBoxPhysI = new GeoPhysVol(waterBoxLogI);
502 const GeoLogVol *waterBoxLogO =
new GeoLogVol(name+
"waterBoxO", &waterBoxO,
m_MapMaterials[std::string(
"water")]);
503 GeoPhysVol *waterBoxPhysO = new GeoPhysVol(waterBoxLogO);
504
505
506 GeoTransform *move =
new GeoTransform(GeoTrf::Translate3D(
x,
y,
z));
507 fwrPhys->add(move);
508
509 GeoNameTag *
tag =
new GeoNameTag(name);
510 fwrPhys->add(tag);
511
512 fwrPhys->add(ringPhys);
513
514
515 fwrPhys->add(move);
516 tag =
new GeoNameTag(name+
"Fill");
517 fwrPhys->add(tag);
518 fwrPhys->add(ringPhys2);
519
520
521 ringPhys2->add(cuBoxPhysI);
522 ringPhys2->add(cuBoxPhysO);
523
524 ringPhys2->add(cuBeamPhysI);
525 ringPhys2->add(cuBeamPhysO);
526
527 ringPhys2->add(waterBoxPhysI);
528 ringPhys2->add(waterBoxPhysO);
529}