DoxigAlpha

atanh

Returns the hyperbolic arc-tangent of x.

Special Cases:

  • atanh(+-1) = +-inf with signal
  • atanh(x) = nan if |x| > 1 with signal
  • atanh(nan) = nan

Function parameters

Parameters

#
x:anytype

Returns the hyperbolic arc-tangent of x.

Functions

#
atanh
Returns the hyperbolic arc-tangent of x.

Source

Implementation

#
pub fn atanh(x: anytype) @TypeOf(x) {
    const T = @TypeOf(x);
    return switch (T) {
        f32 => atanh_32(x),
        f64 => atanh_64(x),
        else => @compileError("atanh not implemented for " ++ @typeName(T)),
    };
}