Results for: "match"

Returns the arc tangent of y and x in radians.

Examples:

atan2(-1.0, -1.0) # => -2.356194490192345  # -3*PI/4
atan2(-1.0, 0.0)  # => -1.5707963267948966 # -PI/2
atan2(-1.0, 1.0)  # => -0.7853981633974483 # -PI/4
atan2(0.0, -1.0)  # => 3.141592653589793   # PI

Returns the arc tangent of x.

Examples:

atan(-INFINITY) # => -1.5707963267948966 # -PI2
atan(-PI)       # => -1.2626272556789115
atan(-PI/2)     # => -1.0038848218538872
atan(0.0)       # => 0.0
atan(PI/2)      # => 1.0038848218538872
atan(PI)        # => 1.2626272556789115
atan(INFINITY)  # => 1.5707963267948966  # PI/2

Returns the inverse hyperbolic tangent of x.

Examples:

atanh(-1.0) # => -Infinity
atanh(0.0)  # => 0.0
atanh(1.0)  # => Infinity

Returns the value of the gamma function for x.

Examples:

gamma(-2.5)      # => -0.9453087204829431
gamma(-1.5)      # => 2.3632718012073513
gamma(-0.5)      # => -3.5449077018110375
gamma(0.0)      # => Infinity
gamma(1.0)      # => 1.0
gamma(2.0)      # => 1.0
gamma(3.0)      # => 2.0
gamma(4.0)      # => 6.0
gamma(5.0)      # => 24.0

Related: Math.lgamma.

Returns a 2-element array equivalent to:

[Math.log(Math.gamma(x).abs), Math.gamma(x) < 0 ? -1 : 1]

See logarithmic gamma function.

Examples:

lgamma(-4.0) # => [Infinity, -1]
lgamma(-3.0) # => [Infinity, -1]
lgamma(-2.0) # => [Infinity, -1]
lgamma(-1.0) # => [Infinity, -1]
lgamma(0.0)  # => [Infinity, 1]

lgamma(1.0)  # => [0.0, 1]
lgamma(2.0)  # => [0.0, 1]
lgamma(3.0)  # => [0.6931471805599436, 1]
lgamma(4.0)  # => [1.7917594692280545, 1]

lgamma(-2.5) # => [-0.05624371649767279, -1]
lgamma(-1.5) # => [0.8600470153764797, 1]
lgamma(-0.5) # => [1.265512123484647, -1]
lgamma(0.5)  # => [0.5723649429247004, 1]
lgamma(1.5)  # => [-0.12078223763524676, 1]
lgamma(2.5)      # => [0.2846828704729205, 1]

Related: Math.gamma.

Avoids the potential for a child process to become a zombie process. Process.detach prevents this by setting up a separate Ruby thread whose sole job is to reap the status of the process pid when it terminates.

This method is needed only when the parent process will never wait for the child process.

This example does not reap the second child process; that process appears as a zombie in the process status (ps) output:

pid = Process.spawn('ruby', '-e', 'exit 13') # => 312691
sleep(1)
# Find zombies.
system("ps -ho pid,state -p #{pid}")

Output:

312716 Z

This example also does not reap the second child process, but it does detach the process so that it does not become a zombie:

pid = Process.spawn('ruby', '-e', 'exit 13') # => 313213
thread = Process.detach(pid)
sleep(1)
# => #<Process::Waiter:0x00007f038f48b838 run>
system("ps -ho pid,state -p #{pid}")        # Finds no zombies.

The waiting thread can return the pid of the detached child process:

thread.join.pid                       # => 313262

Returns the maximum number of group IDs allowed in the supplemental group access list:

Process.maxgroups # => 32

Sets the maximum number of group IDs allowed in the supplemental group access list.

No documentation available

Compile a AlternationPatternNode node

Dispatch enter and leave events for AlternationPatternNode nodes and continue walking the tree.

Inspect a AlternationPatternNode node.

Copy a AlternationPatternNode node

in foo | bar

No documentation available

Enumerates the outdated local gems yielding the local specification and the latest remote version.

This method may take some time to return as it must check each local gem against the server’s index.

Returns a Hash containing the following keys:

:accept

Number of started SSL/TLS handshakes in server mode

:accept_good

Number of established SSL/TLS sessions in server mode

:accept_renegotiate

Number of start renegotiations in server mode

:cache_full

Number of sessions that were removed due to cache overflow

:cache_hits

Number of successfully reused connections

:cache_misses

Number of sessions proposed by clients that were not found in the cache

:cache_num

Number of sessions in the internal session cache

:cb_hits

Number of sessions retrieved from the external cache in server mode

:connect

Number of started SSL/TLS handshakes in client mode

:connect_good

Number of established SSL/TLS sessions in client mode

:connect_renegotiate

Number of start renegotiations in client mode

:timeouts

Number of sessions proposed by clients that were found in the cache but had expired due to timeouts

Enables use of shared session key material in accordance with RFC 5705.

Returns true if key is the corresponding private key to the Subject Public Key Information, false otherwise.

No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
No documentation available
Search took: 5ms  ·  Total Results: 2599