Overview of the procedures of the fMRI study and of the ART. A) During the first (day 1) and second (day 2) visits, we measured working memory capacity, psychomotor visual attention, and cognitive effort levels through the Digit Span (DS)23, the Psychomotor Visual Task (PVT)24, and the Need for Cognition Scale (NFS)25. These measurements were performed to exclude fasting effects on learning following changes in general cognitive skills. During the second visit, glucose levels were measured before and after breakfast in the Re-feeding Group and with a time interval of 20/25 minutes in the Fasting Group. Ketone levels were measured once at the beginning of the second session. After the neuropsychological assessment, participants were asked to lie inside the scanner. The intensity of the US was then calibrated following standardized procedures 26. The US was set to an intensity for which participants refer to the electrical stimulation as highly unpleasant but not painful. Following explanations about the task and relief ratings, the fMRI exam started for a total duration of about 75 minutes. After the acquisition of the anatomical scans, the participants performed the ART. Since we focused on the dynamics of learning, in the present fMRI study we did not include the test phases of the ART, as in 5. After fMRI acquisition, an explanation of hypotheses and aims was provided to each participant. B) The ART consists of three learning phases, a Pavlovian phase that uses a block-design, an avoidance learning and fear extinction learning phases that use an event-related type of presentation of the stimuli, see 5 for details. C) We applied a jittered design to better distinguish BOLD and SCR responses during US omissions. The illustration shows an example of a trial during the avoidance learning phase, where background, CS presentation (US anticipation), and CS offset (relief) were jittered events before that the online relief rating was collected.

A) Avoidance actions and B) Relief pleasantness ratings during the avoidance phase for the Fasting Group (FG, continuous lines) and the Re-feeding Group (RG, dashed lines). A) The results from the GLMM analysis indicated a (general) lower probability of pressing the button for the CS- and CS+unav (all p-values < 0.001), and a significant reduction in the probability to press the button over the trials of the CS- and CS+unav when compared to the CS+av (all p-values < 0.024). The Fasting Group, compared to the Re-feeding Group, showed a significantly higher probability to avoid the CS+av. B) Individual relief ratings were higher at the offset of the CS+av and followed a rPE-like learning trajectory: high relief ratings during the first unexpected omissions of the US and lower ratings recorded at the end of the learning phase (Trial: β = - 0.180, ± 0.055, df = 48.141, t = - 3.287, p = 0.002, %95 CIs [- 0.287:- 0.072], RESI = 0.386). There was also an expected significantly lower relief for the safe CS- versus the CS+av (CS: β = - 0.965, ± 0.287, df = 47.954, t = - 3.367, p = 0.002, %95 CIs [- 1.526:- 0.404], RESI = 0.425). No Group-related differences were found in the relief ratings recorded for each CS. This model also included the avoidance actions performed for the CS-. The results did not change when this covariate was removed from the analysis. Error bars represent the standard error of the mean, while the lines represent the models fit.

The avoidance profiles of the Fasting Group (left panel) and the Re-feeding Group (right panel), during the previous behavioral (dashed lines) and the present fMRI (continuous lines) studies. The Fasting Group showed an increase in general avoidance behaviors in the MRI environment.

The relief pleasantness ratings for the Fasting Group (FG, continuous lines) and the Re-feeding Group (RG, dashed lines). Resembling the trajectory of a rPE, general relief significantly decreased over the trials (Trial: β = - 0.431 ± 0.083, df = 43.988, t = - 5.200, p < 0.001, 95% CIs [- 0.582:- 0.279], RESI = 0.757), and was significantly lower for the CS- (β = - 1.352 ± 0.144, df = 640.000, t = - 9.357, p < 0.001, 95% CIs [- 1.634:- 1.069], RESI = 0.442). Additionally, the Fasting Group showed a significantly faster decrease in relief than the Re-feeding Group. Error bars represent the standard error of the mean, while the lines represent the model fit for each CS.

A) The percentage change in BOLD signal in the vmPFC (left graph) and Nac (right graph) in response to US omissions at the CS- versus CS+av offsets for both the Fasting Group (FG, in orange) and the Re-feeding Group (RG, in blue). Compared to the Re-feeing Group, the Fasting Group showed a significantly smaller differential brain activation driven by the expected reduction in vmPFC and Nac activity in response to the CS-. B) The results from the amplitude modulation in AFNI showed a positive modulation of the relief rating on the activation of the Nac during the CS-offsets in the Re-feeding Group only. In the Fasting Group, the main activation for the CS-offset and the relief modulation approached a zero value.

The probability of Skin Conductance responding (accumulated average over the trials) in the physiological signal that followed US omissions at the CS- (black) and CS+av (blue) offsets, for both the Re-feeding Group (left panel) and the Fasting Group (right panel). The Fasting Group showed a minimization in the probability of responding, while in the Re-feeding Group the higher probability of responding was explained by higher relief ratings.

A) The general omission of the US (contrast: CS+av plus CS- offsets versus baseline during avoidance learning), elicited significant brain activations similar to those reported in Table S3 for each separated CS vs baseline. Unexpectedly, we did not find activation of the most orbital part of the vmPFC but rather a significant activation in the a32sg of the left vmPFC (peak: x: 2.5, y: -53.5, z: 0.7) which included also the dACC (sagittal sections). There was also a significant activation of the Caudate and Putamen (bilaterally) which activations on the left (peak: x: -28.5, y: -2.5, z: -8.1) extended to the left Nac (axial section), (significant for a cluster extended (FWE-corrected) threshold alpha below 0.05 with an initial p = 0.001 uncorrected). All the brain activations mentioned were significant independent of how many times the participants pressed the button for the CS-. B) Shows the brain activity in response to general US omissions during the fear extinction learning phase: CS+av plus CS- offsets versus baseline. The general omissions of the US elicited significant brain activations similar to those reported in Table S4 for each separated CS vs baseline. We found significant activations in the Caudate and Putamen (bilaterally) (left peak: x: 28.5, y: 2.5, z: -8.1) (axial and coronal sections), in the superior part of the a32 vmPFC (peak: x: -1.5, y: -57.5, z: 11.7) (sagittal section) which included also the dACC, and significant activation of the Insule (right peak: x: -35.5, y: -17.5, z: 5.1). The results were significant for a cluster extended (FWE-corrected) threshold alpha below 0.05 with an initial p = 0.001 uncorrected.