Example #1
0
        public static double FindAngle(LineSegment fLine, LineSegment sLine)
        {
            var v1 = fLine.ConvertToVector();
            var v2 = sLine.ConvertToVector();

            double scalar = v1.X * v2.X + v1.Y * v2.Y;

            double m1 = FindMagnitude(fLine);
            double m2 = FindMagnitude(sLine);

            return(Math.Acos(scalar / m1 * m2));
        }