## 2 Electromagnetic Testing Principle  
A general principle of the proposed method is shown in Figure 1. The system has three main blocks: an electromagnetic testing probe, signal processing unit, and auto-detection algorithm based on machine learning techniques. The sensor probe has a multiple C-slice core shape made of silicon steel with a copper coil supplied by an alternating current to produce an alternating magnetic field (\(B_{o}\)) according to [PERSON]'s law. An eddy current in the multilayer is then produced according to [PERSON]'s law. The eddy current penetrates into the specimen according to the skin effect, which is inversely proportional to the exciting frequency. The strength of the eddy current decreases exponentially with the depth from the surface of the specimen. Thus, the exciting frequency is calculated so that the eddy current can penetrate the hidden corrosion depth. The eddy current is distorted by the presence of the rivet and hidden corrosion and produces the secondary magnetic field (\(B_{z}\)). The \(B_{z}\) could be measured by the Hall sensor array at the center of the C-core. The measured magnetic field \(B_{z}\) is in the vertical direction as the sensitive direction of the Hall sensors. The alternating output voltage of the Hall sensor array is low-pass filtered (LPF) and amplified before converting to DC voltage by the root-mean-square (RMS) circuits. The number of LPF, amplifier and RMS circuits is the same as the number of Hall sensor elements for simultaneous signal processing. The signal is then digitalized by a data acquisition device (National Instrument DAQ) and transferred to a computer. Support, \(f\), \(\delta\), \(\mu\), \(\alpha\), and \(B_{zo}\) are the exciting frequency of the coil, electrical conductivity, permeability of specimen, phase shift of magnetic field, and am amplitude of the total magnetic field in the vertical direction. The eddy current strength and skin depth are calculated by Equation (1). The output voltage of the Hall sensor element is proportional to the magnetic field as described in Equation (2), where \(k\) and \(l\) are the constant factor and supplied current of the Hall sensor. The measured RMS voltage is then to the magnetic field \(B_{zo}\), as calculated by Equation (3). \[J_{d}=J_{surf}e^{-d/\delta}\quad\text{ with }\quad\delta=1/\sqrt{\pi f\mu\sigma} \tag{1}\]  
\[V_{H}(t)=k\times I\times B_{Z}(t)=k\times I\times B_{z0}Sin(2\pi ft+\alpha) \tag{2}\]  
\[V_{RMS}=\sqrt{\frac{1}{T}\int_{0}^{T}\left[V_{Z}(t)\right]^{2}}dt\approx k \times I\times\frac{1}{\sqrt{2}}B_{z0} \tag{3}\]where \(f\) is the exciting frequency [Hz]; \(\delta\) is the electrical conductivity of specimen [m/S]; \(\mu\) is the absolute permeability of specimen [H/m]; \(J_{surf}\) and \(J_{d}\) are the eddy current on the surface and at depth d from the surface of specimen [A/m], respectively; \(\delta\) is the skin depth [m]; \(B_{z0}\) is the amplitude of magnetic field in vertical direction [T]; \(k\) is the Hall constant [V.(A.mT)-1]; \(V_{H}\) and \(I\) are Hall output voltage and current supply [V], [A]; \(\alpha\) is the phase shift of magnetic field [rad]; and, \(V_{RMS}\) is the root-mean-square of the Hall output voltage [V]. It is noted that the total magnetic field \(B_{z0}\) is the superposition of the magnetic field from the primary magnetic field (\(B_{o}\)), eddy current of the multilayers (\(B_{m}\)), distorted eddy current by the rivet (\(B_{r}\)), and corrosion (\(B_{c}\)). However, the \(B_{o}\) and \(B_{m}\) could be assumed constant, and the variations of \(B_{ro}\) only depend on the superposition of the \(B_{r}\) and \(B_{c}\). The magnetic field from corrosion is usually very small compared to the rivet (\(B_{c}<B_{r}\)); thus, detecting the corrosion is difficult. Another issue is that the amount of data for training the machine-learning model is low due to the expensive and time-consuming experiments.