Java acot acot(double x)

Here you can find the source of acot(double x)

Description

acot

License

Mozilla Public License

Declaration

public static double acot(double x) 

Method Source Code

//package com.java2s;
/** This Source Code Form is subject to the terms of the Mozilla Public
 * License, v. 2.0. If a copy of the MPL was not distributed with this
 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
 *//*w  w w  . jav a 2 s  .co m*/

public class Main {
    public static double acot(double x) {
        if (x != 0) {
            return Math.atan(1 / x);
        } else {
            throw new ArithmeticException();
        }
    }
}

Related

  1. acot(double x)
  2. acot(final T value)