# Situationally Sensitive Path Planning
## 4 Methodology
### Global Environment Layer
#### 4.1.4 Situational Preference-Based Path Planning: Cost and Shortest Path Calculations  
Let us consider the global environmental layer's graph \(G\) and an agent \(a\in A\). When agent \(a\) performs a path query, the global layer calculates the path by running [PERSON]'s algorithm on a modified instance of the original weighted graph (Algorithm 2). This modified instance contains personalized edge costs calculated from both environmental and agent personality factors. This instance calculation is performed prior to [PERSON]'s algorithm returning the shortest path (Algorithm 3). \[ \begin{split} C(s,a)&=s_{base}\\ +&(s_{dist}\cdot a_{dist})\\ +&\left(\frac{s_{pop}}{s_{area}}\cdot a_{density} \right)\\ +&(s_{dirt}\cdot a_{dirt})\\ +&\left(s_{safe}\cdot a_{safe}\right)\end{split}  \tag{1}\]  
```
procedure\(CalculateCosts(Graph\ G,\ agent\ a)\) \(E\leftarrow[]\) for\(\{(u,v)\ |\ u\in G,\ v\in G,\ (u,v)\in G.Edges\}\)do \(c_{dist}\gets s_{dist}\cdot a_{dist}\) \(c_{density}\leftarrow\frac{s_{seg



### Local Agent Layer

The local agent layer consists of individual agent entities that conduct their autonomous, independent, and perspective-dependent motion via synthetic visual fields, RVO-based inter-agent collision avoidance, and internally held scalar values that represent preferences during path determination. #### 4.2.1 Synthetic Visual Fields

Briefly states, our model considers vision as an event-driven system rather than a global knowledge system: agents are visible to other agents if their mesh colliders intersect with the other agents' view frustum colliders (see the collision inset illustration in Figure 3). Agents' synthetic visual fields are represented as monocular view frustums that egocentrically follow agents' forward orientation and position. These view frustums appear as sideways square pyramids, with a 160-degree total horizontal spread and a 130-degree total vertical spread. For simplicity, we assume that the agents' field of view (FOV) is purely horizontal in nature. Rather than using Unity3D's Camera component, we employ Unity3D's PhysX collision logic and treat view frustums and agent meshes as convex colliders. #### 4.2.2 RVO-Based Local Collision Avoidance

We employ RVO for agent collision avoidance at very localized resolutions. The Reciprocal Velocity Obstacles method is one of several velocity-based local collision avoidance models derived from [PERSON]'s Velocity Obstacles [108; 109; 110]. RVO proceeds from one important assumption: in a paired scenario with two agents \(A\) and \(B\) heading into a collision course, both agents will actively adjust their velocities to avoid collisions (Figure 3). This is well understood in behavioral science, following significant observational work in proxemics and inter-personal social effects. RVO reflects situational proxemics, particularly by introducing the idea of \"shared responsibility\" between agents, rather than putting all the onus on one agent, as is in the VO paradigm. This sharing of the small bundle of space and time that can open up ahead of a potential collision has important corollaries in the conceptual literature, particularly in social psychology of shared gaze and the exchange of non-verbal communications as body language signals among mobile pedestrians in encounter-based dyads. Consider two agents \(A\) and \(B\) with positions \(p_{A}\), \(p_{B}\) current velocities \(v_{A},v_{B}\), and preferred velocities \(v^{pred}_{A},v^{pred}_{B}\). The generalized form of \(RVO^{A}_{B}\) is defined as follows:

\[RVO^{A}_{B}\left(v_{B},v_{a},a^{A}_{B}\right)=\left\{v^{\prime}_{A}\middle| \frac{1}{a^{A}_{B}}v^{\prime}_{A}+\left(1-\frac{1}{a^{A}_{B}}\right)v_{A}\in VO ^{A}_{B}(v_{B})\right\} \tag{2}\]

Observe the parameter \(\alpha^{A}_{B}\in[0,\ 1]\), which incorporates agent \(A\)'s willingness to share responsibility with other agents. As this weight approaches 1, the RVO operation more closely resembles the original VO formulation.