### Reconstruction algorithm

MLAA algorithm is based on two iterative procedures. For the reconstruction of the activity distribution, a maximum likelihood expectation maximization (MLEM) procedure is used with the TOF-PET sinogram and the attenuation map as input. On the other hand, the reconstruction of the attenuation map is performed using a maximum likelihood gradient ascent procedure with the TOF-PET sinogram and the activity distribution as input. As both activity and attenuation images are unknown, these procedures are concatenated every iteration or few iterations leading to the mentioned simultaneous reconstruction of both images.

The MLEM algorithm used in this work can be expressed as:

$$ {\lambda}_j^{\left(n+1\right)}={\lambda}_j^{(n)}\bullet \frac{\sum_{i,\mathrm{TOF}}{c}_{ij}^{\mathrm{TOF}}\frac{y_{i,\mathrm{TOF}}}{b_{i,\mathrm{TOF}}^{(n)}}}{\sum_{i,\mathrm{TOF}}{c}_{ij}^{\mathrm{TOF}}{a}_i^{(n)}} $$

(1)

where \( {\lambda}_j^{(n)} \) is the estimated activity at iteration *n* on image voxel *j*, *y*_{i, TOF} is the measured number of coincidences in sinogram entry (*i*,TOF), \( {c}_{ij}^{\mathrm{TOF}} \) is the system matrix which reflects the sensitivity of pixel *j* with respect to sinogram entry (*i*,TOF), \( {a}_i^{(n)} \) is the estimated attenuation sinogram, and \( {b}_{i,\mathrm{TOF}}^{(n)} \) is the estimated emission sinogram. \( {c}_{ij}^{\mathrm{TOF}} \) was estimated using a Siddon’s ray tracing algorithm [27] and the TOF resolution model was included with a Gaussian profile according to the employed coincidence resolving time (CRT). \( {b}_{i,\mathrm{TOF}}^{(n)} \) and \( {a}_i^{(n)} \) can be expressed as:

$$ {b}_{i,\mathrm{TOF}}^{(n)}={\sum}_j{c}_{ij}^{\mathrm{TOF}}{\lambda}_j^{(n)}\ {a}_i^{(n)}=\exp \left(-{\sum}_j{l}_{ij}{\mu}_j^{(n)}\right) $$

(2)

where \( {\mu}_j^{(n)} \) is the estimated attenuation coefficient and *l*_{ij} is the intersection length of the line of response (LOR) for sinogram entry *i* with pixel *j*.

The maximum likelihood gradient ascent algorithm used for the reconstruction of the attenuation map can be expressed using the following equation:

$$ {\mu}_j^{\left(n+1\right)}={\mu}_j^{(n)}+\frac{\alpha_p}{D}\left(1-\frac{\sum_i{c}_{ij}{y}_i}{\sum_i{c}_{ij}\left({a}_i^{(n)}{b}_i^{(n)}\right)}\right) $$

(3)

where *α*_{p} is a relaxation coefficient and *D* the diameter of the PET ring [12, 14]. Note that no TOF information is used in this case. The results shown in this study were obtained after 1000 iterations updating the attenuation map according to Eq. 3 every 3 MLEM iterations (see Eq. 1) and with *α*_{p} = 2 and *D* = 903 mm.

As pointed out by Defrise et al. [16], the MLAA algorithm allows to calculate the attenuation sinogram up to an additive constant. They also mentioned that if the attenuation coefficient is known for some LORs, the emission data determine in a unique way all the attenuation factors. For that purpose, they proposed using a reference object with known attenuation and activity placed outside the convex hull of the scanned object to recover the attenuation factors for all LORs. This is possible because the attenuation is thus known for any LOR that crosses this reference object but does not cross the scanned object. However, to the best of our knowledge, this strategy has not been tested to date.

In order to implement this technique, the MLAA algorithm was modified as follows. Every time the attenuation map is updated by (3), an additive constant is added to the entire map forcing the pixels within the reference object to have an average attenuation coefficient according to its known value (\( {\overline{\mu}}_{\mathrm{ref}} \)). For that purpose, the difference between \( {\overline{\mu}}_{\mathrm{ref}} \) and the mean attenuation coefficient within a region of interest (ROI) drawn inside the reference object in the attenuation image at current iteration (\( {\overline{\mu}}_{\mathrm{ROI}}^{(n)} \)) is obtained, and the entire attenuation map is corrected by this difference as follows:

$$ {\mu}_{j,\mathrm{corr}}^{(n)}={\mu}_j^{(n)}+{K}_{\mathrm{corr}}^{(n)} $$

(4)

where \( {K}_{\mathrm{corr}}^{(n)} \) is given by

$$ {K}_{\mathrm{corr}}^{(n)}={\overline{\mu}}_{\mathrm{ref}}-{\overline{\mu}}_{\mathrm{ROI}}^{(n)} $$

