intersection_circlesIntersectionCirclesIntersectionCirclesintersection_circlesintersection_circles
Short description
intersection_circlesIntersectionCirclesIntersectionCirclesintersection_circlesintersection_circles — Calculate the intersection points of two circles or circular arcs
Signature
intersection_circles( circle.center.y Circle1Row, circle.center.x Circle1Column, circle.radius Circle1Radius, angle.rad Circle1StartPhi, angle.rad Circle1EndPhi, string Circle1PointOrder, circle.center.y Circle2Row, circle.center.x Circle2Column, circle.radius Circle2Radius, angle.rad Circle2StartPhi, angle.rad Circle2EndPhi, string Circle2PointOrder, out point.y Row, out point.x Column, out integer IsOverlapping )void IntersectionCircles( const HTuple& Circle1Row, const HTuple& Circle1Column, const HTuple& Circle1Radius, const HTuple& Circle1StartPhi, const HTuple& Circle1EndPhi, const HTuple& Circle1PointOrder, const HTuple& Circle2Row, const HTuple& Circle2Column, const HTuple& Circle2Radius, const HTuple& Circle2StartPhi, const HTuple& Circle2EndPhi, const HTuple& Circle2PointOrder, HTuple* Row, HTuple* Column, HTuple* IsOverlapping )static void HOperatorSet.IntersectionCircles( HTuple circle1Row, HTuple circle1Column, HTuple circle1Radius, HTuple circle1StartPhi, HTuple circle1EndPhi, HTuple circle1PointOrder, HTuple circle2Row, HTuple circle2Column, HTuple circle2Radius, HTuple circle2StartPhi, HTuple circle2EndPhi, HTuple circle2PointOrder, out HTuple row, out HTuple column, out HTuple isOverlapping )def intersection_circles( circle_1row: Union[float, int], circle_1column: Union[float, int], circle_1radius: Union[float, int], circle_1start_phi: float, circle_1end_phi: float, circle_1point_order: str, circle_2row: Union[float, int], circle_2column: Union[float, int], circle_2radius: Union[float, int], circle_2start_phi: float, circle_2end_phi: float, circle_2point_order: str ) -> Tuple[Sequence[float], Sequence[float], int]
def intersection_circles_s( circle_1row: Union[float, int], circle_1column: Union[float, int], circle_1radius: Union[float, int], circle_1start_phi: float, circle_1end_phi: float, circle_1point_order: str, circle_2row: Union[float, int], circle_2column: Union[float, int], circle_2radius: Union[float, int], circle_2start_phi: float, circle_2end_phi: float, circle_2point_order: str ) -> Tuple[float, float, int]Herror intersection_circles( double Circle1Row, double Circle1Column, double Circle1Radius, double Circle1StartPhi, double Circle1EndPhi, const char* Circle1PointOrder, double Circle2Row, double Circle2Column, double Circle2Radius, double Circle2StartPhi, double Circle2EndPhi, const char* Circle2PointOrder, double* Row, double* Column, Hlong* IsOverlapping )
Herror T_intersection_circles( const Htuple Circle1Row, const Htuple Circle1Column, const Htuple Circle1Radius, const Htuple Circle1StartPhi, const Htuple Circle1EndPhi, const Htuple Circle1PointOrder, const Htuple Circle2Row, const Htuple Circle2Column, const Htuple Circle2Radius, const Htuple Circle2StartPhi, const Htuple Circle2EndPhi, const Htuple Circle2PointOrder, Htuple* Row, Htuple* Column, Htuple* IsOverlapping )
Description
intersection_circlesIntersectionCircles calculates the intersection points of two
circles or circular arcs. The points, if any, are returned in
(Rowrowrow,Columncolumncolumn). The circles are defined by their center
(Circle1Rowcircle1Rowcircle_1row,Circle1Columncircle1Columncircle_1column), and
(Circle2Rowcircle2Rowcircle_2row,Circle2Columncircle2Columncircle_2column) respectively, and their radii
Circle1Radiuscircle1Radiuscircle_1radius, and Circle2Radiuscircle2Radiuscircle_2radius respectively.
In addition to that, a circular arc is characterized by the angle of the
start point (Circle1StartPhicircle1StartPhicircle_1start_phi,Circle2StartPhicircle2StartPhicircle_2start_phi),
the angle of the end point (Circle1EndPhicircle1EndPhicircle_1end_phi,Circle2EndPhicircle2EndPhicircle_2end_phi),
and the point order (Circle1PointOrdercircle1PointOrdercircle_1point_order,Circle2PointOrdercircle2PointOrdercircle_2point_order)
along the boundary.
If Circle1PointOrdercircle1PointOrdercircle_1point_order is set to 'positive'"positive", the circular arc
is defined counterclockwise.
If Circle1PointOrdercircle1PointOrdercircle_1point_order is set to 'negative'"negative", the circular arc
is defined clockwise.
The same applies for Circle2PointOrdercircle2PointOrdercircle_2point_order.
If both circles or circular arcs have a part in common
IsOverlappingisOverlappingis_overlapping returns the value 1, otherwise 0 is returned.
In this case the endpoints of the mutual arc are returned in
(Rowrowrow,Columncolumncolumn).
Execution information
-
Multithreading type: reentrant (runs in parallel with non-exclusive operators).
-
Multithreading scope: global (may be called from any thread).
-
Processed without parallelization.
Parameters
Circle1Rowcircle1Rowcircle_1row (input_control) circle.center.y → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Row coordinate of the center of the first circle or
circular arc.
Circle1Columncircle1Columncircle_1column (input_control) circle.center.x → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Column coordinate of the center of the first circle or
circular arc.
Circle1Radiuscircle1Radiuscircle_1radius (input_control) circle.radius → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Radius of the first circle or circular arc.
Circle1StartPhicircle1StartPhicircle_1start_phi (input_control) angle.rad → (real)HTuple (double)HTuple (double)floatHtuple (double)
Angle of the start point of the first circle or
circular arc [rad].
Default: 0.00.0
Circle1EndPhicircle1EndPhicircle_1end_phi (input_control) angle.rad → (real)HTuple (double)HTuple (double)floatHtuple (double)
Angle of the end point of the first circle or
circular arc [rad].
Default: 6.283186.28318
Circle1PointOrdercircle1PointOrdercircle_1point_order (input_control) string → (string)HTuple (HString)HTuple (string)strHtuple (char*)
Point order along the first circle or circular arc.
Default: 'positive'"positive"
List of values: 'negative', 'positive'"negative", "positive"
Circle2Rowcircle2Rowcircle_2row (input_control) circle.center.y → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Row coordinate of the center of the second circle or
circular arc.
Circle2Columncircle2Columncircle_2column (input_control) circle.center.x → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Column coordinate of the center of the second circle or
circular arc.
Circle2Radiuscircle2Radiuscircle_2radius (input_control) circle.radius → (real / integer)HTuple (double / Hlong)HTuple (double / int / long)Union[float, int]Htuple (double / Hlong)
Radius of the second circle or circular arc.
Circle2StartPhicircle2StartPhicircle_2start_phi (input_control) angle.rad → (real)HTuple (double)HTuple (double)floatHtuple (double)
Angle of the start point of the second circle or
circular arc [rad].
Default: 0.00.0
Circle2EndPhicircle2EndPhicircle_2end_phi (input_control) angle.rad → (real)HTuple (double)HTuple (double)floatHtuple (double)
Angle of the end point of the second circle or
circular arc [rad].
Default: 6.283186.28318
Circle2PointOrdercircle2PointOrdercircle_2point_order (input_control) string → (string)HTuple (HString)HTuple (string)strHtuple (char*)
Point order along the second circle or circular arc.
Default: 'positive'"positive"
List of values: 'negative', 'positive'"negative", "positive"
Rowrowrow (output_control) point.y(-array) → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)
Row coordinates of the intersection points.
Columncolumncolumn (output_control) point.x(-array) → (real)HTuple (double)HTuple (double)Sequence[float]Htuple (double)
Column coordinates of the intersection points.
IsOverlappingisOverlappingis_overlapping (output_control) integer → (integer)HTuple (Hlong)HTuple (int / long)intHtuple (Hlong)
Do both circles or circular arcs have a part in common?
Result
If the parameters are valid, the operator intersection_circlesIntersectionCircles
returns the value 2 (H_MSG_TRUE).
Module
Foundation