Line data Source code
1 : #pragma once 2 : 3 : #include "LandweberIteration.h" 4 : #include "elsaDefines.h" 5 : 6 : namespace elsa 7 : { 8 : /** 9 : * @brief Implementation of the Simultaneous Iterative Reconstruction 10 : * Technique (SIRT). For SIRT \f$ T = \text{diag}(\frac{1}{\text{row sum}}) 11 : * = \text{diag}(\frac{1}{\sum_i A_{ij}})\f$ and \f$ M = \text{diag}( 12 : * \frac{i}{\text{col sum}}) = \text{diag}(\frac{1}{\sum_j A_{ij}})\f$. 13 : * 14 : * Outside of the Computed Tomography community, this algorithm is also often 15 : * know as Simultaneous Algebraic Reconstruction Technique (SART). 16 : * 17 : * @author David Frank 18 : * @see LandweberIteration 19 : */ 20 : template <typename data_t = real_t> 21 : class SIRT : public LandweberIteration<data_t> 22 : { 23 : public: 24 : /// Scalar alias 25 : using Scalar = typename LandweberIteration<data_t>::Scalar; 26 : 27 : /** 28 : * @brief Constructor for SIRT, accepting an operator, a measurement vector 29 : * and a step size# 30 : * 31 : * @param[in] A linear operator to solve the problem with 32 : * @param[in] b measurment vector of the problem 33 : * @param[in] stepSize the fixed step size to be used while solving 34 : */ 35 : SIRT(const LinearOperator<data_t>& A, const DataContainer<data_t>& b, 36 : SelfType_t<data_t> stepSize); 37 : 38 : /** 39 : * @brief Constructor for SIRT, accepting an operator and a measurement 40 : * vector 41 : * 42 : * @param[in] A linear operator to solve the problem with 43 : * @param[in] b measurement vector of the problem 44 : */ 45 : SIRT(const LinearOperator<data_t>& A, const DataContainer<data_t>& b); 46 : 47 : /// make copy constructor deletion explicit 48 : SIRT(const SIRT<data_t>&) = delete; 49 : 50 : /// default destructor 51 4 : ~SIRT() override = default; 52 : 53 : protected: 54 : std::unique_ptr<LinearOperator<data_t>> 55 : setupOperators(const LinearOperator<data_t>& wls) const override; 56 : 57 : private: 58 : /// implement the polymorphic clone operation 59 : SIRT<data_t>* cloneImpl() const override; 60 : 61 : /// implement the polymorphic comparison operation 62 : bool isEqual(const Solver<data_t>& other) const override; 63 : }; 64 : } // namespace elsa