# Immersive Virtual Reality Experience of Historical Events Using Haptics and Locomotion Simulation
## 2 Materials and Methods
### Locomotion Simulation  
From early on [33], it was established that sense of presence is enhanced by using human body movements for locomotion in VR applications. As a result, we wanted to study a body-centric device, which strengthens immersion as it eliminates the real-world limitations and enables the user to wander through unlimited virtual spaces. However, our application already introduced the user to a significant number of devices to utilize, so we wanted a locomotion appliance that would seem the most natural. Furthermore, we wanted the user to be able to move freely while performing other tasks, like interacting with objects or gazing in different directions.  
The solution that required the lowest mental effort and provided a satisfying sense of presence was the VR treadmill as stated in [34]. We utilized a commercial solution [35], which uses a flat, low-friction walking surface and a rotating containment ring, which prevents the user from displacing in the physical space. The orientation of the ring defines the walking direction which can be anywhere between 0 and 360 degrees. The device's ring contains an adjustable belt system so that people with different body types can fit in. Its vertical movement is also flexible and it can adapt to people with different heights.  
However, if the VR treadmill is used for a long period of time, it adds certain fatigue to the user. Therefore, we designed our application in a way that allows the users to rest during their experience, while they still remain engaged and immersed. Specifically, in the underwater scene, the user encounters points of interest on their way, where they can stop and read educative information as shown in Figure 1. Likewise, in the second part of the application, the user, while moving freely on the ship, stops to interact with the different elements provided (the steering wheel, the binoculars, and the Antikythera Mechanism). Consequently, we avoid making the users uncomfortable while moving, thus losing their sense of presence.  
The integration of the treadmill was made feasible with the device's Unreal Software Development Kit (SDK). The user's movement and orientation are detected by the treadmill's sensors while the user's location is identified by the HMD sensors. The sensor's collected data define the following variables:  
* **MovementVector**: a 3-dimensional vector describing the movement speed value in the three different axes. The MovementVector is also multiplied with a user-defined variable called speedMultiplier so that the movement speed can be adjusted to each individual walking style;  
Figure 3: Some of the elements the user can interact with: (**a**) This is the steering wheel the user can grab and navigate the ship (**b**) The reconstructed Antikythera mechanism where the user can rotate the handle and learn about its mechanics.  
* **OrientationVector**: a 4-dimensional vector describing the user's orientation in quaternions. The OrientationVector is transferred to the player's local coordinate system by multiplying it with the corresponding transformation matrix or by using an appropriate function provided by the Unreal's library;
* **UserLocation**: a 3-dimensional vector defining the user's position in the three different axes. The user's final location is updated in each frame and calculated as: \[\begin{split}\mathit{UserLocation}=&\mathit{UserLocation }+(\mathit{MovementVector}\times\\ &\mathit{OrientationVector}\times\mathit{UnrealConstant}\times \mathit{DeltaSeconds}),\end{split}\] (1) where _UnrealConstant_ is a constant variable used for correct unit conversion from the treadmill's input value to Unreal's final output. _DeltaSeconds_, commonly referred to as Delta Time, describes the elapsed time since the previous frame. This is used for a smooth and steady walking animation, regardless of the system's hardware or the scene's complexity.