radiansToPercentage function
Implementation
double radiansToPercentage(double radians) {
/// we have an inconsistency of pi/2 in terms of percentage and radians
var normalized = radians < 0 ? -radians : 2 * pi - radians;
var percentage = ((100 * normalized) / (2 * pi));
return (percentage + 25) % 100;
}