Welcome to shewchuk’s documentation!

Note

If object is not listed in documentation it should be considered as implementation detail that can change and should not be relied upon.

Robust floating point operations.

class shewchuk.Expansion(_argument: Self | Number = 0.0, *args: float, _compress: bool = True)[source]

Represents floating point number expansion.

property real: Self

The imaginary part of the expansion.

property imag: Number

The real part of the expansion.

shewchuk.incircle_test(_point_x: float, _point_y: float, _first_x: float, _first_y: float, _second_x: float, _second_y: float, _third_x: float, _third_y: float) int[source]

Computes location of point relative to a circle formed by three others given their coordinates.

shewchuk.kind(_vertex_x: float, _vertex_y: float, _first_ray_point_x: float, _first_ray_point_y: float, _second_ray_point_x: float, _second_ray_point_y: float) int[source]

Computes kind of angle given its endpoints coordinates.

shewchuk.orientation(_start_x: float, _start_y: float, _end_x: float, _end_y: float, _point_x: float, _point_y: float) int[source]

Computes orientation of point relative to segment given their coordinates.

shewchuk.vectors_cross_product(_first_start_x: float, _first_start_y: float, _first_end_x: float, _first_end_y: float, _second_start_x: float, _second_start_y: float, _second_end_x: float, _second_end_y: float) Expansion[source]

Computes cross product of two vectors given their endpoints coordinates.

shewchuk.vectors_dot_product(_first_start_x: float, _first_start_y: float, _first_end_x: float, _first_end_y: float, _second_start_x: float, _second_start_y: float, _second_end_x: float, _second_end_y: float) Expansion[source]

Computes dot product of two vectors given their endpoints coordinates.