nl.tudelft.simulation.language.d2
Class Angle

java.lang.Object
  extended by nl.tudelft.simulation.language.d2.Angle

public final class Angle
extends Object

The Angle class presents a number of mathematical utility functions on the angle.

(c) copyright 2002-2005 Delft University of Technology , the Netherlands.

See for project information www.simulation.tudelft.nl/language
License of use: Lesser General Public License (LGPL) , no warranty

Version:
$Revision: 1.1 $ $Date: 2007/01/06 13:25:55 $
Author:
Alexander Verbraeck

Method Summary
static double angle(Point2D p0, Point2D p1)
          Return the 2-pi normalized angle when making an arc from p0 to p1
static double normalize2Pi(double angle)
          Normalize an angle between 0 and 2*pi
static double normalizePi(double angle)
          Normalize an angle between -pi and +pi
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

normalize2Pi

public static double normalize2Pi(double angle)
Normalize an angle between 0 and 2*pi

Parameters:
angle - the angle to normalize
Returns:
normalized angle

normalizePi

public static double normalizePi(double angle)
Normalize an angle between -pi and +pi

Parameters:
angle - the angle to normalize
Returns:
normalized angle

angle

public static double angle(Point2D p0,
                           Point2D p1)
Return the 2-pi normalized angle when making an arc from p0 to p1

Parameters:
p0 - first point
p1 - second point
Returns:
the normalized angle


Copyright © 2002-2011 Delft University of Technology, the Netherlands. All Rights Reserved.