(5)

In this way, \( {\mu}_{j,\mathrm{corr}}^{(n)} \) is used as the attenuation map for the next iteration.

### 2D simulation

To test the proposed algorithm, multiple 2D simulations were performed. As input, reconstructed PET/CT images for a patient were extracted from an online database [28, 29] and one slice from the thoracic region was selected (see Fig. 1). The PET image used as true activity distribution has 128 × 128 pixels with a pixel size of 5 mm. CT image was resampled to the same voxel size as the PET image in order to obtain true attenuation images. Attenuation map was obtained by conversion from Hounsfield units (HU) to attenuation coefficients at 511 keV using the bilinear conversion proposed by Carney et al. [30] for the corresponding energy (130 kVp). True emission and attenuation sinograms were generated by forward projection of the true activity and attenuation images (see Eq. 2). Attenuated emission sinogram was generated as the product of both sinograms as follows:

$$ {y}_{i,\mathrm{TOF}}={b}_{i,\mathrm{TOF}}\cdotp {a}_i $$

(6)

The sinograms obtained had 90 angular samples over 180°, 256 radial samples with 2.5 mm bin size and 13, 27, or 81 TOF-bins for 540, 300, or 100 ps CRT, respectively.

Attenuated emission sinograms including noise were generated using an acceptance-rejection Monte Carlo (MC) method. For that purpose, a random sinogram entry (*i*,TOF) is chosen and a random number is generated between 0 and the maximum value of the noise-free sinogram. The event is added to the new sinogram if the random value is lower than the noise-free sinogram at entry (*i*,TOF). This process is repeated until the desired number of events is reached. In that way, a new sinogram is built with a predefined number of events distributed as the noise-free sinogram. The number of coincidences to be simulated was established by obtaining attenuated sinograms of a cylinder with 20-cm diameter filled with water and uniform activity with different number of coincidences. Those sinograms were reconstructed using standard MLEM algorithm with 100 iterations including known attenuation map. The standard deviation (SD) was computed in a ROI at the center of the reconstructed image and the number of events leading to a SD of 5% was selected as a reference for simulations with patient data which corresponded to 10^{7} coincidences for a CRT of 300 ps. In addition, simulations with lower number of coincidences (10^{6} and 10^{5}) were also tested to evaluate the method at different noise levels.

In order to provide an initial estimate of the attenuation map for the MLAA algorithm, we performed a non-attenuation corrected MLEM reconstruction and the body contour was segmented using a Gaussian filter followed by a watershed algorithm. The attenuation coefficient within the patient volume was initialized as water. True attenuation values for the patient table and the reference object were included as a template in the initial attenuation map.

The proposed algorithm was tested with different configurations of the reference object including variations of the geometry, material composition, and activity. Initially, the reference object was defined as a water cylinder with 4-cm diameter inserted in the patient table with an activity concentration equal to the average activity concentration within the patient (*A*_{0}). In addition, other activity values were tested including no activity, *A*_{0}/4, and 4·*A*_{0}. The geometry of the reference object was also tested including 2 and 4 water cylinders each one filled with *A*_{0}/2 and *A*_{0}/4, respectively, to preserve the total activity within the reference objects. For the case of 2 cylinders, an additional cylinder was placed on top of the patient and for the case of 4 cylinders, 2 more cylinders were added on both lateral sides of the patient. Finally, two other materials for the reference object were tested using one cylinder with *A*_{0} made of lung or bone equivalent materials with attenuation coefficients of 2.76·10^{− 3} and 12.01·10^{− 3} mm^{− 1}, respectively.

A CRT of 300 ps was chosen to study all the configurations mentioned above which is similar to the TOF resolution of most recent PET scanners [31,32,33]. In addition, two other CRT values were studied to evaluate the performance of the proposed method in the previous generation of PET scanners with a CRT of 540 ps [34, 35] and in PET scanners with improved CRT (100 ps) that might be available in the future [36,37,38].

### Image analysis

The accuracy of the obtained reconstructed images was evaluated as follows. The patient volume was segmented into four tissue types (*t*) including lung, bone, soft tissue, and adipose tissue according to the attenuation coefficients included in the CT-derived attenuation map. The mean percentage difference (*∆*^{t}) between the reconstructed (*x*_{j}) and the true (\( {x}_j^{\mathrm{true}} \)) emission images and the standard deviation of the percentage difference (SD^{t}) were calculated for each tissue

$$ {\Delta }^t=\frac{1}{n^t}\sum \limits_j\frac{x_j-{x}_j^{\mathrm{true}}}{x_j^{\mathrm{true}}}\bullet 100 $$

(7)

where *n*^{t} is the number of pixels in the tissue *t*. In addition, pixel-wise maps with the percentage difference between the reconstructed and the true emission images were obtained.