Java Angle angle(double px, double py, double qx, double qy)

Here you can find the source of angle(double px, double py, double qx, double qy)

Description

angle

License

LGPL

Declaration

public static double angle(double px, double py, double qx, double qy) 

Method Source Code

//package com.java2s;
//License from project: LGPL 

public class Main {
    public static double angle(double px, double py, double qx, double qy) {
        double deltaX = px - qx;
        double deltaY = py - qy;

        double angleInDegrees = Math.atan2(deltaY, deltaX) * 180 / Math.PI;
        return angleInDegrees;
    }//from  w ww .  j  a v  a  2 s.c o m
}

Related

  1. angle(double a, double b)
  2. angle(double aX, double aY, double bX, double bY)
  3. angle(double x1, double y1, double x2, double y2)
  4. angle(double x1, double y1, double x2, double y2)
  5. angle(double x1, double y1, double x2, double y2)
  6. angle(double[] vec1, double[] vec2)