Module contains each detector type which inherits from the base detector class. detectors detect photon packets colliding with the detectors.
Initalise Annular detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | pos |
Centre of detector |
||
type(vector), | intent(in) | :: | dir |
Normal of the detector |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
real(kind=wp), | intent(in) | :: | r1 |
Inner radius |
||
real(kind=wp), | intent(in) | :: | r2 |
Outer radius |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |
Initalise Camera detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | p1 |
Position of the 1st corner of the detector |
||
type(vector), | intent(in) | :: | p2 |
Distance from p1 to the 2nd corner |
||
type(vector), | intent(in) | :: | p3 |
Distance from p1 to the 3rd corner |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |
Initalise Circle detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | pos |
Centre of detector |
||
type(vector), | intent(in) | :: | dir |
Normal of the detector |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
real(kind=wp), | intent(in) | :: | radius |
Radius of the detector |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |
Annuluar detector
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=wp), | public | :: | bin_wid |
Bin width |
|||
real(kind=wp), | public, | allocatable | :: | data(:) |
Bins |
||
type(vector), | public | :: | dir |
Surface normal of the detector |
|||
integer, | public | :: | layer |
Layer ID of the detector |
|||
integer, | public | :: | nbins |
Number of bins |
|||
type(vector), | public | :: | pos |
position of the detector |
|||
real(kind=wp), | public | :: | r1 |
Inner radius |
|||
real(kind=wp), | public | :: | r2 |
Outer radius |
|||
logical, | public | :: | trackHistory |
Boolean, if true store the history of the photon prior to detection. |
private function init_annulus_dect (pos, dir, layer, r1, r2, nbins, maxval, trackHistory) | Initalise Annular detector |
procedure, public :: check_hit => check_hit_annulus | |
procedure, public :: record_hit => record_hit_1D_sub |
Rectangular or "camera" detector
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=wp), | public | :: | bin_wid_x |
Bin width in the x dimension |
|||
real(kind=wp), | public | :: | bin_wid_y |
Bin width in the y dimension |
|||
real(kind=wp), | public, | allocatable | :: | data(:,:) |
Bins |
||
type(vector), | public | :: | dir |
Surface normal of the detector |
|||
type(vector), | public | :: | e1 |
Edge vector of detector |
|||
type(vector), | public | :: | e2 |
Edge vector of detector |
|||
real(kind=wp), | public | :: | height |
Height of the detector |
|||
integer, | public | :: | layer |
Layer ID of the detector |
|||
type(vector), | public | :: | n |
Normal of the detector |
|||
integer, | public | :: | nbinsX |
Number of bins in x dimension (detector space) |
|||
integer, | public | :: | nbinsY |
Number of bins in y dimension (detector space) |
|||
type(vector), | public | :: | p2 |
Vector from pos (1st corner) to the 2nd corner of the detector |
|||
type(vector), | public | :: | p3 |
Vector from pos (1st corner) to the 3rd corner of the detector |
|||
type(vector), | public | :: | pos |
position of the detector |
|||
logical, | public | :: | trackHistory |
Boolean, if true store the history of the photon prior to detection. |
|||
real(kind=wp), | public | :: | width |
Width of the detector |
private function init_camera (p1, p2, p3, layer, nbins, maxval, trackHistory) | Initalise Camera detector |
procedure, public :: check_hit => check_hit_camera | |
procedure, public :: record_hit => record_hit_2D_sub |
Circle detector
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=wp), | public | :: | bin_wid |
Bin width |
|||
real(kind=wp), | public, | allocatable | :: | data(:) |
Bins |
||
type(vector), | public | :: | dir |
Surface normal of the detector |
|||
integer, | public | :: | layer |
Layer ID of the detector |
|||
integer, | public | :: | nbins |
Number of bins |
|||
type(vector), | public | :: | pos |
position of the detector |
|||
real(kind=wp), | public | :: | radius |
Radius of detector |
|||
logical, | public | :: | trackHistory |
Boolean, if true store the history of the photon prior to detection. |
private function init_circle_dect (pos, dir, layer, radius, nbins, maxval, trackHistory) | Initalise Circle detector |
procedure, public :: check_hit => check_hit_circle | |
procedure, public :: record_hit => record_hit_1D_sub |
Detector array
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
class(detector), | public, | pointer | :: | p | => | null() |
Check if a hitpoint is in the annulus
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(annulus_dect), | intent(inout) | :: | this | |||
type(hit_t), | intent(in) | :: | hitpoint |
Hitpoint to check |
Check if a hitpoint is in the circle
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(circle_dect), | intent(inout) | :: | this | |||
type(hit_t), | intent(in) | :: | hitpoint |
Hitpoint to check |
Initalise Annular detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | pos |
Centre of detector |
||
type(vector), | intent(in) | :: | dir |
Normal of the detector |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
real(kind=wp), | intent(in) | :: | r1 |
Inner radius |
||
real(kind=wp), | intent(in) | :: | r2 |
Outer radius |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |
Initalise Camera detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | p1 |
Position of the 1st corner of the detector |
||
type(vector), | intent(in) | :: | p2 |
Distance from p1 to the 2nd corner |
||
type(vector), | intent(in) | :: | p3 |
Distance from p1 to the 3rd corner |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |
Initalise Circle detector
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(vector), | intent(in) | :: | pos |
Centre of detector |
||
type(vector), | intent(in) | :: | dir |
Normal of the detector |
||
integer, | intent(in) | :: | layer |
Layer ID |
||
real(kind=wp), | intent(in) | :: | radius |
Radius of the detector |
||
integer, | intent(in) | :: | nbins |
Number of bins in the detector |
||
real(kind=wp), | intent(in) | :: | maxval |
Maximum value to store in bins |
||
logical, | intent(in) | :: | trackHistory |
Boolean on if to store photon's history prior to hitting the detector. |