I am reading CASToR_general_documentation v3 (http://www.castor-project.org/sites/default/files/2020-09/CASToR_general_documentation.pdf) and I cannot understand the way idCrystal and idRing are defined. For example, in equation (2) on page 18 idCrystal is defined as follows:

```
idCrystal = idRing × nbCrytalsPerRing
+ idTransaxialCrystal
+ idTransaxialSubmodule × nbTransaxialCrystals
+ idTransaxialModule × nbTransaxialSubmodules × nbTransaxialCrystals
+ idRsector × nbTransaxialModules × nbTransaxialSubmodules
× nbTransaxialCrystals,
```

In equation (4) on the same page, idRing is defined as

```
idRing =idAxialCrystal + idAxialSubmodules × nbAxialCrystals
+ idAxialModule × nbAxialSubmodules × nbAxialCrystals
+ idAxialRsector × nbAxialModules × nbAxialSubmodules × nbAxialCrystals
```

Can you please help me to understand:

1-What is the difference between the idCrystal, idTransaxialCrystal and idAxialCrystal? How do we define idTransaxialCrystal and idAxialCrystal?

2-How many crystals axially a ring contains? If more than one crystal, then it might be the case that there are more than one idRing for a ring as idRing =idAxialCrystal + something.

3-Also, this looks a very complicated way of representing the idCrystal and I don’t understand why idCrystal is defined in such a compicated way while there are some simpler ways. Could you please help me to understand this?

Thanks in advance,

Hello Seyyed,

Indeed, this looks a very complicated way of representing the iDCrystal ! But it is mandatory if you describe the geometry of your PET system using an ascii geometry file (.geom) with five hierarchical levels (crystal, submodule, module, rsector and layer). See Figure 1.

- idCrystal: a unique identification number for each crystal of your PET systems. It goes from 0 to ‘number of elements – 1’

idTransaxialCrystal : the crystal ‘position’ in a submodule along the transaxial direction. It goes form 0 to ‘number of crystals transaxial – 1’ = ‘nbT ransaxialCrystals – 1’. If you look on Figure 1, idTransaxialCrystal (in red) goes from 0 to 9 in layer 0 and 0 to 7 in layer 1.

- To my understanding, one axial crystal per ring.
- What would be a simpler way for a PET system made of layers, rsectors, modules, submodules and crystals ?

Best

**Claude COMTAT**

BioMaps

1 Like

Thank you Claude for your response. It is actually very helpful. Let’s suppose we have a cylindrical scanner consisting of one layer with 100 rsectors. Each rotational sector consists of one module and each module consists of one submodule, and each submodule consists of only one crystal. Hence, in total we have 100 elements from 0 to 99 and also we have one ring. We can simply say that each crystal has an ID equal to its position in the ring along the transaxial direction starting from \theta_0 (the default starting angle) - like transverse indexation figure 3(a). According to equation (3), I have

```
nbCrytalsPerRing = nbRsectors(=100) × nbTransaxialModules(=1)
× nbTransaxialSubmodules(=1) × nbTransaxialCrystals(=1) = 100
```

and

```
idRing = idAxialCrystal(=0) + idAxialSubmodules(=0) × nbAxialCrystals(=0)
+ idAxialModule(=0) × nbAxialSubmodules(=0) × nbAxialCrystals(=0)
+ idAxialRsector(=0) × nbAxialModules(=0) × nbAxialSubmodules(=0)
× nbAxialCrystals(=0) = 0
```

Hence we have:

```
idCrystal =idRing(=0) × nbCrytalsPerRing(=100)
+ idTransaxialCrystal(=0)
+ idTransaxialSubmodule(=0) × nbTransaxialCrystals(=1)
+ idTransaxialModule(=0) × nbTransaxialSubmodules(=1) × nbTransaxialCrystals(=1)
+ idRsector(=the position along the transaxial direction
of the crystal that we are identifying its id) × nbTransaxialModules(=1)
× nbTransaxialSubmodules(=1) × nbTransaxialCrystals(=1)
= idRsector.
```

If I am correct, then, at least in this case, the idCrystals are what we have expected.

I set idTransaxialSubmodule=0, because there is only one submodule in a module in this case. However, if there are two submodules, along the transaxial direction, in a module, then based on the location of the crystal in which submodule, we can set idTransaxialSubmodule=0 or idTransaxialSubmodule=1. Right?

If my understanding of these numbers is correct, then I think this is the way to define idCrystal .

Thanks again,

Seyyed

The equation in the documentation has to be generic. In your example, which is correct, you choose the simplest case with only one element per level, except for rsector.

**Claude COMTAT**

BioMaps

I think now I got it. Thank you Claude for your help. And although the formula looks bulky, it describes a simple and intuitive notion.