public double getBondLength() {
        double epsilon = 1e-3;
        PharmacophoreAtom atom1 = (PharmacophoreAtom) getAtom(0);
        PharmacophoreAtom atom2 = (PharmacophoreAtom) getAtom(1);
        PharmacophoreAtom atom3 = (PharmacophoreAtom) getAtom(2);

        double a2 = atom3.getPoint3d().distanceSquared(atom1.getPoint3d());
        double b2 = atom3.getPoint3d().distanceSquared(atom2.getPoint3d());
        double c2 = atom2.getPoint3d().distanceSquared(atom1.getPoint3d());

        double cosangle = (b2 + c2 - a2) / (2 * Math.sqrt(b2) * Math.sqrt(c2));
        if (-1.0 - epsilon < cosangle && -1.0 + epsilon > cosangle) return 180.0;
        if (1.0 - epsilon < cosangle && 1.0 + epsilon > cosangle) return 0.0;

        return Math.acos(cosangle) * 180.0 / Math.PI;
    }
public double getBondLength ( ) { double epsilon = 1e-3 ; PharmacophoreAtom atom1 = ( PharmacophoreAtom ) getAtom ( 0 ) ; PharmacophoreAtom atom2 = ( PharmacophoreAtom ) getAtom ( 1 ) ; PharmacophoreAtom atom3 = ( PharmacophoreAtom ) getAtom ( 2 ) ; double a2 = atom3 . getPoint3d ( ) . distanceSquared ( atom1 . getPoint3d ( ) ) ; double b2 = atom3 . getPoint3d ( ) . distanceSquared ( atom2 . getPoint3d ( ) ) ; double c2 = atom2 . getPoint3d ( ) . distanceSquared ( atom1 . getPoint3d ( ) ) ; double cosangle = ( b2 + c2 - a2 ) / ( 2 * Math . sqrt ( b2 ) * Math . sqrt ( c2 ) ) ; if ( - 1.0 - epsilon < cosangle && - 1.0 + epsilon > cosangle ) return 180.0 ; if ( 1.0 - epsilon < cosangle && 1.0 + epsilon > cosangle ) return 0.0 ; return Math . acos ( cosangle ) * 180.0 / Math . PI ; }
Get the angle between the three pharmacophore groups that make up the constraint.

@return The angle in degrees between the two groups