/// <summary> /// Crosses the product. /// </summary> /// <param name="point">The point.</param> /// <returns>Point3D.</returns> public Point3D CrossProduct(Point3D point) { double[] matrix = VectorLibrary.CrossProduct(X, Y, Z, point.X, point.Y, point.Z); return(new Point3D(matrix[0], matrix[1], matrix[2])); }
/// <summary> /// Dots the product. /// </summary> /// <param name="point">The point.</param> /// <returns>System.Double.</returns> public double DotProduct(Point3D point) { return(VectorLibrary.DotProduct(X, Y, Z, point.X, point.Y, point.Z)); }
/// <summary> /// Returns the angle [radians] between the two vectors. /// </summary> /// <param name="vector">The vector.</param> /// <returns>System.Double.</returns> public double Angle(Vector vector) { return(VectorLibrary.Angle(this, vector)); }
/// <summary> /// Returns the cross product/determinant of the points. /// x1*y2 - x2*y1 /// </summary> /// <param name="point">The point.</param> /// <returns>System.Double.</returns> public double CrossProduct(Point point) { return(VectorLibrary.CrossProduct(X, Y, point.X, point.Y)); }
/// <summary> /// Cross-product of two vectors. /// </summary> /// <param name="vector">The vector.</param> /// <returns>System.Double.</returns> public double CrossProduct(Vector vector) { return(VectorLibrary.CrossProduct(Xcomponent, vector.Xcomponent, Ycomponent, vector.Ycomponent)); }
/// <summary> /// Returns the angle [radians] of a vector from the origin axis (x, positive, +ccw). /// </summary> /// <returns>System.Double.</returns> public double Angle() { return(VectorLibrary.Angle(Ycomponent, Xcomponent)); }
/// <summary> /// Returns a value indicating the concavity of the vectors. /// 1 = Pointing the same way. /// > 0 = Concave. /// 0 = Orthogonal. /// < 0 = Convex. /// -1 = Pointing the exact opposite way. /// </summary> /// <param name="vector">The vector.</param> /// <returns>System.Double.</returns> public double ConcavityCollinearity(Vector vector) { return(VectorLibrary.ConcavityCollinearity(this, vector)); }
/// <summary> /// True: The convex side of the vector is inside the shape. /// This is determined by the direction of the vector. /// </summary> /// <param name="vector">The vector.</param> /// <returns><c>true</c> if XXXX, <c>false</c> otherwise.</returns> public bool IsConvexInside(Vector vector) { return(VectorLibrary.IsConvexInside(this, vector, Tolerance)); }
/// <summary> /// True: Segments are parallel, on the same line, oriented in the opposite direction. /// </summary> /// <param name="vector">The vector.</param> /// <returns><c>true</c> if [is collinear opposite direction] [the specified vector]; otherwise, <c>false</c>.</returns> public bool IsCollinearOppositeDirection(Vector vector) { return(VectorLibrary.IsCollinearOppositeDirection(this, vector, Tolerance)); }
/// <summary> /// Vectors form a 90 degree angle. /// </summary> /// <param name="vector">The vector.</param> /// <returns><c>true</c> if the specified vector is orthogonal; otherwise, <c>false</c>.</returns> public bool IsOrthogonal(Vector vector) { return(VectorLibrary.IsOrthogonal(this, vector, Tolerance)); }
/// <summary> /// Vectors form a concave angle. /// </summary> /// <param name="vector">The vector.</param> /// <returns><c>true</c> if the specified vector is concave; otherwise, <c>false</c>.</returns> public bool IsConcave(Vector vector) { return(VectorLibrary.IsConcave(this, vector)); }