## 5 Results and Discussion  
### Magnetic Signal Distribution Pattern under the Influence of Residual Stress  
The AC/DC magnetic field analysis module is imported into COMSOL and the magnetization of the welded component is carried out. The stress permeability of the component is analyzed using Equation (9), after which the magnetic signals of the component in the X, Y, and Z directions are derived under the influence of the equivalent residual stress after 1400 s of heat dissipation, as shown in Figure 7a-c.  
From Figure 4d, it can be seen that the equivalent stress in the weld after 1400 s of heat dissipation starts to rise abruptly from the starting point and then shows a decreasing trend around the 10 mm region, after which it starts to rise sharply. In the 50 mm region, the stress reaches 51 MPa, after which the equivalent stress rises slowly with the length of the weld and then decreases sharply after rising to 56 MPa in the 350 mm region. As can be seen in Figure 7a-c, the Z-direction normal component produces an abrupt change in the region of 10-55 mm and then a sharp, abrupt change after 350 mm, but no zero-point phenomenon occurs, while a high-amplitude zero-point phenomenon occurs at the crack- and porosity-type defects at 200 mm, which is due to the significant irregular accumulation of magnetic charge in the crack- and porosity-type defect region, where the magnetic permeability of the defect site is air-type magnetic permeability; thus, the magnetic permeability changes abruptly, resulting in the zero-point phenomenon. The three components in the region of 10-50 mm and the region beyond 350 mm are consistent with each other in the range of the abrupt change in the equivalent effect force, in which the tangential Y component produces a high-amplitude jitter, and its extreme value affects the judgment of the defects to some extent. After that, the three-dimensional magnetic modulus gradient signal is extracted as shown in Figure 4e, and its extreme value exactly corresponds to the center of the defect, and the  
Figure 5: Ultrasonic detection results.  
Figure 6: Three-axis magnetic intensity detection system.  
extreme value of the residual stress-affected region (Figure 7e., in the 10-50 mm region and the region beyond 350 mm) is much lower than the extreme value of the defect region.  
In order to further explore the influence of residual stress on the magnetic signal, a defect of the same size is preset at 50 mm. The magnetic signal components in X, Y, and \(Z\) directions after 1400 s of heat dissipation are shown in Figure 8a-c. The traditional discriminative way is no longer obvious and fails to accurately locate the defect. We invert the 3D magnetic modulus gradient and, in Figure 8e, it can be seen that the 3D magnetic modulus gradient accurately locates the defect at 50 mm.  
The existing theory suggests that the magnetic memory technique can detect defects below the millimeter level. However, it is unknown whether defects below the millimeter level can be detected under residual stress. For this reason, in this paper, the defect size is changed to 0.5 mm long by 0.5 mm wide by 0.5 mm deep and placed at 50 mm, and the magnetic signal after 1400 s heat of dissipation is studied to obtain the three-dimensional magnetic modulus gradient diagram as shown in Figure 9. It can be seen that the extreme value of the three-dimensional magnetic modulus gradient corresponds to 51.33 mm, which is 1.08 mm away from the initially intended location, so the magnetic memory detection technique cannot accurately detect the location of defects below the millimeter level under the influence of residual stress.  
Figure 7: After 1400 s of heat dissipation. (**a**) Normal component \(Z\); (**b**) Tangential component X; (**c**) Tangential component Y; (**d**) Equivalent stress distribution; (**e**) three-dimensional magnetic modulus gradient.