Java Utililty Methods tan

List of utility methods to do tan

Description

The list of methods to do tan are organized into topic(s).

Method

doubletan(double a)
Returns the trigonometric tangent of an angle.
return Math.tan(a);
floattan(final float value)
tan
final int temp;
if (value > 0) {
    if ((int) value > 360f) {
        if ((temp = ((int) value - ((int) (value / 360f)) * 360)) != 0) {
            return TG_TABLE[temp];
        } else {
            return TG_TABLE[360];
    } else {
        return TG_TABLE[(int) (value)];
} else if ((-(int) value) > 360f) {
    if ((temp = (-((int) value - ((int) (value / 360f)) * 360))) != 0) {
        return TG_TABLE[temp];
    } else {
        return TG_TABLE[360];
} else {
    return TG_TABLE[-(int) (value)];
floattan(float angle)
tan
return (float) Math.tan(angle);
floattan(float angle)
tan
return sin(angle) / cos(angle);
floattan(float angle)
tan
return (float) Math.tan(angle);
floattan(float f)
tan
return sin(f) / cos(f);
inttan(int f)
tan
int s, c;
s = sin(f);
c = cos(f);
if (c != 0)
    return ((int) (((((long) s) << 32) / c) >> 16));
return s < 0 ? -2147483648 : 2147483647;
doubletan(Number x)
tan
return Math.tan(x.doubleValue());
doubletan(Short a)
Tan.
return Math.tan(a.doubleValue());
doubletanD(double arg)
tan D
arg = Math.IEEEremainder(arg, 360.0);
if (arg / 90.0 == 1.0)
    return Double.POSITIVE_INFINITY;
else if (arg / 90.0 == -1.0)
    return Double.NEGATIVE_INFINITY;
else
    return Math.tan(Math.toRadians(arg));