public static double distHalf ( double angA , double angB ) { double a = Math . abs ( angA - angB ) ; if ( a <= Math . PI / 2 ) return a ; else return Math . PI - a ; }
Angular distance between two half circle angles .