# An Effective Algorithm for Finding Shortest Paths in Tubular Spaces
## 4 The ESP Searching Algorithm Based on Visibility
### Geometric Properties of the ESP in Tubular Space
Then, \((C)\) is the closed surface containing \(\mathbf{M}\) and enclosed by \(\partial\Omega\), \((\alpha)\), and the cross-section of the tube at \(\mathbf{X}\) (see Figure 7 Right). By using the definition of \((C)\), we can deduce from \(\mathbf{X}\) that the VP will go into the inner space of \((C)\). Since the destination \(\Omega\) is outside \((C)\), the particle must pass the boundary of \((C)\) somewhere on \((\alpha)\). However, by applying Corollary 1, the direction vector \(\mathbf{\dot{p}}(s)\) will always point away from \((\alpha)\), thus the particle cannot return to \((\alpha)\) for a passing point. Therefore, the hypothesis (4) cannot be true, then \(\mathbf{Y}\in\sigma_{X}(S)\) (Q.E.D.). \(\Box\)  
Employing the above lemma, theorems and corollaries lead us to an important result regarding the partitions of the ESP inside a tubular space, as shown in Remark 1. **Remark 1**. : _For any type of tubular space, the shortest path \(\mathbf{p}(s)\) can be segmented into three partitions:_  
* _Partition 1_ (_\(\mathbf{P1}\)_) _: Includes points that can see the destination_ \(\mathbf{\Omega}\)_. The direction_ \(\mathbf{\dot{p}}(s)\) _at any point in this partition is always towards_ \(\mathbf{\Omega}\)  
Figure 6: **(Left)** Tube portion between the cross-sections containing \(\mathbf{X}\) and \(\mathbf{Y}\) which can see each other. \((\alpha)\) is an arbitrary plane containing \(\mathbf{X}\mathbf{Y}\) but not containing \(\mathbf{\dot{p}}(s_{X})\). The ESP \(\mathbf{p}(s)\) only changes its direction \(\mathbf{\dot{p}}(s)\) on its geodesic segment(s). \(S\) is an arbitrary cross-section of the tube where the geodesic segment crosses. **(Right)** On the projection view plane that is perpendicular to \((\alpha)\) ((\(\alpha\)) degenerates to a straight line), as \(\mathbf{\dot{p}}(s)\) points outside the envelope of \(S\), it also points away from \((\alpha)\). As \(\mathbf{\dot{p}}(s_{X})\) points away from \((\alpha)\), by mathematical induction, \(\mathbf{\dot{p}}(s)\) will point away from \((\alpha)\), \(\forall s\in[s_{X},s_{Y}]\). Figure 7: Point \(\mathbf{X}\) can see cross-section \(S\). \(\mathbf{Y}\) is the intersection of the direction of the ESP \(\mathbf{\dot{p}}(S_{X})\) and the plane containing \(S\). In \(\beta(S)\) and through \(\mathbf{Y}\), we draw an arbitrary straight line that intersects the visible area \(\sigma_{X}(S)\). Let \(\mathbf{W}\) be the intersection point that is closest to \(\mathbf{Y}\). **(Left)**\(\mathbf{W}\) is in the inner zone of \(S\); **(Right)**\(\mathbf{W}\) is on the boundary of \(S\). * _Partition 2_ (**P2**) : _Includes points that can see the ending cross-section_ \(S_{end}\)_, but cannot see_ \(\mathbf{\Omega}\)_. The direction_ \(\mathbf{\dot{p}}(s)\) _at any point_ **X** _in this partition is always towards a visible point_ **Y** _in the ending cross-section such that the angle between_ **XY** _and_ **X\(\mathbf{\Omega}\)** _is the smallest one._
* _Partition 3_ (**P3**) : _Includes points that cannot see the ending cross-section_ \(S_{end}\)_. The direction of_ \(\mathbf{\dot{p}}(s)\) _at any point in this partition is the positive direction corresponding to the longest length of sight._  
The three partitions of the searching shortest path inside the tube are described in Figure 8. The proof of this remark is given in Appendix A.2. It is important to note that a tube does not necessarily contain all three partitions. For instance, a straight tube only contains partition 1 regardless of the positions of the source and the destination.