## 2 Materials and Methods
### Evaluation of EEG Signals from a Wearable Device  
A wearable device for acquiring EEG signals (model: Amp GS5001; SOSO H&C [25], Kyungpook University, Daegu, Korea) was used for this study. This device was used in three previous published studies on surgeons' and nurses' mental stress [26; 27; 28]. The device consists of a headband, a main board, two dry electrodes as EEG sensors, and a reference electrode. Two electrodes were positioned at the prefrontal 1 and 2 (Fp1 and Fp2) sites according to the International 10-20 EEG system [29]. The reference electrode was placed on the right earlobe (Figure 1).  
The cortical activity of the frontal lobe was measured with the patient in a resting state with eyes open and closed for 3 min each. To reject artifacts caused by eyeball movement, a neurologist specializing in EEG performed a visual inspection. EEG data were reanalyzed using MATLAB R2012b (MathWorks, Inc., Natick, MA, USA) software, and a bandpass filter of 1-50 Hz was applied to the fast Fourier transform. Data analysis using the software was performed by SOSO H&C after anonymization, and the company was blinded to the study. The frequency power was calculated as the square of the amplitudes for delta (0.5-3.5 Hz), theta (4-7 Hz), alpha (8-12 Hz), SMR (12-15 Hz), mid-range beta (M-beta, 15-20 Hz), high-range beta (H-beta, 20-30 Hz), and gamma waves (30-50 Hz) [30]. Relative frequency power was calculated as the ratio of the corresponding frequency powers to the whole frequency (Figure 2). In addition, we calculated the tension index using the following formula from SOSO H&C based on references for tension [27; 31]:  
\[\text{Tension}=\left\{\text{[Log(H-Beta/Alpha)+1.0843]/2.058993]}\times 99+1\right. \tag{1}\]  
All patients were assessed three times: preoperatively (baseline), within 1 week postoperatively, and 3 months postoperatively. All data meas  
Figure 1: (**A**) Profile of the wearable device. (**B**) The device shown on the patient’s head.  
Figure 2: (**A**) Raw and (**B**) reanalyzed EEG signals, according to the frequency bands displayed in the MATLAB software. (**C**) EEG waveforms, according to the frequency bands. EEG: electroencephalography.  
the same manner. The patients waited 1 min while wearing the device in a resting state, and the EEG data were collected with the eyes open and closed for 3 min each. The patients were seated, in a distraction-free environment, and a research nurse who was familiar with the measurement methods measured the EEG data using the device. For the baseline and 3 months after surgery, the measurements were performed in an empty outpatient clinic room, while the measurement within 1 week after surgery was performed in a ward room. Baseline EEG data were obtained one day before surgery for admitted patients. Data were then gathered 1-7 days after surgery when the patients were diagnosed with delirium by psychiatrists. The average presentation time of delirium symptoms was 2 days after surgery. Through consultation with psychiatrists and prompt communication with ward nurses, research nurses, and residents, EEG signals in patients with delirium were measured immediately after the presentation of delirium symptoms with the consent of the patients' guardians. If the measurement was impossible because the patient was excessively hyperactive and unable to cooperate, the measurement was performed after waiting until the agitation subsided. After discharge, data were gathered at the three-month outpatient follow-up visit. Percentage changes in data from baseline to within 1 week after surgery and from baseline to 3 months after surgery were compared between the delirium and non-delirium groups.