I'm using atan2 to find the distance between two points, following the code in this page: http://www.movable-type.co.uk/scripts/latlong.html
The inputs for atan2 in the "Distance" section of that page can be used in C2 using the angle function, as mentioned by Ashley above. The syntax is angle(0,0,sqrt(1-a),sqrt(a)). On the website, the syntax is atan2(sqrt(a),sqrt(1-a)).
I've been able to get the function working, but the output is off by 10-20%. Not sure what's happening.
Has anyone used this successfully?
Here's my code: