# Sensitivity Analysis of P-Wave Polarization Direction and Velocity Gradient Inversion
## 3 Sensitivity Analysis of Polarization Direction to Relative Velocity Gradient  
Among various optimization methods, gradient-based optimization algorithms are known for their ability to quickly find local optima, which makes them widely applicable in optimization problems [23; 24]. The derivative plays a pivotal role in gradient-based optimization algorithms. It is the cornerstone of gradient-based optimization methods, enabling us to gain insights into the sensitivity and trends of function values with respect to parameter changes, thereby precisely guiding the direction and step size selection for parameter updates [25]. Given the crucial role of derivatives in conventional gradient-based inversion methods, it is crucial to analyze the sensitivity of P-wave polarization direction data to the relative velocity gradients. This analysis not only provides a theoretical foundation for inversion algorithms but also helps us better understand the physical properties of subsurface media. By thoroughly investigating the relationship between P-wave polarization direction and the relative velocity gradient, we can design more efficient optimization strategies, thereby enhancing the accuracy and reliability of inversion results. This lays a solid foundation for subsequent geological interpretation and resource exploration. However, when dealing with P-wave polarization data, the sensitivity analysis becomes particularly complex. Unlike travel-time data, the polarization vector does not follow the stationary principle along the ray path [12]. Therefore, polarization data cannot be linearized along the reference ray as conveniently as travel-time integrals using Fermat's principle. This makes the linearization process for polarization data more challenging and requires more sophisticated methods to handle. Specifically, we need to consider how small variations in the medium parameters along the ray path affect the direction of the polarization vector. Assuming the ray path length \(L\) remains constant, given the small changes in the relative velocity gradient model and other parameters, as well as the small variations in the positions of the ray endpoints and the polarization direction, we can rewrite Equations (5) and (6) in the following form:  
\[\delta\mathbf{r}_{e}=\delta\mathbf{r_{e}}^{\mathbf{r_{b}}}+\delta\mathbf{r_{e}}^{\mathbf{n}}, \tag{8}\]  
\[\delta\mathbf{n}=\delta\mathbf{n}^{\mathbf{g}}+\delta\mathbf{n}^{\mathbf{n_{b}}}, \tag{9}\]  
where \(\delta\mathbf{r_{e}}^{\mathbf{r_{b}}}\), \(\delta\mathbf{r_{e}}^{\mathbf{n}}\), \(\delta\mathbf{n}^{\mathbf{g}}\), and \(\delta\mathbf{n}^{\mathbf{n_{b}}}\) are changes resulting from the variations in \(\mathbf{r_{b}}\), \(\mathbf{n},\mathbf{g}(\mathbf{r})\), and \(\mathbf{n_{b}}\), respectively. From Equations (8) and (9), it is clear that variations in the relative velocity gradient and the ray exit direction can lead to changes in the polarization direction. These changes subsequently affect the positions of the ray endpoints. The positions of the source and receiver are fixed. However, due to changes in the relative velocity gradient, the ray endpoints deviate from the expected receiver positions. To correct this deviation, it is necessary to adjust another parameter (the ray exit direction) that influences the ray endpoint position. This adjustment counteracts the offset caused by the changes in the relative velocity gradient, thereby bringing the ray endpoint back to the receiver's position. To this end, we calculated the changes in the polarization direction caused by variations in the relative velocity gradient in two steps. Firstly, while keeping the source position \(\mathbf{r_{b}}\) and the ray exit direction \(\mathbf{n_{b}}\) fixed, the relative velocity gradient model is slightly changed to obtain changes in the polarization direction and position at the ray endpoints. Then, by appropriately adjusting the exit direction of the ray, the endpoint of the ray is brought back to the receiver position.