## 2 Mathematical Model
### Economic Evaluation of Insulation Thickness  
This investigation employs life cycle cost analysis, a commonly favored approach [31; 32; 33; 34], to ascertain the overall expenses associated with heating and cooling throughout a building's lifespan. It is certain that a thicker insulation material results in higher insulation costs but a decrease in heating/cooling loads and energy expenses. As the insulation thickness augments, there is a corresponding increase in material costs, requiring a balance between the added cost and reduced heating/cooling expenses. The lowest overall cost is attained when using the optimal insulation thickness. Deviating from this optimal thickness results in a higher overall cost. The expense of insulating external walls varies based on the thickness of the material. \[C_{t,ins}=C_{ins}x \tag{18}\]  
Here, the cost per unit volume of the insulation material is represented by \(C_{ins}\). The total cost is computed by combining the insulation cost with the present value of cooling and heating expenses throughout the building's lifespan. The present worth factor (\(PWF\)) is a financial metric used to estimate the value of a cash flow stream in today's money, given a specified discount rate and time horizon. It is based on the principle of discounting future cash flows to present values by considering the time value of money. The \(PWF\) is calculated using the discount rate (\(g\)), inflation rate (\(i\)), and expected building lifetime (\(LT\)) as follows [8]:  
\[PWF=\left(\frac{1+i}{g-i}\right)\left[1-\left(\frac{1+i}{1+g}\right)^{LT}\right] \tag{19}\]  
The building's expected lifetime (\(LT\)) is set at 20 years [4]. As a result, the total heating cost can be computed using the following equations [20]:  
\[C_{t,H}=C_{ins}x+C_{H,pv} \tag{20}\]  
\[C_{t,H}=C_{ins}x+\frac{86,400 HDDC_{f}PWF}{\left(R_{t,pv}+\frac{x}{k}\right)Hu\eta} \tag{21}\]  
Here, \(C_{f}\) is the fuel cost, \(Hu\) is the lower heating value of natural gas, which has been selected as the heating fuel due to its growing usage for space heating globally in recent years. Table 1 includes information on specific values associated with natural gas. The \(C_{t,H}\) equation must be minimized to find the ideal insulation thickness for the heating season. The derivative of the \(C_{t,H}\) equation concerning the insulation thickness is calculated and equated to zero, yielding the ideal insulation thickness for the heating degree day as shown below [20]:  
\[x_{opt,H}=\left(\frac{86,400 HDDC_{f}PWFk}{Hu\eta C_{ins}}\right)^{0.5}-R_{t,w}k \tag{22}\]  
In the same manner, the total cost and the ideal insulation thickness for the cooling season are represented as follows [20]:  
\[C_{t,C}=C_{ins}x+C_{C,pv} \tag{23}\]  
\[C_{t,C}=C_{ins}x+\frac{86,400 CDDc_{e}PWF}{\left(R_{t,w}+\frac{x}{k}\right)COP} \tag{24}\]  
The electricity cost used by the cooling system is represented by \(C_{e}\), expressed in USD per kilowatt-hour, as shown in Table 1. Similarly, the ideal insulation thickness for the cooling season is calculated by minimizing Equation (24) as demonstrated below [20]:  
\[x_{opt,C}=\left(\frac{86,400 CDDc_{e}PWFk}{COPC_{ins}}\right)^{0.5}-R_{t,w}k \tag{25}\]The equations mentioned above can be used for only one specific target. While the \(x_{opt,H}\) equation can be used for a building heated but not cooled, \(x_{opt,C}\) can be used for a building cooled but not heated.