diff --git a/data/MATERIALS.ratdb b/data/MATERIALS.ratdb index fa53a409..b5e2d9be 100644 --- a/data/MATERIALS.ratdb +++ b/data/MATERIALS.ratdb @@ -671,6 +671,18 @@ elements: ["Hydrogen", "Carbon", "Oxygen"], elemprop: [0.0703, 0.558, 0.3717], } +{ +name: "MATERIAL", +index: "nakano_acrylic", +valid_begin : [0, 0], +valid_end : [0, 0], +density: 1.14, +nelements: 3, +nmaterials: 0, +elements: ["Hydrogen", "Carbon", "Oxygen"], +elemprop: [0.0703, 0.558, 0.3717], +} + { name: "MATERIAL", index: "acrylic_polycast", @@ -863,18 +875,6 @@ elements: ["Hydrogen", "Carbon", "Chlorine"], elemprop: [0.0484, 0.3844, 0.5672], } -{ -name: "MATERIAL", -index: "eljen_WLSP", -valid_begin : [0, 0], -valid_end : [0, 0], -density: 1.0, -nelements: 2, -nmaterials: 0, -elements: ["Carbon","Hydrogen"], -elemprop: [0.4737, 0.5263,], -formula: "AROMATIC", -} // ------------------ Gunite --------------------- //Place holder for when we get more info diff --git a/data/OPTICS.ratdb b/data/OPTICS.ratdb index 4b6d484a..3b8653f9 100644 --- a/data/OPTICS.ratdb +++ b/data/OPTICS.ratdb @@ -781,7 +781,20 @@ ABSLENGTH_value2: [1.0e-3, 1.0e-3, 0.49e1, 2.75e1, 10.35e1, 14.99e1, 20.41e1, 28 PROPERTY_LIST: ["RINDEX", "ABSLENGTH", ] } - +{ +name : "OPTICS", +index : "nakano_acrylic", +valid_begin: [0, 0], +valid_end: [0, 0], +//this is taken from the: "acrylic_uvt_good"// +RINDEX_option: "wavelength", +RINDEX_value1: [60.0, 200.0, 210.0, 220.0, 230.0, 240.0, 250.0, 260.0, 270.0, 280.0, 290.0, 300.0, 310.0, 320.0, 330.0, 340.0, 350.0, 360.0, 370.0, 380.0, 390.0, 400.0, 410.0, 420.0, 430.0, 440.0, 450.0, 460.0, 470.0, 480.0, 490.0, 500.0, 510.0, 520.0, 530.0, 540.0, 550.0, 560.0, 570.0, 580.0, 590.0, 600.0, 610.0, 620.0, 630.0, 640.0, 650.0, 660.0, 670.0, 680.0, 690.0, 700.0, 710.0, 720.0, 730.0, 740.0, 750.0, 760.0, 770.0, 780.0, 790.0, 800.0, ], +RINDEX_value2: [1.597, 1.597, 1.584, 1.573, 1.564, 1.556, 1.550, 1.544, 1.539, 1.534, 1.531, 1.527, 1.524, 1.521, 1.519, 1.516, 1.514, 1.512, 1.510, 1.509, 1.507, 1.506, 1.505, 1.503, 1.502, 1.501, 1.500, 1.499, 1.499, 1.498, 1.497, 1.496, 1.496, 1.495, 1.494, 1.494, 1.493, 1.493, 1.492, 1.492, 1.491, 1.491, 1.490, 1.490, 1.490, 1.489, 1.489, 1.488, 1.488, 1.488, 1.488, 1.487, 1.487, 1.487, 1.486, 1.486, 1.486, 1.486, 1.485, 1.485, 1.485, 1.485, ], +ABSLENGTH_option : "wavelength", +ABSLENGTH_value1 : [200.0, 201.0, 202.0, 203.0, 204.0, 205.0, 206.0, 207.0, 208.0, 210.0, 211.0, 212.0, 215.0, 217.0, 218.0, 219.0, 220.0, 221.0, 223.0, 224.0, 226.0, 227.0, 228.0, 229.0, 232.0, 233.0, 235.0, 236.0, 237.0, 238.0, 239.0, 241.0, 242.0, 243.0, 244.0, 245.0, 247.0, 248.0, 249.0, 250.0, 251.0, 252.0, 253.0, 254.0, 255.0, 256.0, 257.0, 258.0, 259.0, 260.0, 261.0, 262.0, 263.0, 264.0, 265.0, 266.0, 267.0, 268.0, 269.0, 270.0, 271.0, 272.0, 273.0, 274.0, 275.0, 276.0, 277.0, 278.0, 279.0, 280.0, 281.0, 282.0, 283.0, 284.0, 285.0, 286.0, 287.0, 288.0, 289.0, 290.0, 291.0, 292.0, 293.0, 294.0, 295.0, 296.0, 297.0, 298.0, 299.0, 300.0, 301.0, 302.0, 303.0, 304.0, 305.0, 306.0, 307.0, 308.0, 309.0, 310.0, 311.0, 312.0, 313.0, 314.0, 315.0, 316.0, 317.0, 318.0, 319.0, 320.0, 321.0, 322.0, 323.0, 324.0, 325.0, 326.0, 327.0, 328.0, 329.0, 330.0, 331.0, 332.0, 333.0, 334.0, 335.0, 336.0, 337.0, 338.0, 339.0, 340.0, 341.0, 342.0, 343.0, 344.0, 345.0, 346.0, 347.0, 348.0, 349.0, 350.0, 351.0, 352.0, 353.0, 354.0, 355.0, 356.0, 357.0, 358.0, 359.0, 360.0, 361.0, 362.0, 363.0, 364.0, 365.0, 366.0, 367.0, 368.0, 369.0, 370.0, 371.0, 372.0, 373.0, 374.0, 375.0, 376.0, 377.0, 378.0, 379.0, 380.0, 381.0, 382.0, 383.0, 384.0, 385.0, 386.0, 387.0, 388.0, 389.0, 390.0, 391.0, 392.0, 393.0, 394.0, 395.0, 396.0, 397.0, 398.0, 399.0, 400.0, 401.0, 402.0, 403.0, 404.0, 405.0, 406.0, 407.0, 408.0, 409.0, 410.0, 411.0, 412.0, 413.0, 414.0, 415.0, 416.0, 417.0, 418.0, 419.0, 420.0, 421.0, 422.0, 423.0, 424.0, 425.0, 426.0, 427.0, 428.0, 429.0, 430.0, 431.0, 432.0, 433.0, 434.0, 435.0, 436.0, 437.0, 438.0, 439.0, 440.0, 441.0, 442.0, 443.0, 444.0, 445.0, 446.0, 447.0, 448.0, 449.0, 450.0, 451.0, 452.0, 453.0, 454.0, 455.0, 456.0, 457.0, 458.0, 459.0, 460.0, 461.0, 462.0, 463.0, 464.0, 465.0, 466.0, 467.0, 468.0, 469.0, 470.0, 471.0, 472.0, 473.0, 474.0, 475.0, 476.0, 477.0, 478.0, 479.0, 480.0, 481.0, 482.0, 483.0, 484.0, 485.0, 486.0, 487.0, 488.0, 489.0, 490.0, 491.0, 492.0, 493.0, 494.0, 495.0, 496.0, 497.0, 498.0, 499.0, 500.0, 501.0, 502.0, 503.0, 504.0, 505.0, 506.0, 507.0, 508.0, 509.0, 510.0, 511.0, 512.0, 513.0, 514.0, 515.0, 516.0, 517.0, 518.0, 519.0, 520.0, 521.0, 522.0, 523.0, 524.0, 525.0, 526.0, 527.0, 528.0, 529.0, 530.0, 531.0, 532.0, 533.0, 534.0, 535.0, 536.0, 537.0, 538.0, 539.0, 540.0, 541.0, 542.0, 543.0, 544.0, 545.0, 546.0, 547.0, 548.0, 549.0, 550.0, 551.0, 552.0, 553.0, 554.0, 555.0, 556.0, 557.0, 558.0, 559.0, 560.0, 561.0, 562.0, 563.0, 564.0, 565.0, 566.0, 567.0, 568.0, 569.0, 570.0, 571.0, 572.0, 573.0, 574.0, 575.0, 576.0, 577.0, 578.0, 579.0, 580.0, 581.0, 582.0, 583.0, 584.0, 585.0, 586.0, 587.0, 588.0, 589.0, 590.0, 591.0, 592.0, 593.0, 594.0, 595.0, 596.0, 597.0, 598.0, 599.0, 600.0, 601.0, 602.0, 603.0, 604.0, 605.0, 606.0, 607.0, 608.0, 609.0, 610.0, 611.0, 612.0, 613.0, 614.0, 615.0, 616.0, 617.0, 618.0, 619.0, 620.0, 621.0, 622.0, 623.0, 624.0, 625.0, 626.0, 627.0, 628.0, 629.0, 630.0, 631.0, 632.0, 633.0, 634.0, 635.0, 636.0, 637.0, 638.0, 639.0, 640.0, 641.0, 642.0, 643.0, 644.0, 645.0, 646.0, 647.0, 648.0, 649.0, 650.0], +ABSLENGTH_value2 : [6.766646, 6.766646, 6.106986, 6.106986, 5.086679, 5.234611, 5.902842, 4.893309, 5.234611, 5.234611, 5.234611, 5.234611, 4.893309, 5.84476, 5.466055, 5.086679, 5.234611, 4.893309, 5.086679, 5.234611, 5.355951, 5.466055, 5.637248, 5.637248, 4.573503, 4.573503, 4.893309, 4.573503, 5.234611, 5.355951, 5.086679, 5.234611, 5.234611, 5.086679, 5.086679, 5.086679, 4.893309, 5.234611, 5.466055, 5.355951, 4.893309, 5.466055, 5.355951, 5.234611, 5.466055, 5.466055, 5.466055, 5.355951, 5.556357, 5.466055, 5.234611, 5.466055, 5.782536, 5.84476, 5.466055, 5.556357, 5.637248, 5.902842, 5.782536, 5.466055, 5.556357, 5.957376, 5.84476, 5.466055, 5.902842, 5.902842, 5.84476, 5.710734, 5.957376, 5.782536, 5.902842, 6.151102, 6.351271, 6.275325, 6.236473, 6.151102, 6.106986, 6.196074, 6.351271, 6.151102, 6.351271, 6.766646, 7.208724, 8.193268, 9.868894, 11.880833, 14.244282, 16.784146, 19.717709, 23.049586, 26.544354, 30.195035, 34.219501, 38.321886, 42.39765, 46.533259, 50.832953, 54.948511, 58.922905, 63.085969, 67.41336, 71.748641, 76.120996, 80.767293, 85.202911, 89.821651, 94.348418, 98.754483, 103.012398, 107.681056, 112.008174, 115.824833, 119.440937, 123.252061, 127.16593, 132.325345, 138.370286, 144.227796, 150.049118, 156.658243, 163.287528, 170.370174, 176.796012, 182.930312, 188.820709, 194.353756, 199.864259, 205.589488, 209.876284, 216.19017, 222.810381, 227.815651, 232.801149, 238.132189, 243.486785, 249.15384, 255.109166, 260.232763, 264.958051, 271.619689, 277.810437, 283.393802, 289.664446, 295.411718, 300.792124, 307.391599, 314.538422, 320.976971, 326.690368, 332.629732, 339.013314, 345.045319, 351.023973, 357.949102, 364.397882, 370.92331, 376.497665, 384.094671, 389.787601, 397.409983, 403.865868, 410.067323, 416.681403, 422.050509, 429.345314, 434.771993, 440.719417, 445.811451, 451.43275, 457.327331, 460.508839, 464.304619, 470.003848, 473.055345, 476.825729, 480.345269, 482.357526, 485.480714, 489.044336, 490.963178, 493.948192, 496.811707, 498.870234, 500.366134, 502.035214, 502.370299, 502.452762, 502.959098, 503.041744, 504.472855, 505.661163, 506.597773, 506.765371, 508.390937, 508.908706, 509.421833, 511.501276, 513.327622, 513.499477, 515.258672, 516.489989, 517.290734, 517.465122, 519.425929, 521.035411, 521.849624, 523.568564, 524.110178, 525.112888, 526.942644, 527.406503, 528.784576, 529.622008, 531.200547, 532.321296, 534.483581, 534.675357, 535.716939, 535.716939, 537.711638, 539.242129, 539.726836, 540.395456, 540.977048, 541.654968, 541.458395, 541.750133, 542.722638, 544.082073, 545.358034, 546.433226, 547.124249, 547.616082, 549.103165, 549.402809, 549.702766, 550.401701, 551.397501, 552.600961, 553.710197, 553.306948, 553.306948, 554.319438, 554.624538, 555.841487, 556.348386, 556.856167, 556.856167, 558.492409, 559.421894, 558.391556, 560.557435, 560.34757, 561.072579, 562.214531, 562.418919, 562.214531, 563.983763, 564.614778, 565.033912, 565.556944, 567.034673, 567.665291, 569.258173, 568.192988, 567.561251, 567.984574, 569.153575, 568.937521, 569.258173, 568.833034, 568.624172, 568.408502, 568.088763, 566.6127, 565.977416, 565.770552, 564.086554, 563.046592, 561.901413, 561.384816, 560.34757, 560.246076, 560.036433, 558.391556, 558.70095, 558.189954, 558.492409, 559.523103, 561.276174, 562.105583, 562.944163, 565.033912, 565.660284, 566.398485, 566.923934, 567.665291, 568.833034, 570.110275, 570.754456, 570.754456, 573.005963, 573.111919, 572.469695, 573.005963, 574.734174, 576.036885, 577.345253, 576.586709, 576.586709, 576.908499, 578.443502, 577.567452, 577.897468, 579.213936, 579.762353, 579.762353, 580.869419, 581.75508, 581.52979, 582.533976, 582.417379, 582.643326, 583.307562, 583.534171, 582.978913, 583.088423, 582.862145, 584.090441, 584.427625, 584.985526, 583.87074, 583.87074, 584.317633, 583.87074, 582.978913, 584.090441, 584.427625, 584.655067, 583.088423, 583.197973, 586.333085, 586.561948, 585.772723, 585.772723, 586.333085, 587.464299, 586.451186, 586.67275, 586.561948, 587.805219, 587.694008, 588.934436, 589.053543, 588.822816, 589.508059, 588.822816, 589.508059, 589.963247, 591.332857, 591.678088, 590.531309, 590.075282, 590.075282, 591.100419, 591.332857, 590.306949, 590.763319, 590.187357, 589.843789, 590.075282, 590.763319, 589.843789, 590.306949, 589.843789, 589.619928, 587.464299, 586.901867, 586.111767, 584.537656, 583.534171, 581.52979, 579.654034, 577.567452, 575.495184, 572.794163, 570.432192, 567.880422, 566.191327, 564.504939, 564.717789, 564.923918, 563.668761, 563.983763, 564.402003, 566.820153, 567.984574, 569.579171, 571.182345, 572.900044, 573.005963, 573.543192, 573.868825, 574.407602, 574.954456, 575.388384, 575.167785, 576.036885, 576.258122, 576.801198, 577.459916, 578.774476, 577.345253, 578.774476, 577.459916, 577.897468, 576.908499, 576.365231, 577.130377, 578.227844, 578.11289, 577.789814, 575.495184, 576.151052, 577.567452, 577.130377, 575.495184, 573.22498, 572.251229, 570.642325, 572.039962, 570.327181, 569.362809, 567.242421, 566.191327, 565.977416, 565.033912, 563.778289, 560.970834, 559.421894], +PROPERTY_LIST: ["RINDEX","ABSLENGTH"] +} { name: "OPTICS", @@ -942,51 +955,3 @@ ABSLENGTH_value1: [60.0, 200.0, 400.0, 600.0, 800.0, ], ABSLENGTH_value2: [1e-3, 1e-3, 1.6e-1, 2.1e-1, 2.5e-1, ], PROPERTY_LIST: ["REFLECTIVITY", "ABSLENGTH", ] } - -//Based on values provided by Eljen -{ -name: "OPTICS", -index: "eljen_WLSP", -valid_begin : [0, 0], -valid_end : [0, 0], -surface: 1, -finish: "polished", -model: "unified", -polish: 0.9, -LIGHT_YIELD: 0.0, //Does not scintillate! -RINDEX_option: "wavelength", -RINDEX_value1: [430.0, 455.0, 480.0, 510.0, 545.0, 589.26, ], -RINDEX_value2: [1.605, 1.6, 1.595, 1.59, 1.585, 1.58, ], -SCINTILLATION_option: "dy_dwavelength", -SCINTILLATION_value1: [360.0,365.0,370.0,375.0,380.0,385.0,390.0,395.0,400.0,405.0,410.0,415.0,420.0,425.0,430.0,435.0,440.0, -445.0,450.0,455.0,460.0,465.0,470.0,475.0,480.0,485.0,490.0,495.0,500.0,505.0,510.0,515.0,520.0, -525.0,530.0 ], -SCINTILLATION_value2: [0.0089,0.04,0.1082,0.38,0.6702,0.8,0.74,0.7118,0.8559,0.99,0.98,0.8,0.6667,0.645,0.623,0.57,0.4956, -0.4,0.3289,0.28,0.2388,0.21,0.1848,0.15,0.1125,0.09,0.0721,0.06,0.0496,0.038,0.027,0.021,0.0181, -0.01,0.0089 ], -SCINTILLATION_WLS_option: "dy_dwavelength", -SCINTILLATION_WLS_value1: [360.0,365.0,370.0,375.0,380.0,385.0,390.0,395.0,400.0,405.0,410.0,415.0,420.0,425.0,430.0,435.0,440.0, -445.0,450.0,455.0,460.0,465.0,470.0,475.0,480.0,485.0,490.0,495.0,500.0,505.0,510.0,515.0,520.0, -525.0,530.0 ], -SCINTILLATION_WLS_value2: [0.0089,0.04,0.1082,0.38,0.6702,0.8,0.74,0.7118,0.8559,0.99,0.98,0.8,0.6667,0.645,0.623,0.57,0.4956, -0.4,0.3289,0.28,0.2388,0.21,0.1848,0.15,0.1125,0.09,0.0721,0.06,0.0496,0.038,0.027,0.021,0.0181, -0.01,0.0089 ], //Repeated from the SCINTILLATION field -ABSLENGTH_option: "wavelength", -ABSLENGTH_value1: [280.0,285.0,290.0,295.0,300.0,305.0,310.0,315.0,320.0,325.0,330.0, -335.0,340.0,345.0,350.0,355.0,360.0,365.0,370.0,375.0,380.0,385.0,390.0,395.0,400.0,405.0,410.0, -415.0,420.0,425.0,430.0,435.0,440.0 ], -ABSLENGTH_value2: [3.28817572011048,2.75133439718263,2.13990712803064,1.63409373161645,1.22558031227786,0.949388119357074,0.74896268667895, -0.612790156138932,0.499310950887775,0.426624800552906,0.3643611110099,0.320985038887337,0.285622070588639,0.256788195960208,0.242907702360334, -0.240738779165503,0.247364333031549,0.264081484983006,0.299585972186438,0.35950273581582,0.449379631418826,0.601847672354127,0.842587755514737, -1.3481449525453,2.6962899050906,7.09521782318717,53.9257981018119,963.391136801541,2450.98039215686,4484.30493273543,9615.38461538462,33333.3333333333, -142857.142857143], -SCINTWAVEFORM_value1: [-1.1], -SCINTWAVEFORM_value2: [1.0], -SCINT_RISE_TIME: 0.1, -REEMISSION_PROB_option: "wavelength", -REEMISSION_PROB_value1: [280.0,530.0 ], -REEMISSION_PROB_value2: [0.92,0.92], //Constant quantum efficiency used -SCINTMOD_value1: [1.0, ], -SCINTMOD_value2: [0.0, ], //Not necessarily needed because it does not scintillate -PROPERTY_LIST: ["LIGHT_YIELD", "RINDEX", "SCINTILLATION", "SCINTILLATION_WLS", "ABSLENGTH", "SCINT_RISE_TIME", "SCINTWAVEFORM", "REEMISSION_PROB","SCINTMOD"] -} diff --git a/data/Watchman/Watchman.geo b/data/Watchman/Watchman.geo index 74b20e2d..a9447704 100644 --- a/data/Watchman/Watchman.geo +++ b/data/Watchman/Watchman.geo @@ -686,8 +686,13 @@ end_idx: 3257, //idx of the last pmt start_idx: 0, //idx of the first pmt pmt_model: "r7081pe", mu_metal: 0, -mu_metal_material: "aluminum", -mu_metal_surface: "aluminum", +mu_metal_material: "acrylic", +mu_metal_surface: "acrylic", +encapsulation: 0, +encapsulation_material:"nakano_acrylic", +encapsulation_surface: "nakano_acrylic", +//enc_radius = 17.5, //encapsualtion radius in cm +//enc_thickness = 0.635, //encapsualtion thickness in cm light_cone: 0, light_cone_material: "aluminum", light_cone_surface: "aluminum", diff --git a/mac/mywatchman_visualize_geofile_lightcones.mac b/mac/mywatchman_visualize_geofile_lightcones.mac new file mode 100644 index 00000000..7d1a16d3 --- /dev/null +++ b/mac/mywatchman_visualize_geofile_lightcones.mac @@ -0,0 +1,45 @@ +/glg4debug/glg4param omit_muon_processes 1.0 +/glg4debug/glg4param omit_hadronic_processes 1.0 + +/rat/db/set DETECTOR experiment "Watchman" +/rat/db/set GEO[inner_pmts] light_cone 0 +/rat/db/set GEO[inner_pmts] encapsulation 1 +/rat/db/set GEO[inner_pmts] mu_metal 0 +/rat/db/set GEO[inner_pmts] orientation "manual" #can change to "point" to have PMTs point to center + +#light cone material parameters +#/rat/db/set GEO[inner_pmts] light_cone_material "aluminum" +#/rat/db/set GEO[inner_pmts] light_cone_surface "aluminum" + +#light cone dimensional parameters for optimized geometry +#/rat/db/set GEO[inner_pmts] light_cone_length 14 +#/rat/db/set GEO[inner_pmts] light_cone_innerradius 12.65 +#/rat/db/set GEO[inner_pmts] light_cone_outerradius 23 +#/rat/db/set GEO[inner_pmts] light_cone_thickness 0.2 + +#/rat/db/set DETECTOR detector_factory "Watchman" +/rat/db/set DETECTOR geo_file "Watchman/Watchman.geo" +/rat/db/set WATCHMAN_PARAMS photocathode_coverage 0.0005 + + +# Visualize the calibration source +#/rat/db/load Watchman/DecayChamber.geo +#/rat/db/set GEO[sourcecan] posz 10000.0 + +/run/initialize + +/vis/open OGLSQt +/vis/scene/create +/vis/scene/add/volume +/vis/sceneHandler/attach +/vis/viewer/set/upVector 0.0 0.0 1.0 +/vis/viewer/set/viewpointThetaPhi -90 135 +/vis/viewer/set/style s +/vis/viewer/flush + +## Cut a plane through the detector +/vis/viewer/addCutawayPlane 0 0 0 cm 1 0 0 +#/vis/viewer/addCutawayPlane 0 -100 0 cm 0 1 0 +#/vis/viewer/set/viewpointThetaPhi -90 0 +#/vis/viewer/zoomTo 10 +#/vis/viewer/panTo 10 0 diff --git a/mac/positron_watchman.mac b/mac/positron_watchman.mac new file mode 100644 index 00000000..3c53f555 --- /dev/null +++ b/mac/positron_watchman.mac @@ -0,0 +1,44 @@ +/glg4debug/glg4param omit_muon_processes 1.0 +/glg4debug/glg4param omit_hadronic_processes 1.0 + +/rat/db/set DETECTOR experiment "Watchman" +#/rat/db/set GEO[inner_pmts] light_cone 1 +/rat/db/set GEO[inner_pmts] encapsulation 1 +#/rat/db/set GEO[inner_pmts] mu_metal 1 +#/rat/db/set GEO[inner_pmts] orientation "manual" #can change to "point" to have PMTs point to center + +#light cone material parameters +#/rat/db/set GEO[inner_pmts] light_cone_material "aluminum" +#/rat/db/set GEO[inner_pmts] light_cone_surface "aluminum" + +#light cone dimensional parameters for optimized geometry +#/rat/db/set GEO[inner_pmts] light_cone_length 14 +#/rat/db/set GEO[inner_pmts] light_cone_innerradius 12.65 +#/rat/db/set GEO[inner_pmts] light_cone_outerradius 23 +#/rat/db/set GEO[inner_pmts] light_cone_thickness 0.2 + +/rat/db/set DETECTOR detector_factory "Watchman" +#/rat/db/set DETECTOR geo_file "Watchman/Watchman.geo" +/rat/db/set WATCHMAN_PARAMS photocathode_coverage 0.25 + +#/rat/db/set DETECTOR experiment "Watchman" +#/rat/db/set DETECTOR detector_factory "Watchman" + +/run/initialize + +# BEGIN EVENT LOOP +/rat/proc simpledaq +/rat/proc count +/rat/procset update 10 + +/rat/proclast outroot +/rat/procset file "watchman_positronCentre_OM.root" +#END EVENT LOOP + +#/generator/add combo gun2:point +/generator/add combo gun:point +/generator/vtx/set e+ 0 0 0 10 +/generator/pos/set 0 0 0 + +/run/beamOn 10 #100 + diff --git a/mac/positron_watchman2.mac b/mac/positron_watchman2.mac new file mode 100644 index 00000000..16e55225 --- /dev/null +++ b/mac/positron_watchman2.mac @@ -0,0 +1,44 @@ +/glg4debug/glg4param omit_muon_processes 1.0 +/glg4debug/glg4param omit_hadronic_processes 1.0 + +/rat/db/set DETECTOR experiment "Watchman" +#/rat/db/set GEO[inner_pmts] light_cone 1 +/rat/db/set GEO[inner_pmts] encapsulation 0 +#/rat/db/set GEO[inner_pmts] mu_metal 1 +#/rat/db/set GEO[inner_pmts] orientation "manual" #can change to "point" to have PMTs point to center + +#light cone material parameters +#/rat/db/set GEO[inner_pmts] light_cone_material "aluminum" +#/rat/db/set GEO[inner_pmts] light_cone_surface "aluminum" + +#light cone dimensional parameters for optimized geometry +#/rat/db/set GEO[inner_pmts] light_cone_length 14 +#/rat/db/set GEO[inner_pmts] light_cone_innerradius 12.65 +#/rat/db/set GEO[inner_pmts] light_cone_outerradius 23 +#/rat/db/set GEO[inner_pmts] light_cone_thickness 0.2 + +/rat/db/set DETECTOR detector_factory "Watchman" +#/rat/db/set DETECTOR geo_file "Watchman/Watchman.geo" +/rat/db/set WATCHMAN_PARAMS photocathode_coverage 0.25 + +#/rat/db/set DETECTOR experiment "Watchman" +#/rat/db/set DETECTOR detector_factory "Watchman" + +/run/initialize + +# BEGIN EVENT LOOP +/rat/proc simpledaq +/rat/proc count +/rat/procset update 10 + +/rat/proclast outroot +/rat/procset file "watchman_positronCentre.root" +#END EVENT LOOP + +#/generator/add combo gun2:point +/generator/add combo gun:point +/generator/vtx/set e+ 0 0 0 10 +/generator/pos/set 0 0 0 + +/run/beamOn 10 #100 + diff --git a/mac/vis_gen_demo/mywm_vis_gen_demo.mac b/mac/vis_gen_demo/mywm_vis_gen_demo.mac new file mode 100644 index 00000000..7d5cee95 --- /dev/null +++ b/mac/vis_gen_demo/mywm_vis_gen_demo.mac @@ -0,0 +1,86 @@ +# +# demo for watchman visualisation +# gary.smith@ed.ac.uk +# 2nd May 2020 +# +# To run do: +# $ rat - wm_vis_gen_demo.mac +# (NB the dash starts the visualiser) +# +# Then in the interaction session type one +# of the commands at the end of this file +# to generate one beam particle e.g. +# Session: /control/execute gen_promptPositron.mac +# +# Various generators can be demonstrated +# - see comments in the respective files +# +# To generate many beam particles just run the +# macro then do e.g. +# Session: /run/beamOn N +# where N is the number of particles you want + +##### +/glg4debug/glg4param omit_muon_processes 1.0 +/glg4debug/glg4param omit_hadronic_processes 1.0 + +# geometry +/rat/db/set DETECTOR experiment "Watchman" +/rat/db/set GEO[inner_pmts] light_cone 0 + +# using detector factory allows modifications to geometry +# (instead of using a geo file) +#/rat/db/set DETECTOR detector_factory "Watchman" +/rat/db/set DETECTOR geo_file "Watchman.geo" + +# using very very low photocoverage for fast viewing here +# (NB usual coverage is 0.20 - 0.30) +#/rat/db/set WATCHMAN_PARAMS photocathode_coverage 0.05 #0.001 + +# commented out means no veto PMTs +#/rat/db/set WATCHMAN_PARAMS veto_coverage 0.02 +##### + +/run/initialize + +#### +# visualisation +/vis/open OGLSQt +/vis/scene/create +/vis/scene/add/trajectories rich smooth +/tracking/storeTrajectory 1 +/tracking/FillPointCont 1 +/vis/scene/add/volume +/vis/scene/add/hits +/vis/scene/add/trajectories +/vis/sceneHandler/attach + +/vis/viewer/set/upVector 0.0 0.0 1.0 +/vis/viewer/set/viewpointThetaPhi -90 135 +/vis/viewer/set/style s +/vis/viewer/flush + +# remove some of the detector to +# allow better viewing inside +#/vis/viewer/addCutawayPlane 0 -100 0 cm 0 1 0 +/vis/viewer/addCutawayPlane 0 0 0 cm 1 0 0 +#### + +### +# generator options +# comment out or execute in the interactive session +# +#/control/execute gen_Li8.mac +#/control/execute gen_electron_gun_point.mac +#/control/execute gen_muon_point_1_GeV.mac +#/control/execute gen_promptPositron.mac +#/control/execute gen_pbomb.mac +#/control/execute gen_promptPositron.mac +# +### + +### +# running +# remove comment out symbol or execute in the interactive session +# + #/run/beamOn 20 diff --git a/mac/watchman.mac b/mac/watchman.mac index abefd286..dede3e31 100644 --- a/mac/watchman.mac +++ b/mac/watchman.mac @@ -4,13 +4,15 @@ /rat/db/set DETECTOR experiment "Watchman" # Turn on mu metal, change surface and material -/rat/db/set GEO[inner_pmts] light_cone 0 -rat/db/set GEO[inner_pmts] light_cone_material "aluminum" -/rat/db/set GEO[inner_pmts] light_cone_surface "aluminum" -/rat/db/set GEO[inner_pmts] light_cone_length 11.5 -/rat/db/set GEO[inner_pmts] light_cone_innerradius 12.65 -/rat/db/set GEO[inner_pmts] light_cone_outerradius 26.0 -/rat/db/set GEO[inner_pmts] light_cone_thickness 0.2 +/rat/db/set GEO[inner_pmts] encapsulation 1 +#/rat/db/set GEO[inner_pmts] mu_metal 1 +#/rat/db/set GEO[inner_pmts] light_cone 1 +#/rat/db/set GEO[inner_pmts] light_cone_material "aluminum" +#/rat/db/set GEO[inner_pmts] light_cone_surface "aluminum" +#/rat/db/set GEO[inner_pmts] light_cone_length 11.5 +#/rat/db/set GEO[inner_pmts] light_cone_innerradius 12.65 +#/rat/db/set GEO[inner_pmts] light_cone_outerradius 26.0 +#/rat/db/set GEO[inner_pmts] light_cone_thickness 0.2 #can change black tarp offset and thickness /rat/db/set GEO[inner_pmts] black_sheet_offset 300.0 #cm diff --git a/myenv.sh b/myenv.sh new file mode 100644 index 00000000..b1e57820 --- /dev/null +++ b/myenv.sh @@ -0,0 +1,6 @@ +source /Disk/ds-sopa-personal/edrakopo/software_WATCHMAN/root_install/bin/thisroot.sh +source /Disk/ds-sopa-personal/edrakopo/software_WATCHMAN/geant_install/bin/geant4.sh +export LD_LIBRARY_PATH=/Disk/ds-sopa-personal/edrakopo/software_WATCHMAN/software_WATCHMAN/geant_install/lib:$LD_LIBRARY_PATH +export DYLD_LIBRARY_PATH=/Disk/ds-sopa-personal/edrakopo/software_WATCHMAN/software_WATCHMAN/geant_install/lib:$DYLD_LIBRARY_PATH +source /Disk/ds-sopa-personal/edrakopo/software_WATCHMAN/rat-pac/ratpac.sh + diff --git a/src/geo/src/GeoPMTFactoryBase.cc b/src/geo/src/GeoPMTFactoryBase.cc index e305bea1..81d7fb08 100644 --- a/src/geo/src/GeoPMTFactoryBase.cc +++ b/src/geo/src/GeoPMTFactoryBase.cc @@ -32,6 +32,7 @@ #include #include #include +#include using namespace std; @@ -115,10 +116,92 @@ namespace RAT { mumetal_log, //Logical Volume mu_metal_surface); //Surface Property - - - - + //add PMT encapsulation : diameter=35cm + int encapsulation = 0; // default to no encapsualtion + try { encapsulation = table->GetI("encapsulation"); } + catch (DBNotFoundError &e) { } + if(encapsulation==1){G4cout <<"Your PMTs are inside an encapsulation! \n ";} + // Material Properties + G4Material* encapsulation_material = G4Material::GetMaterial("nakano_acrylic"); + try { encapsulation_material = G4Material::GetMaterial( table->GetS("encapsulation_material") ); } + catch (DBNotFoundError &e) { } + // Surface Properties + G4SurfaceProperty* encapsulation_surface = Materials::optical_surface["nakano_acrylic"]; + try { encapsulation_surface = Materials::optical_surface[ table->GetS("encapsulation_surface") ]; } + catch (DBNotFoundError &e) { } + G4cout << "PMT encapsulation is added!! \n "; + double enc_radius = 17.5; // default radius + try { enc_radius = table->GetD("enc_radius"); } + catch (DBNotFoundError &e) { } + double enc_thickness = 0.635; //default encapsulation thickness + try { enc_thickness = table->GetD("enc_thickness"); } + catch (DBNotFoundError &e) { } + + //acrylic has 0.635cm thickness //the whole PMT height with base is 318mm, the default encapsulation diameter is: 35cm + G4Sphere* encapsulation_solid = new G4Sphere("encapsulation_solid", + (enc_radius-enc_thickness)*CLHEP::cm, // rmin + enc_radius*CLHEP::cm, // rmax: 17.5cm //PMT diameter is 254mm r:127mm + 0., CLHEP::twopi, //phi + 0., CLHEP::pi); //theta + + G4LogicalVolume * encapsulation_log=new G4LogicalVolume( + encapsulation_solid,// G4VSolid + encapsulation_material, // G4Material + "encapsulation_log"); + G4LogicalSkinSurface* encapsulation_skin = new G4LogicalSkinSurface( + "encapsulation_surface", + encapsulation_log, //Logical Volume + encapsulation_surface); //Surface Property + + //----- add gel and nitrogen inside the encapsulation: + //Note: [0.,CLHEP::pi/2.] is the upper hemisphere & [CLHEP::pi/2., CLHEP::pi] is the lower hemisphere of the sphere + //____ optical grease ______ //V-788 Optical Grease from Rhodia Silicones, + G4Material* encapsulation_innermaterial1 = G4Material::GetMaterial("optical_grease"); + try { encapsulation_innermaterial1 = G4Material::GetMaterial( table->GetS("encapsulation_innermaterial1") ); } + catch (DBNotFoundError &e) { } + G4SurfaceProperty* encapsulation_surface1 = Materials::optical_surface["optical_grease"]; + try { encapsulation_surface1 = Materials::optical_surface[ table->GetS("encapsulation_surface1") ]; } + catch (DBNotFoundError &e) { } + + G4VSolid* encapsulation_innersolid1 = new G4Sphere("encapsulation_innersolid1", + 13.0*CLHEP::cm, // rmin + (enc_radius-enc_thickness)*CLHEP::cm, // rmax + 0., CLHEP::twopi, //phi + 0., CLHEP::pi/2.); //theta + + G4LogicalVolume * encapsulation_innerlog1=new G4LogicalVolume( + encapsulation_innersolid1, // G4VSolid + encapsulation_innermaterial1, // G4Material + "encapsulation_innerlog1"); + G4LogicalSkinSurface* encapsulation_skin1 = new G4LogicalSkinSurface( + "encapsulation_surface1", + encapsulation_innerlog1, //Logical Volume + encapsulation_surface1); //Surface Property + + //_____ nitrogen _____ + G4Material* encapsulation_innermaterial2 = G4Material::GetMaterial("air"); //("Nitrogen"); + try { encapsulation_innermaterial2 = G4Material::GetMaterial( table->GetS("encapsulation_innermaterial2") ); } + catch (DBNotFoundError &e) { } + G4SurfaceProperty* encapsulation_surface2 = Materials::optical_surface["air"]; + try { encapsulation_surface2 = Materials::optical_surface[ table->GetS("encapsulation_surface2") ]; } + catch (DBNotFoundError &e) { } + + G4VSolid* encapsulation_innersolid2 = new G4Sphere("encapsulation_innersolid2", + 0.*CLHEP::cm, // rmin + (enc_radius-enc_thickness)*CLHEP::cm, // rmax + 0., CLHEP::twopi, //phi + CLHEP::pi/2., CLHEP::pi); //theta + + G4LogicalVolume * encapsulation_innerlog2=new G4LogicalVolume( + encapsulation_innersolid2, // G4VSolid + encapsulation_innermaterial2, // G4Material + "encapsulation_innerlog2"); + G4LogicalSkinSurface* encapsulation_skin2 = new G4LogicalSkinSurface( + "encapsulation_surface2", + encapsulation_innerlog2, //Logical Volume + encapsulation_surface2); //Surface Property + + //---------------------------------------------------- //add light cone int light_cone = table->GetI("light_cone"); @@ -633,6 +716,40 @@ namespace RAT { false, id); } + + //place the encapsulation: + G4ThreeVector offsetencapsulation = G4ThreeVector(0.0, 0.0, 0.0*CLHEP::cm); + //G4cout << "pmtpos is " << pmtpos << "\n"; + G4ThreeVector offsetencapsulation_rot = pmtrot->inverse()(offsetencapsulation); + G4ThreeVector encapsulationpos = pmtpos + offsetencapsulation_rot; + if (encapsulation) { + new G4PVPlacement + ( pmtrot, + encapsulationpos, + "encapsulation_phys", + encapsulation_log, + phys_mother, + false, + id); + + new G4PVPlacement + ( pmtrot, + encapsulationpos, + "encapsulation_phys", + encapsulation_innerlog1, + phys_mother, + false, + id); + + new G4PVPlacement + ( pmtrot, + encapsulationpos, + "encapsulation_phys", + encapsulation_innerlog2, + phys_mother, + false, + id); + } G4RotationMatrix* lightconerot = new G4RotationMatrix(); lightconerot->rotateY(angle_y);