GeometryOperators#
- class ansys.aedt.core.modeler.geometry_operators.GeometryOperators[source]#
Manages geometry operators.
Methods
GeometryOperators.List2list
(input_list)Convert a C# list object to a Python list.
Determine if the two segments a and b are intersecting.
Return the sum of two vertices lists.
GeometryOperators.atan2
(y, x)Implementation of atan2 that does not suffer from the following issues: math.atan2(0.0, 0.0) = 0.0 math.atan2(-0.0, 0.0) = -0.0 math.atan2(0.0, -0.0) = 3.141592653589793 math.atan2(-0.0, -0.0) = -3.141592653589793 and returns always 0.0.
Convert the axis angle rotation formulation to a quaternion.
GeometryOperators.axis_to_euler_zxz
(x, y, z)Retrieve Euler angles of a frame following the rotation sequence ZXZ.
GeometryOperators.axis_to_euler_zyz
(x, y, z)Retrieve Euler angles of a frame following the rotation sequence ZYZ.
Retrieve a string for a coordinate system axis.
Retrieve a string for a coordinate system plane.
Retrieve a string for a coordinate system plane.
Return x_pointing and y_pointing vectors as expressions from the yaw, ptich, and roll input (as strings).
GeometryOperators.deg2rad
(angle)Convert the angle from degrees to radians.
Convert angle to degree with given digits rounding.
Ceil of angle.
GeometryOperators.distance_vector
(p, a, b)Evaluate the vector distance between point
p
and a line defined by two points,a
andb
.Retrieve the draft type.
Convert the Euler angles following rotation sequence ZXZ to a quaternion.
Convert the Euler angles following rotation sequence ZYZ to a quaternion.
GeometryOperators.find_closest_points
(...[, tol])Given a list of points, finds the closest points to a reference point.
GeometryOperators.find_largest_rectangle_inside_polygon
(polygon)Find the largest area rectangles of arbitrary orientation in a polygon.
GeometryOperators.find_point_on_plane
(pointlists)Find a point on a plane.
GeometryOperators.get_mid_point
(v1, v2)Evaluate the midpoint between two points.
Convert a string to a numeric value.
Evaluate the centroid of a polygon defined by its points.
GeometryOperators.get_triangle_area
(v1, v2, v3)Evaluate the area of a triangle defined by its three vertices.
GeometryOperators.is_between_points
(p, a, b)Check if a point lies on the segment defined by two points.
GeometryOperators.is_collinear
(a, b[, tol])Check if two vectors are collinear (parallel or anti-parallel).
GeometryOperators.is_parallel
(a1, a2, b1, b2)Check if a segment defined by two points is parallel to a segment defined by two other points.
GeometryOperators.is_perpendicular
(a, b[, tol])Check if two vectors are perpendicular.
GeometryOperators.is_point_in_polygon
(point, ...)Determine if a point is inside or outside a polygon, both located on the same plane.
Check if a point projection lies on the segment defined by two points.
Project a segment onto another segment and check if the projected segment is inside it.
Determine if a segment defined by two points
a
andb
intersects a polygon.Return
True
if the number represented by s is zero (i.e very small).GeometryOperators.mirror_point
(start, ...)Mirror point about a plane defining by a point on the plane and a normal point.
Normalize a geometry vector.
GeometryOperators.numeric_cs
(cs_in)Return a list of [x,y,z] numeric values given a coordinate system as input.
GeometryOperators.orient_polygon
(x, y[, ...])Orient a polygon clockwise or counterclockwise.
GeometryOperators.parallel_coeff
(a1, a2, b1, b2)ADD DESCRIPTION.
GeometryOperators.parse_dim_arg
(string[, ...])Convert a number and unit to a float.
GeometryOperators.point_in_polygon
(point, ...)Determine if a point is inside, outside the polygon or at exactly at the border.
Calculate the distance between a point
p
and a segment defined by two pointsa
andb
.Retrieve the axes from the HFSS X axis and Y pointing axis as per the definition of the AEDT interface coordinate system.
Evaluate the distance between two points expressed as their Cartesian coordinates.
GeometryOperators.q_prod
(p, q)Evaluate the product of two quaternions,
p
andq
, defined as: p = p0 + p' = p0 + ip1 + jp2 + kp3.Evaluate the rotation of a vector, defined by a quaternion.
Evaluate the inverse rotation of a vector that is defined by a quaternion.
Convert a quaternion to a rotated frame defined by X, Y, and Z axes.
Convert a quaternion to the axis angle rotation formulation.
Convert a quaternion to Euler angles following rotation sequence ZXZ.
Convert a quaternion to Euler angles following rotation sequence ZYZ.
GeometryOperators.rad2deg
(angle)Convert the angle from radians to degrees.
Convert to radians with given round.
Radian angle ceiling.
Evaluate the angle between two geometry vectors.
GeometryOperators.v_angle_sign
(va, vb, vn[, ...])Evaluate the signed angle between two geometry vectors.
GeometryOperators.v_angle_sign_2D
(va, vb[, ...])Evaluate the signed angle between two 2D geometry vectors.
Evaluate the cross product of two geometry vectors.
GeometryOperators.v_dot
(a, b)Evaluate the dot product between two geometry vectors.
Evaluate the Euclidean norm of a geometry vector.
GeometryOperators.v_points
(p1, p2)Vector from one point to another point.
GeometryOperators.v_prod
(s, v)Evaluate the product between a scalar value and a vector.
GeometryOperators.v_rotate_about_axis
(...[, ...])Evaluate rotation of a vector around an axis.
GeometryOperators.v_sub
(a, b)Evaluate two geometry vectors by subtracting them (a-b).
GeometryOperators.v_sum
(a, b)Evaluate two geometry vectors by adding them (a+b).