## 3 Results and Discussion
### IFT Measurement
First is the high temperature, which is known to increase the adsorption of inorganic sulfates on the calcite [56]. It is suggested  
Figure 8: Contact angle values of rock samples treated with surfactant solutions and surfactant-CA mixtures after treatment at 120 \({}^{\circ}\)C.  
Figure 7: Contact angle values of rock samples treated with surfactant solutions and surfactant-CA mixtures after treatment at 25 \({}^{\circ}\)C.  
that the affinity of organic sulfate towards calcite is also increased at high temperatures because of chemical similarity. The second factor is the presence of organic coverage on the surface, rendering it oil-wet initially. Such coverage also increases the adsorption of SDS [25] because of hydrophobic interactions. Finally, the highest increase of \(R\) is observed if CA is present. It is known that [57] salinity increase also leads to higher adsorption of surfactant, and CA plays the role of salt as the salting-out compound [47]. It can be concluded that SDS application at 0.05% wt. would be detrimental to the wettability state of the rock at high temperature. All other surfactants alter the wettability towards water-wetness under investigated conditions. These findings still follow the trend of previous results [58; 59; 25]. As for cationic surfactants, it can be observed that CTAB is more efficient than CPB under any conditions and irrespectively of CA's presence (lower \(R/R_{0}\) values and lower contact angle values). The efficiency of cationic surfactants is determined by electrostatic interaction between negatively charged carboxylic groups of adsorbate and positively charged groups of cationic surfactants with the following solubilization of desorbed compounds in micelles [60]. CTAB has a higher logP value (1.86) than CPB (1.63), according to ALOGPS 2.1 [61], which means that solubilization of hydrophobic chain of stearate in CTAB's micelles proceeds more readily. As the difference in the efficiency increases with the temperature, it can be concluded that it is the solubilization mechanism that determines the efficiency of cationic surfactants in wettability alteration. A surfactant with higher solubilization capacity is more likely to solubilize desorbed compounds in its micelles at higher temperature, as the number of micelles decreases when temperature increases [51]. If CA is present, the difference between CTAB and CPB may be caused by CPB degradation, as discussed earlier. It is interesting to note that the presence of CA in cationic surfactants' solutions has a different impact on wettability alteration depending on the temperature. At 25 \({}^{\circ}\)C, plain solutions of both CTAB and CPB are more effective, whereas the situation is overturned at 120 \({}^{\circ}\)C, as the mixture of CTAB and CA performs better than plain CTAB and the mixture of CPB and CA becomes nearly equal to the plain CPB. It can be suggested that screening between the negatively charged CA and positively charged surfactant's head hinders the surfactant's ability to form ionic pairs with negatively charged stearic acid ions. Moreover, the reaction between CA and calcite is limited by surface kinetics at 25 \({}^{\circ}\)C [62]; thus, the residence time of CA on the surface is relatively long if compared to the diffusion time, which counteracts the action of surfactant. Higher temperature partially negates screening as electrostatic forces are obstructed by thermal agitation. The rate of the calcite dissolution is limited by mass transfer rate at 120 \({}^{\circ}\)C. Both of these factors exclude negative mutual influence. The synergistic effect between cationic surfactant and CA can be described (Figure 9). At the first stage (Figure 9a), the positively charged hydrophilic group of surfactant forms a strong ionic pair with negatively charged stearate. The ionic pair is desorbed spontaneously from the surface and moves to the bulk, where the stearate ion is solubilized in the surfactant's micelle (Figure 9b). This means that stearate cannot re-adsorb.