MinimumCurvature

class geodetic_engine.welltrajectory.MinimumCurvature[source]

Bases: object

Positions along a surveyed wellbore by the minimum curvature method.

Parameters:
  • md (ArrayLike) – Measured depths, strictly increasing, in any length unit.

  • inclination (ArrayLike) – Inclinations from vertical in radians, in [0, pi].

  • azimuth (ArrayLike) – Azimuths in radians, clockwise from the north the offsets are to be referenced to.

Raises:
  • InvalidSurveyError – If there are fewer than two stations, the arrays disagree in length or hold non-finite values, MD does not strictly increase, or an inclination is outside [0, pi].

  • DegenerateSurveyError – If two consecutive stations point in opposite directions.

Example

A quarter circle from vertical to horizontal over 1000 m has radius 2000 / pi:

>>> model = MinimumCurvature([0, 1000], [0, np.pi / 2], [0, 0])
>>> model.stations.offsets[-1].round(3).tolist()
[0.0, 636.62, 636.62]
__init__(md, inclination, azimuth)[source]
property stations: Stations

The surveyed stations with their positions.

property dogleg: FloatArray

Angle turned over each interval, in radians; one fewer than stations.

interpolate(md)[source]

Points on the surveyed arcs at the given measured depths.

A depth equal to a station’s returns that station exactly.

Parameters:

md (ArrayLike) – Measured depths, in any order, within the surveyed interval.

Return type:

Stations

Returns:

One point per depth, in the order given.

Raises:

InvalidSurveyError – If a depth is outside the surveyed interval.

resample(step, *, include_survey=True)[source]

Points every step of MD from the first station to the last.

Parameters:
  • step (float) – Spacing in the unit of MD.

  • include_survey (bool, default: True) – Also keep every surveyed station, flagged as such.

Return type:

Stations

Returns:

The points, in order of MD. The last station is always included.

Raises:

InvalidSurveyError – If step is not positive and finite, or so small that it would give more than a million points.