## 2 Theoretical Analysis
### Governing Differential Equations and Transfer-Matrix Coefficient for Pile in the Free Segment  
For the pile in the free segment above the ground surface, an independent local coordinate system on the \(i\)th discrete segment with subscript \(f\) (Figure 4a) is established. By discretizing the pile length of free segment \(L_{f}\) into \(n_{f}\) parts, the pile length of each discrete segment can be determined as \(h_{f}\left(=L_{f}/n_{f}\right)\), the average axial force \(\overline{N}_{fi}\) of the \(i\)th discrete segment (equal to the axial force emerged in both the upper and lower cross-section) can be formulated by  
\[\overline{N}_{fi}=N_{t}+f_{0}(2i-1)h_{f}/2 \tag{9}\]  
Assuming that the average lateral distributed load \(\overline{q}_{fi}\) acting on the \(i\)th discrete segment is constant and equals to the mean value of that acting on the corresponding upper and lower cross-section yields  
\[\overline{q}_{fi}=\Big{[}q_{f}\Big{(}ih_{f}-h_{f}\Big{)}+q_{f}\Big{(}ih_{f} \Big{)}\Big{]}/2 \tag{10}\]  
The flexural differential equations for the \(i\)th discrete free segment of pile shaft can be readily found based on Figure 4b, which are found to be  
\[\frac{d^{4}y_{fi}}{dz_{fi}^{4}}+\frac{1}{EI_{f}}\frac{d}{dz_{fi}}\Bigg{[} \overline{N}_{fi}\frac{dy_{f}}{dz_{fi}}\Bigg{]}-\frac{\varphi_{IN}}{EI_{f}} \frac{d}{dz_{fi}}\Bigg{[}\overline{N}_{fi}\frac{dy_{fi}}{dz_{fi}}\Bigg{]}= \frac{b_{1}}{EI_{f}}q_{fi} \tag{11}\]  
where the notation \(f\) indicates the free segment for the pile shaft. Furthermore, \(b_{1}\), \(E\), \(I_{f}\) and \(EI_{f}\) are the calculated width, material's elastic modulus, moment of inertia and bending stiffness of the pile shaft in the free segment, respectively. Figure 4: Discretization of free segment and element analysis for a segment. (**a**) Discretization of free segment. (**b**) Element analysis for a segment. Thus, in view of the response continuity for independent discrete segment, the transfer matrix equation for the \(i\)th discrete free segment of the pile shaft can be expressed as  
\[S_{fi}=U_{fi}S_{f(i-1)} \tag{12}\]  
where \(S_{fi}= \begin{bmatrix}y_{fi}&\varphi_{fi}&M_{fi}&Q_{fi}&1\end{bmatrix} ^{T}\)and \(S_{f(i-1)}= \begin{bmatrix}y_{f(i-1)}&\varphi_{f(i-1)}&M_{f(i-1)}&Q_{f(i-1)}&1 \end{bmatrix} ^{T}\) are all 5-by-1 transposed matrices and represent the pile horizontal deformation, axis rotation angle, bending moment and shear force for the \(i\)th upper and \(i-1\)th lower discrete free segment for the pile shaft, respectively. In which \(U_{fi}\) is the transfer matrix coefficient of the \(i\)th discrete free segment for the pile shaft. Let \(\alpha_{fi}^{2}=\overline{N}_{fi}/EI_{f}\), the transfer coefficient matrix \(U_{fi}\) of the \(i\)th discrete free segment for the pile shaft can be obtained as  
\[U_{fi}= \begin{bmatrix}1&\frac{\sin(\alpha_{fi}\varepsilon_{f})}{\alpha_{fi}}& \frac{1-\cos(\alpha_{fi}\varepsilon_{gi})}{N_{fi}}&\frac{\alpha_{fi}\varepsilon _{f}-\sin(\alpha_{fi}\varepsilon_{f})}{N_{fi}\alpha_{fi}}&\chi_{1,fi}\\ 0&\cos(\alpha_{fi}\varepsilon_{fi})&\frac{\alpha_{fi}\sin(\alpha_{fi} \varepsilon_{f})}{N_{fi}}&\frac{1-\cos(\alpha_{fi}\varepsilon_{f})}{N_{fi}}& \chi_{2,fi}\\ 0&\frac{-N_{fi}\sin(\alpha_{fi}\varepsilon_{fi})}{\alpha_{fi}}&\cos(\alpha_{ fi}\varepsilon_{f})&\frac{\sin(\alpha_{fi}\varepsilon_{f})}{a_{fi}}&\chi_{3,fi}\\ 0&0&0&1&\chi_{4,fi}\\ 0&0&0&0&1\end{bmatrix}