radius2

The squared radius — raw and signed; negative for an imaginary dipole.

pz² − gz² − 2·(gx·py − gy·px): the square of half the distance between the endpoints for a real dipole, exactly zero when they coincide — the limit of the endpoints merging into one point — and negative when no real endpoints exist. To test imaginary-ness use isImaginary, which rounds; comparing this raw value to zero is FP-fragile.