Class: Numeric
Overview
Defined aliases
-
√ – root of arbitrary degree ( x.√( n ) is n ** ( 1 / x ) ).
-
sqrt as in
4.sqrt
for square root (Math#sqrt).
Instance Method Summary collapse
-
#sqrt ⇒ Object
Square root (using Math#sqrt).
-
#√(number) ⇒ Object
Returns n-th root of the argument, where n is the receiver number.
Instance Method Details
#sqrt ⇒ Object
Square root (using Math#sqrt).
67 68 69 |
# File 'lib/y_support/unicode.rb', line 67 def sqrt Math.sqrt( self ) end |
#√(number) ⇒ Object
Returns n-th root of the argument, where n is the receiver number.
61 62 63 |
# File 'lib/y_support/unicode.rb', line 61 def √ number number ** ( 1.0 / self ) end |