Shouldn't these be members of `EllipsoidGeodesic`?  Unless I'm missing something, two instances of `EllipsoidGeodesic` will step on each other because of these global variables and give you wrong answers.