# Collimator resolution

**URL:** <https://castor-project.discourse.group/t/collimator-resolution/44>\
**Category:** General Discussions\
**Created:** [March 29, 2018, 4:10pm UTC](https://castor-project.discourse.group/t/collimator-resolution/44 "2018-03-29T16:10:11Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Michael\_Ljungberg](https://avatars.discourse-cdn.com/v4/letter/m/a4c791/32.png) [@Michael\_Ljungberg](https://castor-project.discourse.group/u/Michael_Ljungberg)\
**Post date:** [March 29, 2018, 4:10pm UTC](https://castor-project.discourse.group/t/collimator-resolution/44/1 "2018-03-29T16:10:11Z")

</div>

Hi

I want to include a geometric Gaussian collimator representation in the Castor reconstruction. Is there anyone that has made a corresponding translation between a distance-dependent Gaussian and its polynomial castor version and included this in the .geom file?

Thanks,

Best regards

Michael

Michael Ljungberg, professor  
Department of Medical Radiaton Physics  
Lund University, Sweden

---

<div class="post-metadata">

**Author:** ![tmerlin](https://yyz2.discourse-cdn.com/free1/user_avatar/castor-project.discourse.group/tmerlin/32/216_2.png) [@tmerlin](https://castor-project.discourse.group/u/tmerlin)\
**Post date:** [March 30, 2018, 7:07pm UTC](https://castor-project.discourse.group/t/collimator-resolution/44/2 "2018-03-30T19:07:37Z")

</div>

Dear Michael,

Up to now, I haven't heard/read of anyone who did such a translation.

I just wanted to point out that there is the possibility to implement a custom collimator model in the code. The model has to be defined as "custom" in the geom file, and the implementation could be made in the src/scanner/iScannerSPECTConv.cc file, inside the ComputeFocalPositions() function (around lines 840 and 916 to compute the axial and transaxial focal points respectively). From there, the parameters of the model can be accessed.

This feature lacks some flexibility for the moment, but we'll work at making it more practical and modular as some other Castor features.

Kind regards,

Thibaut

---

<div class="post-metadata">

**Author:** ![Michael\_Ljungberg](https://avatars.discourse-cdn.com/v4/letter/m/a4c791/32.png) [@Michael\_Ljungberg](https://castor-project.discourse.group/u/Michael_Ljungberg)\
**Post date:** [March 30, 2018, 7:16pm UTC](https://castor-project.discourse.group/t/collimator-resolution/44/3 "2018-03-30T19:16:26Z")

</div>

Hi Thibaut

Yes – I have read about this in the manual but since I am an old Fortran guy and not so experienced in C I took a first easy step.

By the way, would it be possible to add the output file name as a patient name in the output interfile in the next release?

Hälsningar / Best regards

Michael

&nbsp;&nbsp;&nbsp;&nbsp;Dear Michael,  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;Up to now, I haven't heard/read of anyone who did such a translation.  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;I just wanted to point out that there is the possibility to implement a  
&nbsp;&nbsp;&nbsp;&nbsp;custom collimator model in the code. The model has to be defined as  
&nbsp;&nbsp;&nbsp;&nbsp;"custom" in the geom file, and the implementation could be made in the  
&nbsp;&nbsp;&nbsp;&nbsp;src/scanner/iScannerSPECTConv.cc file, inside the  
&nbsp;&nbsp;&nbsp;&nbsp;ComputeFocalPositions() function (around lines 840 and 916 to compute  
&nbsp;&nbsp;&nbsp;&nbsp;the axial and transaxial focal points respectively). From there, the  
&nbsp;&nbsp;&nbsp;&nbsp;parameters of the model can be accessed.  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;This feature lacks some flexibility for the moment, but we'll work at  
&nbsp;&nbsp;&nbsp;&nbsp;making it more practical and modular as some other Castor features.  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;Kind regards,  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;Thibaut

---

<div class="post-metadata">

**Author:** ![tmerlin](https://yyz2.discourse-cdn.com/free1/user_avatar/castor-project.discourse.group/tmerlin/32/216_2.png) [@tmerlin](https://castor-project.discourse.group/u/tmerlin)\
**Post date:** [March 30, 2018, 7:37pm UTC](https://castor-project.discourse.group/t/collimator-resolution/44/4 "2018-03-30T19:37:26Z")

</div>

Yes, this has already been implemented in our development version.

Kind regards,

Thibaut
