Skip to content

Commit

Permalink
Merge pull request #17871 from JuliaLang/ksh/doctrig2
Browse files Browse the repository at this point in the history
Even MORE trig doc movement...
  • Loading branch information
tkelman authored Aug 8, 2016
2 parents a141ccf + 2912c9e commit ad15fc9
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 55 deletions.
49 changes: 0 additions & 49 deletions base/docs/helpdb/Base.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,6 @@ Raises a `SystemError` for `errno` with the descriptive string `sysfunc` if `ift
"""
systemerror

"""
digamma(x)
Compute the digamma function of `x` (the logarithmic derivative of `gamma(x)`)
"""
digamma

"""
fill!(A, x)
Expand Down Expand Up @@ -976,13 +969,6 @@ seeding.
"""
srand

"""
acot(x)
Compute the inverse cotangent of `x`, where the output is in radians.
"""
acot

"""
oftype(x, y)
Expand Down Expand Up @@ -2640,13 +2626,6 @@ Get the concrete type of `x`.
"""
typeof

"""
acsc(x)
Compute the inverse cosecant of `x`, where the output is in radians
"""
acsc

"""
log(x)
Expand Down Expand Up @@ -3059,13 +3038,6 @@ Element-wise less-than-or-equals comparison operator.
"""
Base.:(.<=)

"""
asec(x)
Compute the inverse secant of `x`, where the output is in radians.
"""
asec

"""
rank(M)
Expand Down Expand Up @@ -4925,13 +4897,6 @@ recurses infinitely.
"""
StackOverflowError

"""
acsch(x)
Compute the inverse hyperbolic cosecant of `x`.
"""
acsch

"""
process_running(p::Process)
Expand Down Expand Up @@ -5689,13 +5654,6 @@ Read a UDP packet from the specified socket, and return the bytes received. This
"""
recv

"""
acoth(x)
Compute the inverse hyperbolic cotangent of `x`.
"""
acoth

"""
det(M)
Expand Down Expand Up @@ -6038,13 +5996,6 @@ the integrity and correctness of data read from `stream`.
"""
deserialize

"""
asech(x)
Compute the inverse hyperbolic secant of `x`.
"""
asech

"""
ismarked(s)
Expand Down
17 changes: 13 additions & 4 deletions base/special/trig.jl
Original file line number Diff line number Diff line change
Expand Up @@ -319,11 +319,20 @@ for (finv, f) in ((:sec, :cos), (:csc, :sin), (:cot, :tan),
end
end

for (fa, fainv) in ((:asec, :acos), (:acsc, :asin), (:acot, :atan),
(:asech, :acosh), (:acsch, :asinh), (:acoth, :atanh))
for (tfa, tfainv, hfa, hfainv, fn) in ((:asec, :acos, :asech, :acosh, "secant"),
(:acsc, :asin, :acsch, :asinh, "cosecant"),
(:acot, :atan, :acoth, :atahn, "cotangent"))
tname = string(tfa)
hname = string(hfa)
@eval begin
($fa){T<:Number}(y::T) = ($fainv)(one(T) / y)
($fa){T<:Number}(y::AbstractArray{T}) = ($fainv)(one(T) ./ y)
@doc """
$($tname)(x)
Compute the inverse $($fn) of `x`, where the output is in radians. """ ($tfa){T<:Number}(y::T) = ($tfainv)(one(T) / y)
($tfa){T<:Number}(y::AbstractArray{T}) = ($tfainv)(one(T) ./ y)
@doc """
$($hname)(x)
Compute the inverse hyperbolic $($fn) of `x`. """ ($hfa){T<:Number}(y::T) = ($hfainv)(one(T) / y)
($hfa){T<:Number}(y::AbstractArray{T}) = ($hfainv)(one(T) ./ y)
end
end

Expand Down
2 changes: 1 addition & 1 deletion doc/manual/integers-and-floating-point-numbers.rst
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,7 @@ only as a storage format. In calculations they'll be converted to ``Float32``:
2

julia> 2*Float16(4.)
8.0f0
Float16(8.0)

The underscore ``_`` can be used as digit separator:

Expand Down
2 changes: 1 addition & 1 deletion doc/stdlib/math.rst
Original file line number Diff line number Diff line change
Expand Up @@ -664,7 +664,7 @@ Mathematical Functions

.. Docstring generated from Julia source
Compute the inverse cosecant of ``x``\ , where the output is in radians
Compute the inverse cosecant of ``x``\ , where the output is in radians.

.. function:: acot(x)

Expand Down

0 comments on commit ad15fc9

Please sign in to comment.