Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
athena
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
EIC
detectors
athena
Commits
49354228
Commit
49354228
authored
3 years ago
by
christopher dilks
Browse files
Options
Downloads
Patches
Plain Diff
maximize azimuthal acceptance
parent
28d6d2aa
No related branches found
No related tags found
1 merge request
!196
resolve "Improve dRICh optics"
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
compact/drich.xml
+1
-1
1 addition, 1 deletion
compact/drich.xml
src/DRich_geo.cpp
+30
-19
30 additions, 19 deletions
src/DRich_geo.cpp
with
31 additions
and
20 deletions
compact/drich.xml
+
1
−
1
View file @
49354228
...
...
@@ -148,7 +148,7 @@
backplane=
"DRICH_window_thickness + 5.0*cm"
rmin=
"DRICH_rmin1 + DRICH_wall_thickness + 0.0*cm"
rmax=
"DRICH_rmax2 - DRICH_wall_thickness - 2.0*cm"
phiw=
"5
3
*degree"
phiw=
"5
9.5
*degree"
thickness=
"0.2*cm"
focus_tune_long=
"0.5"
focus_tune_perp=
"0.2"
...
...
This diff is collapsed.
Click to expand it.
src/DRich_geo.cpp
+
30
−
19
View file @
49354228
...
...
@@ -4,7 +4,7 @@
//
// Author: Christopher Dilks (Duke University)
//
// - Design Adapted from Standalone Fun4all and GEMC implementations
// - Design Adapted from Standalone Fun4all and GEMC implementations
// [ Evaristo Cisbani, Cristiano Fanelli, Alessio Del Dotto, et al. ]
//
//==========================================================================
...
...
@@ -121,7 +121,7 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
/* - `vessel`: aluminum enclosure, the mother volume of the dRICh
* - `gasvol`: gas volume, which fills `vessel`; all other volumes defined below
* are children of `gasvol`
* - the dRICh vessel geometry has two regions: the snout refers to the conic region
* - the dRICh vessel geometry has two regions: the snout refers to the conic region
* in the front, housing the aerogel, while the tank refers to the cylindrical
* region, housing the rest of the detector components
*/
...
...
@@ -201,7 +201,7 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
// reference positions
// - the vessel is created such that the center of the cylindrical tank volume
// coincides with the origin; this is called the "origin position" of the vessel
// - when the vessel (and its children volumes) is placed, it is translated in
// - when the vessel (and its children volumes) is placed, it is translated in
// the z-direction to be in the proper ATHENA-integration location
// - these reference positions are for the frontplane and backplane of the vessel,
// with respect to the vessel origin position
...
...
@@ -307,13 +307,13 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
int
imod
=
0
;
// thetaGen loop: iterate less than "0.5 circumference / sensor size" times
double
nTheta
=
M_PI
*
sensorSphRadius
/
(
sensorSide
+
sensorGap
);
double
nTheta
=
M_PI
*
sensorSphRadius
/
(
sensorSide
+
sensorGap
);
for
(
int
t
=
0
;
t
<
(
int
)(
nTheta
+
0.5
);
t
++
)
{
double
thetaGen
=
t
/
((
double
)
nTheta
)
*
M_PI
;
// phiGen loop: iterate less than "circumference at this latitude / sensor size" times
double
nPhi
=
2
*
M_PI
*
sensorSphRadius
*
std
::
sin
(
thetaGen
)
/
(
sensorSide
+
sensorGap
);
for
(
int
p
=
0
;
p
<
(
int
)(
nPhi
+
0.5
);
p
++
)
{
double
nPhi
=
2
*
M_PI
*
sensorSphRadius
*
std
::
sin
(
thetaGen
)
/
(
sensorSide
+
sensorGap
);
for
(
int
p
=
0
;
p
<
(
int
)(
nPhi
+
0.5
);
p
++
)
{
double
phiGen
=
p
/
((
double
)
nPhi
)
*
2
*
M_PI
-
M_PI
;
// shift to [-pi,pi]
// determine global phi and theta
...
...
@@ -337,7 +337,7 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
double
phiCheck
=
std
::
atan2
(
yCheck
,
xCheck
);
// patch cut
bool
patchCut
=
bool
patchCut
=
std
::
fabs
(
phiCheck
)
<
sensorSphPatchPhiw
&&
zCheck
>
sensorSphPatchZmin
&&
rCheck
>
sensorSphPatchRmin
...
...
@@ -419,7 +419,7 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
// focus 2: move focal region along sensor sphere radius, according to `focusTuneLong`
// - specifically, along the radial line which passes through the approximate centroid
// of the sensor region `(sensorCentroidZ,sensorCentroidX)`
// of the sensor region `(sensorCentroidZ,sensorCentroidX)`
// - `focusTuneLong` is the distance to move, given as a fraction of `sensorSphRadius`
// - `focusTuneLong==0` means `(zF,xF)==(zS,xS)`
// - `focusTuneLong==1` means `(zF,xF)` will be on the sensor sphere, near the centroid
...
...
@@ -460,29 +460,40 @@ static Ref_t createDetector(Detector& desc, xml::Handle_t handle, SensitiveDetec
// if debugging, draw full sphere
if
(
debug_mirror
)
{
mirrorTheta1
=
0
;
mirrorTheta2
=
M_PI
;
/*mirrorPhiw=2*M_PI;*/
};
// solid and volume: create sphere at origin, with specified angular limits
Sphere
mirrorSolid
(
// solid : create sphere at origin, with specified angular limits;
// phi limits are increased to fill gaps (overlaps are cut away later)
Sphere
mirrorSolid1
(
mirrorRadius
,
mirrorRadius
+
mirrorThickness
,
mirrorTheta1
,
mirrorTheta2
,
-
mirrorPhiw
/
2.0
,
mirrorPhiw
/
2.0
-
40
*
degree
,
40
*
degree
);
Volume
mirrorVol
(
detName
+
"_mirror_"
+
secName
,
mirrorSolid
,
mirrorMat
);
mirrorVol
.
setVisAttributes
(
mirrorVis
);
// placement (note: transformations are in reverse order)
//
mirror
placement
transformation
(note: transformations are in reverse order)
auto
mirrorPos
=
Position
(
mirrorCenterX
,
0.
,
mirrorCenterZ
)
+
originFront
;
auto
mirrorPV
=
gasvolVol
.
placeVolume
(
mirrorVol
,
Transform3D
mirrorPlacement
(
Translation3D
(
mirrorPos
.
x
(),
mirrorPos
.
y
(),
mirrorPos
.
z
())
// re-center to specified position
*
RotationY
(
-
mirrorThetaRot
)
// rotate about vertical axis, to be within vessel radial walls
);
// cut overlaps with other sectors using "pie slice" wedges, to the extent specified
// by `mirrorPhiw`
Tube
pieSlice
(
0.01
*
cm
,
vesselRmax2
,
tankLength
/
2.0
,
-
mirrorPhiw
/
2.0
,
mirrorPhiw
/
2.0
);
IntersectionSolid
mirrorSolid2
(
pieSlice
,
mirrorSolid1
,
mirrorPlacement
);
// mirror volume, attributes, and placement
Volume
mirrorVol
(
detName
+
"_mirror_"
+
secName
,
mirrorSolid2
,
mirrorMat
);
mirrorVol
.
setVisAttributes
(
mirrorVis
);
auto
mirrorPV2
=
gasvolVol
.
placeVolume
(
mirrorVol
,
RotationZ
(
sectorRotation
)
// rotate about beam axis to sector
*
Translation3D
(
mirrorPos
.
x
(),
mirrorPos
.
y
(),
mirrorPos
.
z
())
// re-center to specified position
*
RotationY
(
-
mirrorThetaRot
)
// rotate about origin
*
Translation3D
(
0
,
0
,
0
)
);
// properties
DetElement
mirrorDE
(
det
,
Form
(
"mirror_de%d"
,
isec
),
isec
);
mirrorDE
.
setPlacement
(
mirrorPV
);
mirrorDE
.
setPlacement
(
mirrorPV
2
);
SkinSurface
mirrorSkin
(
desc
,
mirrorDE
,
Form
(
"mirror_optical_surface%d"
,
isec
),
mirrorSurf
,
mirrorVol
);
mirrorSkin
.
isValid
();
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment