gemgis.vector.calculate_strike_direction_bent_linestring#

gemgis.vector.calculate_strike_direction_bent_linestring(linestring: shapely.geometry.linestring.LineString) List[float]#

Calculating the strike direction of a LineString with multiple elements

Parameters

linestring (linestring: shapely.geometry.linestring.LineString) – Shapely LineString containing more than two vertices, e.g. linestring = LineString([(0, 0), (10, 10), (20, 20)])

Returns

angles_splitted_linestrings – List containing the strike angles of each line segment of the original

Return type

List[float]

New in version 1.0.x.

Example

>>> # Loading Libraries and creating LineString
>>> import gemgis as gg
>>> from shapely.geometry import LineString
>>> linestring = LineString([(0, 0), (10, 10), (20, 20)])
>>> linestring.wkt
'LINESTRING (0 0, 10 10, 20 20)'
>>> # Calculating the strike angles for LineString elements
>>> angles = gg.vector.calculate_strike_direction_bent_linestring(linestring=linestring)
>>> angles
[45.0, 45.0]

See also

calculate_angle

Calculating the angle of a LineString

calculate_strike_direction_straight_linestring

Calculating the strike direction of a straight LineString

calculate_dipping_angle_linestring

Calculate the dipping angle of a LineString

calculate_dipping_angles_linestrings

Calculate the dipping angles of LineStrings