Java tan tanD(double arg)

Here you can find the source of tanD(double arg)

Description

tan D

License

Apache License

Declaration

static final public double tanD(double arg) 

Method Source Code

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

public class Main {
    static final public double tanD(double arg) {
        arg = Math.IEEEremainder(arg, 360.0);

        // check for infinity cases
        if (arg / 90.0 == 1.0)
            return Double.POSITIVE_INFINITY;
        else if (arg / 90.0 == -1.0)
            return Double.NEGATIVE_INFINITY;
        else/*from  w w w  .j  a v  a  2s .c  o m*/
            return Math.tan(Math.toRadians(arg));
    }
}

Related

  1. tan(float angle)
  2. tan(float f)
  3. tan(int f)
  4. tan(Number x)
  5. tan(Short a)
  6. tand(double x)
  7. tanf(float f)
  8. tanh(double x)
  9. tanh(double x)