## 2 Materials and Methods
### Hardware and Software
#### 2.2.3 Equivalent Steering Angle Prediction Based on a BP Data Network  
A BP neural network can provide non-linear mapping which approximates a given mapping function from input to output. When considering the equivalent steering angle and steering angle sensor, it is difficult to establish a direct logical relationship for the inde  
Figure 3: Bicycle model adapted to paddy field management machine.  
pendent steering state of the front wheels; however, equivalent steering angle prediction using a BP neural network is feasible.  
Therefore, in this study, a BP neural network was used to achieve equivalent steering angle prediction, where gradient search technology was adopted in the learning process of the network to correct the weights through back-propagation of the errors, in order to minimize the difference between the actual and expected output of the network. Figure 4 shows a BP network model with a hidden layer, where \(\delta_{i}\) are the input units (which can be one of many characteristic parameters, such as the wheel wobble amplitude, frequency, speed, or body attitude), \(V_{j}\) are the hidden layer units (which are related to the weights \(\omega_{ij}\) obtained from network training), and \(\mathcal{Q}_{1}\) is the output (which is the equivalent steering angle of the front wheel of the machinery).  
Considering inputs \(\delta\), the input to a hidden layer unit \(V_{i}\) can be expressed as:  
\[r_{j}=\sum_{k=1}^{m}w_{jk}\delta_{k}, \tag{9}\]  
The output of hidden layer unit \(V_{i}\) is:  
\[V_{j}=f(r_{j}), \tag{10}\]  
where the function \(f\) is the activation function, for which non-linear terms are typically introduced to improve the expression ability of the neural network. In this study, we used the Sigmoid activation function.  
The input to the output unit is:  
\[H_{1}=\sum_{q=1}^{j}W_{1q}V_{q}=\sum_{q=1}^{j}W_{1q}f\left(\sum_{k=1}^{m}w_{jk }\delta_{k}\right), \tag{11}\]  
Finally, the output unit also needs to be non-linearized using an activation function, namely,  
\[\mathcal{Q}_{1}=g(H_{1}), \tag{12}\]  
For any input or output unit, the loss function can be used as the index to learn the weights of the hidden layer of the neural network; that is, a new weight can be selected by adding an appropriate \(\Delta\omega\) to the original weight \(\omega\). The gradient descent method can be used to reduce the loss function as much as possible as the number of iterations increases, such that the local minimum value can be ascertained.  
Figure 4: BP neural network structure.  
For the connection weight between an input unit and a hidden layer unit, the chain rule can be used to obtain:  
\[\Delta\omega_{ij}=-\eta\frac{\partial E}{\partial\omega_{ij}}=-\eta\frac{ \partial E}{\partial V_{i}}\frac{\partial V_{i}}{\partial\omega_{ij}}=\eta \xi_{i}\delta_{j}, \tag{13}\]  
\[\text{where }\xi_{i}=f(h_{i})\sum_{i}W_{ij}\xi_{i} \tag{14}\]  
and \(\eta\) is the learning step, which is set according to experience. Similarly, the weight between a hidden layer unit and the output unit can be obtained as follows:  
\[\Delta W_{jk}=-\eta\frac{\partial E}{\partial W_{jk}}=\eta\xi_{j}V_{k}, \tag{15}\]  
\[\xi_{j}=g\big{(}h_{j}\big{)}\big{(}\xi_{j}-\mathcal{Q}_{j}\big{)}. \tag{16}\]  
According to the above, the neural network weight matrix can be obtained using the gradient descent method, based on the input and output layer data:  
\[w_{new}=w_{old}+\Delta w^{\prime}, \tag{17}\]  
\[\Delta w^{\prime}=\{\Delta w,\Delta W\}. \tag{18}\]