AngleExtensions Class
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Provides extension methods for UnitsNet.Angle
public static class AngleExtensions
type AngleExtensions = class
Public Module AngleExtensions
- Inheritance
-
AngleExtensions
Methods
Difference(Angle, Angle) |
Calculate the difference between two angles. Useful to compute the angle error between a desired and an actual track. |
MagneticToTrue(Angle, Angle) |
Convert magnetic angle to true angle, given the variation |
Normalize(Angle, Boolean) |
Normalizes the angle so it is between 0° and 360° or between -180° and +180° respectively. |
TrueToMagnetic(Angle, Angle) |
Helper method to convert a true angle to a magnetic one, given the variation. |
TryAverageAngle(IEnumerable<Angle>, Angle) |
Calculates the average (medium) of a set of points. See https://en.wikipedia.org/wiki/Mean_of_circular_quantities This method fails if an empty input set is provided or the inputs are evenly distributed over the circle. |