Shared Locking
Change Scalar to double because wtf
Calculates the angle between two functions