Table of Contents

Method ManhattanDistanceTo

Namespace
LMKit.Graphics.Geometry
Assembly
LM-Kit.NET.dll

ManhattanDistanceTo(Point)

Calculates the Manhattan distance (L1 norm) from this point to another point.

public double ManhattanDistanceTo(Point other)

Parameters

other Point

The target point.

Returns

double

The Manhattan distance |X - other.X| + |Y - other.Y|.

Remarks

This is a convenience instance wrapper over ManhattanDistance(Point, Point).

ManhattanDistanceTo(IPoint)

Calculates the Manhattan distance (L1 norm) from this point to another point provided via IPoint.

public double ManhattanDistanceTo(IPoint other)

Parameters

other IPoint

The target point.

Returns

double

The Manhattan distance |X - other.X| + |Y - other.Y|.

Remarks

This is a convenience instance wrapper over ManhattanDistance(IPoint, IPoint).