## 3 Mathematical Models
### Inverse Heat Transfer Problem
#### 3.2.1 Optimization of Functional \(S\)  
In order to minimization of functional (9), the modified [PERSON]'s method [27; 28; 29; 30] is applied. In general, [PERSON]'s method is used in numerical methods to find zeros of nonlinear functions. This method belongs to the iterative methods. If this method is used for the optimization of functional then the following necessary condition for local minimizer  
\[\
abla S(\mathbf{P}^{k})=0,\quad\text{for }k=0,1,\ldots \tag{12}\]  
is required to be met. Parameter \(k\) denotes the step of iteration. \(\mathbf{P}^{0}\) is the vector of the initial guess and the determination of a reasonable first iteration can sometimes be problematic. Subsequent iterations should bring the solution parameters closer to the optimal state. Let us consider the second-order approximation of the functional \(S\) using the Taylor series expansion  
\[S(\mathbf{P}^{k+1})=S(\mathbf{P}^{k}+\mathbf{d}^{k})\cong S(\mathbf{P}^{k})+ \left(\
abla S(\mathbf{P}^{k})\right)^{\top}\mathbf{d}^{k}+\frac{1}{2}( \mathbf{d}^{k})^{\top}\
abla^{2}S(\mathbf{P}^{k})\ \mathbf{d}^{k}, \tag{13}\]  
where \(\mathbf{d}^{k}\) is called the Newton direction at state \(\mathbf{P}^{k}\), \(\
abla S(\mathbf{P}^{k})\equiv\mathbf{g}_{S}(\mathbf{P}^{k})\) is the gradient vector and \(\
abla^{2}S(\mathbf{P}^{k})\equiv\mathbf{H}_{S}(\mathbf{P}^{k})\) is the Hessian matrix of \(S\) calculated for values from the vector \(\mathbf{P}^{k}\). In this method, it is assumed that \(\
abla^{2}S(\mathbf{P}^{k})\) is non-singular in each iteration. If we apply the differentiation of Expression (13) with respect to \(\mathbf{d}^{k}\) that meets the Condition (12), then we have  
\[\
abla S(\mathbf{P}^{k})+\
abla^{2}S(\mathbf{P}^{k})\ \mathbf{d}^{k}=0, \tag{14}\]  
and hence  
\[\mathbf{d}^{k}=-\left(\
abla^{2}S(\mathbf{P}^{k})\right)^{-1}\
abla S( \mathbf{P}^{k}). \tag{15}\]  
Remarks on the calculation of vector \(\mathbf{d}^{k}\) in Equation (15): From the computational point of view, calculating the inverse matrix of the Hessian is more complex and it may even be numerically unstable. It is worth calculating it better from the numerical solution of the system of linear equations \(\
abla^{2}S(\mathbf{P}^{k})\ \mathbf{d}^{k}=-\
abla S(\mathbf{P}^{k})\), using, e.g., iterative methods. In the modified [PERSON]'s method, it is assumed that  
\[\mathbf{P}^{k+1}=\mathbf{P}^{k}+\alpha_{k}\mathbf{d}^{k}, \tag{16}\]  
where \(\alpha_{k}\in(0,1]\) is a scalar selected to satisfy the condition: \(S(\mathbf{P}^{k+1})<S(\mathbf{P}^{k})\). The value of \(\alpha_{k}=1\) corresponds to the classical [PERSON]'s method. The optimal value of the parameter \(\alpha_{k}\) should be determined by the minimizing of \(S(\mathbf{P}^{k}+\alpha_{k}\mathbf{d}^{k})\), to ensure the fulfilment of the above-mentioned condition. There are many stopping criteria for an iterative algorithm. The final values of \(\mathbf{P}\) should be stabilized with respect to errors in the input data. Here, we use the following criterion  
\[\left\|\mathbf{P}^{k+1}-\mathbf{P}^{k}\right\|=\sqrt{\left(\mathbf{P}^{k+1}- \mathbf{P}^{k}\right)^{\top}\left(\mathbf{P}^{k+1}-\mathbf{P}^{k}\right)}<\varepsilon, \tag{17}\]  
where \(\varepsilon\) is user prescribed tolerance. 2.2 Determination of the Gradient Vector \(\
abla S(\mathbf{P}^{k})\) and the Hessian Matrix \(\
abla^{2}S(\mathbf{P}^{k})\)  
Calculations of the values of the gradient vector and the Hessian matrix can be very time-consuming. Here, we use analytical methods. The particular elements of the vector and matrix for the considered problem are as follows:\[\
abla S=\left[ \begin{array}{cccccccc}\frac{\partial S}{\partial r_{1}}&\frac{ \partial S}{\partial r_{2}}&\cdots&\frac{\partial S}{\partial r_{M}}&\frac{ \partial S}{\partial a}&\frac{\partial S}{\partial T_{init}}&\frac{\partial S }{\partial T_{b}}\end{array} \right]^{\intercal},\]  
\[\
abla^{2}S=\left[