## 2 Materials and Methods
### Calculation of the Shadow Area of Human Obstacles under Multiple Light Sources
#### 2.2.2 Half-Shadow Calculation of Human Obstacles  
According to the geometric optics theory and mathematical knowledge, in the case of two or more light sources, the obstacle can produce a half shadow, the intersection of all half shadow areas can constitute the full shadow area of the obstacle, and whether the full shadow area exists is related to the relative position of the light source and human body obstacle. When the obstacle was located within the area enclosed by multiple light sources, as shown in Figure 4a,b, the intersection of all half-shaded areas was zero, and the full-shaded area could not be generated. When the obstacle was located outside the area enclosed by multiple light sources, as shown in Figure 4c,d, the intersection of all half-shaded areas was not zero, and there was a full-shaded area of the human obstacle. In the case of multiple light sources, each light source produces a half shadow on the obstacle, and according to the two light sources in Figure 2, the number of half shadows of one obstacle was 2, the number of half shadows of one obstacle of the three light sources in Figure 4 was 3, and the number of half shadows of one obstacle of the four light sources was 4. It can be deduced that under multiple light sources, the number of half shadows produced by each human obstacle is proportional to the number of visible light sources. In addition, since the intersection of multiple sets, as a subset of any set, and the full-shaded area was the intersection of the half-shaded area, it could be seen that with the increase in the number of light sources, the half-shaded area increased, and the full-shaded area decreased when the obstacle position was fixed. The solution of the half-shadow area \(S_{h-s}\) of an obstacle under multiple light sources could be combined with the solution of the shadow matrix \(A\) of a single obstacle with a single light source. We calculated \(N\) shadow matrices \(A_{n}\) generated by \(N\) light sources for a single obstacle. Then, \(N\) shadow matrices \(A_{n}\) were added to obtain the total shadow matrix \(T_{m-s}\) generated by an obstacle under \(N\) light sources. The total shadow matrix \(T_{m-s}\) could be expressed as the following formula. \[T_{m-s}(x,y,n)=\sum_{n=1}^{\text{N}}A_{n}(x,y) \tag{20}\]  
where \(A_{n}\) is the shadow matrix generated by the \(n\)-th light source to an obstacle in the receiving plane. Figure 4: Two-dimensional plane projection of full shadows and half shadows generated by obstacles under different light sources. (**a**) One obstacle located in the three light sources; (**b**) One obstacle located in four light sources; (**c**) One obstacle located outside in the three light sources; (**d**) One obstacle located outside the three light sources. The number of rectangular grids \(W_{m-s}\) whose value was not 0 and not \(N\) in the total shadow matrix \(T_{m-s}\) was counted. If the value was not 0, the rectangular grid was blocked by a shadow; if the value was not \(N\), the rectangular grid with a full shadow region could not be considered. The half-shadow area \(S_{h-s}\) generated by an obstacle under multiple light sources is shown in the following equation:  
\[S_{h-s}=W_{m-s}\times S_{rect} \tag{21}\]  
The calculation of the half-shadow area of multiple obstacles under multiple light sources could be solved according to the calculation method of the half-shadow area of one obstacle under multiple light sources. First, according to the solution method of the total shadow matrix of one obstacle under multiple light sources, the \(M\) shadow matrices \(T_{m-s}\) generated by multiple light sources for \(M\) obstacles could be obtained. After the addition of \(M\) shadow matrices \(T_{m-s}\), the number of rectangular grids \(W_{m-m}\) whose value was not 0 and not \(N\) in the total shadow matrix was counted. Finally, the number of shadow grids \(W_{m-m}\) was substituted into Formula (6) to calculate the half-shadow area \(S_{h-m}\) of multiple obstacles under multiple light sources.